By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,863 Members | 879 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,863 IT Pros & Developers. It's quick & easy.

Reference of SQL commands in Access?

P: n/a
Does anybody have (a link to) a reference of available SQL commands in
MS-Access? I know you can use SOME VisualBasic commands, but I cannot
find a reference anywhere!
Among other things, I need to use an IF command, like this:
SELECT IF (Field=5,"five","not five") AS NewField FROM Table

I really need a reference on this! I havent been able to find
anything in the Access help files, or the MSDN library.
I am using ASP to access the database through Microsoft.Jet.OLEDB.4.0
Nov 12 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
> Does anybody have (a link to) a reference of available SQL commands in
MS-Access? I know you can use SOME VisualBasic commands, but I cannot
find a reference anywhere!
Search the OH for "Microsoft Jet Database Engine SQL Reserved Words".
Among other things, I need to use an IF command, like this:
SELECT IF (Field=5,"five","not five") AS NewField FROM Table


SELECT IIF([Field]=5,"five","not five") AS NewField FROM Table;

HTH - Peter

--
No mails please.
Nov 12 '05 #2

P: n/a
go**********@pbb.dds.nl (Peter) wrote in
news:df**************************@posting.google.c om:
Does anybody have (a link to) a reference of available SQL commands in
MS-Access? I know you can use SOME VisualBasic commands, but I cannot
find a reference anywhere!
Among other things, I need to use an IF command, like this:
SELECT IF (Field=5,"five","not five") AS NewField FROM Table

I really need a reference on this! I havent been able to find
anything in the Access help files, or the MSDN library.
I am using ASP to access the database through Microsoft.Jet.OLEDB.4.0


When Jet 4.0 is installed

JETSQL40.chm is also installed.

Mine is in:
C:\Program Files\Common Files\Microsoft Shared\Office 10\1033. One can find
it using the Search Utility.

Double clicking on this file should present you with quite a good reference
to JET 4.0 SQL.

(You can also access the contents of this file through Access XP Help (in
the User Interface, not in the VBA Editor.)

User Defined and Native VBA functions can often be used in JET SQL. If they
work in a VBA module then they are likely to work in SQL in Access. But I
think
IF (Field=5,"five","not five") would not work in a VBA module. Possibly you
could use:
IIF(Field=5,"five","not five")
but I am not an expert on IIF, preferring to use other contstructions.

But how could they work in ASP? Access and VBA are not running when one
uses JET from ASP. ASP is running, and I guess, one might be using ADO to
connect to JET. One is usually restricted to the objects and methods of the
technologies one is using.

--
Lyle
(for e-mail refer to http://ffdba.com/contacts.htm)
Nov 12 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.