Volatile Table Question

Database
Teradata Employee

Volatile Table Question

Hi All,

I have a volatile table in my session in SQL assistant. In one of the tab I run a sequence of inserts and at the same time in a different tab under the same session I run a select on the same volatile table with a access lock modifier. When these actions are happening in parallel, I'm getting an error saying the Object doesn't exist. PFB the queries.

 

Can anyone please explain me the reason behind this? Thanks in advance.

 

create volatile table abc (col1 integer) on commit preserve rows; insert into abc values(1);

 

insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1); insert into abc values(1);

 

locking row for access sel * from abc;

 

Regards, Deepan.


Accepted Solutions
Teradata Employee

Re: Volatile Table Question

From the online help for SQL Assistant:

 

Note: If you run multiple queries from different tabs within the same Query window, SQL Assistant temporarily connects additional sessions using the same connection information you entered for the initial connection. No special context is available to these additional sessions, however, so do not assume that the default database (if you have changed it) or temporary tables are available. If your queries rely on the default database, or on the existence of temporary tables, you should execute/run only one query at a time from within a specific Query window. This ensures that each query uses the same session that was used by the previous query.

1 ACCEPTED SOLUTION
2 REPLIES
Teradata Employee

Re: Volatile Table Question

From the online help for SQL Assistant:

 

Note: If you run multiple queries from different tabs within the same Query window, SQL Assistant temporarily connects additional sessions using the same connection information you entered for the initial connection. No special context is available to these additional sessions, however, so do not assume that the default database (if you have changed it) or temporary tables are available. If your queries rely on the default database, or on the existence of temporary tables, you should execute/run only one query at a time from within a specific Query window. This ensures that each query uses the same session that was used by the previous query.

Teradata Employee

Re: Volatile Table Question

Thanks Fred for the clarification.