Problem : ORA-31203: DBMS_LDAP: PL/SQL – Init Failed.

Problem : ORA-31203: DBMS_LDAP: PL/SQL – Init Failed.

Hi,

I received the following error. If someone worked on it then please explain me,

SQL> @C:oracleora92ldapdemoplsqltrigger.sql
Dropping Table EMP ..

Table dropped.

Creating Table EMP ..

Table created.

Creating Trigger LDAP_EMP ..

Trigger created.

SQL> @C:oracleora92ldapdemoplsqlempdata.sql
Trigger [LDAP_EMP]: Replicating changes to directory ..
LDAP Host                :
LDAP Port                : 389
Error code    : -31203
Error Message : ORA-31203: DBMS_LDAP: PL/SQL – Init Failed.
Exception encountered .. exiting

1 row created.


 

Solution: ORA-31203: DBMS_LDAP: PL/SQL – Init Failed.

looks like this is the line which is causing the issue.

emp_session := DBMS_LDAP.init(ldap_host,ldap_port);

your ldap_host variable is null. why this is not initialized with others?

Can you try to dummy trigger and just put the code only till this and see whether this call is getting success or not.