Home » Developer & Programmer » Forms » HELP : PROBLEM IN MENU .
HELP : PROBLEM IN MENU . [message #204313] Mon, 20 November 2006 02:04 Go to next message
lunate
Messages: 74
Registered: October 2006
Location: Pakistan
Member

HI ALL.
I M CREATING A MENU.
THEN I WANT TO ADD PROGRAMME UNIT IN MENU_ITEM.
BUT IT GIVE ME THE FOLLOWING ERROR.


PROCEDURE SEARCH IS
BEGIN
SELECT E_CODE,E_DESCRIPTION INTO :EDUCATION_CODES.E1,:EDUCATION_CODES.E2
FROM EDUCATION_CODES
WHERE E_CODE =:EDUCTAION_CODES.E1;

END;
WHEN I COMPILE IT.
>> ERROR.BAD BIND VARIABLE EDUCATION_CODES.E1

MY TABLE NAME IS "EDUCATION_CODES" AND IT HAS 2 COLUMNS.
(E_CODE,E_DESCRIPTION.)

PLEASE HELP ME.
Re: HELP : PROBLEM IN MENU . [message #204358 is a reply to message #204313] Mon, 20 November 2006 05:29 Go to previous messageGo to next message
dawood
Messages: 5
Registered: November 2006
Junior Member
may be you can try like this but i am not sure that this is correct one for your question..
SQL> update education_codes
2 set e_con = 1
3 where e_code = 'abcd';

1 row updated.

SQL> ed
Wrote file afiedt.buf

1 update education_codes
2 set e_con = 2
3* where e_code = 'efgh'
SQL> /

1 row updated.

SQL> select * from education_codes;

E_CODE E_DESCRIPTION E_CON
-------------------- -------------------- --------------------
abcd proceed 1
efgh cancel 2

SQL> create or replace procedure search
2 (education_code out varchar2,
3 education_code1 out varchar2)
4 is
5 begin
6 select e_code, e_description
7 into education_code, education_code1
8 from education_codes
9 where e_code = education_code;
10 end search;
11 /

Procedure created.

SQL> ed
Wrote file afiedt.buf

1 create or replace procedure search
2 (e_co in varchar2,
3 education_code out varchar2,
4 education_code1 out varchar2)
5 is
6 begin
7 select e_code, e_description
8 into education_code, education_code1
9 from education_codes
10 where e_con = e_co;
11* end search;
SQL> /

Procedure created.

SQL> set serveroutput on
SQL> /

Procedure created.

SQL> execute search(1, :g_code, :g_code1);
Bind variable "G_CODE1" not declared.
SQL> variable g_code varchar2(20)
SQL> variable g_code1 varchar2(20)
SQL> execute search(1, :g_code, :g_code1);

PL/SQL procedure successfully completed.

SQL> print g_code g_code1

G_CODE
--------------------------------
abcd


G_CODE1
--------------------------------
proceed
Re: HELP : PROBLEM IN MENU . [message #204394 is a reply to message #204358] Mon, 20 November 2006 07:52 Go to previous message
lunate
Messages: 74
Registered: October 2006
Location: Pakistan
Member

thanx dear
i will try it at home.
then reply u soon ok. Razz
Previous Topic: enable buttons after the query
Next Topic: key-crerec trigger in enter query
Goto Forum:
  


Current Time: Sun Feb 02 06:39:27 CST 2025