Is there any way to get information about the partition that is being accessed when a query is being fired on a VMWare Teradata. I got one table that has the query text in DBQL for all the queries hit.
Any table that provides partition column directly or any way to find out from the query text?
why do you need that information?
It's not available in DBQL, depending on the Select it might be a single partition or 200000, how to store it?
The Explain text found in QryLogExplainV will include the number of partitions accessed like "single partition", "4 partitions", "all partitions".
If it's a WHERE-condition based on equality you could pass it to the partitioning function found in dbc.PartitioningConstraintsV.ConstraintText (after removing the CHECK):
SELECT CURRENT_DATE AS LogDate,
RANGE_N(LogDate BETWEEN DATE '2010-01-01' AND DATE '2030-12-31' EACH INTERVAL '1' DAY )