Home » Developer & Programmer » Forms » login form problem
icon4.gif  login form problem [message #457678] Tue, 25 May 2010 11:10 Go to next message
purelove
Messages: 32
Registered: May 2010
Location: bahrain
Member
hello every one,,,



well i had create a login form which contains 2 text-boxes and 2 buttons(- login & -exit)

the trigger when button pressed on login button is that:::
declare
cursor logon_cursor is
select usrname from student
where usrname = :USER_ID
and pass = :USER_PASS;

student_row logon_cursor%ROWTYPE;

BEGIN
:System.Message_Level := '25';
OPEN logon_cursor;
FETCH logon_cursor INTO student_row;
IF logon_cursor%FOUND
THEN GO_ITEM('student.usrname');
else
MESSAGE('Invalid username or password');
:USER_ID :='';
:USER_PASS :='';
GO_ITEM('USER_ID');
END IF;
:SYSTEM.MESSAGE_LEVEL := '0';
END;




well.,, i had also create a table "student" with 2 attributes
----usrname
----pass




please tell me whats the problem in that!!!

when i run the form and click on the login button ,it just clear the faild!!!!!!
Re: login form problem [message #457716 is a reply to message #457678] Tue, 25 May 2010 13:11 Go to previous messageGo to next message
purelove
Messages: 32
Registered: May 2010
Location: bahrain
Member
....???
Re: login form problem [message #457717 is a reply to message #457716] Tue, 25 May 2010 13:28 Go to previous messageGo to next message
Michel Cadot
Messages: 68686
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
!!!....
Re: login form problem [message #457722 is a reply to message #457678] Tue, 25 May 2010 14:04 Go to previous messageGo to next message
purelove
Messages: 32
Registered: May 2010
Location: bahrain
Member
please tell me whats the problem in that ...???
Re: login form problem [message #457732 is a reply to message #457722] Tue, 25 May 2010 15:10 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
It appears that logon_cursor%FOUND was not found.

Run the form in debug mode (if you're on 10g) or do it manually (using MESSAGE built-in) so that you'd know what is going on.
Re: login form problem [message #457734 is a reply to message #457678] Tue, 25 May 2010 15:25 Go to previous messageGo to next message
gregor
Messages: 86
Registered: March 2010
Location: Germany
Member

1, remove: ":System.Message_Level := '25'; " it isn't nessary at this point. when I look up to your sources.
2. when " cursor logon_cursor " answers "No DATA FOUND"..
..... you said: "it just clear the faild!!!!!! " ... I think the cursor has nothing found,
Re: login form problem [message #457736 is a reply to message #457734] Tue, 25 May 2010 15:48 Go to previous messageGo to next message
purelove
Messages: 32
Registered: May 2010
Location: bahrain
Member
i had remove ":System.Message_Level := '25'
but nothing change!!

also i run the form in debug mode!!! also the same things>>>>well it's just clear the fields>>when the user name and pass is correct o incorrect it just clear it,without displaying any of the messages what i had write it!!!

so what do u thing..??where is the problem...!!???
Re: login form problem [message #457784 is a reply to message #457736] Wed, 26 May 2010 00:43 Go to previous messageGo to next message
purelove
Messages: 32
Registered: May 2010
Location: bahrain
Member
please help me >>!!!!!!!!!!!!!!!!!!
Re: login form problem [message #457792 is a reply to message #457784] Wed, 26 May 2010 00:53 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Well, setting the message level to a certain value won't make any code work (which includes yours too).

You ran the form in debug mode. But, did you set the break point? (I guess not). So, you didn't, actually, debug anything.

Which values do you insert into USER_ID and USER_PASS items? What is the result of the following query when you run it in SQL*Plus (use the same values as in a form). Please, copy/paste your SQL*Plus session here.
select usrname from student
where usrname = &USER_ID
and pass = &USER_PASS;

icon2.gif  Re: login form problem [message #457891 is a reply to message #457792] Wed, 26 May 2010 05:11 Go to previous message
AZEEMSHAHKAZMI
Messages: 6
Registered: July 2009
Location: Pakistan
Junior Member

Hi, Purelove! just share the .fmb file and give the requirements, then we may help you...
Previous Topic: Where to download Oracle forms 4.5
Next Topic: value pass between two forms
Goto Forum:
  


Current Time: Thu Sep 19 19:56:19 CDT 2024