A script-enabled browser is required for this page to function properly.

LOGON Built-in

Description

Performs the default Oracle Forms logon processing with an indicated username and password. Call this procedure from an On-Logon trigger when you want to augment default logon processing.

Syntax

PROCEDURE LOGON
(username VARCHAR2,
password
VARCHAR2);

PROCEDURE LOGON
(username VARCHAR2,
password
VARCHAR2,
logon_screen_on_error
VARCHAR2);

Built-in Type unrestricted procedure

Enter Query Mode yes

Parameters

This Built-in takes the following arguments:

username 
 
Any valid username of up to 80 characters.
 
password 
 
Any valid password of up to 80 characters, including a database connect string.
 
logon_screen_ on_error 
 
An optional BOOLEAN parameter that, when set to TRUE (default), causes Oracle Forms to automatically display the logon screen if the logon specified fails (usually because of a incorrect username/password). When logon_screen_on_error is set to FALSE and the logon fails, the logon screen will not display and FORM_FAILURE is set to TRUE so the designer can handle the condition in an appropriate manner.

Usage Notes:

When using LOGON to connect to an OPS$ database use a slash '/' for the user.name and the database name for the password..

LOGON Restrictions

LOGON Examples

/*

** Built-in: LOGON
** Example: Perform Oracle Forms standard logon to the ORACLE
** database. Decide whether to use Oracle Forms
** Built-in processing or a user exit by consulting a
** global flag setup at startup by the form,
** perhaps based on a parameter. This example
** uses the 'Get_Connect_Info' procedure from the
** GET_APPLICATION_PROPERTY example.
** Trigger: On-Logon
*/
DECLARE
un VARCHAR2(80);
pw VARCHAR2(80);
cn VARCHAR2(80);
BEGIN
/*
** Get the connection info
*/
Get_Connect_Info(un,pw,cn);
/*
** If at startup we set the flag to tell our form that we
** are not running against ORACLE, then call our
** appropriate MY_LOGON userexit to logon.
*/
IF :Global.Non_Oracle_Datasource = 'TRUE' THEN
User_Exit('my_logon username='||un||' password='||pw);
/*
** Otherwise, call the LOGON Built-in
*/
ELSE

/*  
** Use the following to place a slash in the username field for OPS$ logon  
*/  
IF un IS NULL THEN
un:='/';
END IF;
IF cn IS NOT NULL THEN
LOGON(un,pw||'@'||cn);
ELSE
LOGON(un,pw);
END IF;