How to pass a comma as part of a PL/SQL Block Parameter?
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 4 of 4

Thread: How to pass a comma as part of a PL/SQL Block Parameter?

  1. #1
    Join Date
    Dec 2000
    Posts
    6
    These are the parameters I am trying to pass to my SQL Block.
    They are:
    Ledger: PPLI','PPNC
    Department: 9999
    DataType: AC
    When executing it from SQL Plus, I tried:
    kgl_deptexp_Load("PPLI','PPNC", "9999", "AC")


    I get the following error message:
    ORA-06550: line 1, column 24:
    PLS-00201: identifier 'PPLI','PPNC' must be declared
    ORA-06550: line 1, column 7:

    Any ideas??
    Thanks in advance!
    Kim

    What is the correct way to pass in this parameter?

  2. #2
    Join Date
    Oct 2000
    Posts
    123
    Try this:

    kgl_deptexp_Load('PPLI'||','||'PPNC', '9999', 'AC')


    Hope this will help.

    Take care

  3. #3
    Join Date
    Aug 2000
    Posts
    163
    You will have to edit the previous example.
    Try to play with someting like this:

    chr(34)||'PPLI'||chr(39)||','||chr(39)||'PPNC'||chr(34)
    Example of output
    1* select chr(34)||'PPLI'||chr(39)||','||chr(39)||'PPNC'||chr(34) argument from dual
    SQL> /
    ARGUMENT
    -------------
    "PPLI','PPNC"

    or something like this:
    'PPLI'||chr(39)||','||chr(39)||'PPNC'
    Example of output
    SQL> select 'PPLI'||chr(39)||','||chr(39)||'PPNC' argument from dual;
    ARGUMENT
    -----------
    PPLI','PPNC
    Look up Orcle chr() function. Post additional question here if you need more help.

  4. #4
    Join Date
    Dec 2000
    Posts
    43
    kgl_deptexp_Load('PPLI'||','||'PPNC', '9999', 'AC')
    will work fine just like mber has mentioned above.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width