Re: Two of three SQL stmts execute: third results in table does not exist exception



On Mar 16, 3:12 pm, David Harper <devn...@xxxxxxxxxxxxxxxxxxx> wrote:
GGP wrote:

[SNIP]



Thanks for the reply. Yes, I do set TABLENAME almost as you suggest.
The difference is that I have to construct the name by extracting the
root from one of the previous two queries and concatenating a suffix.
For example, all my table names end with "CF" and one of the tables
may relate to 'mass' (info extracted from one of the other queries).
In that case, TABLENAME would actually be "MassCF". The variable
definition is there in the code, and is:

String TABLENAME = strRoot + "CF";

The actual table "MassCF" does exist and spelling is correct (in both
the code and actual table names). During the debugging process, I
checked to see if names were being generated properly, and they appear
to be fine (which is why I suggested that the first two queries
worked). I'd be happy to provide the full class definition if you
think it would help.

Is it possible that your database system uses table names that are
case-sensitive, and it's failing to match your constructed table name
"MassCF" with the actual name "MASSCF"?

David Harper
Cambridge, England

Interesting. I also thought of that, but I don't think it's the
case. In fact, the table names are in the format MassCF, DistanceCF,
etc., and when the queries spit back their results, they're in the
format MASSCF, DISTANCECF, etc. I checked the documentation that's
supplied with the database (http://db.apache.org/derby/docs/10.1/
ref/), and it says in there that SQL statements (and output,
apparently) are not case sensitive.

I also tested your suggestion directly by trying to run the query
using variable names in allcaps. I received the same error (i.e., it
doesn't seem to matter that the SQL parameters are all upper-case,
lower-case, or mixed-case, the same error occurs).

Thanks again for taking the time to think about this. I'm stumped,
too.

Greg.

.



Relevant Pages

  • Re: Two of three SQL stmts execute: third results in table does not exist exception
    ... The difference is that I have to construct the name by extracting the ... root from one of the previous two queries and concatenating a suffix. ... TABLENAME would actually be "MassCF". ... I'd be happy to provide the full class definition if you ...
    (comp.lang.java.databases)
  • Re: Queries Links Change
    ... and keep everything in a real database ... Make Table queries runs and creates some large tables (extracting ... data out of ORACLE, etc.). ...
    (microsoft.public.access.queries)
  • Re: Simplest way to run 2 queries invoked by a form?
    ... >User needs to be able to enter 2 items of data onto a form and press a ... >1) do i put the sql statements into individual queries? ... What do the two queries DO? ... Using unbound controls and code to update ...
    (microsoft.public.access.forms)
  • Re: Default values in queries
    ... SQL statements. ... the SQL string to include the fields and values you now use field defaults ... > queries we do not currently capture this information. ...
    (microsoft.public.access.queries)
  • Re: User queries and security
    ... I make queries read only to a chosen user group (as defined by access ... I have most of my forms based on SQL statements in the record source ... everything under the bonnet from them and apply your security by ...
    (comp.databases.ms-access)