Re: Querydef



OpenRecordset() on something like this:

SELECT MSysObjects.Name, MSysObjects.Type
FROM MSysObjects
WHERE (MSysObjects.Type In (1,4,5,6))
AND (Not (MSysObjects.Name Like "MSys*"
Or MSysObjects.Name Like "~*"))
ORDER BY MSysObjects.Name;

Alternatively, loop through the TableDefs and QueryDefs.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.
"JimP" <jpockmire@xxxxxxxxxxxxxxxxxxxxx> wrote in message news:t9KdnXhGD7e8DdTVnZ2dnUVZ_tXinZ2d@xxxxxxxxxxxxxx
Is it possible to list all of the tables/queries in a query via code?

.



Relevant Pages

  • Re: Update query - sequence problem
    ... Write some code to OpenRecordset on only the records you want. ... Loop through them, using a numeric variable to keep track of the number you are up to. ... Tips for Access users - http://allenbrowne.com/tips.html ... I would like to run an update record query, ...
    (microsoft.public.access.queries)
  • Re: Convert string to code
    ... It contains dependent values, ... Tips for Access users - http://allenbrowne.com/tips.html ... In other words, loop through the records, look at the calculation, do the ...
    (microsoft.public.access.modulesdaovba)
  • Re: How to queryvery many conditions in VBA
    ... Tips for Access users - http://allenbrowne.com/tips.html ... Another idea is to code a loop where each iteration executes an append query for each ID. ...
    (microsoft.public.access.queries)
  • Re: search and replace text in text file from access
    ... Open a temp file for output ... Loop until EOF ... Tips for Access users - http://allenbrowne.com/tips.html ...
    (microsoft.public.access.modulesdaovba)
  • Re: Sum by multiple
    ... I don't think Access provides a way to multiple the values in a column, so you will probably need to write a VBA function. ... OpenRecordset() and loop through the values to get the product. ...
    (microsoft.public.access.queries)