C said:
There appears to be a table in my database (Access 2003) which is formed
through a make table query. Is there any way to find out which query/queries
made it? The dependencies don't show the information and there are hundreds
of queries to go through.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
If you're using an .mdb file you can use VBA & DAO to go thru the
QueryDefs like the following to get the name of the table.
Set the parameter to the table's name. This subroutine will print the
name's of all the queries that refer to that table.
Sub WhichQuery(strSearchFor As String)
dim db as dao.database
dim qd as dao.querydef
set db = currentdb
for each qd in db.querydefs
If InStr(qd.SQL, strSearchFor)>0 Then
Debug.Print qd.name
End If
next qd
End Sub
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)
** Respond only to this newsgroup. I DO NOT respond to emails **
-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv
iQA/AwUBRRWia4echKqOuFEgEQIBjQCfcsrKbv/Su4rESs/HXH3l+I66K0QAn1o/
FAU5qsuarad2hM5DLIBLfXD5
=PuWw
-----END PGP SIGNATURE-----