Obtain Session Information | Teradata Vantage - Obtaining Session Information - Advanced SQL Engine - Teradata Database

Database Administration

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
17.00
Published
June 2020
Language
English (United States)
Last Update
2021-01-22
dita:mapPath
rgu1556127906220.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1093
lifecycle
previous
Product Category
Teradata Vantage™
To find information about a session, for example CPU or I/O data for a specific session, try one of the following tools.
  • Teradata Viewpoint – Using Teradata Viewpoint, you can view information about queries running in a Vantage system so you can spot problem queries. You can analyze and decide whether a query is important, useful, and well-written.
  • PM/APIs – If you write your own application, use the MONITOR SESSION request or the MonitorSession function to collect current status and activity information for sessions that are logged on to Vantage. PM/APIs allow you to immediately access session information but you must have proper privileges to submit the requests or use the functions. For more information, see Teradata Vantage™ - Application Programming Reference, B035-1090.
  • DBC.AmpUsage view and Account String Expansion (ASE) – Use ASE to generate 1 row into DBC.AmpUsage per AMP per session. Note that the AmpUsage rows are not written until the query completes. For more information on ASE, see Logging Resource Usage Data with Account String Variables.
  • DBC.SessionInfo view – Use this view to see the client interface that established the session, the logon date and time, and current role among other information. There is one row for each time a user is logged on.
  • DBQL information – You must have first already enabled logging by submitting the BEGIN QUERY LOGGING statement for the users/accounts/applications you wish to monitor.

For more information on this topic, see Determining the Account for a User Session.