How to log external SQL (aka ODBC) requests?

Is there any way to have 4D log external SQL (aka ODBC) requests?

I’ve tried
SET DATABASE PARAMETER(4D Server log recording;1)
…but this seems to only log sql requests from a 4D client.

The server request log will log all the SQL queries, but turning this on definitely slows the server down.

Jeff,

I’ve turned on SET DATABASE PARAMETER(4D Server log recording;1)
And then I use SQL login from a remote 4D to hit this server, and make SQL requests
But nothing logs to the 4DRequestLog.txt.

I clicked the button on the Maintenance tab of 4D Server - didn’t try it through code.

Here’s an example line from the log:

10668253 2019-08-19T14:47:19.611 28732 ‘SQLS’ 5095 SQL Server execute:SELECT p.PromoCode, p.CCData, p.Amount, p.Authorize, c.PromoMonths, p.CardNo
FROM Payments AS p
LEFT JOIN CreditCardCosts AS c ON p.PromoCode=c.PromoCode
WHERE p.InvoiceID=:$lIQID AND p.PromoCode>0 AND p.CardNo LIKE ‘6034%’ AND p.Amount>0 AND c.CompanyID=0 AND c.PromoDisclosureSkip=FALSE
INTO :$alPromoCode, :$atCCData, :$arAmount, :$atAuthorize, :$alPromoMonths, :$atCardNo 2

I’ve seen activity in the log when the sql request is coming from a 4D client (that is a 4D client request directly to it’s 4D server), but NOT when I’m hitting the server from some outside technology (including an external 4D app using SQL Login).

Did you do your SQL request from something other than a connected 4D Client?