Home » RDBMS Server » Server Administration » i want to insert row in table t1
i want to insert row in table t1 [message #299893] Wed, 13 February 2008 09:18 Go to next message
Rafeek
Messages: 159
Registered: April 2007
Location: egypt
Senior Member
Hi
i want to insert row in table t1 when row delete from
VIEW v1
Quote:

CREATE OR REPLACE VIEW V1
select * from gv$session
where USERNAME='RAFEEK'


thanx
Rafeek
Re: i want to insert row in table t1 [message #299895 is a reply to message #299893] Wed, 13 February 2008 09:20 Go to previous messageGo to next message
Michel Cadot
Messages: 68683
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
You can't.

Regards
Michel
Re: i want to insert row in table t1 [message #299898 is a reply to message #299895] Wed, 13 February 2008 09:23 Go to previous messageGo to next message
Rafeek
Messages: 159
Registered: April 2007
Location: egypt
Senior Member
i want to insert row in tab1 when session is close
(row delete from gv$session)
thanx
rafeek
Re: i want to insert row in table t1 [message #299899 is a reply to message #299898] Wed, 13 February 2008 09:24 Go to previous messageGo to next message
Michel Cadot
Messages: 68683
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Create a trigger on logoff.

Regards
Michel

[Updated on: Wed, 13 February 2008 09:24]

Report message to a moderator

Re: i want to insert row in table t1 [message #299900 is a reply to message #299899] Wed, 13 February 2008 09:28 Go to previous messageGo to next message
Rafeek
Messages: 159
Registered: April 2007
Location: egypt
Senior Member
i Create a trigger on logoff but when the machine (client)
is turn off or restart the trigger not fire.
thanx
rafeek
Re: i want to insert row in table t1 [message #299901 is a reply to message #299900] Wed, 13 February 2008 09:32 Go to previous messageGo to next message
Michel Cadot
Messages: 68683
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
This is the only way.

You can also execute a job each minute to check which sessions disappear.

Regards
Michel

[Updated on: Wed, 13 February 2008 09:33]

Report message to a moderator

Re: i want to insert row in table t1 [message #299902 is a reply to message #299900] Wed, 13 February 2008 09:38 Go to previous messageGo to next message
Rafeek
Messages: 159
Registered: April 2007
Location: egypt
Senior Member
thax
it is the best way
Re: i want to insert row in table t1 [message #299908 is a reply to message #299902] Wed, 13 February 2008 10:42 Go to previous messageGo to next message
Michel Cadot
Messages: 68683
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Of course, you may miss some sessions if they last less than a minute or the like.

Regards
Michel
Re: i want to insert row in table t1 [message #300083 is a reply to message #299908] Thu, 14 February 2008 03:30 Go to previous messageGo to next message
Rafeek
Messages: 159
Registered: April 2007
Location: egypt
Senior Member
i try open 2 sessions (forms and report 6i)
and press restart button on my machine .
and form anther machine run
Quote:

select * from v$session
where USERNAME='username'


i get 3 sessions open (STATE = WAITING)
Re: i want to insert row in table t1 [message #300085 is a reply to message #300083] Thu, 14 February 2008 03:33 Go to previous messageGo to next message
Michel Cadot
Messages: 68683
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Yes, the Oracle session is waiting for your user to send something.
have a look at event it is surely something like 'SQL*Net message from client'.

Regards
Michel
Re: i want to insert row in table t1 [message #300096 is a reply to message #300085] Thu, 14 February 2008 03:59 Go to previous messageGo to next message
Rafeek
Messages: 159
Registered: April 2007
Location: egypt
Senior Member
i can not understand you
what do you mean.?
rafeek

[Updated on: Thu, 14 February 2008 04:02]

Report message to a moderator

Re: i want to insert row in table t1 [message #300097 is a reply to message #300096] Thu, 14 February 2008 04:05 Go to previous messageGo to next message
Michel Cadot
Messages: 68683
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Exactly what I said.
What part don't you understand?

Regards
Michel
Re: i want to insert row in table t1 [message #300100 is a reply to message #300097] Thu, 14 February 2008 04:12 Go to previous messageGo to next message
Rafeek
Messages: 159
Registered: April 2007
Location: egypt
Senior Member
i can not understand
(((have a look at event it is surely something like 'SQL*Net message from client'.)))
what do you mean??
rafeek
Re: i want to insert row in table t1 [message #300101 is a reply to message #300100] Thu, 14 February 2008 04:15 Go to previous message
Michel Cadot
Messages: 68683
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
In v$session there is a column EVENT and I bet the sessions associated to the clients you killed are waiting for such an event.

Regards
Michel
Previous Topic: Archive Files filling up
Next Topic: ora-00279
Goto Forum:
  


Current Time: Mon Sep 16 05:58:12 CDT 2024