OracleCallableStatement - can I access the procedure or function name?

I have an observer that, after preparing a statement, before execution, I need to know the stored procedure name of the prepareStatement (and go do an action, if necessary). I couldn't find a var in either OracleCallableStatement or OraclePreparedStatement that has this information, only the 'call' string, ie: { call myproc(?,?)}. For example (and I'm simply stating fact, not displaying preference :-) , SQLServerCallableStatement has a procedureName var (completely undocumented in their API) that I can access once the call has been prepared.
Any ideas?
THANKS!

You can still use PL/SQL anonymous blocks to execute stored procedures and functions. In fact, it has its advantages, like being able to use named parameter association. However, your syntax is incorrect. It should be
... prepareCall("BEGIN <procedure name>(x=>?, y=>?, ...); END;") for a stored procedure
... prepareCall("BEGIN ? := <function_name>(x=>, y=>?, ...); END;") for a stored functionYou still do a java.sql.Connection.prepareCall(...) using this syntax. However, this returns a java.sql.CallableStatement. A call to prepareStatement(...) returns a java.sql.PreparedStatement which may not work. I know no way of getting the actual procedure or function name.

Similar Messages

  • How can I use the procedures and functions in my library

    hello, all
    I have a pl/sql library MYLIB.pld, MYLIB.pll and MYLIB.plx.
    How can I invoke procedures and functions there in JDeveloper?
    Thanks.
    Damon

    I am indeed using ADF BC to re-develop the oracle application.
    Here is my situation:
    We have an oracle form application.
    Our objective is to try to re-use the existing sources in the form application as much as possible:
    1. tons of procedures and functions in a pl/sql library(a file with extension name portfolioLib.pll or portfolioLib.plx);
    2. tons of form-level triggers, data-block triggers and item-triggers;
    3. tons of database stored procedures and triggers;
    After doing a research on JDeveloper, we decide to use ADF Swing+ADF BC to re-develop the application.
    My opinion for the above three kinds of sources in our form application is:
    for 1: we try to move most of procedures and functions into database(except Form build-in);
    for 2: we try to wrap those triggers in a SQLJ class;
    for 3: we try to call database procedures and functions with PreparedStatment or CallableStatement;
    I just do a test on a post-query trigger on a data-block:
    I created a sqlj file, named testSQLJ.sqlj in the test.view package;
    I tried to call it in createInstanceFromResultSet of testDeptVOImpl.java which is test.model package,
    I was told that testSQLJ cannot be found there. why?
    How can I call some classes from test.view package in some classes of test.model?
    I read some documents about how to deal with post-query trigger in JDeveloper: create a view with SQL statement, but it seems that it does not support pl/sql statement there.
    Can you give me some opinion about the above stuff?
    I really appreciate your help.
    Damon

  • How can i access the EJB from a Webdynpro

    Dear all,
    How can i access the ejb , from a webdynpro?.
    Is there any way to do that?.
    I want to write the entire code (business functions) within the EJB and i wan to access the entire methods from a WebDynpro Application.This is the situation.
    Please help me to , resolve this problem.(Here im using JDBC Connection .. etc.).
    I want to do the basic connection setting's and data retrieval part within the EJB and use that within the WebDynpro..
    how can i seperate this two(i mean, i want to seperate the JDBC connections and WebDynpro,i dont want to hard code any connection parameters within the webdynpro code)
    So that i want use that saet of particular function's in many webdynpro applications..
    (i dont need any help regarding webservice way.)
    If anyone can , please help me..
    I tried that javabean class , manifest file , that way (importing javabean model).
    but im getting errors.
    I cant properly utilize that..
    So please help me with steps regarding that,,
    for javabean
    and if any , for EJB also..
    with regards
    Kishor.G

    HI,
    Since webdynpros follows Model View Controller Architecture You can access EJBs in webdynpro(views/frontend) infact to connec to database uding JDBC you have to utilise EJB ( opening connection to database closing, and other Business functionality).See this link
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/unkown/web dynpro tutorial and sample applications.faq#q-7
    <b>How to access the Car Rental Web Service?</b>
    Regards,
    RK

  • "Sorry you can't access the BT Sport App and onlin...

    I've been trying to login to the BT Sport app and keep getting told that I haven't activated it yet. I'm shown an activate button and when I press it I'm taken to a site where I have to log in using my My BT credentials. Upon logging in I'm shown the following message:
    "Sorry you can't access the BT Sport App and online content because a BT ID created by Stephen is the account holder."
    The message is completely nonsensical as I the account holder and I've logged in with valid credentials. I tried calling the helpline and am still waiting for someone to call me back, even though I called them two hours ago. What awful service.

    Hi W0035521,
    Welcome to the community forum. Do you have more than 1 BT ID? It sounds like you have another ID that has been set up with account holder status. I can take a look at this for you. Please send me in your details using the "Contact The Mods" link found in my profile.
    Thanks
    PaddyB
    BTCare Community Mod
    If we have asked you to email us with your details, please make sure you are logged in to the forum, otherwise you will not be able to see our ‘Contact Us’ link within our profiles.
    We are sorry but we are unable to deal with service/account queries via the private message(PM) function so please don't PM your account info, we need to deal with this via our email account :-)

  • I downloaded iBooks but there's no icon to open it, and I can't uninstall because I can't access the app. How do I either open it or uninstall and reinstall?

    When I downloaded iBooks no icon appeared on the homepage, so I can't uninstall to reinstall, nor can I access the app. How can I do either of these?

    If you're sure you downloaded it, and the app was actually installed, try using the search function to find the app. Tap your homekey once to get to the search screen (or swipe to the left one screen over from your left-most home screen), then type in iBooks.
    If search doesn't locate iBooks, then the app wasn't installed. Try restarting your iPad. (Don't just put it to sleep and wake it up again; shut it down then turn it back on.)

  • I'm trying to send a pages document as an email attachment to pc users.  They can't access the document.

    I'm trying to send a pages document as an email attachment to pc users.  They can't access the document.  When I try go to the "file" menu, there is no "save as" option.

    Hi Shelly,
    Command-P (Print)
    In the Print dialogue, click the PDF button at lower left, choose Mail PDF
    The result should be a new email document with the pdf file attached.
    Address and send.
    The procedure applies to any document which may be printed, not just Pages documents.
    Regards,
    Barry

  • How can we access the file/directory system in the server

    Hi friends,
    I have made a text editor attached with an audio player for my project.
    Both text editor and audio player are implemented in applet and put in to a
    jsp page using jsp:plugin. Text editor and player are separate applets running
    in the same page and from same server.A client who is using this editor may
    want to save the edited text files to the server as well as hear audio files from
    directories in the server.
    My question is how can we access the file/directory system in the server
    like we do in the local machine.When the user cliks save or openfromserver button
    in the editor, folder/files in the server must be displayed as we do with FileChooser.
    I am using Apache Tomcat 5,wiindows 2000 server, jdk1.5.
    manu

    You can't access it directly. But your applet can make net connections to the server, and the server can provide that kind of functionality. Generally this is easiest by making HTTP connections and having the server provide the functionality via the web server. (So in your case, JSPs or servlets on the server would list/deliver/create/modify/delete files, and the applets would invoke those JSPs and servlets.

  • Can i create any procedure or function inside a oracle reserve package?

    Hi!
    Can i create any procedure or function inside a oracle reserve package. Suppose, I want to create a function called x in the dbms_output package. Can i do that? Or can i extend the features of this package and create/derived a function from it like we extend any class in JAVA. I'm not sure - whether this is at all possible. I'll be waiting for your reply.
    Thanks in advance.
    Satyaki De.

    No, but you can write a wrapper package and use that instead of using the Built-In package directly. So, instead of calling DBMS_OUTPUT, you call your own Package.
    Steven Feuerstein wrote a wrapper for DBMS_OUTPUT, called P:
    Re: DBMS_OUTPUT.PUT_LINE

  • Can I access the file name from within an action?

    Hiya Y'all;
    I have an action written that batch opens a bunch of files, resizes the canvas of the frontmost, pastes the rest in, &etc., resulting in a montage. I would love to be able to access the names of the files used to create the montage, paste them in from the clipboard using the text tool, and thus label each pic. I can access the same general functionality through the File>Automate>Contact Sheet II command, but I then have little control over how PS resizes the images, and since my file names are often >32 characters, Contact Sheet II truncates the names in a silly way.
    I really would prefer not to have to use Applescript or Javascript, but I'm getting the feeling that I may have to. Is it possible to use AS to put the name in the clipboard, call the action from the script, and do that each time I paste in a new image? I can't do it once, since I will have six file names that each need to be pasted in . . .
    Hope y'all have some advice,
    R

    Thanks everyone . . . I use Chris's solution, setting it up in an action that is called by Applescript. It works great, though it takes noticeably more time to run the script (I think it has to load and be interpreted each time).
    I haven't tried Michael's suggestion, but, bottom line, you guys ROCK! It's amazing to have an obscure technical question answered in a day or so, and continuing interest from other good folk.
    Thanks to you all!
    Richard

  • Hi there, got 3 issues at once.... 1) can't download the latest itune version (it simply stops, not even an error message) 2) can't access the itune store and in order to fix this i need the latest version 3) one of my ipods isn't recognised by itune

    Hi there, got 3 issues at once....
    1) can't download the latest itune version onto my PC (it simply stops, not even an error message)
    2) can't access the itune store and in order to fix this i need the latest version - catch 22!
    3) one of my ipods isn't recognised by itune, nit sure if because of the earlier problems?
    .... thanks
    S.

    Hello SAB7700,
    This first article can help get iTunes successfully downloaded and updated, which should restore access to the iTunes Store.
    Issues installing iTunes or QuickTime for Windows
    http://support.apple.com/kb/HT1926
    Once iTunes is successfully updated, the following articles provides steps that can help get your iPod working in iTunes again and the iTunes Store functioning, should the update not resolve these issues
    iPod not recognized in My Computer and in iTunes for Windows
    http://support.apple.com/kb/TS1369
    Can't connect to the iTunes Store
    http://support.apple.com/kb/TS1368
    Cheers,
    Allen

  • Can we access the session scoped variable by simply using its name

    The Java EE 6 Tutorial contains a "Duke's Bookstore Case Study Example”. I could not understand following statements of this case study:
    *bookdetails.xhtml*
    {code}
    <h:outputText value="#{selected.title}"/>
    {code}
    *BookstoreBean.java*
    {code}
    public String details() {
    context()
    .getExternalContext()
    .getSessionMap()
    .put(
    "selected",
    getFeatured());
    return ("bookdetails");
    {code}
    I want to know can we access the session scoped variable in bookdetails.xhtml by simply using its name as done above?

    It is basic Expression Language (EL) functionality, it isn't even specific to JSF. And it isn't specific to the session scope either, you can put beans in any scope (page, request, session, application, flash, conversation, whatever custom scope you create) and reference it using EL by only its name. The thing that you have to take care of is that the bean lives in SOME scope, which can be achieved using JSF specific annotations or configuration files, through CDI or by manually putting the bean in a specific scope through Java code. It's flexible, which is the nature of the Java platform.

  • I can't access the 'options' in iTunes visualizer menu

    Hello everyone. Hope someone can help me with a problem re:iTunes Visualizer. I can't access the Visualizer Options no matter what I'm in, such as my music library, the Radio function, etc. I've upgraded to 10.6 & restarted iTunes and rebooted. I've also updated my Quicktime but I still see the 'Options' grayed out. The path I use is: View>Visualizer>Options. I've previously had no trouble running the Visualzer and selecting the Options till I upgraded to 10.6 Now, 'Options' is always dimmed. I've tried switching between the new Visualizer and the Classic, but no luck either way. Can someone tell me how to enable the Options? Thanks.

    i get a unknown error 11222.
    There's some info on your error message number in the Specific Conditions and Alert Messages: (Mac OS X / Windows) section of the following document:
    iTunes: Advanced iTunes Store troubleshooting

  • How can i access the table GL_CODE_COMBINATIONS  !!

    I'm sorry ~ My English is poor ~~ understand me ^^
    I execute procedure APPS.GL_TEST but error occured
    ORA-00904:"GL_TEST";invalid identifier.
    but it execute well at orange (program that like toad)
    May be i can't access GL_CODE_COMBINATIONS table ~~
    I have to execute APPS.GL_CODE_COMBINATIONS_PKG.INSERT_ROW(
    X_ROWID => X_ROWID,
    X_CODE_COMBINATION_ID => X_CCID,
    it have GL_CODE_COMBINATIONS table
    so have to make account ccid
    How can i access the table GL_CODE_COMBINATIONS !!
    Thank you ^^
    --CREATE OR REPLACE PROCEDURE APPS.GL_TEST(EFFBUF OUT VARCHAR2, RETCODE OUT NUMBER)
    IS
    V_VAL NUMBER;
    BEGIN
    UPDATE GL_CODE_COMBINATIONS
    SET SEGMENT7 = 'TEST'
    WHERE CODE_COMBINATION_ID = 1169;
    END GL_TEST;
    Message was edited by:
    jake

    ORA-00904:"GL_TEAT";invalid identifier.spelling mistake?
    Is user APPS owner of the table GL_CODE_COMBINATIONS?
    If not, you need to grant the necessary privilege directly and not through a role

  • I downloaded 11.1 but now can't access the store, can only view my library. I've reinstalled but still get a blank, white screen when I try to go to the itunes store. How can I get to the store for purchases?

    I downloaded 11.1 but now can't access the store, can only view my library. I've reinstalled but still get a blank, white screen when I try to go to the itunes store. How can I get to the store for purchases?

    In iTunes prefs>Store - is the Store check box unchecked?
    Did you repair pemissions with Disk Utility?
    MJ

  • Can not access the Instance Data of a Singleton class from MBean

    I am working against the deadline and i am sweating now. From past few days i have been working on a problem and now its the time to shout out.
    I have an application (let's call it "APP") and i have a "PerformanceStatistics" MBean written for APP. I also have a Singleton Data class (let's call it "SDATA") which provides some data for the MBean to access and calculate some application runtime stuff. Thus during the application startup and then in the application lifecysle, i will be adding data to the SDATA instance.So, this SDATA instance always has the data.
    Now, the problem is that i am not able to access any of the data or data structures from the PerformanceStatistics MBean. if i check the data structures when i am adding the data, all the structures contains data. But when i call this singleton instance from the MBean, am kind of having the empty data.
    Can anyone explain or have hints on what's happening ? Any help will be appreciated.
    I tried all sorts of DATA class being final and all methods being synchronized, static, ect.,, just to make sure. But no luck till now.
    Another unfortunate thing is that, i some times get different "ServicePerformanceData " instances (i.e. when i print the ServicePerformanceData.getInstance() they are different at different times). Not sure whats happening. I am running this application in WebLogic server and using the JConsole.
    Please see the detailed problem at @ http://stackoverflow.com/questions/1151117/can-not-access-the-instance-data-of-a-singleton-class-from-mbean
    I see related problems but no real solutions. Appreciate if anyone can throw in ideas.
    http://www.velocityreviews.com/forums/t135852-rmi-singletons-and-multiple-classloaders-in-weblogic.html
    http://www.theserverside.com/discussions/thread.tss?thread_id=12194
    http://www.jguru.com/faq/view.jsp?EID=1051835
    Thanks,
    Krishna

    I am working against the deadline and i am sweating now. From past few days i have been working on a problem and now its the time to shout out.
    I have an application (let's call it "APP") and i have a "PerformanceStatistics" MBean written for APP. I also have a Singleton Data class (let's call it "SDATA") which provides some data for the MBean to access and calculate some application runtime stuff. Thus during the application startup and then in the application lifecysle, i will be adding data to the SDATA instance.So, this SDATA instance always has the data.
    Now, the problem is that i am not able to access any of the data or data structures from the PerformanceStatistics MBean. if i check the data structures when i am adding the data, all the structures contains data. But when i call this singleton instance from the MBean, am kind of having the empty data.
    Can anyone explain or have hints on what's happening ? Any help will be appreciated.
    I tried all sorts of DATA class being final and all methods being synchronized, static, ect.,, just to make sure. But no luck till now.
    Another unfortunate thing is that, i some times get different "ServicePerformanceData " instances (i.e. when i print the ServicePerformanceData.getInstance() they are different at different times). Not sure whats happening. I am running this application in WebLogic server and using the JConsole.
    Please see the detailed problem at @ http://stackoverflow.com/questions/1151117/can-not-access-the-instance-data-of-a-singleton-class-from-mbean
    I see related problems but no real solutions. Appreciate if anyone can throw in ideas.
    http://www.velocityreviews.com/forums/t135852-rmi-singletons-and-multiple-classloaders-in-weblogic.html
    http://www.theserverside.com/discussions/thread.tss?thread_id=12194
    http://www.jguru.com/faq/view.jsp?EID=1051835
    Thanks,
    Krishna

Maybe you are looking for