List Source Queries in a Query

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Liz the Whizz

    List Source Queries in a Query

    I want to write some code that will list the source tables and queries
    for each query in a database. At present, it is listing the original
    source tables, rather than the query(s) that subsequent queries are
    based on.

    Eg if I have a table called Table 1, then a query based on it called
    Query 1, and a further query called Query 2 which is based on Query 1,
    not directly on the table, I want the code to identify Query 1, not
    Table 1 as the source for those fields that use it.

    Is this possible?
Working...