SQL Profiler

  • Open SQL Server Profiler, which can opened from SQL Server Management Studio, Tools-> SQL Server Profiler 
  • Connect to SQL Server that is hosting SedonaOffice. 
  • Go to the Events Selection tab:
Machine generated alternative text: Trace Properties General Events Selection Review selected events and event columns to trace To see a complete list select the "Show all events" and "Show all columns" options Duration r Client Proc Events Security Audit Audit Login Audit Logout & stingConnection TSQL aec Prepared SQL Prepare SQL SQL: BatchCompIeted SQL: Batch Starting Security Audit Includes event classes that are used to audit server activity Login Name (no fitters applied) ApplicationName NTI_lserName LoginName CPI_I Reads Writes r r r Show all events Show all columns Column ah em Organize Columns Name of the login of the user (either SQL Server security bgin or the Windows bgin credentials In the form of DOMAIN X I J semame)
  • Right-Click Security Audit -> Deselect Event Category 
  • Right-Click Sessions -> Deselect Event Category 
  • Right-click Stored Procedures -> Select Event Category 
  • Right-click TSQL -> Select Event Category 
  • Click the Show All Events Checkbox:
Machine generated alternative text: Trace Properties General Events Selection Review selected events and event columns to trace To see a complete list select the "Show all events" and "Show all columns" options Duration ClientProc Events CLR Database Errors Attention Background Job Emor Bitmap Waming Blocked process report CP Ll threshold exceeded Database Suspect Data Page Data Application Name NTI_lserName Login Name CPI_I Reads Writes Show all events Show all columns Column ah em Organize Columns Indicates when a page is added to the suspect_pages table In msdb Application Name (I fitter(s) applied) Name of the client application that created the connection to SQL Server This column is populated with the values passed by the application rather than the displayed name of the program
  • Right-click Errors and Warnings -> Select Event Category 
  • Click the Column Filters… Button. 
  • In the Edit Filter Window, click ClientProcessID, Expand Equals, and enter the PID for SedonaOffice for the user seeing the error:
Machine generated alternative text: Edit Filter ApplicatonName BinaryData Clien tProcessID Duration EndTme LoginName NTLlserName Reads SPID Star tTme TextDa ta Writes Clien tPr c. ssID The prcu:ess ID of the application calling SQL Server. Equals Not equal to Greater than or equal Less than or eaual Exclude rcwvs that do not contain values
  • Click OK. 
  • Click Run. 
  • Go to SedonaOffice and replicate the error if possible. 

In the trace, find the last query or stored proc that tried to run before a red error/attention message. This is the information we need to look into the error. In this example, I just used the PID for SQL Server Management Studio and local dummy databases instead of SedonaOffice to avoid meddling with the registry to point my Sedona client to my local machine instead of our server. But the message we'd be looking for above the error in this example is "select * from Example_Table": 


Machine generated alternative text: SR: Cachelnsert SQL : Batchstarting SQL : Stmtstarti ng SQL : StmtRecc«npi I e Except ion user Error Message SQL : BatchCcmpI eted sel ect sel ect sel ect sel ect Inval id Inval id sel ect from from from from Exampl e_TabI e Exampl e_TabI e Exampl e_TabI e Exampl e_TabI e M i crosoft M i crosoft M i crosoft M i crosoft M i crosoft M i crosoft M i crosoft J err J err J err J err J err J err J err J err P Jeff P Jeff P Jeff P J err P Jeff P J err P 4472 4472 4472 4472 4472 4472 4472 2017 2017 2017 2017 2017 2017 2017 02- 02- 02- 02- 02- 02- 02- object name ' Example_TabIe . object name ' Example_TabIe . from Example_TabIe

Sometimes the last several messages before the error will be something like "--encrypted text--", in this case we need the last thing that ran before those messages. 

If you click on a row in the Profiler, you should be able to get the full query or stored proc that tried to run for that row and can copy and paste it. You could also provide screenshots as long as the full query/stored proc fits in the row or details box: 

Machine generated alternative text: SQL : StmtReccmpi I e Exception user Error Message SQL : BatchCc«npI eted sel ect Invalid Inval id sel ect from Example_TabIe object name ' Example_TabIe . object name ' Example_TabIe . from Example_TabIe M i crosoft M i crosoft M i crosoft M i crosoft J err J err J err J err J err P J err P Jeff P 4472 4472 4472 4472 2017 2017 2017 2017 02- 02- 02- 02- o. sel ect Ready. from Example_TabIe Rows: I Connections: I
Was this article helpful?
Thank you for your feedback!
User Icon

Thank you! Your comment has been submitted for approval.