Sql's within the macro are not logged in DBQLogtbl

Database
Teradata Employee

Sql's within the macro are not logged in DBQLogtbl

We observe that the Sql's inside the TD macro were not logged in the dbqlogtbl and we could see the execute statement alone

Ex:
exec DBADMIN_WEB_DB.MC_RESPONSETIME_BY_STATEMENTTYPE_DBC(DATE-1, 0)

Is this expected?


Accepted Solutions
Apprentice

Re: Sql's within the macro are not logged in DBQLogtbl

I think you'll find that (at least part of) the reason for this is because all sql within a macro are always treated as part of a single request, and DBQL logging is at the request (not statement) level.

Ward Analytics Ltd - information in motion
www: http://www.ward-analytics.com
1 ACCEPTED SOLUTION
3 REPLIES
Apprentice

Re: Sql's within the macro are not logged in DBQLogtbl

Yes.

 

Not 100% certain but I think you'll find this has always been the case.

 

Dave

Ward Analytics Ltd - information in motion
www: http://www.ward-analytics.com
Apprentice

Re: Sql's within the macro are not logged in DBQLogtbl

I think you'll find that (at least part of) the reason for this is because all sql within a macro are always treated as part of a single request, and DBQL logging is at the request (not statement) level.

Ward Analytics Ltd - information in motion
www: http://www.ward-analytics.com
Teradata Employee

Re: Sql's within the macro are not logged in DBQLogtbl

Thanks Dave .