Stored Procedure Universe with Webi and Xcelcius

Business Objects XI 3.0, Xcelcius 2008
Created a stored procedure Universe on top of SQL Server 2005.  The stored procedure inserts a row into a table, and works fine when calling it from SQL Server server.  When I call it from Webi it wraps a transaction around the call and rolls it back after executing it.
Are the new Stored Procedure Universes in 3.0 meant to be only "read only" and don't allow inserts/updates/deletes commands in the stored procedures they execute ? Seems a little short sighted if they are.
Thanks,
Keith
Edited by: Keith Johnson on Aug 16, 2008 11:30 PM

Keith,,
absolutely with universe designer you can never use such like those procedures, you can not use insert or update statements on those procedure, it will give you errors.
but in xcelsius, you can do it with another layer
check this please
xml data button
http://resources.businessobjects.com/support/cx/samples/learning/downloads/ttv4-xml_data_button.pdf
XCELSIUS DYNAMIC DATA SOURCE
Dynamic datasources for Xcelsius
good luck

Similar Messages

  • How to use optional prompts with stored procedure universe?

    Hi Experts,
    Iu2019m working on stored procedure universe in BO XI 3.0 SP2 FP2.5 with oracle at back end. My requirement is that I have to pass 5 optional prompts in the report and we have to pass these prompts through open document link. Please tell if this can be worked out on stored procedure universe?
    Thanks in advance.

    Hi,
    Try with OpenDoc syntax as follows.
    http://<servername>:<port>/OpenDocument/opendoc/<plat
    formSpecific>?iDocID=****&sIDType=CUID&sType=wid/rpt&lsM/lsS/lsRPROMPTNAME=[V1],[V2]&sDocName=reportname&sRefresh=Y/N
    where
    server name: cms server name
    port: portno
    <platformspecific>=: for java -> openDocument.jsp
                                      for .net -> opendocument.aspx
    idocid,sDocName & cuid -> we can get report properties ( goto info view -> select report -> right click -> properties i.e. doc id, cuid and report name)
    sType -> type of report i.e webi or deski ...
    lsS -> to pass single prompt value
    lsM -> to pass multiplle values to prompt
    lsR -> range of values ....
    Note: Here prompt name should be same as the one which we used in the report. Use + if there is blank space.
    Cheers,
    Suresh Aluri.

  • Unable to create object from stored procedure universe

    Dear All Experts,
    I am facing a problem on unable to create object dimensions on a Stored procedure universe. Fyi, I have successfully insert a stored procedure ('SP_Sales') with input parameter (@date) into universe (Universe_1). But I unable create any object based on the the stored procedured ('SP_Sales') due to it show nothing from the Edit Select Statement of 'Object1', empty for Tables nd columns windows.
    Thefore, i unable to drag data in WEBI when i select univese as "Universe_1", it will not sure any object. Please advise.
    I am using XI4.0, MSSQL2008.

    Hi ,
    You wont be able to edit the object definitions.
    u2022 Designer generates one table per selected stored procedure (or many
    tables if multiple result sets) and one object per column returned by a
    stored procedure.
    u2022 The result set structure is determined when you describe the function.
    Please refer chapter 7(Page 451) of below document for more details.
    [Universe Designer Guide|http://help.sap.com/businessobject/product_guides/boexir31/en/xi3-1_designer_en.pdf]
    Hope this helps.
    Bilahari M

  • Poor performance with WebI and BW hierarchy drill-down...

    Hi
    We are currently implementing a large HR solution with BW as backend
    and WebI and Xcelcius as frontend. As part of this we are experiencing
    very poor performance when doing drill-down in WebI on a BW hierarchy.
    In general we are experiencing ok performance during selection of data
    and traditional WebI filtering - however when using the BW hierarchy
    for navigation within WebI, response times are significantly increasing.
    The general solution setup are as follows:
    1) Business Content version of the personnel administration
    infoprovider - 0PA_C01. The Infoprovider contains 30.000 records
    2) Multiprovider to act as semantic Data Mart layer in BW.
    3) Bex Query to act as Data Mart Query and metadata exchange for BOE.
    All key figure restrictions and calculations are done in this Data Mart
    Query.
    4) Traditionel BO OLAP universe 1:1 mapped to Bex Data Mart query. No
    calculations etc. are done in the universe.
    5) WebI report with limited objects included in the WebI query.
    As we are aware that performance is an very subjective issues we have
    created several case scenarios with different dataset sizes, various
    filter criteria's and modeling techniques in BW.
    Furthermore we have tried to apply various traditional BW performance
    tuning techniques including aggregates, physical partitioning and pre-
    calculation - all without any luck (pre-calculation doesn't seem to
    work at all as WebI apparently isn't using the BW OLAP cache).
    In general the best result we can get is with a completely stripped WebI report without any variables etc.
    and a total dataset of 1000 records transferred to WebI. Even in this scenario we can't get
    each navigational step (when using drill-down on Organizational Unit
    hierarchy - 0ORGUNIT) to perform faster than minimum 15-20 seconds per.
    navigational step.
    That is each navigational step takes 15-20 seconds
    with only 1000 records in the WebI cache when using drill-down on org.
    unit hierachy !!.
    Running the same Bex query from Bex Analyzer with a full dataset of
    30.000 records on lowest level of detail returns a threshold of 1-2
    seconds pr. navigational step thus eliminating that this should be a BW
    modeling issue.
    As our productive scenario obviously involves a far larger dataset as
    well as separate data from CATS and PT infoproviders we are very
    worried if we will ever be able to utilize hierarchy drill-down from
    WebI ?.
    The question is as such if there are any known performance issues
    related to the use of BW hierarchy drill-down from WebI and if so are
    there any ways to get around them ?.
    As an alternative we are currently considering changing our reporting
    strategy by creating several higher aggregated reports to avoid
    hierarchy navigation at all. However we still need to support specific
    division and their need to navigate the WebI dataset without
    limitations which makes this issue critical.
    Hope that you are able to help.
    Thanks in advance
    /Frank
    Edited by: Mads Frank on Feb 1, 2010 9:41 PM

    Hi Henry, thank you for your suggestions although i´m not agree with you that 20 seconds is pretty good for that navigation step. The same query executed with BEx Analyzer takes only 1-2 seconds to do the drill down.
    Actions
    suppress unassigned nodes in RSH1: Magic!! This was the main problem!!
    tick use structure elements in RSRT: Done it.
    enable query stripping in WebI: Done it.
    upgrade your BW to SP09: Has the SP09 some inprovements in relation to this point ?
    use more runtime query filters. : Not possible. Very simple query.
    Others:
    RSRT combination H-1-3-3-1 (Expand nodes/Permanent Cache BLOB)
    Uncheck prelimirary Hierarchy presentation in Query. only selected.
    Check "Use query drill" in webi properties.
    Sorry for this mixed message but when i was answering i tryied what you suggest in relation with supress unassigned nodes and it works perfectly. This is what is cusing the bottleneck!! incredible...
    Thanks a lot
    J.Casas

  • Remote Stored Procedure Call Dispatcher WEB WERVICE

    Hello all,
    Environment: Windows OS, Oracle 10g, mod_plsql
    I am looking for solutions to the following problem:
    A way to dispatch calls to stored procedures from client to server with a minimal impact on performance.
    We are looking at two possible solutions:
    1) Making a call to a Remote Stored Procedure Call Dispatcher (RSPCDispatcher) stored procedure through mod_plsql.
    2) Making a call to a Remote Stored Procedure Call Dispatcher (RSPCDispatcher) stored procedure through a web service.
    Solution 1) is not the preferred one as you may already know that mod_plsql will not be supported starting 12g.
    Solution 2) is the one we prefer as we believe that web services will be ever more supported in the future. When we move to 11g we may turn this web service into a native one (avoiding overhead in the OC4J for hosting the web service etc.).
    We are looking for code examples and information pointers of how we could implement this dispatcher as a stored procedure in a DB package. We know that the implementation should be similar to the one done for mod_plsql in the OWA schema but the code there is obfuscated, so we could not borrow ideas from there.
    We are not sure how to deal with the generalization of the above stated problem. We need to be able to pass to this dispatcher the stored procedure package and name we are invoking, ordered list of parameters (or parameters map), and the transport strategy (XML, JSON, etc.).
    Basically, we are notsure how to deal with the USING clause of the EXECUTE IMMEDIATE statement. We can dynamically generate the SQL statement corresponding to the stored procedure we want to call, but we are not sure how to bind the parameters we are passing?
    Also, we know that EXECUTE IMMEDIATE may be slow sometimes. So if could avoid it, this could further improve performance.
    Perhaps the run-time generalized stored procedure execution may not be what we are looking for?! Perhaps we should include several design-time steps?! What about a script that given a package name (or just a single stored procedure) would generate a wrapper package which stored procudures' names would correspond to their respective counterparts in the given package which would take two parameters - the list of parameters in some sort of format, and the transport (content delivery strategy) and would return the result in the given content delivery strategy?! This script may also define the XSD of the XML message a stored procedure is called with (the parameter map) as well as the XSD of the XML result the stored procedure returns. Also the script could generate client code with the given language strategy (Java, .NET, etc.) for calling the RSPCDispatcher web service.
    We request the following from the Oracle community folks:
    a) Please, give us any relevant information that could be helpful to resolve this problem.
    b) Any resource of how to inspect stored procedures in a package, its parameters, parameter types and direction (IN, OUT, or INOUT), etc.
    Thank you very much in advance.
    Regards,
    Georgi

    Hello all,
    Environment: Windows OS, Oracle 10g, mod_plsql
    I am looking for solutions to the following problem:
    A way to dispatch calls to stored procedures from client to server with a minimal impact on performance.
    We are looking at two possible solutions:
    1) Making a call to a Remote Stored Procedure Call Dispatcher (RSPCDispatcher) stored procedure through mod_plsql.
    2) Making a call to a Remote Stored Procedure Call Dispatcher (RSPCDispatcher) stored procedure through a web service.
    Solution 1) is not the preferred one as you may already know that mod_plsql will not be supported starting 12g.
    Solution 2) is the one we prefer as we believe that web services will be ever more supported in the future. When we move to 11g we may turn this web service into a native one (avoiding overhead in the OC4J for hosting the web service etc.).
    We are looking for code examples and information pointers of how we could implement this dispatcher as a stored procedure in a DB package. We know that the implementation should be similar to the one done for mod_plsql in the OWA schema but the code there is obfuscated, so we could not borrow ideas from there.
    We are not sure how to deal with the generalization of the above stated problem. We need to be able to pass to this dispatcher the stored procedure package and name we are invoking, ordered list of parameters (or parameters map), and the transport strategy (XML, JSON, etc.).
    Basically, we are notsure how to deal with the USING clause of the EXECUTE IMMEDIATE statement. We can dynamically generate the SQL statement corresponding to the stored procedure we want to call, but we are not sure how to bind the parameters we are passing?
    Also, we know that EXECUTE IMMEDIATE may be slow sometimes. So if could avoid it, this could further improve performance.
    Perhaps the run-time generalized stored procedure execution may not be what we are looking for?! Perhaps we should include several design-time steps?! What about a script that given a package name (or just a single stored procedure) would generate a wrapper package which stored procudures' names would correspond to their respective counterparts in the given package which would take two parameters - the list of parameters in some sort of format, and the transport (content delivery strategy) and would return the result in the given content delivery strategy?! This script may also define the XSD of the XML message a stored procedure is called with (the parameter map) as well as the XSD of the XML result the stored procedure returns. Also the script could generate client code with the given language strategy (Java, .NET, etc.) for calling the RSPCDispatcher web service.
    We request the following from the Oracle community folks:
    a) Please, give us any relevant information that could be helpful to resolve this problem.
    b) Any resource of how to inspect stored procedures in a package, its parameters, parameter types and direction (IN, OUT, or INOUT), etc.
    Thank you very much in advance.
    Regards,
    Georgi

  • Using Stored Procedure Universe in Reports

    Hi Friends,
    I got some issues using SP's in Universe and WebI Report.
    Case #1:
    Can we execute dynamic SQL using stored procedure universe..?
    I use SQL server as the DB for my reports.I created a SP which will execute on getting a input value from the user.This input value will frame the SQL dynamically in the SP.for executing the dynamic SQL i use sp_executesql inside the SP.The SP wexecutes successfuly in the DB but when i try executing it in the Universe i get a error message as follows: "Exception : DBD,[Microsoft][SQL SErver Native Client 10.0][SQL Server]Incorrect syntax  nesr 'FROM'.State:42000"
    The script i used for creating SP for your reference:
    CREATE PROCEDURE P_S_GetCodeValueList
              @s_table nvarchar(75)
    as
    begin
              declare @s_sqlCommand nvarchar(1000)
              declare @s_tablename nvarchar(75)
              declare @s_code nvarchar(75)
              set @s_tablename=@s_table
              set @s_code = '*'
              set @s_sqlCommand= 'SELECT ' + @s_code + ' FROM ' + @s_tablename
              exec sp_executesql @s_sqlCommand
    end
    Case #2:
    AIl also tried creating reports using the SP Universe which needs to get the parameter when the user refesh the report.
    But every time the report is refreshed the report fetches the data which was produced when the SP is executed in the Universe for the first time.
    I need to get the prompt in the report , to which the user could give a value and the SP gets executed for that value.
    Is there any option in BO to do this?
    It will be very helpful if you could give me some work arounds on this.
    Regards,
    Sugumar

    Hi Sugumar,
    I can answer you for your 2nd question:
    When you create the Stored procedure in the Universe and test it on retreiving data by inserting variable input you can check if the user could insert new value for the SP parameters.
    Hope this helps!
    Regards
    Giuseppe

  • Error when linking report to stored procedure defined with one input parm

    Error when linking report to stored procedure defined with one input parameter
    The report will work ok, when the parameter is removed from the stpred procedure
    An unhandled win32 exception occurred in crw32.exe[4480]
    Stored Proc (sql server 2005)
    USE [Allegro]
    GO
    /****** Object:  StoredProcedure [dbo].[SP_Test]    Script Date: 07/08/2009 10:42:14 ******/
    SET ANSI_NULLS ON
    GO
    SET QUOTED_IDENTIFIER ON
    GO
    ALTER procedure [dbo].[SP_Test](@valuationmode VARCHAR(55)) as
    Begin
    select
         valuation,
         valuationtime,
         valuationmode
    from valuation
    where valuationmode = @valuationmode;
    End;

    This is an example of a stored procedure that is trying to be linked to a new report as the only datasource.
    If I remove the parameter I can create a report, however this will return all of the results of thw query to the report, rather than the desired results. If I add the parameter on the Crystal Report, the stored procedure then has to return all of the results to Crystal and then perform the filtering of records. By using a parameter in the stored procedure, you should be able to do all of the filtering as part of the query on the databse server, making this more efficient.

  • Postgresql/EDB Stored Procedure Universe Connection

    I'm trying to define a new connection for a Stored Procedure Universe against our EnterpriseDB Postgresql database, but EnterpriseDB doesn't show up as one of the Middleware options for defining the new Connection.  Anyone know how to enable EnterpriseDB/Postgres to allow Stored Procedure Universe Connections?

    May be you can try creating a ODBC connection and then use the ODBC connection.

  • Do SQL pros write seperate stored procedures to handle Save and update operations?

    hi friends,
    Currently i'm bit confused with the industry standard of writing store procedures for save and update operations. I have sees people write separate stored procedure to handle save and update operations even they have to write complex queries. Also I have
    seen people writing one store procedure to handle both Save and Update operations even when the queries are complicated. when I asked them why they do it, they said why should waste time on writing another query to update instead write one save store procedure
    to handle all.
    In here there are SQL Pros, Gurus, what would say about this?
    what is the actual industry standard with stored procedure to perform save and update operations, do you write separate ones or do both in one?
    thanks
    I use Visual studio 2012 Ultimate and SQL server 2008 developer edition!

    >what is the actual industry standard with stored procedure to perform save and update operations
    There is no industry standard. Guideline though you want to be happy with the sp-s; same for your peers.
    As noted above the MERGE command is like a Swiss Army knife; it can perform INSERT, UPDATE & DELETE
    in one (huge) statement.
    Make sure you pick good names for the sp-s, document the parameters and comment the logic if any.
    Format the stored procedure for readability:
    http://www.sqlusa.com/sqlformat/
    Kalman Toth Database & OLAP Architect
    SELECT Query Video Tutorial 4 Hours
    New Book / Kindle: Exam 70-461 Bootcamp: Querying Microsoft SQL Server 2012

  • Stored Procedure Call with only Input Parameter

    Hi, The Example at Oracle Toplink Developer's Guide, Volume 5 uses an output param named IS_VALID. How Can I Call a Stored Procedure that has only Input Param ? If I don't use an Ouput Param Toplink throw the following Exception:
    *Excepción [TOPLINK-4002]* (Oracle TopLink - 10g Release 3 (10.1.3.3.0) (Build 070620)): oracle.toplink.exceptions.DatabaseException Excepción Interna: java.sql.SQLException: ORA-00900: invalid SQL statement
    Here's the Sample Code Depicted at the Guide:*
    Example 98–48 Stored Procedure Call with an Output Parameter
    StoredProcedureCall call = new StoredProcedureCall();
    call.setProcedureName("CHECK_VALID_POSTAL_CODE");
    call.addNamedArgument("POSTAL_CODE");
    call.addNamedOutputArgument(
    "IS_VALID", // procedure parameter name
    "IS_VALID", // out argument field name
    Integer.class // Java type corresponding to type returned by procedure
    ValueReadQuery query = new ValueReadQuery();
    query.setCall(call);
    query.addArgument("POSTAL_CODE");
    Vector parameters = new Vector();
    parameters.addElement("L5J1H5");
    Number isValid = (Number) session.executeQuery(query,parameters);
    Here's my code
    StoredProcedureCall call = new StoredProcedureCall();
         call.setProcedureName("MYSTOREDPROCEDURE");
         call.addNamedArgument("INPUTPARAM1");
         call.addNamedArgument("INPUTPARAM2");
         call.addNamedArgument("INPUTPARAM3");
         call.addNamedArgument("INPUTPARAM4");
         call.addNamedArgument("INPUTPARAM5");
         call.addNamedArgument("INPUTPARAM6");
         ValueReadQuery query = new ValueReadQuery();
         query.setCall(call);
         query.addArgument("INPUTPARAM1");
         query.addArgument("INPUTPARAM2");
         query.addArgument("INPUTPARAM3");
         query.addArgument("INPUTPARAM4");
         query.addArgument("INPUTPARAM5");
         query.addArgument("INPUTPARAM6");
    Vector parameters = new Vector();
         parameters.addElement("INPUTVALUE1");
         parameters.addElement("INPUTVALUE2");
         parameters.addElement("INPUTVALUE3");
         parameters.addElement("INPUTVALUE4");
         parameters.addElement("INPUTVALUE5");
         parameters.addElement("INPUTVALUE6");
         uow.executeQuery(query,parameters);
    Regards,
    Manuel

    You need to use a DataModifyQuery as your query does not return anything.
    James : http://www.eclipselink.org

  • Does Oracle have Extended Stored Procedure like SQL Server and Sybase?

    Hi, i am new to Oracle. I want to know if...
    Does Oracle have Extended Stored Procedure like SQL Server and Sybase?
    If it does not have, then how can i call outside program written in C or JAVA from the Database stored procedure or trigger?

    refer to this link on external procedures
    http://download-west.oracle.com/docs/cd/A87860_01/doc/server.817/a76956/manproc.htm#11064

  • Problem with Stored Procedure exection in Sender and Receiver side of JDBC

    Hi All,
    I am facing problem while executing Stored Procedures using sender and receiver sides of JDBC adapter.
    Here is my SP in Oracle DB :
    PROCEDURE EMP                           
    ( ID IN VARCHAR2,NAME IN VARCHAR2,PROCESSED IN VARCHAR2  ) AS                                                          
    BEGIN                                                         
       INSERT INTO EMPLOYEE VALUES (ID, NAME, PROCESSED);COMMIT;END EMP;
    Now I want to execute this SP using sender JDBC channel and receiver JDBC channel.
    Can anyone please help me executing this SP?
    Regards,
    Soorya

    Hi Soorya,
    The receiver Data type should be like this:
    <StatementName>
    <storedProcedureName action=u201D EXECUTEu201D>
        <table>realStoredProcedureeName</table>
    <param1 [isInput=u201Dtrueu201D] [isOutput=true] type=SQLDatatype>val1</param1>
    </storedProcedureName >
      </StatementName>
    Check the link http://help.sap.com/saphelp_nw04/helpdata/en/64/ce4e886334ec4ea7c2712e11cc567c/frameset.htm
    Which DB  are you using?? The sender structure will be like
    <resultset>
    <row>
    <field1></field1>
    <field2></field2>
    <field3></ field3>
    </row>
    </resultset>
    Search SDN you will get lot of examples
    Regards
    Suraj

  • How to create stored procedure for insert update and delete operations with input output paramters?

    I  have the follwing table is called master table contain the follwing fields,
    So here i need to create  three Stored procedures 
    1.Insert operations(1 o/p paramter,and  14 input paramters)              - uspInsert
    2.Update operations(1 o/p paramter,and  14 input paramters)          - uspUpdate
    3.Delete Operations(1 o/p paramter,and  14 input paramters)          
     - uspdelte
    The following is the table ,so using this to make the three sp's ,Here we will use Exception machanism also.
    Location 
    Client Name
    Owner 
    ConfigItemID
    ConfigItemName
    DeploymentID
    IncidentID
    Package Name
    Scope 
    Stage
    Type 
    Start Date
    End Date
    Accountable 
    Comments
    So can u pls help me out for this ,bcz i knew to stored procedure's creation.

    I  have the follwing table is called master table contain the follwing fields,
    So here i need to create  three Stored procedures 
    1.Insert operations(1 o/p paramter,and  14 input paramters)              - uspInsert
    2.Update operations(1 o/p paramter,and  14 input paramters)          - uspUpdate
    3.Delete Operations(1 o/p paramter,and  14 input paramters)            - uspdelte
    The following is the table ,so using this to make the three sp's ,Here we will use Exception machanism also.
    Location 
    Client Name
    Owner 
    ConfigItemID
    ConfigItemName
    DeploymentID
    IncidentID
    Package Name
    Scope 
    Stage
    Type 
    Start Date
    End Date
    Accountable 
    Comments
    So can u pls help me out for this ,bcz i knew to stored procedure's creation.
    Why you have to pass 14 parameters for DELETE and UPDATE? Do you have any Primary Key?  If you do NOT have primary key in your table then in case you have duplicate information, SQL will update both or delete them together. You need to provide DDL of
    you table. What are the data types of fields?
    Best Wishes, Arbi; Please vote if you find this posting was helpful or Mark it as answered.

  • Stored Procedure Universe Issues

    Working in version 3.1 SP1 Fix pack 1.8 and created some simple stored procedures to use in the universe and everything worked fine but then due to changing requirements added additional logic to the stored procedures (SQL 2005 database) for the report to include additional prompts and mulitple selects within the code.  With these changes, have encountered multiple errors when trying to insert them in the universe or when we are able to insert them in to the universe then no data ever returns from the new stored procedures even though correct execute statements are being created on the SQL Server and they work on SQL Server and in other BI tools.  Has anyone else encountered this or know of any limitations using stored procedures in universes?

    Holy thread-resurrection Batman!
    Please open a new dicussion after reading the bi4.0 data access guide: http://help.sap.com/businessobject/product_guides/boexir4/en/xi4sp5_data_acs_en.pdf
    Also, please specify which SP and Patch you are using.
    Regards,
    H

  • Simple stored procedure - select with an if statement, returning a cursor

    Hi,
    I'm trying to create a very simple stored procedure, but having never worked with them before I'm not quite sure what I'm doing wrong.
    Here's my code:
    create or replace
    procedure contact_return(
        v_contact_id IN varchar2,
        p_cursor OUT SYS_REFCURSOR)
    AS
    begin
      set sql_statement varchar2(4000) := '
        SELECT URN,
          FIRSTNAME,
          LASTNAME,
          TITLE,
          CREATED_DT,
          AREA_URN,
          MOBILE,
          WORK,
          EMAIL,
          ORG_NAME,
          ADDRESS,
          POSTCODE,
          IN_USE
        FROM CONTACT';
      if v_contact_id is not null then
        sql_statement := sql_statement || ' where urn = ' || v_contact_id;
      end if;
      open p_cursor for sql_statement;
    end;
    It's actually returning 2 errors:
    Error(7,3): PL/SQL: SQL Statement ignored
    Error(7,7): PL/SQL: ORA-00922: missing or invalid option
    Which seem to be a problem with my set sql_statement line, but it looks correct to me?
    Thanks

    rajendra wrote:
    Dear User,
    It is not allowed to declare a variable inside the PL/SQL block means after begin ( in your case line no 7 ).
    Lot of errors in your code.
    Tell me your exact requirement and what you want to do , after that I will be able to solve your problem.
    Thanks,
    Rajendra
    Well, you can declare after the begin, though it'll be as part of an embedded code block e.g.
    SQL> ed
    Wrote file afiedt.buf
      1  create or replace procedure contact_return(empno IN  number
      2                                            ,c     OUT SYS_REFCURSOR
      3                                            ) AS
      4  begin
      5    declare
      6      sql_statement varchar2(4000) := '
      7        select *
      8        from emp
      9        where empno = nvl(:1,empno)';
    10    begin
    11      open c for sql_statement using contact_return.empno;
    12    end;
    13* end;
    SQL> /
    Procedure created.
    SQL> var x refcursor
    SQL> exec contact_return(7788,:x);
    PL/SQL procedure successfully completed.
    SQL> print x;
         EMPNO ENAME      JOB              MGR HIREDATE                    SAL       COMM     DEPTNO
          7788 SCOTT      ANALYST         7566 19-APR-1987 00:00:00       3000                    20
    so, it is allowed, as long as it's coded correctly.

Maybe you are looking for

  • Insert and update a data block which is based on view--urgent help required

    Hi experts, I created a view(A_VIEW) which is based on a union select. I have created a data block A_VIW_BLOCK which is based on this view. I need to insert/update one of the base tablesfor A_VIEW through this data block. I also need to be able to ma

  • Screen exit for transactoin /SCWM/VEH related to SCM eWM

    Hello All, I need to add a dropdown or F4 help button on a custom screen in transactoin /SCWM/VEH related to SCM eWM. I did not finf any screen exits for this transactoins. Please suggest is there any way in acheiving this? Also can anybody explain h

  • What does this icon do in Mail ?

    Hi ALL,  a quickie question to try and help my missus, what does this icon do please ?. Her iPad is the best thing i have ever given her    she says ! Tim

  • ORA-28336: cannot encrypt SYS owned objects

    Hi ,I am getting the following error during impdp. Processing object type SCHEMA_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS ORA-31693: Table data object "IDCFAPP"."ROBJECTOFSERVICE" failed to load/unload and is being skipped due to error: ORA-28336: ca

  • HT4472 I want to update my OS to 10.6.8

    I want to update my OS to 10.6.8 I dont see where to buy the update OS. Where can I find to buy it