Home » Developer & Programmer » Forms » Login Status (forms6i &oracle 8i)
Login Status [message #480581] Mon, 25 October 2010 17:26 Go to next message
ahmed_best2001
Messages: 10
Registered: October 2010
Junior Member
hi

Using Forms 6i &oracle 8i

scenario

I hav a login form
On succesful login a new form is opened
i hav a status variable whose value gets change when login is successful(status=1)

Problem
if the window is closed directly or any power failure etc...

i want the status value to get updated(status=0)
I know i have to write an Update query bt on which trigger i hav to write it????
Thanks
Re: Login Status [message #480588 is a reply to message #480581] Mon, 25 October 2010 19:38 Go to previous messageGo to next message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
There's key-exit and when-window-closed but neither of those will fire in the event of a power failure - nothing will.
In fact there is no accurate way of coding events to occur whenever a user is disconnected from the system as far as I'm aware - and that's a problem in any language not just forms.
If your design relies on that then you need to change the design.
Re: Login Status [message #480589 is a reply to message #480588] Mon, 25 October 2010 19:46 Go to previous messageGo to next message
ahmed_best2001
Messages: 10
Registered: October 2010
Junior Member
yes CM Thanks for your reply Smile
I have tried it Sad
Is there any other way around to achieve the same task???

Thanks!!!
Re: Login Status [message #480597 is a reply to message #480589] Tue, 26 October 2010 00:30 Go to previous message
sasipalarivattom
Messages: 121
Registered: June 2007
Location: Cochin ( INDIA )
Senior Member
Dear Ahmed,

You can try using database session id. It is also not 100% accurate but is worth a try.
Whenever you connect to the database, a session id is assigned to you.
Keep this session id in your table on each login.
and when you want to check the login status of a user, check this session id too.
If the session id is active and your status is 1 then you can say the user is active.

In case of power failure or something like that, this session id will be expired in some time.
So you can rely on this.

The only concern is that the session id may stay alive for a little more time (I found maximum 5 mins) if you were exited forcefully.

Try this and please do reply your thoughts and findings.

Good Luck,
Regards,
Sasi
Previous Topic: Horizontal and verical scroll bar
Next Topic: FRM-41072 cannot create group list
Goto Forum:
  


Current Time: Thu Sep 19 17:16:12 CDT 2024