Bentley Communities
Bentley Communities
  • Site
  • User
  • Site
  • Search
  • User
ProjectWise
  • Product Communities
ProjectWise
ProjectWise PowerShell Extensions Forum Issue with get-PWDocumentAuditTrailRecords
    • Sign In

    • State Not Answered
    • Replies 4 replies
    • Subscribers 65 subscribers
    • Views 1758 views
    • Users 0 members are here

    Issue with get-PWDocumentAuditTrailRecords

    Peter Willmen
    Offline Peter Willmen over 5 years ago

    Running the function on a test file and getting the following error:-

    ERROR: SQL Statement failed: SELECT [o_audtno], [o_objtype], [o_objguid], [o_objno], [o_action], [o_userno], [o_acttime], [o_comments],[o_numparam1],[o_numparam2],[o_textparam],[o_

    guidparam], [o_username],[o_userdesc],[o_itemname],[o_itemdesc],[o_parentguid] FROM dms_audt WHERE o_objtype = 2 AND o_objguid LIKE '5658e35f-b1b2-4ae9-b1d1-1cbd6cfd3d77'

    --Detail:

    get-PWDocumentAuditTrailRecords : Exception of type 'System.Exception' was thrown.

    At C:\pwps\AuditTEST.ps1:62 char:6

    + $str=get-PWDocumentAuditTrailRecords -FolderPath 'Test' -DocumentName 'testfile. ...

    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo : NotSpecified: (testfile.txt:String) [Get-PWDocumentAuditTrailRecords], Exception

    + FullyQualifiedErrorId : Failed to retrieved document audit trail information.,PWPS_DAB.GetPWDocumentAuditTrailRecords

    However I can get the detail if I run the SQL script from the error without the square brackets around the field names.

    Any suggestions?

    • Sign in to reply
    • Cancel
    Parents
    • Brian Flaherty
      0 Offline Brian Flaherty Tue, Nov 28 2017 12:55 PM

      Can you provide the script you are running. Also, what version of ProjectWise? PWPS_DAB? OS? Database type and version?

      • Cancel
      • Vote Up 0 Vote Down
      • Sign in to reply
      • Verify Answer
      • Cancel
    • Peter Willmen
      0 Offline Peter Willmen Wed, Nov 29 2017 5:02 AM in reply to Brian Flaherty

      The test script is very basic: Get-PWDocumentauditTrailRecords -FolderPath 'Test' -DocumentName 'Testfile.txt'

      I have tried it on 08.11.11.584 with an Oracle database and also on a Bentley Hosted CONNECT version running SQL Server with similar results.

       

      • Cancel
      • Vote Up 0 Vote Down
      • Sign in to reply
      • Verify Answer
      • Cancel
    Reply
    • Peter Willmen
      0 Offline Peter Willmen Wed, Nov 29 2017 5:02 AM in reply to Brian Flaherty

      The test script is very basic: Get-PWDocumentauditTrailRecords -FolderPath 'Test' -DocumentName 'Testfile.txt'

      I have tried it on 08.11.11.584 with an Oracle database and also on a Bentley Hosted CONNECT version running SQL Server with similar results.

       

      • Cancel
      • Vote Up 0 Vote Down
      • Sign in to reply
      • Verify Answer
      • Cancel
    Children
    • Brian Flaherty
      0 Offline Brian Flaherty Wed, Nov 29 2017 5:24 PM in reply to Peter Willmen

      This may require a conference call. Please email to schedule one. brian.flaherty@bentley.com

      • Cancel
      • Vote Up 0 Vote Down
      • Sign in to reply
      • Verify Answer
      • Cancel

    Communities
    • Home
    • Getting Started
    • Community Central
    • Products
    • Support
    • Secure File Upload
    • Feedback
    Support and Services
    • Home
    • Product Support
    • Downloads
    • Subscription Services Portal
    Training and Learning
    • Home
    • About Bentley Institute
    • My Learning History
    • Reference Books
    Social Media
    •    LinkedIn
    •    Facebook
    •    Twitter
    •    YouTube
    •    RSS Feed
    •    Email

    © 2023 Bentley Systems, Incorporated  |  Contact Us  |  Privacy |  Terms of Use  |  Cookies