-
Hi,
I was inserting a bulk data from one table to a partitioned table. I am using a terminal emulator which automatically ends connection with the host every 10-15 minutes.
Thus my session was closed. I donot know if the inserts will still be continuing or not. When queried on those tables, there will be a lock, so I am unable to get even the record count.
What should I do?
Badrinath
-
Query from v$session for INACTIVE sessions and kill them. The transaction will be rolled back.
-
But this is a ever occuring problem, so is there any way I can submit this 'sql ' to a background process, so that even if the terminal is off, still the inserts keep going on;
BAdrinath
-
Hello there,
I am not sure if I can help, but if it is unix, then:
You can send it on command line and end it with an & (to say run in the background).
eg if an sql script:
sqlplus system/manager @test.sql &
Good luck,
Nirasha
-
& wont work since the process would be killed after your session ends, may you could try nohup, check unix manual for this command
-
Why don't you wrap your INSERT into PL/SQL procedure and invoke that with DBMS_JOB? As yoon as you submit a job with dbms_job you can log off, since the yob is carried out entirely on server.
Jurij Modic
ASCII a stupid question, get a stupid ANSI
24 hours in a day .... 24 beer in a case .... coincidence?
-
u can use the "AT" function of UNIX in running the script.
do.
$ at now
at> sqlplus system/manager @test.sql
at> ^D
$
-
Combining the nohup and & solutions from previous posts is the way I tend to do it. If you do this, you may want to redirect any output to a log file (default is nohup.out)
e.g.
nohup sqlplus system/manager @test.sql &
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
|
Click Here to Expand Forum to Full Width
|