15.10 - QryLogV - Teradata Database

Teradata Database Data Dictionary

Product
Teradata Database
Release Number
15.10
Content Type
Administration
User Guide
Publication ID
B035-1092-151K
Language
English (United States)

Query

DBC

 

View Column

Data Type

Format

Source Table.Column

ProcID

DECIMAL(5,0)

NOT NULL

-(5)9 (explicit)

DBQLogTbl.ProcID (Composite NUPI)

CollectTimeStamp

TIMESTAMP(6)

NOT NULL

YYYY-MM-DDBHH:MI:SS

DBQLogTbl.CollectTimestamp (Composite NUPI)

QueryID

DECIMAL(18,0)

NOT NULL

--Z(17)9

DBQLogTbl.QueryID

UserID

BYTE(4)

NOT NULL

X(8)

DBQLogTbl.UserID

UserName

VARCHAR(128)

UNICODE

NOT CASESPECIFIC

X(128)

DBQLogTbl.UserName

DefaultDatabase

VARCHAR(128)

UNICODE

NOT CASESPECIFIC

X(128)

DBQLogTbl.DefaultDatabase

AcctString

VARCHAR(128)

UNICODE

NOT CASESPECIFIC

X(128)

DBQLogTbl.AcctString

ExpandAcctString

VARCHAR(128)

UNICODE

NOT CASESPECIFIC

X(128)

DBQLogTbl.ExpandAcctString

SessionID

INTEGER

NOT NULL

--,---,---,--9 (explicit)

DBQLogTbl.SessionID

LogicalHostID

SMALLINT

NOT NULL

ZZZ9 (explicit)

DBQLogTbl.LogicalHostID

RequestNum

INTEGER

NOT NULL

--,---,---,--9 (explicit)

DBQLogTbl.RequestNum

InternalRequestNum

INTEGER

NOT NULL

--,---,---,--9

DBQLogTbl.InternalRequestNum

TxnUniq

BYTE(4)

X(8)

DBQLogTbl.TxnUniq

LockLevel

VARCHAR(10) LATIN

NOT CASE SPECIFIC

X(10)

DBQLogTbl.LockLevel

LogonDateTime

TIMESTAMP(6)

NOT NULL

YYYY-MM-DDBHH:MI:SS

DBQLogTbl.LogonDateTime

AcctStringTime

TIME

99:99:99 (explicit)

DBQLogTbl.AcctStringTime

AcctStringHour

SMALLINT

--9 (explicit)

DBQLogTbl.AcctStringHour

AcctStringDate

DATE

YY/MM/DD (explicit)

DBQLogTbl.AcctStringDate

LogonSource

VARCHAR(128)

LATIN

NOT CASESPECIFIC

X(128)

DBQLogTbl.LogonSource

AppID

CHAR(30)

UNICODE

NOT CASESPECIFIC

X(30)

DBQLogTbl.AppID

ClientID

CHAR(30)

UNICODE

NOT CASESPECIFIC

X(30)

DBQLogTbl.ClientID

ClientAddr

CHAR(45) LATIN

NOT CASESPECIFIC

X(45)

DBQLogTbl.ClientAddr

QueryBand

VARCHAR(6160)

UNICODE

NOT CASESPECIFIC

X(6160)

DBQLogTbl.QueryBand

ProfileID

BYTE(4)

X(8)

DBQLogTbl.ProfileID

StartTime

TIMESTAMP(6)

NOT NULL

YYYY-MM-DDBHH:MI:SS.S(F)Z (explicit)

DBQLogTbl.StartTime

FirstStepTime

TIMESTAMP(6)

NOT NULL

YYYY-MM-DDBHH:MI:SS.S(F)Z (explicit)

DBQLogTbl.FirstStepTime,
DBQLogTbl.StartTime

FirstRespTime

TIMESTAMP(6)

YYYY-MM-DDBHH:MI:SS.S(F)Z (explicit)

DBQLogTbl.FirstRespTime

ElapsedTime

INTERVAL HOUR(4) TO SECOND(6)

-h(2):mm:ss.s(6)

DBQLogTbl.FirstRespTime,
DBQLogTbl.StartTime

NumSteps

SMALLINT

NOT NULL

---,--9 (explicit)

DBQLogTbl.NumSteps

NumStepswPar

SMALLINT

---,--9 (explicit)

DBQLogTbl.NumStepswPar

MaxStepsInPar

SMALLINT

---,--9 (explicit)

DBQLogTbl.MaxStepsInPar

NumResultRows

FLOAT

----,---,---,---,--9 (explicit)

DBQLogTbl.NumResultRows

TotalIOCount

FLOAT

----,---,---,---,--9 (explicit)

DBQLogTbl.TotalIOCount

AMPCPUTime

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.AMPCPUTime

ParserCPUTime

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.ParserCPUTime

UtilityByteCount

FLOAT

----,---,---,---,--9 (explicit)

DBQLogTbl.UtilityByteCount

UtilityRowCount

FLOAT

----,---,---,---,--9 (explicit)

DBQLogTbl.UtilityRowCount

ErrorCode

INTEGER

--,---,---,--9 (explicit)

DBQLogTbl.ErrorCode

ErrorText

VARCHAR(1024)

UNICODE

NOT CASESPECIFIC

X(255)

DBQLogTbl.ErrorText

WarningOnly

CHAR(1) LATIN

NOT CASESPECIFIC

X(1)

DBQLogTbl.WarningOnly

AbortFlag

CHAR(1) LATIN

NOT CASESPECIFIC

X(1)

DBQLogTbl.AbortFlag

CacheFlag

CHAR(1) LATIN

NOT CASESPECIFIC

X(1)

DBQLogTbl.CacheFlag

StatementType

CHAR(20) LATIN

NOT CASESPECIFIC

X(20)

DBQLogTbl.StatementType

StatementGroup

VARCHAR(128)

UNICODE

X(20)

DBQLogTbl.StatementGroup

QueryText

VARCHAR(10000)

UNICODE

NOT CASESPECIFIC

X(10000)

DBQLogTbl.QueryText

NumOfActiveAMPs

INTEGER

--,---,---,--9 (explicit)

DBQLogTbl.NumOfActiveAMPs

MaxAMPCPUTime

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.MaxAmpCPUTime

MaxCPUAmpNumber

SMALLINT

---,--9 (explicit)

DBQLogTbl.MaxCPUAmpNumber

MinAmpCPUTime

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.MinAmpCPUTime

MaxAmpIO

FLOAT

----,---,---,---,--9

DBQLogTbl.MaxAmpIO

MaxIOAmpNumber

SMALLINT

---,--9 (explicit)

DBQLogTbl.MaxIOAmpNumber

MinAmpIO

FLOAT

----,---,---,---,--9 (explicit)

DBQLogTbl.MinAmpIO

SpoolUsage

FLOAT

----,---,---,---,--9 (explicit)

DBQLogTbl.SpoolUsage

LSN

INTEGER

--,---,---,--9 (explicit)

DBQLogTbl.LSN

EstResultRows

FLOAT

----,---,---,---,--9 (explicit)

DBQLogTbl.EstResultRows

EstProcTime

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.EstProcTime

EstMaxRowCount

FLOAT

----,---,---,---,--9 (explicit)

DBQLogTbl.EstMaxRowCount

TDWMEstMemUsage

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.TDWMEstMemory

AMPCPUTimeNorm

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.AMPCPUTimeNorm

ParserCPUTimeNorm

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.ParserCPUTimeNorm

MaxAMPCPUTimeNorm

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.MaxAmpCPUTimeNorm

MaxCPUAmpNumber
Norm

SMALLINT

---,--9

DBQLogTbl.MaxCPUAmpNumberNorm

MinAmpCPUTimeNorm

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.MinAmpCPUTimeNorm

ParserExpReq

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.ParserExpReq

ProxyUser

VARCHAR(128)

UNICODE

NOT CASESPECIFIC

X(128)

DBQLogTbl.ProxyUser

ProxyRole

VARCHAR(128)

UNICODE

NOT CASESPECIFIC

X(128)

DBQLogTbl.ProxyRole

SessionTemporalQualifier

VARCHAR(1024) LATIN

NOT CASESPECIFIC

X(1024)

DBQLogTbl.SessionTemporalQualifier

CalendarName

VARCHAR(128)

UNICODE

NOT NULL

X(128)

DBQLogTbl.CalendarName

CPUDecayLevel

SMALLINT

---,--9 (explicit)

DBQLogTbl.CPUDecayLevel

IODecayLevel

SMALLINT

---,--9 (explicit)

DBQLogTbl.IODecayLevel

TacticalCPUException

INTEGER

--,---,---,--9

DBQLogTbl.TacticalCPUException

TacticalIOException

INTEGER

--,---,---,--9

DBQLogTbl.TacticalIOException

SeqRespTime

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.SeqRespTime

ReqIOKB

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.ReqIOKB

ReqPhysIO

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.ReqPhysIO

ReqPhysIOKB

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.ReqPhysIOKB

DataCollectAlg

BYTEINT

--Z(2)9

DBQLogTbl.DataCollectAlg

CallNestingLevel

BYTEINT

--Z(2)9

DBQLogTbl.CallNestingLevel

NumRequestCtx

BYTEINT

--Z(2)9

DBQLogTbl.NumRequestCtx

KeepFlag

CHAR(1)

UNICODE

X(1)

DBQLogTbl.KeepFlag

QueryRedriven

CHAR(1)

UNICODE

X(1)

DBQLogTbl.QueryRedriven

ReDriveKind

CHAR(10)

UNICODE

X(10)

DBQLogTbl.ReDriveKind

LastRespTime

TIMESTAMP(6)

YYYY-MM-DDBHH:MI:SS.S(F)Z

DBQLogTbl.LastResponseTime

DisCPUTime

FLOAT

----,---,---,---,--9.999

DBQLogTbl.DisCPUTime

Statements

INTEGER

--,---,---,--9

DBQLogTbl.Statements

DisCPUTimeNorm

FLOAT

----,---,---,---,--9.999

DBQLogTbl.DisCPUTimeNorm

TxnMode

CHAR(10) LATIN

X(10)

DBQLogTbl.TxnMode

RequestMode

CHAR(5) LATIN

X(5)

DBQLogTbl.RequestMode

DBQLStatus

INTEGER

--,---,---,--9

DBQLogTbl.DBQLStatus

NumFragments

INTEGER

--,---,---,--9

DBQLogTbl.NumFragments

VHLogicalIO

FLOAT

----,---,---,---,--9.999

DBQLogTbl.VHLogicalIO

VHPhysIO

FLOAT

----,---,---,---,--9.999

DBQLogTbl.VHPhysIO

VHLogicalIOKB

FLOAT

----,---,---,---,--9.999

DBQLogTbl.VHLogicalIOKB

VHPhysIOKB

FLOAT

----,---,---,---,--9.999

DBQLogTbl.VHPhysIOKB

LockDelay

FLOAT

----,---,---,---,--9.999

DBQLogTbl.LockDelay

CheckpointNum

FLOAT

----,---,---,---,--9

DBQLogTbl.CheckpointNum

UnityTime

Note: This column is reserved for future use.

FLOAT

----,---,---,---,--9

DBQLogTbl.UnityTime

UtilityInfoAvailable

CHAR(1)

X(1)

DBQLogTbl.UtilityInfoAvailable

UnitySQL

Note: This column is reserved for future use.

CHAR(1)

X(1)

DBQLogTbl.UnitySQL

ThrottleBypassed

CHAR(1)

X(1)

DBQLogTbl.ThrottleBypassed

IterationCount

INTEGER

--,---,---,--9

DBQLogTbl.IterationCount

TTGranularity

VARCHAR(30)

UNICODE

NOT CASE SPECIFIC

NOT NULL

X(30)

DBQLogTbl.TTGranularity

MaxStepMemory

FLOAT

----,---,---,---,--9.999

DBQLogTbl.MaxStepMemory

TotalServerByteCount

Note: This column is also documented in the QueryGrid manuals.

FLOAT

----,---,---,---,--9

DBQLogTbl.TotalServerByteCount

PersistentSpool

FLOAT

----,---,---,---,--9

DBQLogTbl.ExtraField20

RemoteQuery

CHAR(1)

LATIN

NOT CASESPECIFIC

X(1)

DBQLogTbl.ExtraField9

ProxyUserID

BYTE(4)

X(8)

DBQLogTbl.ProxyUserID

DelayTime

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.DelayTime

MinRespHoldTime

FLOAT

Z,ZZ9.9

DBQLogTbl.ExtraField22

TotalFirstRespTime

FLOAT

ZZ,ZZZ,ZZ9.999

DBQLogTbl.ExtraField23

The DBQLogTbl.ExtraFieldXX columns (where XX represents the number of the column) are reserved for future use. These fields will be converted to a column name in a future release.

IterationCount

This column logs the iteration count for the data parcel associated with a request. This value is NULL for requests with a single using data row and no using data row.

LogonSource

Teradata recommends using alternative columns instead of the LogonSource column, if available. For information about the recommended columns for LogonSource, see Appendix B: “LogonSource Column Fields and Examples.”

NumFragments

This column is NULL for static plans only.

ProxyUserID

This is the ID of the ProxyUser being charged for SPOOL and TEMP space. If the field is NULL the session user ID is used for SPOOL and TEMP space.

SessionTemporalQualifier

When a DML or SELECT request refers to a temporal table but omits a temporal qualifier, the system uses the value of the session temporal qualifier. This is the session temporal qualifier in effect when the query is logged.

For example, this column uses the ANSIQUALIFIER value if the session temporal qualifier is set to ANSIQUALIFIER for ANSI temporal tables.

For more information about the session temporal qualifiers, see Temporal Table Support and ANSI Temporal Table Support.

TDWMEstMemUsage

This column returns the estimated memory (in MB) used to classify a query into a workload definition.

TotalServerByteCount

The TotalServerByteCount column is the total number of bytes read from or sent to foreign servers involved in the request.

Possible Values for CacheFlag

 

Value

Description

T

Query is found in step cache.

S

Query is a parameterized query and a specific plan is generated.

G

Query is parameterized query and a generic plan is generated.

A

Query is a parameterized query and a specific always decision is taken. That is, each time a query is submitted using values are peeked at and the query is parsed.

Possible Values for CPUDecayLevel

  • 0
  • 1
  • 2
  • Possible Values for IODecayLevel

  • 0
  • 1
  • 2
  • Possible Values for LockLevel

  • NOLOCK
  • ACCESS
  • READ
  • WRITE
  • EXCLUSIVE
  • UNKNOWN
  • Possible Values for NumResultRows

    For an Enhanced Statement Status (ESS) client, the value 18,446,744,073,709,551,615 could mean that number or higher.

    Note: The value formatted as a decimal value is 18,446,744,073,709,551,616 due to float arithmetic.

    For a non-ESS client, a warning message is returned if the actual activity count exceeds 4294967295.

    The same value (modulo 2^32) is logged in the NumResultRows column.

    The value 4294967295 along with the warning message indicates the actual counter is one of the following:

    1 A multiple of 4294967296 minus 1.

    2 Is equal to 18,446,744,073,709,551,615.

    3 Is greater than 18,446,744,073,709,551,615.

    The maximum internal counter is 18,446,744,073,709,551,615.

    The value 4294967295 or less, without the warning message, is the actual row count.

    Possible Values for QueryText

     

    Value

    Description

    Unavailable and the RequestNum column value is zero.

    An unconditional abort (UCAbort) from the session or Gateway vproc or Teradata Director Program kill between requests. This may reflect the abort of an open transaction.

    * SQL query

    An asynchronous abort (AsynchAbort) from the session or Gateway vproc or Teradata Director Program kill naming a specific request number. If the abort occurs when the request in the dispatcher, the StatementType column and StatementGroup column values are the usual values for the request, and the error code indicates that the request was aborted.

    Possible Values for QueryRedriven

     

    Value

    Description

    E

    The request was re-parsed due to an internal Parser error.

    M

    The request was re-parsed due to an internal Parser memory limit.

    R

    The request was re-driven due to a database restart.

    N

    The request was not redriven or re-parsed.

    Possible Values for RedriveKind

     

    Value

    Description

    ' '

    Not participating.

    MN

    Memory nonfallback responses.

    Possible Values for RequestNum, StatementGroup, and StatementType

     

    Value

    Description

    UCAbort

    An unconditional abort from the session or Gateway vproc or Teradata Director Program kill between requests. This may reflect the abort of an open transaction. If an UCAbort occurs, the value is zero.

    AsynchAbort

    An asynchronous abort from the session or Gateway vproc or Teradata Director Program kill.

    Note: If AsynchAbort occurs, the value is the normal client request number. If the AsynchAbort occurs when the request is in the dispatcher, the StatementType and StatementGroup column values are the usual values for the request, and an error is generated.

    Possible Values for ThrottleBypassed

     

    Value

    Description

    1

    ThrottleBypass ruleset attribute is set.

    0

    ThrottleBypass ruleset attribute is not set.

    Possible Values for TTGranularity

     

    Value

    Description

    LOGICALROW

    Row is timestamped with the time the row is processed by the AMP.

    REQUEST

    Row is timestamped with the time the request is submitted.

    TRANSACTION

    Row is timestamped with the time when the first non-locking reference is made to a temporal table, or when the built-in function TEMPORAL_TIMESTAMP is first accessed during the transaction.

    Possible Values for UtilityInfoAvailable

     

    Value

    Description

    Y

    SQL request has utility information (for example, from DSA or the control SQL session of a load or export utility) logged in the DBQLUtilityTbl table.

    N

    SQL request does not have utility information logged in the DBQLUtilityTbl table.

     

    Example  

    The following SELECT statement retrieves all rows that match the specified query ID from the QryLogV view.

    select * from QryLogV where queryid =  307190925762023013;

    Example  

    This example shows how to track data volume for specific load jobs.

    SELECT UtilityByteCount,UtilityRowCount from DBC.QryLogV where UtilityByteCount is not NULL or UtilityRowCount is not NULL;

    Result:

     UtilityByteCount  UtilityRowCount
    -----------------  ---------------
                  431               25
                   52                1