Run the procedure works without slash

It's weird.
I'm in a plsql connected to a database session.

I can run a procedure as follows:
run status_pkg.check_owner_vcard (1,1,2);

However, I would like eventually to use variables, but when I try to do something like this:

SQL > declare
2 start
3 run status_pkg.check_owner_vcard (1,1,2);
4 end;
7 m
run status_pkg.check_owner_vcard (1,1,2);
*
ERROR at line 3:
ORA-06550: line 3, column 9:
PLS-00103: encountered the symbol "STATUS_PKG" when awaits an of the
Next:
:= . (@ %; immediate)
The symbol ': = ' was replaced by 'STATUS_PKG' continue.

It is not a function - procedure which could wait for oracle?
Any help appreciated
Rgds
Peter

sqlplus command does not work inside a plsql block. Remove it and your block should run.

Tags: Database

Similar Questions

  • Cannot run the procedure several times

    Hello

    I use oracle 12 c

    I just created a stored procedure that works very well

    Problem is that the second time I run it, it does not what it should (data fusion)

    When I run the second time I always get PL/SQL procedure successfully completed but the target table is still empty, here is the procedure:

    1 create or replace procedure MERGE_TABLEA

    2 as

    3. start

    4 MERGE TABLE_A has B (SELECT 'ID', 'NAME' OF TABLE_B) with the HELP of

    ON (A.ID = B.ID)

    WHEN MATCHED THEN

                     UPDATE SET B.SID = B.NAME

    WHEN NOT MATCHED THEN

    INSERT (A.' ID',' NAME')

    VALUES (B.ID, B.NAME);

    END;

    /

    PL/SQL procedure successfully completed.

    I also tried to build a simple procedure that id just insert and name of the table to test ina and it works very well, no matter how many times I've run it

    Is it maybe something with the merger or what?

    Thank you!

    OK guys, I think there are some misunderstandings here,

    @ddf_dba_ifox , version of the db that I use is stated in the first line of my post, I can't publish data for security reasons


    @rp0428 I forgot to mention that I'M to truncate the table, and then run the procedure again but the merger no longer works as the table is empty

    In any case, I found out why

    I'm merging the tables in the DB using the schema that is related to my installation of Oracle APEX

    In the procedure if you notice there is no COMMIT

    As apex has users within a schema, that I couldn't see the lines without committing before

    Thank you all anyway!

  • Dbms_metadata in a stored procedure. If the table is in the schema, run the stored procedure the procedure works very well.  If I try to get the table ddl to a different scheme it can't find table in a schema.  I run as an anonymous blocks and it works

    create or replace FUNCTION get_table_md (p_owner in varchar2, p_table IN VARCHAR2) RETURN CLOB IS
    -Define local variables.
    / * declare
    p_owner varchar2 (30): = "AVTYM";
    p_table IN VARCHAR2 (30): = "TRANSACTION_HEADER";
    */
    h NUMBER; -handle returned by OPEN
    e NUMBER; -handle returned by ADD_TRANSFORM
    p_tableref varchar2 (30);
    doc CLOB.
    Doc2 CLOB.
    BEGIN

    -Specify the type of object.
    h: = DBMS_METADATA. OPEN ('TABLE');

    -Use filters to specify the desired object.
    DBMS_METADATA. SET_FILTER (h, 'SCHEMA', p_owner);
    DBMS_METADATA. SET_FILTER (h, 'NAME', p_table);

    -Request that the metadata be transformed into creation DDL.
    th: = DBMS_METADATA. ADD_TRANSFORM (h, 'DDL');

    -Retrieves the object.
    doc: = DBMS_METADATA. FETCH_CLOB (h);


    -Free resources.
    DBMS_METADATA. Close (h);
    p_tableref: = substr (p_table, 1, 25). ' $RDEF';
    Doc2: is REGEXP_replace(doc,p_table,p_tableref,1,1,'im');.
    doc: = REGEXP_replace(doc2,'"CREATE_DT"','"EXCHANGE_DT"',1,2,'im');
    -dbMS_OUTPUT. Put_line (doc);
    RETURN doc;

    END;

    Hello

    check the privilege you may have granted by a role that you need direct access to the object and not by the role. You can test if you are granted by a role, by running the SET command role no and see if you can still run the anonymous block.

    Thank you

  • Apex 4. Run the procedure to recover my files

    Dear all,

    I experience a problem moving my apex application (sss) to a new server.
    I export demand for 3.2 APEX to APEX 4.0 new
    + transfer of data using a simple DB dump (export).

    Everything will work perfectly except our main application functionality, sitting on the workspace of "HR_PRD" that we have a few problems.

    In our DB schema called "HR_REP" I have a table that stores BLOBs for download a document attached to a record of the employee.
    So I created a package that contains the custom procedure to download the files stored in the table "wr_docs".

    URL = http://sphfrapex01.hopfr.net.fr.ch:8080/apex/HR_PROD.wr_apputil.download_my_file?p_file=3655106341169143


    I can download the file whithout any problems and it appears correctly in the report showing all my files.
    BUT when it tries to download... Unfortunately, access to the file does not work on the new APEX 4.0 platform!

    As this sounds like a simple question 'rights', I did several tests...

    I tried to create a simple procedure on my 'old' server called 'TEST' which simply print a simple text:
    HTP. ("test to print something");

    Here, I granted AUDIENCE to perform this procedure.
    It works well on the APEX 3.2 platform when on the new APEX 4.0, refusal to execute the procedure.

    Can you help me please?
    I'm certainly missing something obvious thanks to the GRANT run the TEST at?

    I granted AUDIENCE, so the appeal should work...


    I have to admit, I'm a bit lost here.

    Thanks in advance for your help.
    Philippe Kilchoer

    Hi Philippe,.

    using EPG to APEX? You may have forgotten to update WWV_FLOW_EPG_INCLUDE_MOD_LOCAL to include your procedure. Take a look on

    http://download.Oracle.com/docs/CD/E14373_01/AppDev.32/e13363/up_dn_files.htm#CJACBEHG

    Concerning
    Patrick
    -----------
    My Blog: http://www.inside-oracle-apex.com
    APEX 4.0 Plug-Ins: http://apex.oracle.com/plugins

  • To run the file .fmx without application server installed

    Hello

    I installed Oracle database 10g and Oracle Developer Suite 10 g. In Developer Suite, I use form of Oracle 10 g and I can browse Oracle Form + OC4j file .fmb but I can not run the .fmx file. I don't really know how to make it work without installing Oracle Application Server.

    Please help me for this. Thanks in advance.

    Kind regards
    Afonso

    Go through the basics of deployment of forms

    http://download-East.Oracle.com/docs/CD/B14099_19/Web.1012/b14032/basics.htm

    You must add your folder where you kept your fichiers.fmx/.mmx,/plx to the FORMS_PATH variable in default.env

    Or create a configuration section in the formsweb.cfg file

    Run the form by using the browser
    http://MachineName:port/forms/frmservlet? configname
    or
    http://MachineName:port/forms/frmservlet? form = formname & userid

  • Run the procedure after the application deployment

    Hi all

    I faced a small question.
    When I deploy my application to another server - it must run a procedure (this means that the procedure must be run once immediately after successful deployment).
    It takes to update some records in the system tables.

    Apex supports characteristic or something like that?

    APEX 4.1

    Thank you

    Published by: Rod 13.05.2013 confidence 0:56

    Cane Trust wrote:

    I faced a small question.
    When I deploy my application to another server - it must run a procedure (this means that the procedure must be run once immediately after successful deployment).
    It takes to update some records in the system tables.

    Apex supports characteristic or something like that?

    APEX 4.1

    How do you deploy your application? The documentation contains all the details of creating a packaged application with all dependencies for database included as items of support. Your procedure must be performed in one of these objects support scripts.

  • Run the procedure by table number

    Hello

    Oracle 11.2.0.1
    Windows

    Create the np_type type is varray (3) of the number
    /

    Create the cn_type type is varray (3) the number;
    /

    Create the cxn_type type is varray (3) of varchar2 (2000)
    /

    I created the TEST table by pl/sql block below:

    declare
    execstr varchar2 (2000): =' create table test(';)
    Start
    because me in 1.80 loop
    execstr: = execstr | 'col ' | TO_CHAR (i) | 'number,';
    end loop;
    execstr: = substr (execstr, 1, length (execstr)-1);
    execstr: = execstr | ')';
    dbms_output.put_line (execstr);
    run immediately execstr;
    end;
    /

    create the table sp_table (Splitid number, Delimiterlength number);
    insert into sp_table values (1.4);
    insert into sp_table values (2.7);
    insert into sp_table values (3.9);
    insert into sp_table values (4.1);
    insert into sp_table values (5.2);
    insert into sp_table values (6,6);


    create or replace procedure myproc1
    (
    STRX in varchar2, delarray in np_type)
    as
    execstr varchar2 (2000);
    CN cn_type.
    CXN cxn_type;
    XPos number: = 1;
    Start
    execstr: = ' insert into test values(';)
    because loop me in 1.3
    Select Delimiterlength in the sp_table (i) cn where Splitid = delarray (i);
    CXN (i):=substr(STRX,XPos,CN(i));
    execstr: = execstr | CXN (i) | ',';
    XPos: = (i) cn + xpos;
    end loop;
    execstr: = RTRIM (execstr, ','). ')';
    dbms_output.put_line (execstr);
    -execution immediate execstr;
    end;
    /

    SQL> declare
      2    v np_type:=np_type(4,4,4);
      3    begin
      4    --dbms_output.put_line(v(3));
      5    exec myproc1('111',v);
      6    end;
      7  /
      exec myproc1('111',v);
           *
    ERROR at line 5:
    ORA-06550: line 5, column 8:
    PLS-00103: Encountered the symbol "MYPROC1" when expecting one of the
    following:
    := . ( @ % ;
    The symbol ":=" was substituted for "MYPROC1" to continue.
    
    SQL>
    The procedure above will insert the numbered string supplied in the test table that splits the chain numbered inspires provided splitids of sp_table.

    In fact, I tried to help a member of the forum for his question, but I'm not get where I get the above error. Of course, there is little that miss me, but not that. This thread is running too in this forum.

    Please help me.

    Concerning
    Girish Sharma
    create or replace procedure myproc1
    (
    strx in varchar2, delarray in np_type)
    as
    execstr varchar2(2000);
    cn cn_type := cn_type(null, null, null);
    cxn cxn_type := cxn_type(null, null, null);
    xpos number:=1;
    begin
    execstr := 'insert into test values(';
    for i in 1..3 loop
    select Delimiterlength into cn(i) from sp_table where Splitid = delarray(i);
    cxn(i):=substr(strx,xpos,cn(i));
    execstr :=execstr || cxn(i) || ',';
    xpos :=cn(i) + xpos;
    end loop;
    execstr := RTRIM(execstr,',')|| ')';
    
    dbms_output.put_line(execstr);
    --execute immediate execstr;
    end;
    /
    

    and

    declare
        a1 number :=4; a2 number :=4; a3 number :=4;
        v np_type:=np_type(a1,a2,a3);
        begin
        for i in 1..3 loop
        dbms_output.put_line('v(' || i || ') = ' || v(i));
        end loop;
        myproc1('111',v);
        end;
    /
    

    Your varrays are null or empty in myproc1

  • Cannot run the procedure

    Hello


    I'm able to run this procedure.

    I created the procedure successfully.

    CREATE OR REPLACE PROCEDURE update_LOGIN_TABLE (NAMER OUT VARCHAR2)
    IS
    temp_num NUMBER;
    BEGIN
    temp_num: = 10;
    DBMS_OUTPUT. Put_line (temp_num);
    Setting a DAY to the USER SET NAME = 'Ranga' where NAME = NAMER;
    COMMIT;
    EXCEPTION
    WHILE OTHERS THEN
    ROLLBACK;
    END update_LOGIN_TABLE;
    */*


    It comes to my Table Structure:

    SQL > select * from users;
    PASS NAME
    -------------------- --------------------
    Sai Baba
    SAI Natha
    roux keyboard
    roux keyboard


    When I tried to run, I get this: execute update_LOGIN_TABLE ('good');


    SQL > execute update_LOGIN_TABLE ('good');
    BEGIN update_LOGIN_TABLE ('good'); END;

    ***
    ERROR on line 1:
    ORA-06550: line 1, column 26:
    PLS-00363: 'delighted' expression cannot serve a purpose of assignment
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored

    update_LOGIN_TABLE (NAMER OUT VARCHAR2)

    I think you probably wanted an IN argument in your procedure.

  • Not able to run the procedure

    Hello world

    I am trying to execute the procedure below,

    CREATE or REPLACE procedure test1 (n1 n2 in number, number, tot OUT number)
    is
    i the number: = null;
    Start
    loop
    If n2 > n1 then
    i: = i + 1;
    tot: = n1 + i;
    dbms_output.put_line (tot);
    elsif n2 < 1 then
    dbms_output.put_line ('enter a higher value for n2');
    end if;
    end loop;
    end;
    /

    All I'm trying to do is to print the numbers according to the values we give during execution, but doesn't seem to work for me.
    IE.,.

    N1 = 1;
    N2 = 5;
    tot = 1,2,3,4,5;

    I'm sorry if there is a mistake in the procedure and would be really grateful if you can help me with this. Thanks in advance for your help.

    Published by: Pravin on August 31, 2010 14:25

    If you want you can use this code it has the same logic

    CREATE OR REPLACE procedure test1(n1  IN number,
                                      n2  IN number,
                                      tot OUT number) is
      cnt number := 0;
    begin
      if n2 < n1 then
        dbms_output.put_line('Enter a higher value for n2');
      end if;
    
      for i in n1 .. n2 loop
        dbms_output.put_line(i);
        cnt := cnt + 1;
      end loop;
    
      tot := cnt;
    end test1;
    
  • How to run the oracle form without using a web browser

    I am a new developer in Oracle Form builder.
    Could someone tell me how can I use oracle without using a web browser?

    Bravo,

    N ° Web, since Forms 9i versions, are Web Client and needs an application server to run the forms runtime.

    François

  • Run the procedure once a year

    I have a procedure files and creating sequences that are used as serial numbers for some forms.
    For the moment, the admin user must click on a button, once a year to perform the procedure.

    I need to do this automatically every year eg 06:00 on 1 January.

    Can someone point me in the right direction

    Gus

    Hello

    At least you have some time to think about it! ;)

    Have a look/google for DBMS_SCHEDULER - which should sort out you.

    See you soon

    Ben

  • How can I run the procedure without parameters.

    CREATE OR REPLACE PROCEDURE P1 ((nvl(A,'dkjf') VARCHAR2)
    IS
    BEGIN
    DBMS_OUTPUT. PUT_LINE(A||',');
    END;


    It gives me error

    I want to run in this mode exec p1;

    It should automatically take dkjf as a parameter;

    help required on this.
    CREATE OR REPLACE PROCEDURE P1 ( A VARCHAR2 default 'dkjf' )
    IS
    BEGIN
    DBMS_OUTPUT.PUT_LINE(A||',');
    END;
    
    begin
      p1;
    end;
    

    What do you expect?

  • How to run the form directly without having to open the form designer

    Hello Expert:

    Normally I run Oracle Form designer and print button.

    is there anyway that I can run it directly from IE without going into the Forms Designer.

    or I fom.fmx and compile the form already, is anyway to make it work directly without having to open the form designer.

    or even when to call form.fmx or compile the form from asp.net

    I use the Oracle 10 g Forms Designer.

    Thanks in advance.

    Published by: user11403781 on February 4, 2011 13:14

    You can run a form directly from a browser, assuming that the HTTP listener is running. In the case of Developer Suite, this would be OC4J. So, follow these steps:

    1 locate and open this file: ORACLE_HOME\install\portlist.ini

    2. take note of the value for ' * Oracle Developer Suite HTTP port. " It will probably be something like 8888 and 8889 or 8890 or something similar.

    3. start OC4J using the shortcut created during installation. It will be labeled something like "Start an OC4J Instance". This will open a DOS window. Do not close IT. Leave this session BACK will end the listener.

    4 once OC4J has initialized (you will see "... initialized" in the DOS window) open a browser and enter the following (replace you with host name and port requested in step 2 and form):

    http://YourHostname:port/forms/frmservlet?form=C:\myForms\helloworld.FMX

    If you are not able to get OC4J to initialize and remain running, attempts to run a form will fail. Also, if your machine is not registered DNS you can have problems using the host name in the URL. Instead use 'localhost' or '127.0.0.1 '. For example:

    http://127.0.0.1:8889/forms/frmservlet?form=test.FMX

  • I'm looking to move from Windows/Apple/logic and Cubase Cubase. My questions have to do with the current (2014) Mac mini, specifically the i5 $999 2.8 GHz with 8 GB of RAM. This computer will be powerful enough to run the current logic without any pr

    I'm looking to move from Windows/Apple/Logic Pro X and Cubase Cubase.

    My questions have to do with the current (2014) Mac mini, specifically the i5 $999 2.8 GHz with 8 GB of RAM.

    This computer will be powerful enough to run Logic Pro X DAW and Cubase 8 courses without any problem?

    I would say yes, but I post here too:

    Logic Pro

  • error code 80070424. I tried running the duaueng.dll without success

    I tried all possible solutions on all the forums I can find to get a solution on why my windows will not update.  I get the error code 80070424. I tried to launch the duaueng.dll thing, everything! Help, please!

    Adding to the position of Jose-

    Which Windows operating system?

    Vista: Windows Update error 80070424
    http://Windows.Microsoft.com/en-us/Windows-Vista/Windows-Update-error-80070424

    Win7: Windows Update error 80070424
    http://Windows.Microsoft.com/en-us/Windows7/Windows-Update-error-80070424

    Still no joy, then try: click Start, select run, type: regsvr32 c:\windows\system32\wuaueng.dll
    And then click OK. (Works for WinXP & Vista)

    If it is Vista you try this, restarted as like Vista Restart.

    Harold Horne / TaurArian [MVP] 2005-2011. The information has been provided * being * with no guarantee or warranty.

Maybe you are looking for

  • Parts of my site Wordpress stopped working in FF but are ok in Internet Explorer. Why?

    It was only in the last 2 days. Before no problem at all... I tried the clearing - cache, cookies, reinstalled et seq. restarted the computer. disabled each add-on individually. Started in safe mode. Oh and Fishworld a certain portion of it stopped w

  • My laptop cannot install windows update. Error found: 646

    My laptop cannot install the update to windows. Error found: 646

  • game does not open

    I downloaded a game and it worked the first time I've used it but when I went to open it a second time, that is to say that I can't run this game multilpe programs if it really say that the game is already open is not. What I can do and I don't reall

  • Question about DHCP on WRT54G

    Hi all: Could I use DHCP for wireless connection and assign IP private for PC for connection wiring? It will come into conflict with each other? Best regards Chen min

  • Vista has locked me

    I have read and read am lock out it won't take my password at all and it won't let me not even to restore or answer my drive its been like this 3 months after I got it I can't use java can enter for some programs at all right to update is there a num