ODBC error

ODBC error

am 13.01.2007 18:09:58 von ANJANE

I am executing a procedure that returns data from a temp table created.
Sometimes the query works at the first attempt, but fails on subsequent
attempts. It is intermittent. Leaving some time between queries, it works
fine.

Basically, in my query, I do some joins of tables, load the data to a temp
table and return all the data from the temp table via a cursor to the user.
I drop the temp table if it exists at the beginning.

I get the following error message.

Microsoft OLE DB Provider for ODBC Drivers error '80004005'

Error while executing the query; ERROR: pg_class_aclcheck: relation 6014747
not found

The relation number keeps changing.

I am calling this query using a DSN-less setuo, from an ASP page. I use the
psqlodbc-07_03_0200 ODBC driver

All the help to resolve this is appreciated.

Thanks

--
View this message in context: http://www.nabble.com/ODBC-error-tf2971825.html#a8315925
Sent from the PostgreSQL - odbc mailing list archive at Nabble.com.


---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

Re: ODBC error

am 13.01.2007 23:27:17 von Hiroshi Inoue

ANJANE wrote:
> I am executing a procedure that returns data from a temp table created.
> Sometimes the query works at the first attempt, but fails on subsequent
> attempts. It is intermittent. Leaving some time between queries, it works
> fine.
>
> Basically, in my query, I do some joins of tables, load the data to a temp
> table and return all the data from the temp table via a cursor to the user.
> I drop the temp table if it exists at the beginning.
>

It doesn't seem a problem of the odbc driver.
Please try it via psql and see the result.

regards,
Hiroshi Inoue

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

Re: ODBC error

am 16.01.2007 15:02:25 von ANJANE

As I said the query works intermittently. Whenever it fails, I get the
following error message

...select tp_get_clientusers('1','S%', 'rcursor');fetch all in rcursor;

Microsoft OLE DB Provider for ODBC Drivers error '80004005'

Error while executing the query; ERROR: pg_class_aclcheck: relation 6017860
not found

/portal/testdb.asp, line 82

the relation oid keeps changing. Not sure what this means.

Sreyams


Hiroshi Inoue wrote:
>
> ANJANE wrote:
>> I am executing a procedure that returns data from a temp table created.
>> Sometimes the query works at the first attempt, but fails on subsequent
>> attempts. It is intermittent. Leaving some time between queries, it works
>> fine.
>>
>> Basically, in my query, I do some joins of tables, load the data to a
>> temp
>> table and return all the data from the temp table via a cursor to the
>> user.
>> I drop the temp table if it exists at the beginning.
>>
>
> It doesn't seem a problem of the odbc driver.
> Please try it via psql and see the result.
>
> regards,
> Hiroshi Inoue
>
> ---------------------------(end of broadcast)---------------------------
> TIP 9: In versions below 8.0, the planner will ignore your desire to
> choose an index scan if your joining column's datatypes do not
> match
>
>

--
View this message in context: http://www.nabble.com/ODBC-error-tf2971825.html#a8390489
Sent from the PostgreSQL - odbc mailing list archive at Nabble.com.


---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

Re: ODBC error

am 16.01.2007 17:36:13 von Tom Lane

ANJANE writes:
> Error while executing the query; ERROR: pg_class_aclcheck: relation 6017860
> not found
> the relation oid keeps changing. Not sure what this means.

It looks like it means corrupt system catalogs :-(. If you're lucky,
the problem is just in the indexes --- try reindexing pg_class and
see if that helps.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Re: ODBC error

am 17.01.2007 01:06:25 von Hiroshi Inoue

ANJANE wrote:
> As I said the query works intermittently. Whenever it fails, I get the
> following error message
>
> ..select tp_get_clientusers('1','S%', 'rcursor');fetch all in rcursor;
>
> Microsoft OLE DB Provider for ODBC Drivers error '80004005'
>
> Error while executing the query; ERROR: pg_class_aclcheck: relation 6017860
> not found
>
> /portal/testdb.asp, line 82
>
> the relation oid keeps changing. Not sure what this means.

You can't create tables and use them safely in stored procedures unless
you treat
them via EXECUTE commands..

regards,
Hiroshi Inoue


---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq