-
Microsoft Access ODBC and queries written in Java
I am currently using IBM Visual Age for Java. I have created a servlet that
connects to a Microsoft Access database. I was wondering what is the correct
syntax to pass a query with a JOIN statement and a where clause.
This an example of the query.
s.executeQuery("SELECT [QPOA].universalAcc, [CRDB].lName, [CRDB].fName, [QPOA].branch,
[QPOA].accountNumber, "
+"[CRDB].fName from CRDB INNER JOIN QPOA ON [CRDB].universalAcc = [QPOA].universalAcc
where [(QPOA].[accountNumber]=\"12345\";");
Any help would be appreciated
-
Re: Microsoft Access ODBC and queries written in Java
Use Access's query designer to create a query joining the files, using
selections, and so on. Then switch to SQL view to get SQL syntax that
Access can understand.
PC2
"Richard" <dolostone@yahoo.com> wrote in message
news:3aef1bbb$1@news.devx.com...
>
> I am currently using IBM Visual Age for Java. I have created a servlet
that
> connects to a Microsoft Access database. I was wondering what is the
correct
> syntax to pass a query with a JOIN statement and a where clause.
> This an example of the query.
>
> s.executeQuery("SELECT [QPOA].universalAcc, [CRDB].lName, [CRDB].fName,
[QPOA].branch,
> [QPOA].accountNumber, "
> +"[CRDB].fName from CRDB INNER JOIN QPOA ON [CRDB].universalAcc =
[QPOA].universalAcc
> where [(QPOA].[accountNumber]=\"12345\";");
> Any help would be appreciated
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks