Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Programming Logic through ADO for ACCESS???

Status
Not open for further replies.

VisualGuy

Programmer
Joined
May 27, 2003
Messages
162
Location
US
I've come to realize that PL/SQL is exlusive to Oracle. That doesn't help me for what I need to do. I'm writing a program that populates a flexgrid using data it receives from and ACCESS database.

My problem is that I need to use some IF/THEN/ELSE and counter assigning logic in one of my SQL queries.

Is this possible? I know you can set up all kinds of queries, but can you use the kind of logic in an SQL statement in VB when talking to ACCESS. If so, a small example of IF/THEN/ELSE and counter logic would be greatly appreciated.

Thanks...
 
I would suggest that you use ADO to do the logic bit before populating the flexgrid.

Alternatively you could do some code in Access to filter your records and then get the resulting recordset.

Access doesn't support PL/SQl or Transact SQL Stuff.
 
>IF/THEN/ELSE

The JET provider has its own provider specific functionality as well.
Several VBA functions are avaible in JET.

For IF/THEN/ELSE, you can use the IIF() function.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top