Best way to call SPROC

For now I am calling SPROCS from HTMLDB links and passing the app, page, and session. Then using htp.p to print out a <script> tag with window.location to redirect to a page in the app. Is there a better way to have the SPROC redirect to an HTMLDB page maintaining session state?

I call a SPROC via a URL from a link on an HTMLDB page. After execution of the SPROC, I want to go back to a different page of the HTMLDB app. I currently use the htp.p and have print out the following to the browser:
<script>
window.location="f?p=<app>:<page>:<session>";
</script>
I passed app, page and session into the SPROC via the URL.

Similar Messages

  • Best way to call EJB - Servlet or Tag Library

    Hi,
    What is the best way to call an EJB from a JSP? We are using Weblogic 7.0(moving to 8.1 beta). WE have a form on a JSP that needs to get data from an EJB. Our flow goes from JSP --> Controller servlet or tag library -->EJB "Bean" Controller ---> EJB. The specfic EJB we need to populate drop downs and fields will be called by a bean controller. Is it better to call the bean controller using a tag library in the jsp or go to the controller servlet to get the data? If servlet is the answer, where do I lookup the EJB Home and call the create from within the servlet? Any help would be greatly appreciated!!
    Thanks!

    IMO, if you are following some design patterns, like the MVC framework, the best thing is to populate the model(entities that contain the business data) and call the respective getXX methods from the model on the JSP page. The reason for doing so is to keep JSP pages away from any other work other than to just display the business data contained in the respective business entities.
    The model can be populated in the servlet and either set in the request or session attribute as per the requirement.
    The EJB can be looked up in the servlet as and when required. I would suggest to make use of the Service Locator Pattern to do a look up for the EJB Remote Interface and accordingly make the business calls.
    Hopefully this answers some of your questions.

  • What is the best way to call a report from within a report

    What is the best way to call a report from within a report(master / Detail concept)
    A type of drill down report
    Oracle Database 10g
    Forms 10.1.2.0.2
    Report Builder 10.1.2.0.2

    Hi
    Have a look in this link, certainly you will get fix, if not just post a comment on blog, will get reply soon
    http://windows7bugs.wordpress.com/?s=oracle+10g+bug

  • What is the best way to call a pageflow action from JavaScript?

    What is the best way to call a pageflow action from JavaScript?
    Thanks,
    John

    John,
    How would I do this from a grid??? Unfortunately there are no JavaScript attributes
    on any of the grid tags that I can see.
    Thanks,
    John
    "John H" <[email protected]> wrote:
    >
    Thanks John!
    "John Rohrlich" <[email protected]> wrote:
    John,
    If you want to put up a confirm dialog before calling an action from
    an
    anchor it is done as follows.
    Here is an example from code of mine that deletes a customer order,if
    the
    user confirms the delete. I pass the order id as a parameter.
    - john
    Here is the JavaScript -
    function confirmDelete() {
    if(confirm('Continue with order delete?'))
    return true;
    else
    return false;
    Here is a sample anchor tag -
    <netui:anchor action="requestToDeleteOrder" onClick="return
    confirmDelete(); return false;">
    Delete
    <netui:parameter name="orderId" value="{container.item.orderId}"/>
    </netui:anchor>
    "John H" <[email protected]> wrote in message
    news:402138f5$[email protected]..
    Thanks for the replies. I figured it was going to require buildingmy own
    url
    to call the action. I had hoped there was an easier way to do it.Rich,
    the
    reason I want to do this is because I want to call the JavaScript
    function
    confirm()
    when a user clicks on a link (in a repeater/grid) to drop a record,I only
    want
    to call the drop action if the user confirms the drop. Maybe thereis a
    better
    way to do what I am trying to do??? I really appreciate any help
    you
    guys
    can
    give me on this, I am pretty new to this sort of stuff.
    Thanks,
    John
    "Rich Kucera" <[email protected]> wrote:
    "John H" <[email protected]> wrote:
    What is the best way to call a pageflow action from JavaScript?
    Thanks,
    JohnTry figuring out the URL to the pageflow action, create a hidden
    form
    in the
    page, then use JS to submit the form. Why would you want to though,
    isn't
    the server going to want to send you to the next page?

  • Best way to call

    which is the best way to call a scotland mobile phone from skype? i been using pay as u go credit and its 8 cents a min and was wondering if a monthly thing or a subscription is the way to go

    Translation patterns are for internal use to manipulate a number and then a route pattern will be responsible for pushing it out the gateway or some other method.  If this DID is still being sent to you you could either manipulate this at the CUBE and hairpin it backout or send it to CUCM and hairpin it back after it gets translated with a translation pattern out a route pattern.  I would recommend doing everything at the gateway unless you want to keep some record that the number is in use which CUCM can do more effectively.
    This DID being used for a fax is elsewhere offnet at this point I take it?  Make sure you have the proper CSS's and partitions set for hair pinning if you do this on CUCM since by nature forwarding to external numbers is disabled by default (or at least it used to be as I recall).

  • Best way to call oracle db from BPEL 2.0

    Hi
    Anybody knows which is the best way to call select or call store procedures from BPEL 2.0 ? Do I need to use JCD (java collaboration definition in repository-based projects -caps 5.x) and oracle eWAY to interact with oracle database?
    Regards.

    You can also create a new WSDL with a concrete binding to DATABASE, as explained on http://wiki.open-esb.java.net/Wiki.jsp?page=CreatingAWSDLDocumentForTypeDATABASE
    BRs
    Kris

  • What is the best way to call SSH commands through Java technologies

    What is the best way to call SSH commands through Java technologies

    I don't think you can specify the password at the prompt using ssh. Plink has the -pw command option for passwords. What I did was except ssh to ask me and write the password programmatically through the outputStream I obtained from my Process object. I looked for "password: ", and then wrote the password with a trailing newline.
    Both plink and ssh will also ask if you trust the host if it is the first time you are connecting to it. So before just writing the password, check if the program wants verification from you: normally supplying "y" or "n". This should only have to happen the first time the client connects. It looks like thisPLINK:
    The server's host key is not cached in the registry. You
    have no guarantee that the server is the computer you
    think it is.
    The server's key fingerprint is:
    1024 f8:43:61:4c:a2:5b:77:be:5b:a7:bb:1f:f7:79:b3:b7
    If you trust this host, enter "y" to add the key to
    PuTTY's cache and carry on connecting.
    If you want to carry on connecting just once, without
    adding the key to the cache, enter "n".
    If you do not trust this host, press Return to abandon the
    connection.
    Store key in cache? (y/n)
    SSH:
    The authenticity of host '127.0.0.1 (127.0.0.1)' can't be established.
    RSA key fingerprint is e1:02:13:c8:52:c2:23:41:9b:5b:58:2c:18:e6:59:af.
    Are you sure you want to continue connecting (yes/no)?What I did was read character by character from the inputStream until I found things of interest ... like "password: ". You only need to search for this in your method which will launch the ssh or plink Process. Once you have verifyed yourself, you can just pass commands to the Process, which is an ssh connection.
    My suggestion is to read() each byte from the Process's inputStream and write it to stdout. Look and see what you need to be looking for so you can interactive with the program correctly. You can't use readLine here becuase when the ssh asks for the password it does not print a newline. I do know for sure, that ssh will simply print, "passowrd: ". Plink will print this as well if the -pw option is not supplied.

  • Best way to call screen in BOR method

    Hi,
    I'm new to BOR objects. I have a requirement to create to a screen to accept values and perform validation on the value.
    As I'm using FOP(EWBC), So in the steps the best way looks like using BOR objects.
    Can any body please guide me what is the best way to create and call a screen in the BOR method?
    Thanks in advance
    Rohan

    IMO the best way is to create a Function Module and call it from your BOR method

  • Best way to call methods on similar objects without an interface

    Hi,
    I have two objects that i need to iterate, they both have the same method i need to call during iteration, but those two objects are from different libraries and i cannot change them to add them as implement interface...
       for (Iterator it = documents.iterator(); it.hasNext();) {
               Document1 document = (Document1) it.next();
               document.getName();
    But I can also get a documents's collection where the object is Document2 and not Document1 that also has getName(), what's the best way to implement this? I mean i know i can just add if conditions to say if (instanceof) do this or that.. but I don't think this is good as everytime there's a new type of doc i'd have to add one more...
    Any suggestions?
    Thanks,

    I have two objects that i need to iterate, they both have the same method i need to call during iteration, but those two objects are from different libraries and i cannot change them to add them as implement interface...
    You already know what you need to do. You just don't want to do it.
    You can't treat two (or more) instances the same if they aren't the same. Here are three methods:
    1. Add code (like you propose) to determine which type you have
    2. Create your own classes that extend those classes and have your own class implement your own interface that has the 'getName' method. When you create instances of your own class the constructor can have code that determines which type you have and then use the appropriate 'getName' method. Your app code would use your own classes instead of the ones from the libraries
    3. Use reflection to call the 'getName' method.

  • Best way to call custom classloader

    I have created a custom classloader to perform hot deployment for application server. How do I let JVM to use my class loader instead of system class loader?
    a. Using the command line argument -Djava.system.class.loader
    b. Using -javaagent and setting System.setProperty("java.system.class.loader", myclass) in premain method.
    c. Is there any other alternative?
    If I am using the command line approach, I will need to have my jar file in the classpath. What is the best way to do this?
    Thanks for your help

    Or you could write a small program which sets up the classloader and then loads the target program with it.

  • What is the best way to call a servlet from another servlet?

    I have a project with 9 servlets (class project). The way I have been moving from servlet to servlet is like this
    doPost(...)
    {      response.setContentType(CONTENT_TYPE);
    PrintWriter out = response.getWriter();
    out.println("<html>");
    out.println("<head><title>Functions</title>");
    out.println(f"<form name=frm6 method=post action=/servlet2");
    out.println("<input type=submit name='btn' value='servlet2'>");
    out.println("</form>");
    So I have these 9 servlets - I call any 8 of them from the first servlet so I have 8 buttons on 8 forms <form=frm1, frm2, ...frm8 method = post...> But when I bring up the first servlet only 6 buttons show up. I was thinking about using hyperlinks instead, but I would like to do this with buttons. I wanted to do this with javascript and the location object, but I was advised to use jsp. I just want to move from one servlet to the next. Any suggestions appreciated for the best/preferred method for moving from one servlet to the next.
    Thanks

    I think you may need some clarification of terminology etc..
    First off, JSP isn't an alternative to javascript, it's an alternative to coding a servlet. A JSP is a mixture of java code and HTML and is translated into a servlet by the system. JSPs are primarilly for generating HTML pages with variable content. JSPs very frequently generate HTML which includes Javascript.
    You probably shouldn't think of what you're doing as one servlet invoking another, that does happen; a servlet can transfer an transaction to another servlet or JSP. In fact it's standard practice that a servlet does the logical stuff (like interpretting form data) then transfers to a JSP to generate the response page. However in this case it's the browser that can invoke one of the 8 servlets, the first servlet merely creates the page from which they are invoked.
    It's not obvious why only some of your buttons are showing up. In a case like this use the "view source" option on your browser to find out what HTML the servlet is actually delivering. What's wrong should be evident from that.
    You can put a hyperlink arround a button, or an image. Mostly people turn up their noses at the buttons supplied by HTML and use their own images for buttons. You
    can do somthing like this:
    <img src="/images/button3.png" border="0">
    (Of course this arrives as a GET transaction not a POST).
    Or you can do a bit of javascript like:
    <img src="/images/button3.png" style="Cursor: pointer;"
    onclick="document.locations.href='/servlet3';">

  • Best way to call a function in a generic class from a base class

    Hi,
    I have a generic class that works with subclasses of some other baseclass. When I construct the subclass, I call the constructor of the baseclass which I want to call a function in the generic class. e.g. suppose I have the following classes
    public class List<T extends BaseClass>
        newTCreated(T t)
    }

    Sorry, I pressed Tab and Enter last time when typing the code so I posted without meaning to
    Hi,
    I have a generic class that works with subclasses of some other baseclass. When I construct the subclass, I call the constructor of the baseclass which I want to call a function in the generic class. e.g. suppose I have the following classes
    public class List<T extends BaseClass>
        public void newTCreated(T t)
            // add the t to some internal list
        public T getT(int index)
            // get the object from the internal list
    public class BaseClass
        public BaseClass(List<?> list)
            list.newTCreated(this);
    public class SubClass extends BaseClass
        public SubClass(List<SubCass> list)
            super(list);
    }This doesn't compile because of the call to newTCreated in the BaseClass constructor because BaseClass is not necessarily of type T. Is there any way of checking when I call the newTCreated function that the BaseClass is actually of type SubClass? I could either add the call explicitly in each SubClass's constructor or have a function addToList in BaseClass that is called from the BaseClass constructor but overloaded in each subclass but both of those rely on future subclasses doing the same. Or I could change the newTCreated function to take an argument of type BaseClass and then cast it to type T but this doesn't give a compilation error, only a runtime exception.
    It seems like there should be solution but having only recently started writing Generic classes I can't find it. Thanks in advance for any help,
    Tom

  • What the best way to call twenty tuxedo domains from one weblogic server use WTC

    I need to call twenty tuxedo domains from one weblogic server use
    WTC. the Service be called in the twenty tuxdo domains are same, do I need to
    write twenty EJB in the weblogic server to call the same service? who have good
    adea to deal with this problem?

    Hi,
    I have a question on the second case. When the client doesn't care of which
    Tuxedo domain it is hitting. What happens if one of the Tux domain is down ? What
    happens to the client request to that domain ?
    Another question is lets say i have a Tuxedo configuration as MP mode( Multi
    machine mode) how does WTC load balance between the Tuxedo domains.
    Thanks,
    Srinivas
    "A. Honghsi Lo" <[email protected]> wrote:
    Hi xcjing,
    One way to handle your needs is to use local service name to remote
    reservice name translation. For instance,
    (in 6.1,6.0 WLS)
    <T_DM_IMPORT ResourceName="TOUPPER1" LocalAccessPoint="WTC"
    RemoteAccessPointList="TUX-DOM1">
         <RemoteName>TOUPPER</RemoteName>
    </T_DM_IMPORT>
    <T_DM_IMPORT ResourceName="TOUPPER2" LocalAccessPoint="WTC"
    RemoteAccessPointList="TUX-DOM2">
         <RemoteName>TOUPPER</RemoteName>
    </T_DM_IMPORT>
    <T_DM_IMPORT ResourceName="TOUPPER3" LocalAccessPoint="WTC"
    RemoteAccessPointList="TUX-DOM3">
         <RemoteName>TOUPPER</RemoteName>
    </T_DM_IMPORT>
    etc
    With this configuration if your client have to call "TOUPPER" service
    in
    TUX-DOM1 then you code your client to call "TOUPPER1" and the request
    will be routed to TUX-DOM1. The same way for request has to go to
    TUX-DOM3, your client calls "TOUPPER3" service and WTC will route it
    to
    TUX-DOM3. In this remote name translation you may have to write 20 EJB
    although they are almost the same. However, if your EJB can analyze
    your client input to decide which Remote Tuxedo Domain to send the
    service request to then you probably only need one EJB.
    In the case that your client does not care which remote Tuxedo Domain
    provides the service then adding
    <T_DM_IMPORT ResourceName="TOLOWER" LocalAccessPoint="WTC"
    RemoteAccessPointList="TUX-DOM1">
         <RemoteName>TOLOWER</RemoteName>
    </T_DM_IMPORT>
    <T_DM_IMPORT ResourceName="TOLOWER" LocalAccessPoint="WTC"
    RemoteAccessPointList="TUX-DOM2">
         <RemoteName>TOLOWER</RemoteName>
    </T_DM_IMPORT>
    <T_DM_IMPORT ResourceName="TOLOWER" LocalAccessPoint="WTC"
    RemoteAccessPointList="TUX-DOM3">
         <RemoteName>TOLOWEr</RemoteName>
    </T_DM_IMPORT>
    etc
    Will load balance your client "TOLOWER" service request among your 20
    remote Tuxedo Domain.
    However, there is a bug in WTC that causes the Remote Service Name
    translation functionality not working properly. It is fixed in the
    upcoming release of WLS.
    Honghsi :-)
    xcjing wrote:
    Thank you very much! But I still have question, give an example,
    twenty Tuxedo domain is named domain1,domain2,....domain20. The
    same Tuxedo Service: TOUPPER is deploy on those twenty Tuxedo domains,some time
    I need call the TOUPPER Service on domain1,saome time I need call theTOUPPER
    Service on domain3 or
    other domain depend on the input from client. you mean I need to importThe TOUPPER
    Service from twenty Tuxedo domains in the console,then write one EJBto call the
    TOUPPER Service,but how can the EJB know which Tuxedo domain's TOUPPERto call
    from?
    Thank you!
    "A. Honghsi Lo" <[email protected]> wrote:
    hi xcjing,
    You don't have to write 20 beans or deploy 20 beans because there
    are
    20
    remote Tuxedo TDomain you need get the service from. Of course, WLSand
    WTC does not prohibit you from doing it though. Whether you need20
    beans or not depend more on you architecture.
    To access 20 remote Tuxedo Domain from one single WLS with singleWTC
    you can configure 20 remote Tuxedo Domain in the BDMCONFIG (6.1,6.0)
    or
    from the console (7.0). You import 20 services one from each remote
    Tuxedo domain. You write one bean, and deploy one bean. Your WLS
    clients will be able to access THE ejb, the EJB will access the WTC
    service, and WTC will load balanced the service requests among the20
    remote Tuxedo Domain.
    Regards,
    honghsi :-)
    xcjing wrote:
    I need to call twenty tuxedo domains from one weblogic server use
    WTC. the Service be called in the twenty tuxdo domains are same,
    do
    I need to
    write twenty EJB in the weblogic server to call the same service?
    who
    have good
    adea to deal with this problem?

  • Best way to call EJBs from JavaBeans/JSP

    Does anyone have a favorite way for getting EJB data from a JavaBean into
              your JSPs?
              I'm looking for a way of caching the EJBHome references so the beans don't
              have to do a lookup on each page, each time they are called.
              Thanks,
              -TB
              

    How does this HelperClass keep the references cached after it looks them up?
              Is it a singleton object, or does it keep the references in static fields?
              "Argyn Kuketayev" <[email protected]> wrote in message
              news:3b1e468b$[email protected]..
              > make a HelperClass, which will have a method getXXXHome()
              > inside the Helper class you may implement cashing.
              >
              > thanks,
              > Argyn
              >
              > T. Bailey wrote in message <[email protected]>...
              > >Does anyone have a favorite way for getting EJB data from a JavaBean into
              > >your JSPs?
              > >
              > >I'm looking for a way of caching the EJBHome references so the beans
              don't
              > >have to do a lookup on each page, each time they are called.
              > >
              > >Thanks,
              > >-TB
              > >
              > >
              >
              >
              

  • Best Way to call Dynamically an stored procedure

    Hi Guys,
    Here my question... I need to call dynamically to an stored procedure...
    - the stored procedure can change, the name , the number of parameters
    - the called stored procedure can contain output parameters.
    lv_sql := 'BEGIN '|| lv_program_name || ' ( ' || get_parameters(lv_program_name) || '); END;';
    get_parameters function generates an string depeding on the number of parameters that this function reads from the
    oracle dictionary (i.e: ':1,:2,:3,:4......... )
    then the dynamyc code must be executed as follow
    execute immediate lv_sql
    using .................................?????????
    The issue that I am facing is how to handle the "using clause".... since before that I ran the program I dont know how many parameters the program will have...
    Please your help... (or suggestion to solve in another way)
    ...:::OKMMAN:::...

    About "Satyaki_De " comment,
    Since I dont know the stored procedure to be called, I cant know the number of parameters and its type to be returned... I mean.. to use the clause "using ...." in static way...
    By now, I am creating dinamically a stored procedure... I am building a stored procedure that calls to the "unknown" stored procedure... reading the data dictionary and building dynamically the "Using...." clause... but I dont like ... since probably in production enviroment I will not have that kind of grants....
    Regarding the link... I didn't know that new type... ! That's will solve the type issue... but still is pending the number of variable to provide to the "using" clause...
    ...:::OKMMMAN:::...
    Edited by: okmman_cl on Feb 11, 2009 1:59 PM

Maybe you are looking for

  • How do I remove the music in my iphone?

    How do I remove the music in my iphone?

  • Is there a way to format text data that has been persisted?

    I am persisting five lines of numeric data in my app.  Each persisted line of data saves and returns perfectly after a ro-boot, except for the text size and color. To be clear : If I save 199.55, that is what appears after a device re-boot.  The 'for

  • Mm_menu.js not working in IE

    I know the old  mm_menu.js script and approch is old. But my client wants to get it the drop drown menu to work in IE. I have IE 9 but I don't think it works in 8 either.  I have read some older posts to use this hack by adding  an IE Emulate HTTP he

  • HT1473 iTunes library

    I want to put my music folder on itunes but i cant because when i click Add File to Library then select my folder nothing happens could someone please help me?

  • How do you hide the Page Options button on dashboards in 11g?

    Hello, I would like to hide the "Page Options" button on a dashboard in 11g. I found some examples on how to do it in 10g, and they all talk about editing a file called dashboardtemplates.xml. I can't find this file on my 11g BI server, so I'm assumi