10g declare :global variable error (bad bind variable)

In a 10g form, I tried this code in the pl/sql block and in the spec of a library package
begin
   :global.config := 'x';
...upon compile, I get an error
"bad bind variable"
...encountered the symbol "GLOBAL" when expecting one of the following...It doesn't like :GLOBAL.variablename := 'x';
What am I doing wrong?
Thank you.

globals are allowed in librarys, but in libraries you have to use COPY and NAME_IN to access objects you access via :-logic in forms-modules, e.g. setting the global would be like
COPY('X', 'GLOBAL.CONFIG');Edited by: aweiden on 29.10.2008 19:33

Similar Messages

  • Parameter error - bad bind variable in a Package..!!

    Hello All
    i am tring to create a security package with in one procedure i am trying to handle the number of times the user enters the wrong user name or password:
    -i created a parameter on my login form and add it to my procedure and it works just fine,But when i tried to copy the same procedure the package inside my library can't recognize that Parameter.
    -It gives me error : bad bind variable.
    The code is as follows.
    PARAMETER.COUNT := :PARAMETER.COUNT + 1;
    IF :PARAMETER.COUNT > 3 THEN
    WRONG_ALERT('WRONG_PASS',' ur number of trials has expiered the form will be closed ');
    EXIT_FORM;
    END IF;
    Can anyboady help me pls.
    Regards,
    Abdetu.

    Super,It works Just fine.
    Thanks Gerd,
    That's make me decide that if i have the following statatment for example:
    IF :USER_CODE IS NULL THEN .........
    I have to change it to :
    IF copy (name_in ('USER_CODE' )) IS NULL THEN..........
    But,if i have the following select statment :
    ==============================
         SELECT USER_CODE , USER_PASS WORD
         INTO :GLOBAL.USER_CODE , :GLOBAL.USER_PASS WORD
         FROM APP_USERS
         WHERE USER_CODE = :USER_CODE
         AND USER_PASS WORD= :USER_PASS WORD;
    Should i transfer it to the following:
    =========================
    SELECT USER_CODE , USER_PASS WORD
    INTO     COPY(NAME_IN ('GLOBAL.usr_code'), COPY(NAME_IN ('GLOBAL.PASSWORD')
    FROM APP_USERS
         WHERE USER_CODE = COPY(NAME_IN ('USER_CODE' )
    AND USER_PASS WORD=COPY(NAME_IN ('USER_PASS WORD');
    Pls help me,it's my first time ...
    Thanks in advance.
    Regards,
    Abdetu.

  • Image Item - Error: bad bind variable

    Hi All,
    I select a Image field from a table and set it to a Image Item in a form 10g. But I have error "Bad bind variable"
    Here is source code in my Post_query trigger:
    SELECT cust_sign INTO :dema_depo.dema_depo_sign
    FROM cust_sign WHERE custcod = :dema_depo.cust_sign_custcod;
    I would like to learn if you have any solution or document to solve my problem.
    Thanks very much for your help!
    BACH

    Dear Sir/Madam,
    I'm reading chapter 16: Working with Images - Oracle Forms Developer's Guide and found that cannot write a SELECT statement to select a a LONG RAW value INTO an image item.
    Thus, any the other way to fetch fr a DB LONG RAW value INTO an image item ???
    Many thanks!
    BACH

  • Syntax for declaring global variable in report

    Hello all,
    Kindly let me know syntax for declaring global variable in report?
    Thnks,
    SUnny

    Hi Sunny,
    All data declaration in the main program is global.
    Only if you do some data declaration withtin the subroutines then the scope of the variable is limited to that FORM ....ENDFORM.
    As you read in the above reply for a global variable in FM you need to declare in the top include.
    This means that you want this variable to be made available to all the Function Modules in that Function Group.
    If you want to make the variabe be available only within that FM then do the declaration in the source code itself.
    hope this explaination helps,
    Taher.

  • Declare global variable and retrive?

    Hi,
    we are working in live project in webtool, we wants to create global variable,
    calling that variable in a required pages, our questions is that where to declare global variable and how to declare in which page we have to declare?   pls guide us its very urgent and send the code.
    Regards
    Kannan.D
    Edited by: kannan desikan on Jan 14, 2008 8:07 AM

    Hi Kannan,
    I would suggest using a comma delimied list or putting it in the database.
    ArrayList myList = new ArrayList();
    myList.Add("one");
    myList.Add("two");
    myList.Add("three");
    string comma = "";
    // store the array in the session state
    foreach (string s in myList){
      Session["persistedArray"] += comma + s;
      comma = ",";
    To get the array back
    if (Session["persistedArray"] != null){
      ArrayList myList = Session["persistedArray"].ToString().Split(new char[1] {','});
    If your array is storing objects, you should use the database.

  • APEX: Declare global variable in APEX

    Hello All,
    Can anyone tell me how to declare global variable in Process(Pl/sql code) in Oracle APEX.
    Thanks,
    Jiten

    There is nothing like Global Variable that can be declared in Process in Apex.
    Look up Shared Components > Application Item. Maybe that is something that meets your requirement.
    Alternate, use Page 0 items.
    Regards,

  • PLS-00049 error :bad bind variable

    We recently migrated our dev databse to 10g
    for the following table the trigger is erroring out as follows :
    The same trigger works in 9i production though .Can anyone see anything that might be amiss
    CREATE TABLE ARCH_CLAIM_REJECTION_CODES
    REJECTION_ID NUMBER(38) NOT NULL,
    REJECTION_DESC VARCHAR2(600 BYTE),
    DT_STAMP NUMBER,
    DT_CREATED DATE,
    DT_LAST_UPDATED DATE
    INSERT INTO CLAIM VALUES (
    :OLD.REJECTION_ID,
    :OLD.REJECTION_DESC,
    :OLD.DT_STAMP,
    :OLD.DT_LAST_UPDATED,
    :OLD.DT_CREATED
    PLS-00049: bad bind variable 'OLD.REJECTION_ID'
    PLS-00049: bad bind variable 'OLD.REJECTION_DESC'
    PLS-00049: bad bind variable 'OLD.DT_STAMP'
    PLS-00049: bad bind variable 'OLD.DT_LAST_UPDATED'
    PLS-00049: bad bind variable 'OLD.DT_CREATED'

    REATE OR REPLACE TRIGGER ODSLIVE.TR_CLAIM_REJECTION_CODES_BUR
    BEFORE UPDATE ON CLAIM_REJECTION_CODES
    FOR EACH ROW
    DECLARE
    gv_errcode VARCHAR2(100);
    gv_errmsg VARCHAR2(100);
    BEGIN
    --DBMS_OUTPUT.PUT_LINE('TRIGGER CALLED FOR CLAIM_REJECTION_CODES');
    INSERT INTO ARCH_CLAIM_REJECTION_CODES VALUES (
    :OLD.REJECTION_ID,
    :OLD.REJECTION_DESC,
    :OLD.DT_STAMP,
    :OLD.DT_LAST_UPDATED,
    :OLD.DT_CREATED
    EXCEPTION
    WHEN OTHERS THEN
    gv_errcode :=SQLCODE;
    gv_errmsg :=SQLERRM;
    PKG_COMMONACTIVITIES.PR_ERRORLOG_DETAILS('TRIG-01-0001',
    gv_errcode,
    gv_errmsg,
    'TR_CLAIM_REJECTION_CODES_BUR',
    'CLAIM_REJECTION_CODES');
    --DBMS_OUTPUT.PUT_LINE('TM-01-0001 '||'TR_CLAIM_REJECTION_CODES_BUR '||'CLAIM_REJECTION_CODES'||gv_errmsg);
    --RAISE;
    END TR_CLAIM_REJECTION_CODES_BUR;

  • TRIGGER ERROR: bad bind variable

    Hello,
    I'm just starting off with oracle and am trying to do the same as auto_increment in mysql is doing by creating this sequence and trigger, but on the trigger I am getting the following error:
    error:
    PLS-00049: bad bind variable 'TAKEOVER_USERS.TAKEOVER_UID'This is the code for trigger, table and sequence:
    trigger:
    CREATE OR REPLACE TRIGGER  "TAKEOVER_USERS_T1"
    BEFORE
    insert on "TAKEOVER_USERS"
    for each row
    begin
    select TAKEOVER_UID.nextval into :takeover_users.TAKEOVER_UID from dual;
    end;Table:
    CREATE TABLE  "TAKEOVER_USERS"
       ( "TAKEOVER_UID" NUMBER NOT NULL ENABLE,
    "TAKEOVER_FBID" VARCHAR2(20) NOT NULL ENABLE,
    "takeover_accepted_terms" NUMBER(1,1) NOT NULL ENABLE,
    "takeover_lastName" VARCHAR2(30),
    "takeover_firstName" VARCHAR2(30),
    "takeover_country" VARCHAR2(40),
    "takeover_session" VARCHAR2(50) NOT NULL ENABLE,
    "takeover_created" TIMESTAMP (6) NOT NULL ENABLE,
      CONSTRAINT "takeover_users_PK" PRIMARY KEY ("TAKEOVER_UID") ENABLE
       )sequence:
    CREATE SEQUENCE   "TAKEOVER_UID"  MINVALUE 1 MAXVALUE 99999999999999 INCREMENT BY 1 START WITH 1 NOCACHE  NOORDER  NOCYCLEYou got any idea what I need to change to make this work?
    Thanks!
    Christine

    if your DB is 11g you can try this
    CREATE OR REPLACE TRIGGER  "TAKEOVER_USERS_T1"
    BEFORE
    insert on "TAKEOVER_USERS"
    for each row
    begin
    :NEW.TAKEOVER_UID:=TAKEOVER_UID.nextval;
    end;if 10g or older..
    CREATE OR REPLACE TRIGGER  "TAKEOVER_USERS_T1"
    BEFORE
    insert on "TAKEOVER_USERS"
    for each ROW
    BEGIN
    SELECT TAKEOVER_UID.NEXTVAL INTO :NEW.TAKEOVER_UID FROM dual;
    end;Regards,
    Prazy

  • How to declare global variables using another global variable in ODI

    I am declaring a gloabal variable using another global variable.
    say for example:
    I have a global variable empid.
    I am decalaring another global variable empname in refreshing tab of global variables and the select statment is
    select empname from emp where empno = #GLOBAL.empid -------if i write like this i am getting error as invalid character.
    select empname from emp where empno = '#GLOBAL.empid'-------if i write like this i am getting error as invalid number.
    I have kept the datatype as numeric and action as non persistent
    Please help
    Thank you in advance.

    Hi,
    You cant test/refresh empname standalone.
    You need to create a new package drag and drop both variables and make them as refresh variable and execute that package and test.
    Flow,
    empid----> empname
    Thanks,
    Guru

  • To declare global variable in enhancement Spot

    I have added 3 field which contain leave details of previous month in pe51 form and in enhancement spot FILL-ZK-MOD in Standard payslip progeam HINCEDT0 and  added code to calculate the leaves in this varaibles. now i require to display data of this variables on payslip.this varaibles are local to that enhancement hence could not able to access on form.
    if i can declare this varaible as global. is there any solution to this.

    Hi,
    Go to the include RPCEDDZ9 ...where you can declare.
    Thanks,
    Shailaja Ainala.

  • Getting a bad bind variable error while compiling a custom form in R12

    Hi,
    I am getting a bad bind variable error while compiling a custom form.
    I tried setting the forms_path variable and I am still getting the error. Can anyone please suggest what can be done?
    DECLARE
    BEGIN
    IF :parameter.p_line_ship_to = 'T'
    THEN
    IF :SYSTEM.cursor_item = 'LINE.SHIP_TO'
    THEN
    :parameter.lov_num_param1 := :line.ship_to_customer_id;
    oe_lines.ship_to ('WHEN-VALIDATE-ITEM');
    :parameter.lov_num_param1 := :line.ship_to_customer_id;
    END IF;
    :parameter.p_line_ship_to := 'F';
    END IF;
    END;
    I am getting this error:
    Bad bind variable 'parameter.p_line_ship_to'

    The Parameter is not defined in the form.. But, this form is already been compiled and deployed.. I have to make some changes to the form and tried to compile it, when i am getting this error. Is it possible that the parameter would be defined in some other form or can this error be due to some other reasons?
    Thanks in Advance.

  • Bad Bind Variable? I'm trying to make a host variable!

    Okay, so I've declared a global variable:
    VARIABLE g_total NUMBER
    and I want to use this variable to hold the results of a stored procedure (I minimized my code to focus on the problem area):
    CREATE OR REPLACE PROCEDURE my_procedure
    (p_price IN m_movies.price%TYPE
    p_quantity IN m_cart.quantity%TYPE)
    IS
    BEGIN
    :g_total := p_price * p_quantity;
    DBMS_OUTPUT.PUT_LINE('Order total is: '||:g_total);
    END;
    After all this, I get an error "bad bind variable g_total" for both lines I'm using it inside the procedure. What the heck is a bind variable? I'm using a host variable! (I think). Does this have anything to do with the fact that I can only assign a very generic NUMBER datatype to the host variable? Please help!

    Hi,
    Maybe the problem is in other place, because the code works fine (I commented column types because I don't have these tables):
    Connected to Oracle Database 10g Express Edition Release 10.2.0.1.0
    Connected as hr
    SQL>
    SQL> VARIABLE g_total NUMBER;
    SQL> DECLARE
      2     PROCEDURE my_procedure(p_price    IN NUMBER /*m_movies.price%TYPE*/,
      3                            p_quantity IN NUMBER /*m_cart.quantity%TYPE */) IS
      4     BEGIN
      5        :g_total := p_price * p_quantity;
      6        DBMS_OUTPUT.PUT_LINE('Order total is: ' || :g_total);
      7     END;
      8  BEGIN
      9     my_procedure(p_price    => 2,
    10                  p_quantity => 3);
    11  END;
    12  /
    PL/SQL procedure successfully completed
    g_total
    6
    SQL> Regards,

  • BADI for BI  Global Variables in Reporting

    Hi all,
    We have requirement in our project like, we want to write BADI for all BI Global Variable. As already Customer exit is available for all the BI global variable , but as there is limitation of IF-ENIF Statements in Include program of Customer Exit Function module , So we are planning to go BADI. Does any one have idea on BADI for BI global variable.
    Thanks in advance

    Kindly check below link for your kind information.
    http://www.scribd.com/doc/40764652/SAP-BI-Global-Report-Variable-User-Exit-Modularization
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60e34f63-f44c-2c10-488e-c89b04e0ca7c?quicklink=index&overridelayout=true
    How to declare Global variable in BADI
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/30de01e0-b6f5-2b10-fba1-b9193b82da2a?quicklink=index&overridelayout=true
    Re: virtual keyfigure using BADI
    Regards,
    Kamruz

  • Bad Bind Variables

    Hi all,
    I have created new form based on View.If i'm trying to update the values in base tables,but it is showing me the
    Error :BAD BIND VARIABLES 'cs_estimate_details.attribute2'
    WHEN-BUTTON-PRESSED i'm writing the code like this
    :block_name.item_name := :base_table.column_name;
    :xx_discount_manager_v.discount_rate := :cs_estimate_details.attribute2 ;
    Can i directly apply into base tables or not ,if any solution plss help me in this,urget
    if any bosy having code and which trigger used pls let me know
    Regards
    Siva

    If you want to updated the contents of the view from your form which is based on the view you may want to consider using the "instead of" trigger on the view.
    Regards,
    Tony
    @ Gerd
    Welcome back :)

  • Global Variables declaration in PI 7.1

    Hi All,
    In message mapping where can I declare global variables in PI 7.1.
    Thanks and regards
    Uma

    Hi Sarvesh,
    Thank you for the response.
    The blog given by you is on PI 7.0, But icon(Java Sections) is not present in PI 7.1 mapping editor .
    Please guide me how can I proceed further.
    Thanks & regards
    Uma
    Edited by: Uma Balasubramanya on Mar 20, 2009 1:11 PM

Maybe you are looking for

  • Contribute CS4 - Connection help

    I have a local copy of our intranet site on a file server (not my local machine).  Each time updates are required, using Dreamweaver I edit the 'local' file and then 'put' the file to the live web server. Is it possible to set up Contribute on a user

  • CSS disjointed rollovers with animation?

    im redesigning my site and for some reason my rollovers arent working. the top two thumbs are active.. nike and coke: http://www.toddheymandirector.com/SPOTS/index_2010.html would it make sense to try this in CSS? and can CSS do disjointed rollovers

  • Reason rewire audio problems

    Hi, I've followed all the instructions posted within this forum and in the manuals but I still cannot get Reason audio in Logic. Midi rewires fine between Logic and Reason, i.e. playing a rewire track in Logic does trigger the Reason rack - audio com

  • Loading fact

    hi every one, Can anyof u tell me how to load a fact? In my project i have loaded customer,salesrep,product,entity data from flatfiles to staging tables then loaded these tables to tgt ware house itables now i have to load facttable doing lookup on d

  • How to deploy fusion web application war file on weblogic

    Hi I am new to ADF. Please let me know how to create war file and the steps for deployment of war file . Its very urgent...