473,420 Members | 1,644 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,420 software developers and data experts.

accessing an Access-query from an applet

Dear all,

Maybe I'm stupid, in any case I'm stupefied by now. Please help.

Stored procedures in Access should be accessible from a java-applet throught
a callable statement, but all I get is error messages from Access, which
tell me nothing.

Can anybody tell me what is wrong with the following:

In an Access database, I have a selectionquery called TEST, which simply
yields a set of string values:

This is the query in the database:
SELECT name FROM dogs

The output should be someting like:
Spot
George
Fido
....

Now this is the Java-call:
String query = "{ ? = call test }";
CallableStatement cal = theExistingConnection.prepareCall(query);
cal.executeQuery();
ResultSet r = cal.getResultSet();

The execute-statement fails, returning SQLException 70002: field COUNT is
incorrect. Why?

And while we're at it, is there a CLEAR example anywhere on the net of
stored-procedure calls and what parameters to set and why?

Thanks in advance,

WS
Nov 12 '05 #1
1 1466
On Fri, 16 Jan 2004 12:57:07 GMT, wn********@yahoo.com wrote:

I'm on thin ice with Java, but the SELECT query has a problem in that
it uses a reserved word. Try modifying your table and then use:
SELECT DogName from Dogs
Or if you must:
SELECT [name] FROM dogs

Also make sure executeQuery is indeed the right method to run a SELECT
query, and that it is not just used for ACTION queries (i.e. UPDATE,
APPEND etc).

What happened to Fluffy?

-Tom.

Dear all,

Maybe I'm stupid, in any case I'm stupefied by now. Please help.

Stored procedures in Access should be accessible from a java-applet throught
a callable statement, but all I get is error messages from Access, which
tell me nothing.

Can anybody tell me what is wrong with the following:

In an Access database, I have a selectionquery called TEST, which simply
yields a set of string values:

This is the query in the database:
SELECT name FROM dogs

The output should be someting like:
Spot
George
Fido
...

Now this is the Java-call:
String query = "{ ? = call test }";
CallableStatement cal = theExistingConnection.prepareCall(query);
cal.executeQuery();
ResultSet r = cal.getResultSet();

The execute-statement fails, returning SQLException 70002: field COUNT is
incorrect. Why?

And while we're at it, is there a CLEAR example anywhere on the net of
stored-procedure calls and what parameters to set and why?

Thanks in advance,

WS


Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

36
by: Thomas | last post by:
after spending countless hours trying, i give up and hope to get some help in here. on server1 i got the web myweb.com with my test.asp. in the test.asp, i'm trying to read a file from an UNC...
2
by: Steven T. Hatton | last post by:
I find the surprising. If I derive Rectangle from Point, I can access the members of Point inherited by Rectangle _IF_ they are actually members of a Rectangle. If I have a member of type Point...
3
by: prodirect | last post by:
Hi all, I hope someone can help me. I've recently created a database and wanted to put it up on an ftp sight so that multiple people could access the same tables at the same time from different...
4
by: Eugen Walcher | last post by:
Hello all, I've tried posting this same question on other newsgroups with no luck. This group seems to have a lot more activity so I apologize if you have seen it before. I'm trying to...
3
by: Vivek Sharma | last post by:
Hi, I have created a dropdownlist as a web user control. I am using its multiple instances on the webpage. How do I access the selectedValue of each instance? All the instances have different...
1
by: CS Wong | last post by:
Hi, I have a page form where form elements are created dynamically using Javascript instead of programatically at the code-behind level. I have problems accessing the dynamically-created...
0
by: Joergen Bech | last post by:
Fairly new to ASP.NET 1.1. Getting the error below when running application on a web server outside of my control, but only the first time I run it: 1. After a long period of inactivity (or...
5
by: Daniel Corbett | last post by:
I am trying to save a file dynamically created in a webpage. I get the following headers, but cannot figure out how to save the attachment. I am basically trying to replicate what internet...
3
by: Olivier BESSON | last post by:
Hello, I have a web service of my own on a server (vb.net). I must declare it with SoapRpcMethod to be used with JAVA. This is a simple exemple method of my vb source : ...
3
by: Nathan Sokalski | last post by:
I have a validator that I wrote by inheriting from BaseValidator. At certain points in the code, I need to access other controls on the page containing the validator. I have the IDs of these...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.