Finding Stored Procedure(s) Executed

Hi,
I need to find which stored procedure got executed when I run my application.
My application is in .NET and I am using Oracle 9.2.0.5
Thanks in advance.
Pravin Pawar

You can use SQL trace and TKPROF for that.
1. Creation of PL/SQL and execution of procedures:
bas002>
bas002>
bas002> create or replace procedure p2
  2  is
  3  d date;
  4  begin
  5  select sysdate into d from dual;
  6  end;
  7  /
Procedure created.
bas002> show errors
No errors.
bas002>
bas002> create or replace procedure p1
  2  is
  3  n number;
  4  begin
  5  p2;
  6  select count(*) into n from dual;
  7  end;
  8  /
Procedure created.
bas002> show errors
No errors.
bas002>
bas002> create or replace procedure p0
  2  is
  3  begin
  4  null;
  5  end;
  6  /
Procedure created.
bas002> show errors
No errors.
bas002>
bas002>
bas002> alter session set sql_trace=true;
Session altered.
bas002>
bas002> exec p1;
PL/SQL procedure successfully completed.
bas002>
bas002> exec p0;
PL/SQL procedure successfully completed.
bas002>
bas002> alter session set sql_trace=false;
Session altered.2. use TKPROF to get formated trace file:
tkprof bas002_ora_892.trc output=test.trctest.trc contains:
TKPROF: Release 10.2.0.2.0 - Production on Wed Jan 30 15:03:54 2008
Copyright (c) 1982, 2005, Oracle.  All rights reserved.
Trace file: bas002_ora_892.trc
Sort options: default
count    = number of times OCI procedure was executed
cpu      = cpu time in seconds executing
elapsed  = elapsed time in seconds executing
disk     = number of physical reads of buffers from disk
query    = number of buffers gotten for consistent read
current  = number of buffers gotten in current mode (usually for update)
rows     = number of rows processed by the fetch or execute call
alter session set sql_trace=true
call     count       cpu    elapsed       disk      query    current        rows
Parse        0      0.00       0.00          0          0          0           0
Execute      1      0.00       0.00          0          0          0           0
Fetch        0      0.00       0.00          0          0          0           0
total        1      0.00       0.00          0          0          0           0
Misses in library cache during parse: 0
Optimizer mode: ALL_ROWS
Parsing user id: 55 
BEGIN p1; END;
call     count       cpu    elapsed       disk      query    current        rows
Parse        1      0.00       0.00          0          0          0           0
Execute      1      0.03       0.03          0          0          0           1
Fetch        0      0.00       0.00          0          0          0           0
total        2      0.03       0.03          0          0          0           1
Misses in library cache during parse: 1
Optimizer mode: ALL_ROWS
Parsing user id: 55 
SELECT SYSDATE
FROM
DUAL
call     count       cpu    elapsed       disk      query    current        rows
Parse        1      0.00       0.01          0          0          0           0
Execute      1      0.00       0.00          0          0          0           0
Fetch        1      0.00       0.00          0          0          0           1
total        3      0.00       0.02          0          0          0           1
Misses in library cache during parse: 1
Optimizer mode: ALL_ROWS
Parsing user id: 55     (recursive depth: 1)
SELECT COUNT(*)
FROM
DUAL
call     count       cpu    elapsed       disk      query    current        rows
Parse        1      0.00       0.00          0          0          0           0
Execute      1      0.00       0.00          0          0          0           0
Fetch        1      0.00       0.00          0          0          0           1
total        3      0.00       0.00          0          0          0           1
Misses in library cache during parse: 1
Optimizer mode: ALL_ROWS
Parsing user id: 55     (recursive depth: 1)
BEGIN p0; END;
call     count       cpu    elapsed       disk      query    current        rows
Parse        1      0.00       0.00          0          0          0           0
Execute      1      0.00       0.00          0          0          0           1
Fetch        0      0.00       0.00          0          0          0           0
total        2      0.00       0.00          0          0          0           1
Misses in library cache during parse: 0
Optimizer mode: ALL_ROWS
Parsing user id: 55 
alter session set sql_trace=false
call     count       cpu    elapsed       disk      query    current        rows
Parse        1      0.00       0.00          0          0          0           0
Execute      1      0.00       0.00          0          0          0           0
Fetch        0      0.00       0.00          0          0          0           0
total        2      0.00       0.00          0          0          0           0
Misses in library cache during parse: 0
Optimizer mode: ALL_ROWS
Parsing user id: 55 
OVERALL TOTALS FOR ALL NON-RECURSIVE STATEMENTS
call     count       cpu    elapsed       disk      query    current        rows
Parse        3      0.00       0.00          0          0          0           0
Execute      4      0.03       0.03          0          0          0           2
Fetch        0      0.00       0.00          0          0          0           0
total        7      0.03       0.03          0          0          0           2
Misses in library cache during parse: 1
OVERALL TOTALS FOR ALL RECURSIVE STATEMENTS
call     count       cpu    elapsed       disk      query    current        rows
Parse        2      0.00       0.01          0          0          0           0
Execute      2      0.00       0.00          0          0          0           0
Fetch        2      0.00       0.00          0          0          0           2
total        6      0.00       0.02          0          0          0           2
Misses in library cache during parse: 2
    6  user  SQL statements in session.
    0  internal SQL statements in session.
    6  SQL statements in session.
Trace file: bas002_ora_892.trc
Trace file compatibility: 10.01.00
Sort options: default
       1  session in tracefile.
       6  user  SQL statements in trace file.
       0  internal SQL statements in trace file.
       6  SQL statements in trace file.
       6  unique SQL statements in trace file.
      60  lines in trace file.
       0  elapsed seconds in trace file.I don't know if it's possible to get with TKPROF all procedures called by top level procedures (in this example p2 call is missing).
I made this test with 10.2.0.2 but it should work the same for 9.2.0.5.
Message was edited by:
Pierre Forstmann

Similar Messages

  • Could not find stored procedure 'DataRefresh.GetSchedule'.

    When I try to fresh a powerpivot workbook that is published on SharePoint. It always give me an error. When I look in the ULS log it says
    Following error occured while trying to execute a sql query: System.Data.SqlClient.SqlException (0x80131904): Could not find stored procedure 'DataRefresh.GetSchedule'.     at System.Data.SqlClient.SqlConnection.OnError(SqlException exception,
    Boolean breakConnection, Action`1 wrapCloseInAction)     at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)     at System.Data.SqlClient.TdsParser.TryRun(RunBehavior
    runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)     at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()    
    at System.Data.SqlClient.SqlDataReader.get_MetaData()     at System.Data.Sq... 31a41e9c-44c3-409b-3f57-f575019b7830
    05/24/2013 15:48:58.33* w3wp.exe (0x1DCC)                        0x2720 PowerPivot Service           
     Data Refresh                   97 Medium   ...lClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)    
    at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite)     at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior
    cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite)     at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior,
    RunBehavior runBehavior, Boolean returnStream, String method)     at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)     at System.Data.S... 31a41e9c-44c3-409b-3f57-f575019b7830
    05/24/2013 15:48:58.33* w3wp.exe (0x1DCC)                        0x2720 PowerPivot Service           
     Data Refresh                   97 Medium   ...qlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior)     at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior
    behavior)     at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)     at System.Data.Common.DbDataAdapter.Fill(DataSet
    dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)     at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)     at Microsoft.AnalysisServices.SPAddin.MTSAccessorBase.ExecuteWithResults(String
    commandText, CommandType commandType, SqlParameter[] paramArray)  ClientConnectionId:6e4dd12c-4c00-4d28-810f-979bae03b34d 31a41e9c-44c3-409b-3f57-f575019b7830
    05/24/2013 15:48:58.33  w3wp.exe (0x1DCC)                        0x2720 SharePoint Foundation        
     Monitoring                     b4ly Medium   
    val it: unit=()

    I have this issue in my SharePoint 2013 azure environment. It is unclear what I need to do to overcome this issue. Any help is most appreciated.
    I get the following log messages:
    Following error occured while trying to execute a sql query: System.Data.SqlClient.SqlException (0x80131904):
    Could not find stored procedure 'DataRefresh.GetSchedule'.
    EXCEPTION: NoAvailableStreamingServerException: We cannot locate a server to load the workbook Data Model.
    macrel

  • Error Could not find stored procedure dbo.proc_GetFollowableLists

    I am troubleshooting a FIM installation and I am getting this error:
    The Execute method of job definition Microsoft.Office.Server.UserProfiles.LMTRepopulationJob (ID 9f556bbb-1796-4dee-9a73-f283b7874aeb) threw an exception. More information is included below.
    Could not find stored procedure 'dbo.proc_GetFollowableLists'.
    I don't get a single hit on that when searching the forums or webs. Any ideas? is it related to FIM Install?

    Hi,
    Please perform the steps below:
    Launch Services.msc on your servers and ensure that the SharePoint Timers Service is started and that its Startup Type is Automatic.
    Go to Central Administration > Monitoring > Configure usage and health data collection, see if Enable usage data collection and Enable health data collection are checked. If they are already checked, disable them firstly, then enable them again. Remember
    to perform IISReset and restart the service in the step 1.
    Please refer more information via:
    http://social.technet.microsoft.com/wiki/contents/articles/24492.sharepoint-2013-the-execute-method-of-job-definition-microsoft-office-server-userprofiles-lmtrepopulationjob-id-threw-an-exception.aspx
    http://www.mysharepointadventures.com/2012/10/event-6398-could-not-find-stored-procedure-dbo-search_getrecentstats/
    http://spjoel.wordpress.com/2012/08/06/could-not-find-stored-procedure-dbo-search_getrecentstats/
    http://www.marc-lognoul.me/itblog-en/sharepoint-2010-event-id-5586-and-6398-could-not-find-stored-procedure-dbo-search_getrecentstats-revisited/
    Regards,
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected] .
    Rebecca Tu
    TechNet Community Support

  • Could not find stored procedure 'mds_getRepositoryVersion'.

    When I start up the BI_Server1 component I get the following error in the logs and the server goes into ADMIN state. Any ideas what may be causing this? I've fixed a previous issue with wrong password in mds-owsm,that error is gone now.
    I've already confirmed I can access the database through SSMS.
    SELECT OBI_REP.BI116_MDS.mds_getRepositoryVersion()
    Result:
    11.1.1.61.63
    OBIEE11g 11.1.1.6
    Sql Server 2008 R2
    Windows Server 2008
    ####<Jul 20, 2012 5:27:18 PM EDT> <Info> <JDBC> <******> <bi_server1> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <0000JYaIM1pEgKhwD8icKw1G2SoP000002> <1342819638294> <BEA-001128> <Connection for pool "mds-owsm" closed.>
    ####<Jul 20, 2012 5:27:18 PM EDT> <Error> <JDBC> <WUVW****> <bi_server1> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <0000JYaIM1pEgKhwD8icKw1G2SoP000002> <1342819638313> <BEA-001112> <Test "SELECT 1 FROM DUAL" set up for pool "mds-owsm" failed with exception: "java.sql.SQLSyntaxErrorException: [FMWGEN][SQLServer JDBC Driver][SQLServer]Invalid object name 'DUAL'.".>
    ####<Jul 20, 2012 5:27:18 PM EDT> <Error> <JDBC> <WU****> <bi_server1> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <0000JYaIM1pEgKhwD8icKw1G2SoP000002> <1342819638315> <BEA-001111> <Unable to verify the test "SELECT 1 FROM DUAL" set up for pool "mds-owsm". Connections will not be tested. The test will not be used by isValid neither.>
    ####<Jul 20, 2012 5:27:18 PM EDT> <Info> <Common> <WU*****> <bi_server1> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <0000JYaIM1pEgKhwD8icKw1G2SoP000002> <1342819638318> <BEA-000628> <Created "1" resources for pool "mds-owsm", out of which "1" are available and "0" are unavailable.>
    ####<Jul 20, 2012 5:27:18 PM EDT> <Error> <Deployer> <WU******> <bi_server1> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <0000JYaIM1pEgKhwD8icKw1G2SoP000002> <1342819638608> <BEA-149205> <Failed to initialize the application 'bipublisher [Version=11.1.1]' due to error oracle.mds.exception.MDSExceptionList: MDS-01329: unable to load element "persistence-config"
    MDS-01370: MetadataStore configuration for metadata-store-usage "MAR_TargetRepos" is invalid.
    [FMWGEN][SQLServer JDBC Driver][SQLServer]Could not find stored procedure 'mds_getRepositoryVersion'.
    oracle.mds.exception.MDSExceptionList: MDS-01329: unable to load element "persistence-config"
    MDS-01370: MetadataStore configuration for metadata-store-usage "MAR_TargetRepos" is invalid.
    [FMWGEN][SQLServer JDBC Driver][SQLServer]Could not find stored procedure 'mds_getRepositoryVersion'.
         at oracle.mds.config.PConfig.loadFromBean(PConfig.java:953)
         at oracle.mds.config.PConfig.<init>(PConfig.java:758)
         at oracle.mds.config.MDSConfig.loadFromBean(MDSConfig.java:787)
         at oracle.mds.config.MDSConfig.loadFromElement(MDSConfig.java:848)
         at oracle.mds.config.MDSConfig.<init>(MDSConfig.java:491)
         at oracle.mds.config.MDSConfig.<init>(MDSConfig.java:438)
         at oracle.mds.internal.lcm.deploy.DeployManager.deploy(DeployManager.java:516)
         at oracle.mds.internal.lcm.deploy.DeployManager.startDeployment(DeployManager.java:204)
         at oracle.mds.internal.lcm.MDSLifecycleListenerImpl.start(MDSLifecycleListenerImpl.java:215)
         at oracle.mds.lcm.weblogic.WLLifecycleListener.preStart(WLLifecycleListener.java:77)
         at weblogic.application.internal.flow.BaseLifecycleFlow$PreStartAction.run(BaseLifecycleFlow.java:282)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.application.internal.flow.BaseLifecycleFlow$LifecycleListenerAction.invoke(BaseLifecycleFlow.java:199)
         at weblogic.application.internal.flow.BaseLifecycleFlow.preStart(BaseLifecycleFlow.java:62)
         at weblogic.application.internal.flow.HeadLifecycleFlow.prepare(HeadLifecycleFlow.java:283)
         at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:613)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:184)
         at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:58)
         at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:154)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60)
         at weblogic.deploy.internal.targetserver.AppDeployment.prepare(AppDeployment.java:141)
         at weblogic.management.deploy.internal.DeploymentAdapter$1.doPrepare(DeploymentAdapter.java:39)
         at weblogic.management.deploy.internal.DeploymentAdapter.prepare(DeploymentAdapter.java:191)
         at weblogic.management.deploy.internal.AppTransition$1.transitionApp(AppTransition.java:21)
         at weblogic.management.deploy.internal.ConfiguredDeployments.transitionApps(ConfiguredDeployments.java:261)
         at weblogic.management.deploy.internal.ConfiguredDeployments.transitionApps(ConfiguredDeployments.java:246)
         at weblogic.management.deploy.internal.ConfiguredDeployments.prepare(ConfiguredDeployments.java:165)
         at weblogic.management.deploy.internal.ConfiguredDeployments.deploy(ConfiguredDeployments.java:122)
         at weblogic.management.deploy.internal.DeploymentServerService.resume(DeploymentServerService.java:180)
         at weblogic.management.deploy.internal.DeploymentServerService.start(DeploymentServerService.java:96)
         at weblogic.t3.srvr.SubsystemRequest.run(SubsystemRequest.java:64)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
    Caused By: oracle.mds.exception.MDSExceptionList: MDS-01329: unable to load element "persistence-config"
    MDS-01370: MetadataStore configuration for metadata-store-usage "MAR_TargetRepos" is invalid.
    [FMWGEN][SQLServer JDBC Driver][SQLServer]Could not find stored procedure 'mds_getRepositoryVersion'.
         at oracle.mds.config.PConfig.loadFromBean(PConfig.java:953)
         at oracle.mds.config.PConfig.<init>(PConfig.java:758)
         at oracle.mds.config.MDSConfig.loadFromBean(MDSConfig.java:787)
         at oracle.mds.config.MDSConfig.loadFromElement(MDSConfig.java:848)
         at oracle.mds.config.MDSConfig.<init>(MDSConfig.java:491)
         at oracle.mds.config.MDSConfig.<init>(MDSConfig.java:438)
         at oracle.mds.internal.lcm.deploy.DeployManager.deploy(DeployManager.java:516)
         at oracle.mds.internal.lcm.deploy.DeployManager.startDeployment(DeployManager.java:204)
         at oracle.mds.internal.lcm.MDSLifecycleListenerImpl.start(MDSLifecycleListenerImpl.java:215)
         at oracle.mds.lcm.weblogic.WLLifecycleListener.preStart(WLLifecycleListener.java:77)
         at weblogic.application.internal.flow.BaseLifecycleFlow$PreStartAction.run(BaseLifecycleFlow.java:282)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.application.internal.flow.BaseLifecycleFlow$LifecycleListenerAction.invoke(BaseLifecycleFlow.java:199)
         at weblogic.application.internal.flow.BaseLifecycleFlow.preStart(BaseLifecycleFlow.java:62)
         at weblogic.application.internal.flow.HeadLifecycleFlow.prepare(HeadLifecycleFlow.java:283)
         at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:613)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:184)
         at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:58)
         at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:154)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60)
         at weblogic.deploy.internal.targetserver.AppDeployment.prepare(AppDeployment.java:141)
         at weblogic.management.deploy.internal.DeploymentAdapter$1.doPrepare(DeploymentAdapter.java:39)
         at weblogic.management.deploy.internal.DeploymentAdapter.prepare(DeploymentAdapter.java:191)
         at weblogic.management.deploy.internal.AppTransition$1.transitionApp(AppTransition.java:21)
         at weblogic.management.deploy.internal.ConfiguredDeployments.transitionApps(ConfiguredDeployments.java:261)
         at weblogic.management.deploy.internal.ConfiguredDeployments.transitionApps(ConfiguredDeployments.java:246)
         at weblogic.management.deploy.internal.ConfiguredDeployments.prepare(ConfiguredDeployments.java:165)
         at weblogic.management.deploy.internal.ConfiguredDeployments.deploy(ConfiguredDeployments.java:122)
         at weblogic.management.deploy.internal.DeploymentServerService.resume(DeploymentServerService.java:180)
         at weblogic.management.deploy.internal.DeploymentServerService.start(DeploymentServerService.java:96)
         at weblogic.t3.srvr.SubsystemRequest.run(SubsystemRequest.java:64)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
    >
    Edited by: 844667 on Jul 20, 2012 2:48 PM

    Hi,
    I am getting the same thing and have not been able to find a resolution - would you happen to recall how you resolved this?

  • Java Stored Procedure in EXECUTE IMMEDIATE

    Hi,
    I need advice for the following.
    I'm on Oracle 11g R2. I'm testing application in Oracle 11gR1 and R2 and Oracle Express.
    Purpose is to generate XML reports.
    I have PLSQL Stored Procedure which does that, but since there is bug in Oracle11gR2 related to XMLTRANSFORM I have and Java Stored Procedure which is workaround. They are both compiled, valid etc.
    Java class is :
    import java.io.PrintWriter;
    import java.io.Writer;
    import oracle.xml.parser.v2.DOMParser;
    import oracle.xml.parser.v2.XMLDocument;
    import oracle.xml.parser.v2.XSLProcessor;
    import oracle.xml.parser.v2.XSLStylesheet;
    * This class is used as Java stored procedure
    * There is a bug on Oracle11gR2, related to the limitation on the number of style sheet instructions
    * This stored procedure is workaround when PLSQL code can not be used.
    * File must not have package, otherwise is wrongly compiled in DB
    public class JavaXslt {
         public static void XMLTtransform(oracle.sql.CLOB xmlInput,oracle.sql.CLOB xslInput,oracle.sql.CLOB output) throws Exception{
              DOMParser parser;
              XMLDocument xml;
              XMLDocument xsldoc;
              try{
                   parser = new DOMParser();
                   parser.parse(xmlInput.getCharacterStream());
                   xml = parser.getDocument();
                   parser.parse(xslInput.getCharacterStream());
                   xsldoc = parser.getDocument();
                   XSLProcessor processor = new XSLProcessor();
                   XSLStylesheet xsl = processor.newXSLStylesheet(xsldoc);
                   Writer w = output.setCharacterStream(1L);
                   PrintWriter pw = new PrintWriter(w);
                   processor.processXSL(xsl, xml, pw);
              }catch (Exception ex){
                   throw ex;
    PROCEDURE Java_XmlTransform (xml CLOB, xslt CLOB, output CLOB) AS LANGUAGE JAVA
    NAME 'JavaXslt.XMLTtransform(oracle.sql.CLOB, oracle.sql.CLOB, oracle.sql.CLOB)';
    I'm calling Java stored procedure from PLSQL Stored procedure (if it is Oracle11gR2) like that :
    Java_Proc.Java_XmlTransform(inputXML, xslt, res);
    So till here everything works ok. XSLT as applied and output XML (res) is OK.
    But when Oracle Express is used Java is out of the question, so there is no Java stored procedure. Howewer PLSQL Stored procedure is still needed.
    So I had to put call to Java Stored procedure in EXECUTE IMMEDIATE statement in order to compile to PLSQL package.
    But when I do that :
    EXECUTE IMMEDIATE 'BEGIN Java_Proc.Java_XmlTransform (:1, :2, :3); END;' USING inputXML, xslt, res;
    result value CLOB (res) has zero length...
    What am I missing? Should i set return value to Java class?
    Hope my explanations are clear though.
    Thanks

    Hi odie_63,
    Thanks for quick response.
    I didn't clearly explained.
    When using Oracle 11gR1 and Oracle Express I'm using only PLSQL Procedure.
    When using Oracle 11gR2 i have to use Java Stored procedure because there is documented bug in R2.
    That's why i have to use EXECUTE IMMEDIATE. I don't know which version is the client DB and whether there is or no Java procedures.
    I did tried
    EXECUTE IMMEDIATE 'BEGIN Java_Proc.Java_XmlTransform (:1, :2, :3); END;' USING IN inputXML, IN xslt, OUT res; and the result was ORA-06537: OUT bind variable bound to an IN position
    When using IN OUT for last parameter i.e.
    EXECUTE IMMEDIATE 'BEGIN Java_Proc.Java_XmlTransform (:1, :2, :3); END;' USING IN inputXML, IN xslt, IN OUT res;
    there is no exception, but still DBMS_LOB.getlength(res) = 0
    Thanks

  • Could not find stored procedure 'sp_start_job'

    I'm trying to run a ms sql server agent job from within my vb.net code using sp_start_job and getting exception...
    Could not find stored procedure 'sp_start_job'.
    ... so obviously I'm doing something wrong.  My vb code contains is ...
            jobCommand = New SqlCommand("sp_start_job", sqlConn)
            jobCommand.CommandType = CommandType.StoredProcedure
            jobParameter = New SqlParameter("@job_name", SqlDbType.VarChar)
            jobParameter.Direction = ParameterDirection.Input
            jobCommand.Parameters.Add(jobParameter)
            jobParameter.Value = "nameOfServerAgentJob"
            jobCommand.ExecuteNonQuery()
    Can someone show me how to run the SQL Server Agent job properly from my vb code?
    Thanks tonnes for any help, Roscoe

    Or directly redirect the connection upon creation of the connection string to the right database, e.g.
    string ConnectionString = "Data Source=YourServer;Initial Catalog=msdb;Integrated Security=True";
    See more samples of connection strings here:
    http://www.connectionstrings.com/sql-server/
    -Jens
    Jens K. Suessmeyer http://blogs.msdn.com/Jenss

  • Could not find stored procedure

    Dear gurus,
    I am working, for the first time, on a SAP BPC ( MS ) demo.
    I have created a new input schedule based on a dynamic template, with some modifications.
    However when I try to submit data, it gives an error:
    "Could not find stored procedure 'dbo.up_ConcurrentLockDEL_HR'.;"
    DEL_HR is my application and is based on a existing one "FINANCE", but I have added new dimensions and deleted another ones.
    I can not understand this message because I don't know where I define stored procedures. I also commented all script logics that this application had.
    Could you help me on this?
    Best regards,
    Vitor Ramalho

    Hi Vitor,
    You need to login to the server, where SQL has been installed. You can login to that system using remote desktop connection.
    Once you login to the SQL server, under the databases, you will find your application set. Expand it and navigate to Programmability and then to Stored Procedures. Here, you will get all the stored procedures.
    The above statements will guide you to find the stored procedures. However, the problem, we are looking at is little different. Usually, with every application, a stored procedure with the name, "dbo.up_ConcurrentLockappname" gets created automatically. However, I am guessing that this stored procedure is not available for your application. Search for the stored procedure just to make sure that its available or not. If its not available, search for dbo.up_ConcurrentLockFinance. I am asking to search for the Finance one since your application is copy of the Finance application. So, just to make sure that the source application is fine. If this stored procedure is present but the stored procedure for your application is not present, then I would suggest you to create the application once again. Process it properly.
    Hope this helps.

  • What happens to the report if the underlying stored procedure to execute the report take atleast 3 hrs to run

    Hi,
    I have a report which is calling a stored procedure..
    Stored procedure exceutes 4-5 stored procedure and then returns the count each procedure it ran using union all statement... The stored procedure takes around 3-4 hrs to run because it is looking at quarterly data and YTD data.
    So once the report is kicked off and the procedure behind it runs and runs how will communicate to the report to show the final data... the final data will just be 5 rows with counts.
    I think we are running into a issue where the stored procedure runs and runs and then the report goes into la la land and has no clue what to do...
    Can you please shed some light on this..
    Thanks
    Karen

    Hi Karen,
    When we render a report, the report would process the following procedures:
    Open connections to data source and reading data rows from data extensions for all datasets, means retrieve data. Then process the engine requests, including the tablix, grouping, sorting, filtering, aggregations and subreport processing, means process report.
    Finally, render the report, including the pagination modules and on-demand expression evaluations.
    So the report rending has to wait until the stored procedure is executed. To improve the performance, we can consider the three aspects:
    Improve the performance of the stored procedures. Such as index and join. For better support, I suggest you can post a new thread about this issue in Transact-SQL forum at:
    http://social.msdn.microsoft.com/Forums/sqlserver/en-US/home?forum=transactsql. It is appropriate and more experts will assist you.
    Simplify the report. For example, avoid including a reference to [&TotalPages] or any complex expressions in the page header and page footer. For more details, please see the following document:
    http://technet.microsoft.com/en-us/library/bb522806(v=sql.105).aspx
    Using cashing if you have a long-running query that cannot be tuned further. For more details, please refer to the following article:
    http://msdn.microsoft.com/en-us/library/ms159241(v=sql.110).aspx
    Hope this helps.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • [Microsoft][ODBC SQL Server Driver][SQL Server]Could not find stored procedure 'dbo.sp_SPNAMEHERE'.

    OK, something seemed to have changed with my system because this error is NEW. It might be related to my system upgrade from Vista to Win7, but just guessing here.
    I run a database on a corporate MS Sql Server (2005) and an ASP application that connects via ODBC. The real world application works fine, however when I attempt to access Stored Procedures from Dreamweaver (on my development machine)  I am getting the following error:
    [Microsoft][ODBC SQL Server Driver][SQL Server]Could not find stored procedure 'dbo.sp_SPNAMEHERE'.
    This only seems to happen on Stored procedures that RETURN a recordset.
    system:
    Win7
    Dreamweaver CS4
    Code: VBScript/Classic ASP
    SQL Server 2005
    Connecting via ODBC: MM_MY_STRING = "Driver={SQL Server};Server=wscxxxxxxxxx;Database=dbsystem;Uid=username;Pwd=XXXXXXXXXXXX"
    Stored procedures that do not return a recordset are not an issue.... this has put my development work at a standstill!!
    Thanks in advance!

    Well, I hate bumps, but I am really running out of solutions. I have now tried to use a system DSN on my development machine and that didnt solve the problem. I just un-installed DW and re-installed it and that didnt solve my problem either.
    This is very frustrating, because I cannot use any stored procs that return recordsets... I am stuck... can anybody think of a relatively easy work-around to working in DW w/ recordsets that come from SPs when you cant actually access them?
    The really weird thing is, when I build the command, and choose the stored proc, and give it valid input variables, and TEST it from the TEST button, everything works and data is returned as expected. Once I click "OK" and actually add it to the ASP page the recordset that should be visible isnt... and when I click the plus sign in the bindings window I get the error...
    Help!!

  • Event ID 57 - Could not find stored procedure 'dbo.proc_MSS_CrawlAdmin' and Could not find 'dbo.proc_MSS_Crawl'

    Sharepoint Enterprise 2010 - sp1 (feb. 2013 cu) - running enterprise search service
    Running sql. 2012 enterprise
    Event log has constant event ID 57 with A database error occurred. Source: Microsoft SQL Server Native Client 10.0 Code: 2812 occurred 1 time(s) Description: Could not find stored procedure 'dbo.proc_MSS_Crawl'  and along with it another Could not find
    stored procedure 'dbo.proc_MSS_CrawlAdmin'.
    How do I fix this issue?

    Hi there,
    I am seeing this issue (just the "proc_MSS_Crawl" stored procedure, not the other). Did you find a fix for this? Did you try running the configuration wizard to see if this resolved it?
    Regards,
    Ben
    Ben Weeks
    SharePoint Consultant @ Webtechy Ltd
    T: +441223922070 F: +448701315220
    Web: http://www.webtechy.co.uk Blog:
    http://blog.webtechy.co.uk

  • Central Administraion Internal server error 500 | event id 5586 sharepoint foundation unknown sql exception 2812 could not find stored procedure dbo.proc_gettimerlock

    Hi,
    We have two SharePoint 2010 SP2 servers with one SQL 2012 Backend.
    Recently we cannot open the central administration, getting 500 internal server error and multiple SQL errors in event viewer:
    event id 5586 sharepoint foundation unknown sql exception 2812 could not find stored procedure dbo.proc_gettimerlock
    event id 5586 sharepoint foundation unknown sql exception 2812 occured could not find stored procedure 'proc_fetchdocforhttpget'
    Also I cannot run SharePoint configuration wizard, getting this error: sharepoint 2010 failed to resgister sharepoint services
    In the log file, I found this error "an exception of type microsoft.sharepoint.spexception was thrown 0x80131904"
    Any ideas?
    Thanks, Shehatovich

    As You can see below stored procedure has its specific Permission's, check user who is performing action as well as CentralAdministation Pool has right permission and their permissions are not modified from SQL Server.
    -Samar
     =
    Sr. Software engineer

  • How do I merge data from table1 on server 1 to final table on server 2 with a stored procedure to execute every so many hours.

    How do I merge data from table1 on server 1 to final table on server 2 with a stored procedure to execute every so
    many hours.

    How big is the table on server B? Is that possible to bring the all data into a server A and merge the data locally?
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • How do I merge data from table1 on server 1 to final table on server 2 with a stored procedure to execute every 4 hours.

    How do I merge data from table1 on server 1 to final table on server 2 with a stored procedure to execute every so many hours.

    Hello,
    If you had configure server2 as
    linked server on the server1, you can run the following statement inside stored proceduce to copy table data. And then create a job to the run stored proceduce every 4 hours.
    Insert Into Server2.Database2.dbo.Table2
    (Cols)
    Select Cols From Server1.Database1.dbo.Table1
    Or you can use the SQL Server Import and Export Wizard to export the data from server1 to server2, save the SSIS package created by the wizard on the SQL Server, create a job to run the SSIS package. 
    Reference:http://technet.microsoft.com/en-us/library/ms141209.aspx
    Regards,
    Fanny Liu
    Fanny Liu
    TechNet Community Support

  • Error Could not find stored procedure 'SP_DATA1FINANCE'.;CommitTrans::Send

    Hi,
    We are getting the following error when trying to send data via Input schedule or via Data Manager.:
              - Error Message -
    ExecuteSQL::Could not find stored procedure 'SP_DATA1FINANCE'.;CommitTrans::Send through SendGovernor failed;
    This same error is happening in every application, for example we have an application called Ventas, and the error occurs as follows:
              - Error Message -
    ExecuteSQL::Could not find stored procedure 'SP_DATA1FINANCE'.;CommitTrans::Send through SendGovernor failed;
    We did not have problems before when using version 5.1, this error is appearing now that we migrate to version 7.0-
    Do you have any idea what could be the cause of this error? We already tried Re-Processing Applications but still the same problem.
    Thanks
    Ana

    After you upgrade you have to save all applications.
    Bacause in V7 there are other stored procedures then in V5.
    Kind regards,
    Sam

  • Error: Could not find stored procedure !!

    Hi,
    Error: Could not find stored procedure.
    I Installed the SQL Server SP2 and the error still occurs when ever I call the stored procedure from my windows app!!
    Any Help ?

    I run this query:
    select uid,
    left ([name], 30) as [name]
    from sysobjects
    where [name] like 'ThisMonthRecords%'
    the result is:
    1 ThisMonthRecords

Maybe you are looking for