How to call a parametrized procedure from a htp.formsubmit

Hi there, i'm trying to call a procedure with parameters from my formsubmit. i would like to call that procedure once my submit button is pressed. I did this :
HTP.formOpen(twbkwbis.f_cgibin||'MyPackage.MyProcedure(param1, param2, param3, param4)');
twbkfrmt.P_PrintText('<input type=submit name=ACTION  value="Soumettre">');
HTP.formClose;
but i had that 404 error page not found .
i also did this :
twbkfrmt.P_PrintText( htf.formSubmit(NULL, 'Soumettre', cattributes=>'ONCLICK= " return MyProcedure(param1, param2, param3, param4) " ') );
and still the same error...does anyone have an idea to help me with this...thank you
Edited by: user11146505 on 2009-07-10 06:49
Edited by: user11146505 on 2009-07-10 06:51
Edited by: user11146505 on 2009-07-10 06:52
Edited by: user11146505 on 2009-07-10 06:52
Edited by: user11146505 on 2009-07-10 06:54
Edited by: user11146505 on 2009-07-10 06:55
Edited by: user11146505 on 2009-07-10 06:55
Edited by: user11146505 on 2009-07-10 06:57

Hello and welcome to the list,
To call your MyPackage.MyProcedure procedure as the submit action of a form use code like this:
HTP.formopen('MyPackage.MyProcedure ','POST');
HTP.formtext('param1');
HTP.formtext('param2');
HTP.formtext('param3');
HTP.formtext('param4');
HTP.formsubmit(cvalue=>'Soumettre');
HTP.formclose;Note that when your code gets called it will be passed named parameters corresponding to each of the fields defined in the form, so if your procedure has 4 paramters named param1, param2, param3, param4 then you need 4 fields on your form with the same names, additionally the should each be defined with a default value such as NULL since unfilled fields on the report are not guaranteed to be passed to your procedure. If you have fields in your form with names other than the paramter names in your procedure you will get an error.
As you can see there is no need to define the parameters in the formopen procedure, and no need to define an onclick handler on the submit button. Also you don't want to name the submit button unless you are going to pass the value of the buttons label (the cValue) to your procedure as a paramter.

Similar Messages

  • How to call a stored procedure from WorkShop

    Hello Everyone .. I'm quite new with WebLogic 8.1 & WorkShop, so please bare with
    me .. Today I'm simply trying to find out how to call a stored procedure from
    within workshop, using any of the DB Controls .. I see workshop provides a way
    create a Java Control, Rowset Control, but it wont easily allow for a stored procedured
    to be entered in place of the inline query .. Perhaps I've over looked it. Any
    advise on the best way to tackle this task will be appreciated.
    Atahualpa

    Atahualpa--
    Maybe this will help:
    http://edocs.bea.com/workshop/docs81/doc/en/workshop/guide/controls/database/conStoredProcedures.html
    Eddie
    Atahualpa wrote:
    Hello Everyone .. I'm quite new with WebLogic 8.1 & WorkShop, so please bare with
    me .. Today I'm simply trying to find out how to call a stored procedure from
    within workshop, using any of the DB Controls .. I see workshop provides a way
    create a Java Control, Rowset Control, but it wont easily allow for a stored procedured
    to be entered in place of the inline query .. Perhaps I've over looked it. Any
    advise on the best way to tackle this task will be appreciated.
    Atahualpa

  • How to call a stored procedure from EJB3/toplink essentials..?

    Hi,
    I want to call a stored procedure residing in the oracle 10 g Database from my application's data access layer, which is designed using EJB3/toplink essentials.
    I think this feature is not available right now in the EJB3 spec...any workaround with code if possible will be very help full...
    Thanks & Regards,
    Sarvesh

    This should help you....
    how to execute a stored procedure from ejb3.0 bean using entity manager

  • How to call multiple stored procedure from same DB Adapter

    Hi,
    I want to invoke 3 stored procedures from my message flow in BUS . I created a DB adapter and invoked 1 successfully . Now I don't to configure 2 other DB adapters for calling other 2 stored procedures . I want some how to be able to call the other 2 from the first DB adapter only . Somehow I need the flexibility to have procedure names as the operation names in 1 wsdl and be able to configure this in JDeveloper for this at time of DB adapter configuration . I am using 11G . Is it possible ?

    You can probably create a DB adapter with operation type selected as Execute Pure SQL and write SQL code to invoke the stored procedures depending on the procedure name (which you can get as one of the parameters of DB Adapter).
    However, Even if you were able to do it, the DB Adapter schemas are generated based on stored procedure parameter list and types. If you use Execute Pure SQL type of DB Adapter the schema will be generated based on the parameters which you are using in your custom SQL code within DB Adapter. Which means that if you want to add a new stored procedure as target which has a different name and different parameters then you will need to regenerate the DB adapter and update your custom SQL code. This also means that you will need to do regression testing interfaces to all stored procedures whenever there is any change in this DBAdapter.
    Now, my question is why do you want to invoke multiple stored procedures from same DB adapter?
    This is not a good way to design integration solutions and makes your services resistance to change as it will take more time to change and test.
    If all that you want is to have a web service which can have different operations for different stored procedures then you should create three business services and create a wrapper proxy service which has one operation for each stored procedure, within the proxy transform and call the correct backend service (you can use operational branch). This way you have a modular code where each module (read interface to one stored procedure) can be independently modified and tested.

  • How to call Pl/sql procedure from form ?

    Hi all,
    I need to call a procedure from form after the user has pressed the button to invoke the sql procedure, can anyone please advise me on how to do it ?
    Thanks.
    Lim

    Hi,
    Thanks for your reply.
    yes, I have include in when-button-pressed trigger as
    AIC_PROC_AR_CCID_UPD;
    Below is my procedure :-
    CREATE OR REPLACE PROCEDURE AIC_PROC_AR_CCID_UPD(errbuf out Varchar2,
              retcode out Number ) is
    VAR_BUF VARCHAR2(240);
    Cursor C1 is
    SELECT CONCATENATED_SEGMENTS ACCT,
    SEGMENT5 SEG5
    FROM AIC_GL_COA AGC
    WHERE AGC.CODE_COMBINATION_ID IS NULL;
    Rec1 C1%RowType;
    BEGIN
    FOR Rec1 IN C1 LOOP
         BEGIN
         UPDATE AIC_GL_COA A SET ( DESCRIPTION, CODE_COMBINATION_ID, SEGMENT5 )=
         ( SELECT FFVT.DESCRIPTION, GLA.CODE_COMBINATION_ID, GLA.SEGMENT5
         FROM GL_CODE_COMBINATIONS_KFV GLA,
         FND_FLEX_VALUES_TL FFVT,
         FND_FLEX_VALUES FFV
         WHERE GLA.CONCATENATED_SEGMENTS = REC1.ACCT
         AND FFV.FLEX_VALUE = REC1.SEG5
         AND FFV.FLEX_VALUE_ID = FFVT.FLEX_VALUE_ID
         AND FFV.FLEX_VALUE_SET_ID = 1002673 )
         WHERE A.SEGMENT5 = REC1.SEG5 ;
         EXCEPTION
         WHEN NO_DATA_FOUND THEN
         FND_FILE.PUT_LINE(FND_FILE.OUTPUT, 'NO RECORD UPDATE !!');     
         END;
    END LOOP;
    COMMIT;
    RETURN;
    END;
    However, when I try to compile it, error prompt :-
    Error 306 at line 1, column 1
    wrong number or types of arguments in call to 'AIC_PROC_AR_CCID_UPD'
    Error 0 at line 1, column 1
    statement ignored.
    By the way, my form 6i is running at client site and connection to procedure in unix server. Will this is ok ?
    Thanks
    Rgds
    Lim

  • How to call PL/SQL procedure from PERL

    I have a requirement to create a PERL wrapper for few PL/SQL procedure.
    Can any one tell me how to call the procedures from PERL ?
    Thanks in advance.
    ....srini

    A quick Google search shows:
    http://www.saturn5.com/~jwb/dbi-examples.html#ora_sp

  • How to call a stored procedure from servlet?

    Hi all
    We are developing a project in servlet which needs to call a stored procedure in oracle 8i database.How to make a call? Whether can i get any data from the database using STORED PROCEDURE
    THANKS IN ADVANCE
    kamalakannan

    Hello,
    You can do an HTTP call from a store procedure using thre UTL_HTTP package; so you should be able to call your servlet this way.
    See UTL_HTTP documentation
    Regards
    Tugdual Grall

  • How to call a default procedure from event handling...

    Hello All,
    I am new to Oracle Application Server Portal. I have created a form and I want to update the table using custom update button. can any body tell me how to call the default doUpdate procedure from event handling..

    This should help:
    - http://download.oracle.com/docs/cd/B14099_19/portal.1014/b14135/pdg_portletbuilder.htm#BABFIHIF
    Cheers,
    Mick.

  • How to call a PLSQL procedure from MSexcel ?

    Hi all.
    This is a beginner question. I do not know anything about OLE DB.
    I have an Excel sheet on one side.
    I have a 9i DB 9.0.1.4 on Sun Sparc on the other side.
    I need to call a PLSQL procedure directly from Excel.
    HOW TO ?
    (This is simply because I need to pass eastern europe special caracters to my PLSQL procedure. Is there another way to do so?)
    Best Regards.

    In MS Excel you use VBA as the Macro Language.
    You will need to install the Oracle client and the OLEdb provider.
    Once this is done, Run the samples in Visual basic to test connectivity to your database (if you can).
    In either case, look at the VB code that connects and calls an Oracle stored procedure. THis code is almost identical in VBA.
    Make sure you reference the Microsoft ADO references.

  • How to call a stored procedure from my JSP?

    Hi to all,
              I have a very simple jsp page and a simple sql server stored procedure!
              I need to call this stored procedure by passing two parameters.
              My result set will have 4 columns.
              I would really appreciate any input on how to issue this call to a SP.
              I am new to JSP.
              Regards,
              Sam
              

              Sam,
              BEA provides examples that are shipped with the product under
              <beahome>\weblogic700\samples\server\src\examples\
              Look at the jsp directory for JSP examples that access a database and look at
              say the jdbc\oracle\storedprocs.java for an example of java code calling out to
              a stored procedure - - by combining one of the jsp database examples with this
              stored procedure example you should be 'good to go'
              Chuck Nelson
              DRE
              BEA Technical Support
              

  • How to call a Stored procedure from xsodata service?

    Hi Everyone,
    I have created an stored procedure and I'm trying to consume this store procedure from xsodata service.
    But unable to activate the service because of an error.
    Invalid procedure or parameter list in procedure "package.WebContent.src.hana.procedures::PROCEDURE
    I have activated both store procedure as well as attribute view.
    Here is my stored procedure.
    PROCEDURE "SCHEMA"."package.WebContent.src.hana.procedures::PROCEDURE" (
    IN row "SCHEMA"."package.tables::object" )
      LANGUAGE SQLSCRIPT
      SQL SECURITY INVOKER AS
      --DEFAULT SCHEMA <default_schema_name>
      --READS SQL DATA AS
    BEGIN
      Write your procedure logic
    declare shortdesc string;
    SELECT SHORT_DESCRIPTION INTO shortdesc FROM :row;
    END;
    Service:
    service namespace "package.WebContent.src.hana.service"{
    "package/OBJECT.attributeview" as "OBJECTS"
    key ("OBJECT_ID")
        create using "package.WebContent.src.hana.procedures::PROCEDURE";
    Is there anything wrong in the way i'm calling the procedure??

    Hi Arjun,
    You can expose the procedure as an Odata Service if you wrap it in a Scripted Calculation View..
    Firstly You will have to create a Scripted Calculation View from the Modeller perspective.
    Below is an example I just tried.
    Add Columns & Input Parameters
    Consume this Calc View in your Odata service :
    service namespace "services.test"
    "pda.Models::CV_TEST" as "Customer"
    keys generate local "ID"
    parameters via entity;
    Check your service by Passing the Input Parameters
    http://<host>:<port>/<>/services/test.xsodata/CustomerParameters(2)/Results?$format=json
    Hope this was Helpful
    Regards,
    Avinash Raju

  • How to call MSSQL stored procedure from oracle database

    MSSQL and Oracle databases are linked thru ODBC link using Oracle HSODBC.
    I can query MSSQL table or view from Oracle Database using standard notation for acessing remote objects schema.object@dblink_name...
    Can anybody give me syntax for calling MSSQL stored procedure thru ODBC database link?
    I tried syntax exec schema.stored_procedure@dblink_name but it doesn't work...i'm getting schema.stored_procedure must be declared error...
    Tnx,in advance!
    Dejan Botica

    Oracle database 10gR2.
    MSSQL2000 database.
    For example query:
    select * from dbo.Tbl_Test@kron@dw_jamnica; works fine...
    ...while for example exec dbo.Test@kron@dw_jamnica;
    reports error:
    ORA-06550: line 1, column 7:
    PLS-00201: identifier 'DBO.TEST@KRON@DW_JAMNICA' must be declared
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    Table Tbl_Test and procedure Test exists in MSSQL instance.
    Regards,
    Dejan

  • How to call PL/SQL procedure from Jdeveloper

    hai
    i am using JDeveloper 10g version 10.1.3. i am working on Web Application[JSF,ADF BC]. i had commit button in one form. when i click that button a PL/SQL procedure can be invoked.( the procedure is to check for primary key)
    how to do this
    thanks in advance
    C.R

    There are already some threads about calling PL/SQL from Java. E.g.: adf bc jsf application and database stored procedure
    Ronald

  • How to Call pl/sql procedure from shell script

    Hi,
    I've one procedure which takes the xml file name as input from one of the remote location. Every day users keep one file in that location.
    For eg:
    ACS_RPO00020110316_20110316220956.xml
    ACS_RPO00020110319_20110319220956.xml
    I need to read the latest file in this case. In this case second one is the latest file.
    Can some body please help me how to write script to pass parameter to that procedure that via shell program and execute that.
    Thanks in advance.
    Regards
    Nagendra

    hi
    I executed the below mentioned steps, but I did not get any result:
    I am pasting all the steps which I did
    -bash-3.2$ ls -lrt
    total 316
    -rw-r--r-- 1 oratest dba 4884 Mar 16 03:56 XXGEBIZ_EPO160320110356.xml
    -rw-r--r-- 1 oratest dba 4884 Mar 16 03:57 XXGEBIZ_EPO160320110357.xml
    -rw-r--r-- 1 oratest dba 4884 Mar 16 17:52 GEBIZ_ACS_RPO00020110316_20110316175216.xml
    -rw-r--r-- 1 oratest dba 38 Mar 16 18:18 GEBIZ_ACS_RPO00020110316_20110316181858.NODATA
    -rw-r--r-- 1 oratest dba 63 Mar 16 22:09 GEBIZ_ACS_RPO00020110316_20110316220956.xml
    -rw-r--r-- 1 oratest dba 9716 Mar 16 22:14 GEBIZ_ACS_RPO00020110316_20110316221429.xml
    -rw-r--r-- 1 oratest dba 12988 Mar 17 01:42 GEBIZ_POC_RPO000EPO20110317_20110317014247.xml
    -rw-r--r-- 1 oratest dba 13103 Mar 17 01:53 GEBIZ_POC_RPO000EPO20110317_20110317015356.xml
    -rw-r--r-- 1 oratest dba 38 Mar 17 01:57 GEBIZ_POC_RPO00020110317_20110317015712.NODATA
    -rw-r--r-- 1 oratest dba 38 Mar 17 18:44 GEBIZ_ACS_RPO00020110317_20110317184423.NODATA
    -rw-r--r-- 1 oratest dba 12326 Mar 17 18:46 GEBIZ_ACS_RPO00020110317_20110317184603.xml
    -rw-r--r-- 1 oratest dba 67578 Mar 18 01:32 GEBIZ_POF_RPO000EPO20110318_20110318013232.xml
    -rw-r--r-- 1 oratest dba 14484 Mar 18 20:27 GEBIZ_POF_RPO000EPO20110318_20110318202754.xml
    -rw-r--r-- 1 oratest dba 47653 Mar 19 01:29 GEBIZ_PYS_RPO00020110319_20110319012953.xml
    -rw-r--r-- 1 oratest dba 937 Mar 21 09:34 GEBIZ_SUPP.xml
    -rw-r--r-- 1 oratest dba 947 Mar 21 09:35 GEBIZ_SUPP1.xml
    -rwxrwxrwx 1 oratest dba 121 Mar 21 17:43 test
    -bash-3.2$
    -bash-3.2$ cat > test
    ls -lrt | tail -1
    filelist = $(ls GEBIZ_SUPP*.xml)
    for file in $filelist ; do
    echo "inside loop"
    file = $file
    echo "file name " $file
    done
    XGBZ_SUPP_MAST_XMLTAG_PROC $file
    -bash-3.2$ chmod 777 test
    -bash-3.2$ ./test
    -bash: ./test: Text file busy
    -bash-3.2$
    Initially I listed down all the files, in a sample file I've written the steps. But nothing is executed.
    One thing I want to ask here XGBZ_SUPP_MAST_XMLTAG_PROC is my procedure. I think I need to invoke sqlplus in the so as to execute my pl/sql script.
    Gurus, please let me know how to write them.
    Regards
    Nagendra

  • How to call a "web procedure" from ORACLE Framework

    I need to call a procedure which generates an HTML file from my java Controller
    The procedure I try to execute use some HTP methods
    like :
    HTP.p ('<tr ><td class="x2i"></td></tr> <tr><td width"100%"></td></tr>');
    The java code is :
    OADBTransaction tx = pageContext.getApplicationModule(webBean).getOADBTransaction();
    String call = "call FAO_HR_ABSENCE_HISTORY_REP_WEB.setup(?)";
    try{
    CallableStatement cs = tx.createCallableStatement(call,1);
    cs.setInt(1,pageContext.getEmployeeId());
    cs.execute(); //
    }catch(Throwable th)
    th.printStackTrace();
    throw new OAException(""+th.getMessage(), OAException.ERROR);
    When I try to run it I catch the error below :
    java.sql.SQLException: ORA-06502: PL/SQL: numeric or value error: NULL index table key value
    ORA-06512: at "SYS.HTP", line 1536
    ORA-06512: at "SYS.HTP", line 1714
    ORA-06512: at "APPS.ORACLEAPPS", line 1111
    ORA-06502: PL/SQL: numeric or value error
    ORA-06512: at "APPS.ICX_SEC", line 3111
    ORA-06502: PL/SQL: numeric or value error: NULL index table key value
    ORA-06512: at "SYS.HTP", line 1536
    ORA-06512: at "SYS.HTP", line 1714
    ORA-06512: at "APPS.ICX_SEC", line 3457
    ORA-06502: PL/SQL: numeric or value error
    ORA-06512: at "APPS.HR_UTIL_DISP_WEB", line 3518
    ORA-06512: at "APPS.FAO_HR_ABSENCE_HISTORY_REP_WEB", line 156
    ORA-06502: PL/SQL: numeric or value error: NULL index table key value
    ORA-06512: at line 1
         at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
    ........

    Matteo,
    A couple of things:
    Even if your procedure works fine, it will provide some html output which is not getting used in your code given above anywhere. What exactly do you want to achieve?
    I am not familiar with the HTP package. Probably this is not the way to use in case of OAF. If you explain your requirement, we can suggest you properly.
    --Shiv                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

Maybe you are looking for

  • VO Substitution error

    Can anyone please inform where exactly am I going wrong with VO substitution? Through Jdeveloper I was able to do substitute the standard VO in DEV & TEST instances. Now currently we are planning to migrate the extension to UAT and soon to PRODUCTION

  • I see that a lot of people like to use handbreak, is there a PC version?

    First of all, is it ok to talk about that stuff here on the apple forums, and if it is, I checked the website and it said they were working on a PC version, but is there any PC version equivelant that anyone would recommend?

  • URL only loads fully if firefox run as administrator! Why?

    I have a URL that I want to view. The URL stopped working on my Vista based laptop but still works OK on my windows 7 based PC. The URL is "http://www.xe.com/currencycharts/?from=GBP&to=CHF&view=1M". The bit that doesn't work is the display of the gr

  • /560 net pay getting cumulated every month

    /560 net pay wage type getting cumulated every month, I have entered the bank details also, Please suggest some solution. Its urgent Regards Abhimanyu

  • Messages gone

    i woke up this morning & all my text messages have been erased.  Any idea how to retrieve them or why they have been deleted?  don't like it since i didn't do it.