[AccessD] Modifying a query

Darren DICK darrend at nimble.com.au
Tue Jun 6 21:41:08 CDT 2006


Once you go through the tabledefs bit there is a property (I think) called 'sql'
eg

Set qrydef(SomeQuery)
Debug.print qrydef.sql

(Something like that - did it years ago from a recommendation from someone on
this list)

that will spit out a query in sql format
You can then edit and modify that 
Choose to save or not at the end

HTHelps


Have a great day
 
Darren
------------------------------
T: 0424 696 433
 

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Rocky Smolin - Beach
Access Software
Sent: Wednesday, 7 June 2006 10:20 AM
To: Access Developers discussion and problem solving
Subject: [AccessD] Modifying a query

Dear List:

Can you modify the criteria in an existing query through code?  Usually 
I just construct the query as a SQL statement and use db.execute to run 
it.  But this time I think it would be better to leave the query where 
it is and modify the criterion based on a selection by the user.  The 
query is part of a predefined set of queries that were embedded in a 
macro by the user.

MTIA,

Rocky

-- 
Rocky Smolin
Beach Access Software
858-259-4334
www.e-z-mrp.com


-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com




More information about the AccessD mailing list