How to call method in JCD - which will execute prepared statement

Hi All,
I have a scenari where I have to call method in JCD, where in this method I have to execute prepared statement and return value.
Please suggest me how to do this.
Thanks & Regards,
Anitha.B

hi bolla,
this is 100% java code. can you elaborate a little more what is your exact problem?
i think your scenario is easy to accomlish.
regards chris

Similar Messages

  • How can I make a shortcut which will enter my email address in an input widow of a web page?

    how can I make a shortcut which will enter my email address in a website window.

    That is controlled by the web browser you are using. It is called Auto Fill in most of them. I don't use Safari so I'm not sure how that works in that browser.

  • How to call a Oracle Proc,which contains Object Type as in Param, from java

    Hi
    Would like to know how to call a Oracle Procedure which contains the Object Type Parameter from java.
    Here is my code will look like...
    1. CREATE OR REPLACE TYPE emp AS OBJECT
    Empno NUMBER,
    Ename VARCHAR2(50)
    [COLOR=royalblue]In step1 I have created object type.[COLOR]
    2.CREATE OR REPLACE PACKAGE ref_pkg IS
    TYPE tab_emp IS TABLE OF emp;
    END ref_pkg;
    [COLOR=royalblue]In step2,I have created a table type which is of type emp;[COLOR]
    3. CREATE OR REPLACE PROCEDURE p_emp(p_emptab IN ref_pkg.tab_emp) as
    BEGIN
    FOR I IN 1..p_emptab.COUNT
    LOOP
    Some code written here
    END LOOP;
    END;
    [COLOR=royalblue]In step3 I have passed tabletype which is of type emp as argument.[COLOR]
    Now I need to invoke this procedure from JAVA.
    Calling a procedure doesn�t matter.
    But how I can map objecttype ? how will java recognize oracle object ?
    How can I implement this ?
    Any Help/Clues is Appreciated.
    Thanks
    Krishna

    Hi Bob
    You can call a stored proc from a database control with the jc:sql annotation itself.
    Assume a stored proc taking one In parameter
    * @jc:sql statement="call sp_updateData({id})"
    void call_sp_updateCust(int id);
    You can even call stored proc with OUT parameters using
    * @jc:sql statement="{call sp_MyProc(?, ?)}"
    void call_sp_MyProc(SQLParameter[] params)
    You can also call stored functions via db control.
    More info and diff ways to call at
    http://e-docs.bea.com/workshop/docs81/doc/en/workshop/guide/controls/database/conStoredProcedures.html
    Thanks
    Vimala

  • How to Call Methods in Ecatt?

    Hello Gurus,
    I dont find CALLMETHOD or CALLSTATIC commands in Ecatt. I am using R/3 4.7 version of SAP.
    My question also is how to call methods. I have a scenario where my test script execution depends on the return type of method. Say if the return type of method is A only then I should run the script else the script should not be executed.
    Your help in this regard is highly appreciated.
    Regards,
    GS.

    >
    Get Started wrote:
    > Hello Gurus,
    >
    > I dont find CALLMETHOD or CALLSTATIC commands in Ecatt. I am using R/3 4.7 version of SAP.
    >
    > My question also is how to call methods. I have a scenario where my test script execution depends on the return type of method. Say if the return type of method is A only then I should run the script else the script should not be executed.
    >
    > Your help in this regard is highly appreciated.
    >
    > Regards,
    > GS.
    Hi GS,
    Please use the command "CallMethod" and it is available with latest SAP version.
    You have to provide the Object Instance Parameter and Instance Method.
    Regards,
    SSN.

  • How to create a user  y which will have the same content of existing user x

    how to create a user y which will have the same content of existing user x ,
    like all the tables,procedures,functions and packages

    You can do the following.
    1. Use CREATE USER to create the new account/schema
    2. Use exp to export old schema
    3 Use imp with fromuser=<old user> and touser=<newuser>

  • How to call Other webapplication resource ,which is in different contex.

    How to call Other webapplication resource ,which is in different contex.

    Hi,
    Hope you have a directory or the file path of the file stored in the application server.
    Please check this...
    Step1: Create a RFC function module in SE37 with exporting the file name with full path and importing to the table for storing the records of the file. You can use the open dataset for output statement for reading the data from the application server. Also check transaction CG3Z & CG3Y for uploading and downloading the file from application server.
    Step2: call this RFC enabled FM in your program with destination as target system(file stored) to get the data from the file.
    If you are not sure about the file path, then you the FM which you specified to get the actual and correct file path.
    Thanks!...
    Regards,
    Suresh.D

  • How to call method of Component A in Component B

    Hi Friends,
    I want to use Method A of Component A in Component B. Can some one tell me how to call method A on action of a button in component B.
    Regards
    Sankar

    Hi,
      DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.
      lo_cmp_usage =   wd_this->wd_cpuse_method( ).
      IF lo_cmp_usage->has_active_component( ) IS INITIAL.
        lo_cmp_usage->create_component( ).
      ENDIF.
    DATA lo_interfacecontroller TYPE REF TO yiwci_sg_method .
    lo_interfacecontroller =   wd_this->wd_cpifc_method( ).
      lo_interfacecontroller->execute_method(
           i was able to do the above process successfully but how to bind data to the node of component 2.
    In the component 1 : method A i defiend to get records upto 25 rows. now i tried using same method . but how to bind data using this method
    Regards
    sankar

  • How do I get a codec which will support my avi files?

    How do I get a codec which will support my avi files from my D90?

    Lightroom 5.5 is the latest version. If you don't want to wait for the next release, you can download Adobe DNG Converter 8.6RC which will transform your D810 NEFs into DNGs that the current version of Lightroom can use.
    Download Adobe Photoshop Camera Raw 8.6 Beta - Adobe Labs
    The above URL will evidently download both Camera Raw and the DNG Converter release candidates.
    Hal

  • How to call methode on remot computer

    I have 2 Applcations on 2 computers in Network
    App 1 on PC1 send xml file to App2 on PC2
    how to call Methods in App2 on PC2 to read the file
    // clss A on PC1
    class A
    sendFile(){
    // clss B on PC2
    class A
    readFile(){
    how to cal method readFile from Class A on PC1

    By using Remote Method Invocation, the topic of this forum.
    See the Javadoc and the RMI tutorials.

  • Which will execute first

    Hai,
    I am having Where class and having class in a single select query.. Which will execute at first.

    user12283394 wrote:
    Hai,
    I am having Where class and having class in a single select query.. Which will execute at first.select deptno, min(SAL), max(SAL) FROM EMP WHERE job='CLERK' group by deptno having count(*) > 3;
    You should read basic sql query comment..
    Refer :-
    http://dbis.ucdavis.edu/courses/sqltutorial/tutorial.pdf
    Regards
    Azar
    DBA

  • How to call methods from within run()

    Seems like this must be a common question, but I cannot for the life of me, find the appropriate topic. So apologies ahead of time if this is a repeat.
    I have code like the following:
    public class MainClass implements Runnable {
    public static void main(String args[]) {
    Thread t = new Thread(new MainClass());
    t.start();
    public void run() {
    if (condition)
    doSomethingIntensive();
    else
    doSomethingElseIntensive();
    System.out.println("I want this to print ONLY AFTER the method call finishes, but I'm printed before either 'Intensive' method call completes.");
    private void doSomethingIntensive() {
    System.out.println("I'm never printed because run() ends before execution gets here.");
    return;
    private void doSomethingElseIntensive() {
    System.out.println("I'm never printed because run() ends before execution gets here.");
    return;
    }Question: how do you call methods from within run() and still have it be sequential execution? It seems that a method call within run() creates a new thread just for the method. BUT, this isn't true, because the Thread.currentThread().getName() names are the same instead run() and the "intensive" methods. So, it's not like I can pause one until the method completes because they're the same thread! (I've tried this.)
    So, moral of the story, is there no breaking down a thread's execution into methods? Does all your thread code have to be within the run() method, even if it's 1000 lines? Seems like this wouldn't be the case, but can't get it to work otherwise.
    Thanks all!!!

    I (think I) understand the basics.. what I'm confused
    about is whether the methods are synced on the class
    type or a class instance?The short answer is; the instance for non-static methods, and the class for static methods, although it would be more accurate to say against the instance of the Class for static methods.
    The locking associated with the "sychronized" keyword is all based around an entity called a "monitor". Whenever a thread wants to enter a synchronized method or block, if it doesn't already "own" the monitor, it will try to take it. If the monitor is owned by another thread, then the current thread will block until the other thread releases the monitor. Once the synchronized block is complete, the monitor is released by the thread that owns it.
    So your question boils down to; where does this monitor come from? Every instance of every Object has a monitor associated with it, and any synchronized method or synchonized block is going to take the monitor associated with the instance. The following:
      synchronized void myMethod() {...is equivalent to:
      void myMethod() {
        synchronized(this) {
      ...Keep in mind, though, that every Class has an instance too. You can call "this.getClass()" to get that instance, or you can get the instance for a specific class, say String, with "String.class". Whenever you declare a static method as synchronized, or put a synchronized block inside a static method, the monitor taken will be the one associated with the instance of the class in which the method was declared. In other words this:
      public class Foo {
        synchronized static void myMethod() {...is equivalent to:
      public class Foo{
        static void myMethod() {
          synchronized(Foo.class) {...The problem here is that the instance of the Foo class is being locked. If we declare a subclass of Foo, and then declare a synchronized static method in the subclass, it will lock on the subclass and not on Foo. This is OK, but you have to be aware of it. If you try to declare a static resource of some sort inside Foo, it's best to make it private instead of protected, because subclasses can't really lock on the parent class (well, at least, not without doing something ugly like "synchronized(Foo.class)", which isn't terribly maintainable).
    Doing something like "synchronized(this.getClass())" is a really bad idea. Each subclass is going to take a different monitor, so you can have as many threads in your synchronized block as you have subclasses, and I can't think of a time I'd want that.
    There's also another, equivalent aproach you can take, if this makes more sense to you:
      static final Object lock = new Object();
      void myMethod() {
        synchronized(lock) {
          // Stuff in here is synchronized against the lock's monitor
      }This will take the monitor of the instance referenced by "lock". Since lock is a static variable, only one thread at a time will be able to get into myMethod(), even if the threads are calling into different instances.

  • How to call methods at selection screen?

    Hi all,
    I am developing a program in object oriented abap.
    i have defined a class and implementated, and we have to instantiate the class in start of selection.
    now the problem is how to call a method at selection screen event.
    i want to validate the inputs entered by users. so can i create a static method which can be called without instantiating a class?
    please guide me
    thanks

    Hello Mr A,
    Define the method as a Static Method and that will solve your problem. Static methods can be called directly and does not need the class to be instantiated before it can be called.
    Data: my_class type ref to zcl_report_utilities.
    At Selection-Screen.
    Call Method zcl_report_utilities=>check_selections
           exporting
              iv_repnm    = sy-cprog
            importing
              et_messages = lt_msgs.
    Start-Of-Selection.
      Create Object my_class
             exporting
                im_pernr  = ls_e1plogi-objid
                im_begda = c_lowdate
                im_endda = c_hidate.
       Call Method my_class->read_infotypes
              exporting
                 im_infty = c_org_assn
              changing
                 et_infty  = it_infty.
    Here you can see how the method check_selections is called before the class zcl_report_utilities is instantiated. The best part about the Static Methods is if you are writing the class in the Class Library (SE24), any other programs can call them directly (if they need to) without needing to instantiating the entire class before the call.
    Also note the difference in syntax when calling the static method check_selections to when calling the Instance method read_infotypes.
    Hope this solves your issue and please do not forget to reward points.
    Cheers,
    Sougata.
    p.s. if you are defining your class locally (program specific) then use Class-Methods to define a static method.
    Edited by: Sougata Chatterjee on May 1, 2008 9:53 AM

  • How to write Join View Adaptor which will pull data from Siebel and OID ?

    Hi Experts,
    I wanted to write web service call where OIF will talk to OVD than OVD will have join adaptor which will pull few data like msisdn from Siebel and view data from oid like given name and generate SAML assertion.
    I wanted to know how to write join adaptor for the same
    Help Appreciated.

    Hi Experts,
    Is anyone has any idea on webservice call to OIF which will call OVD that will have join adaptor connecting siebel and oid ?
    any help is appreciated

  • How to call methods from string names?

    On my java project i have a front controller. All the requests will first go to controller and i will make parameter validation on the controller level. If validation is completely ok, page will be dispatched to real servlet with validated parameters.
    If the request pattern is "photos" for example i will call static function and send referance of request object Validation.Photos(request); or if the pattern is "albums" function will be Validation.Albums(request).
    everything is ready on my codes except how to call a Validation function with a string name. Need a clear and a fast way because on every request i will do this.
    Thank you

    ahh life is problem;) another one i couldnt understand.
    import javax.servlet.http.HttpServletRequest;
    interface Validasyon {
            boolean invoke(HttpServletRequest request,String param);
         class IntIsNumeric implements Validasyon {
           public boolean invoke(HttpServletRequest request,String param) {
                param=request.getParameter(param);
                System.out.println("param="+param);
                try
                     Integer.parseInt(param);
                catch(NumberFormatException e)
                     return false;
                catch(NullPointerException e)
                     return false;
                int gelen1=Integer.parseInt(param);
                if(gelen1<1 || gelen1>Integer.MAX_VALUE)
                     return false;
                return true;
         }i am sending parameter to IntIsNumeric classes's invoke method like below
    Validasyon c=new IntIsNumeric();
    boolean a=c.invoke(request,"photo_id");but IntIsNumeric method does not recognize my input parameters "request" and "param" always return null. Why?

  • How to call method TH_SERVER_LIST/TH_WPINFO  module in perl script

    Hello,
    I need a perl code example on how we can call TH_SERVER_LIST/TH_WPINFO  modules ?
    Thanks in Advance,
    Amit

    Here's a script that will call TH_WPINFO:
    #!/usr/bin/perl -w
    use strict;
    use sapnwrfc;
    use Dumpvalue;
    SAPNW::Rfc->load_config;
    my $conn = SAPNW::Rfc->rfc_connect;
    my $rd = $conn->function_lookup("TH_WPINFO");
    my $rc = $rd->create_function_call;
    $rc->SRVNAME("apsrv235_RQA_00");
    $rc->invoke;
    foreach my $row (@{$rc->WPLIST}) {
         my $d = new Dumpvalue;
         $d->dumpValue(\$row);
    $conn->disconnect;
    which will produce output like this:
    -> HASH(0x9a6a0d0)
       'WP_ACTION' => 'Direct Read              '
       'WP_BNAME' => 'WFUSER      '
       'WP_CPU' => '        '
       'WP_DUMPS' => '0 '
       'WP_ELTIME' => '    1 '
       'WP_IACTION' => 10
       'WP_INDEX' => 55
       'WP_IRESTRT' => 1
       'WP_ISTATUS' => 4
       'WP_ITYPE' => 4
       'WP_IWAIT' => 0
       'WP_MANDT' => 100
       'WP_NO' => 55
       'WP_PID' => '536666  '
       'WP_REPORT' => 'SAPLTHFB                                '
       'WP_RESTART' => 'Yes '
       'WP_SEM' => '0 '
       'WP_SEMSTAT' => 0
       'WP_SERVER' => '                    '
       'WP_STATUS' => 'Running'
       'WP_TABLE' => 'SWWWIHEAD                     '
       'WP_TYP' => 'BGD'
       'WP_WAITINF' => '                                        '
       'WP_WAITING' => '     '
       'WP_WAITTIM' => '        '
    -> HASH(0x9a75074)
       'WP_ACTION' => '                         '
       'WP_BNAME' => '            '
       'WP_CPU' => '        '
       'WP_DUMPS' => '0 '
       'WP_ELTIME' => '    0 '
       'WP_IACTION' => 0
       'WP_INDEX' => 77
       'WP_IRESTRT' => 1
       'WP_ISTATUS' => 2
       'WP_ITYPE' => 6
       'WP_IWAIT' => 0
       'WP_MANDT' => '   '
       'WP_NO' => 77
       'WP_PID' => '520514  '
       'WP_REPORT' => '                                        '
       'WP_RESTART' => 'Yes '
       'WP_SEM' => '0 '
       'WP_SEMSTAT' => 0
       'WP_SERVER' => '                    '
       'WP_STATUS' => 'Waiting'
       'WP_TABLE' => '                              '
       'WP_TYP' => 'UP2'
       'WP_WAITINF' => '                                        '
       'WP_WAITING' => '     '
       'WP_WAITTIM' => '        '

Maybe you are looking for

  • What is Cell  Definition  (BW 3.5)

    Hi Experts, Could any of you explain what is the Cell definition and how that is useful in reporting (SAP BW 3.5) Please explain with a good example as Iam struggling to understand teh exact use of this. Points guaranteed. Thanks & Regards, Sunny

  • Error : Annual budget exceeded (FMAVC005)

    Dear guru, I want to create PR (ME51N), the net total amount is 50.000. But the error message shows : Annual budget exceeded by 11.812.000 IDR (FM PB Availability Control) for document item 00010 Message no. FMAVC005 Diagnosis The annual budget is ex

  • Simulate 1-N relationship as N-N by using Parent-Child structure

    Hi, i have a 1-N relationship between SKILL and USER tables meaning 1 skill can be applied to several users. A skill can have a parent skill meaning that a ParentSkill inherits all privileges of it's child. I would like to simulate a N-N relationship

  • Field functional area does not appear as an entry field into the document..

    Hi, We are using the functional area field in our system. In order to access this field, we proceeded to customize the system as follows: -  We already activate Cost of Sales Accounting for our Company Code. -  The field functional area was set optio

  • Unable to view reports in Telesales

    Hi, I am unable to view any standard reports from Telesales and Telesales Agent responsibility. Is there anything do I need to view the standard reports. Please guide as I am new to this module for implementation Thank you