Use MS Query in VBA to only get a SQL statement
- From: "RB Smissaert" <bartsmissaert@xxxxxxxxxxxxxxxx>
- Date: Mon, 23 May 2005 12:31:09 +0100
I wonder if this were possible:
Use MS Query to construct a SQL statement and use the statement in VBA code (ADO, ODBC connecting to Interbase), but don't let it run the statement.
So just use the MS Query as a SQL wizard, incorporated in VBA code.
Doing this would save a lot of coding to get a similar wizard, although it shouldn't be too difficult either.
One drawback I can see is that MS Query won't let you do a WHERE condition on a field that is not in the SELECT
clause. The good thing though is that it will automatically add any joins, although I am not sure how it will handle
joins that are not inner joins.
Hope this explains it clear enough and thanks for any advice.
RBS
.
- Follow-Ups:
- Prev by Date: RE: Dynamic Web Query from VBA
- Next by Date: Re: Help on printing comments
- Previous by thread: Do within an If statement
- Next by thread: RE: Use MS Query in VBA to only get a SQL statement
- Index(es):
Relevant Pages
|
Loading