Adam Turner via AccessMonster.com wrote:
Sure...actually I just recently discovered this approach myself as I had a
very similar, almost identical, scenario.
It should work fine for you.
The case statement is a (wonderful) ANSI 92 and later construct that is
supported by Oracle, and, I believe, MS SQL. However, I believe you may
have ANSI 92 enabled. This is found under options->Tables/Queries->SQL
COmpatible Syntax (ANSI 92) in the bottom right hand corner.
Otherwise, your solution will not work, as far as I can tell.
I'm not sure what effect the ANSI 92 compatibility has on Jet
performance or whatever. I work mainly in Oracle, so maybe someone else
can comment.
As an aside, When I first started with A2003 last year, I tried
switching to ANSI 92 compaitibility once but Jet SQL still demanded the
cumbersome ANSI join syntax and not the very much easier and older join
syntax of Oracle (called a Theta type join), so I switched back. The
theta joins make it so deliciously easy to write dynamic SQL with VBA code.
--
Tim
http://www.ucs.mun.ca/~tmarshal/
^o<
/#) "Burp-beep, burp-beep, burp-beep?" - Quaker Jake
/^^ "Whatcha doin?" - Ditto "TIM-MAY!!" - Me