SQL Trace

Sometimes it is helpful or necessary to see which SQL statements eBiss sends to the database. To enable the trace change the key OrmTraceDbOperations in the eBiss config file eBiss.WinClient.exe.config to True:

<add key="OrmTraceDbOperations" value="true" />

If the eBiss Client is restarted afterwards, all SQL statements appear in the eBss Client Log File1).

Note: Please do not forget to reverse the settings to avoid unnecessary overload of the log file.

Example:

You would like to get a list of all document numbers of sent invoices of day X and partner Y. The document search returns several thousand hits.

Document filter:

= Trading partner name starts-with "PartnerName" and receipt date after-"02/28/2021 23:59:59"

Resulting SQL statement in tracelog:

SELECT [A].[Oid], [A].[Interchange_oid], 
[A].[SequenceNumber], [A].[Message_oid], [A].[OriginDocument_oid], [A].[EntityType_oid], 
[A].[SystemLocation_oid], [A].[PartnerLocation_oid], [A].[DocType], [A].[DocSubType], [A].[DocNumber], [A].[DocDate], [A].[StandardMain], [A].[StandardSub], 
[A].[StandardVersion], [A].[CommunicationId], [A].[StartOffset], [A].[State], [A].[TaskState], [A].[LevelTaskState], B.Oid "Oid_20", 
B.Subject "Subject_21", B.EntryDate "EntryDate_22", C.Oid "Oid_23", C.SequenceNumber "SequenceNumber_24", C.Partner_oid "Partner_oid_25", C.OwnLocation_oid "OwnLocation_oid_26", D.Oid "Oid_27", 
D.Name "Name_28", E.Oid "Oid_29", E.Name "Name_30", F.Oid "Oid_31", F.Name "Name_32" 
FROM [Document] AS A 
 LEFT JOIN [Message] AS B ON A.[Message_oid] = B.[Oid] 
 LEFT JOIN [Interchange] AS C ON A.[Interchange_oid] = C.[Oid] 
 LEFT JOIN [Partner] AS D ON C.[Partner_oid] = D.[Oid] 
 LEFT JOIN [Partner] AS E ON C.[OwnLocation_oid] = E.[Oid] 
 LEFT JOIN [EntityType] AS F ON A.[EntityType_oid] = F.[Oid]
WHERE ((B.[EntryDate] >= '2021-02-28T23:59:59' 
 AND A.[Message_oid] IS NOT NULL 
 AND (D.[Name] LIKE 'PartnerName%' AND D.[Name] IS NOT NULL) AND C.[Partner_oid] IS NOT NULL AND A.[Interchange_oid] IS NOT NULL 
 AND ((B.[MessageBox_oid] = '8f088cbd-8769-462a-ab0f-4bfcad6374e9'))))
ORDER BY A.SequenceNumber ASC
1)
Go to eBiss/System/Properties and there open the Client Log via the button.