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.

Similar Messages

  • How to use order by in stored procedure base block?

    How to use order by in stored procedure base block? I need to change order by dynamically

    Use SET_BLOCK_PROPERTY('BLOCK_NAME',ORDER_BY,'COLUMN_NAME1, COLUMN_NAME2');

  • Dynamic prompting with stored procedures XI- urgent

    Post Author: moleary77
    CA Forum: Crystal Reports
    I have a report that has 7 parameters and two stored procedures, I get the dynamic prompting to work wonders as stand alone dynamic parameters, however I need them to be cascading. How can I accomplish this while still using my stored procedures? Is there something I need to change within the stored procedure, I've looked all over in Crystal and I can't seem to figure it out. Please let me know! Below are my stored procs
    set ANSI_NULLS ONset QUOTED_IDENTIFIER ONGOALTER PROCEDURE &#91;dbo&#93;.&#91;gm_RPT_Appt_Parms&#93;-- Add the parameters for the stored procedure hereASBEGIN-- SET NOCOUNT ON added to prevent extra result sets from-- interfering with SELECT statements.SET NOCOUNT ON;-- Insert statements for procedure hereDECLARE @PTABLE TABLE(COMPANY VARCHAR(10) NULL,BOOKCODE VARCHAR(22) NULL,FACILITY VARCHAR(47) NULL,PROV VARCHAR(21) NULL,LOGONID VARCHAR(15) NULL,DEPARTMENT VARCHAR(26) NULL)--GET COMPANIESINSERT INTO @PTABLE(COMPANY, BOOKCODE, DEPARTMENT ) SELECT DISTINCT COMPANY , BOOKCODE, DEPARTMENT FROM MWBOOK ORDER BY COMPANY , BOOKCODE, DEPARTMENT INSERT INTO @PTABLE(COMPANY, FACILITY ) SELECT DISTINCT COMPANY, FACILITY FROM CLFAC ORDER BY COMPANY, FACILITY INSERT INTO @PTABLE(COMPANY, PROV ) SELECT DISTINCT COMPANY , PROV FROM MWPROV ORDER BY COMPANY , PROV SELECT * FROM @PTABLE
    END
    set ANSI_NULLS ONset QUOTED_IDENTIFIER ONGOALTER PROCEDURE &#91;dbo&#93;.&#91;gm_RPT_Appt_Data&#93; -- Add the parameters for the stored procedure here @START DATETIME, @END DATETIME, @COMPANY VARCHAR(10), @BOOK VARCHAR(2056) = NULL,   @USERCODE varchar(2056) = NULL, @FACILITY varchar(2056)= NULL,  @PROV varchar(2056) = NULLASBEGIN -- SET NOCOUNT ON added to prevent extra result sets from -- interfering with SELECT statements.DECLARE @VALUES VARCHAR(2000) SET NOCOUNT ON; IF(@BOOK IS NULL) BEGIN  SET @VALUES = ''    SELECT @VALUES = @VALUES + COALESCE(BOOKCODE + ',','') FROM MWBOOK WHERE COMPANY = @COMPANY  SET @BOOK = @VALUES END IF(@FACILITY IS NULL) BEGIN  SET @VALUES = ''    SELECT @VALUES = @VALUES + COALESCE(FACILITY + ',','') FROM CLFAC WHERE COMPANY = @COMPANY  SET @FACILITY = @VALUES END IF(@USERCODE IS NULL) BEGIN  SET @VALUES = ''    SELECT @VALUES = @VALUES + COALESCE(LOGONID + ',','') FROM CLUSER WHERE COMPANY = @COMPANY  SET @USERCODE = @VALUES END
    IF(@PROV IS NULL) BEGIN  SET @VALUES = ''    SELECT @VALUES = @VALUES + COALESCE(PROV + ',','') FROM MWPROV WHERE COMPANY = @COMPANY  SET @PROV = @VALUES END  SELECT  mws.ANOTE,   mwb.BOOKNAME,   mwb.FACILITY,   LEFT(mwa.PATIENTID, 50) AS PATIENT,  mwa.ADATE,   mwa.ADESC,   mwa.ANOTE,   mwa.USERCODE,   mwa.BOOK,   mwa.USERFLAG,   mwa.ATIME,   mwa.COMPANY,   mwa.AKEYTIME,   mwb.PROV  FROM     dbo.MWAPPTS mwa LEFT OUTER JOIN dbo.MWBOOK mwb ON    mwa.COMPANY = mwb.COMPANY AND mwa.BOOK=mwb.BOOKCODE   LEFT OUTER JOIN dbo.MWSCHED mws ON    mwa.ADATE=mws.ADATE AND mwa.BOOK=mws.BOOK AND mwa.COMPANY = mws.COMPANY  WHERE   mwa.BOOK IN (SELECT ARRTEXT FROM DBO.SPLIT(@BOOK, ','))  AND mwa.USERCODE IN (SELECT ARRTEXT FROM DBO.SPLIT(@USERCODE, ','))  AND mwa.ADATE BETWEEN @START AND @END   AND mwb.FACILITY IN (SELECT ARRTEXT FROM DBO.SPLIT(@FACILITY, ','))  AND mwa.COMPANY=@COMPANY  AND (mwb.PROV IN (SELECT ARRTEXT FROM DBO.SPLIT(@PROV, ','))) ORDER BY  MWA.ADATE,  MWA.BOOK
    END

    Since your {?Project} parameter is part of a stored procedure, you have to think of it as part of the table.  In reality, it could "change" the result set so Crystal has always prompted them first. It's like in math with the order of operation between +-*/.Â
    All "added" parameters (like the one you created within the report) must be prompted after the server-based prompts (stored proc).
    - Kathryn Webster (Report Design Specialist)

  • How to use @jws:sql call Stored Procedure from Workshop

    Is there anyone know how to use @jws tag call Sybase stored procedure within
    Workshop,
    Thanks,

    Anurag,
    Do you know is there any plan to add this feature in future release? and
    when?
    Thanks,
    David
    "Anurag Pareek" <[email protected]> wrote in message
    news:[email protected]..
    David,
    In the current release, we do not support calling stored procedures from a
    database control. You will have to write JDBC code in the JWS file to call
    stored procedures.
    Regards,
    Anurag
    Workshop Support
    "David Yuan" <[email protected]> wrote in message
    news:[email protected]..
    Anurag,
    I know how to use DB connection pool and create a db control with it. In
    fact, we have created a Web Service with the db control using plain SQL
    in
    @jws:sql. However, my question here is how to use @jws tag in Weblogic
    Workshop to create a Web Services based on Sybase stored procedure orany
    Stored Proc not plain SQL.
    Thanks,
    David
    "Anurag Pareek" <[email protected]> wrote in message
    news:[email protected]..
    David,
    You can use a database control to obtain a connection from any JDBC
    Connection Pool configured in the config.xml file. The JDBC Connectionpool
    could be connecting to any database, the database control is
    independent
    of
    that.
    Regards,
    Anurag
    Workshop Support
    "David Yuan" <[email protected]> wrote in message
    news:[email protected]..
    Is there anyone know how to use @jws tag call Sybase stored
    procedure
    within
    Workshop,
    Thanks,

  • How to use materialized view in stored procedure

    in my stored procedure I use couple of queries (see the script below). I want to create materialized views to replace these queries. Is it possible to achieve and how to achieve it in my case? thanks in advance
    set serveroutput on
    DECLARE
      v_cur_tid NUMBER(5):=0;
      v_cur_cs_attendance NUMBER(5):=0;
      v_cur_c_tot_enrolments NUMBER(5):=0;
      v_most_enrolments NUMBER(5):=0;
      v_least_enrolments NUMBER(5):=0;
      v_most_pop_cid NUMBER(5):=0;
      v_least_pop_cid NUMBER(5):=0;
      CURSOR class_cursor IS
    select
    id,
    name,
    max_attendees
    from
    class
    where
    id in (select distinct(event_id) from trainer_schedule where event_type='c' and is_active='y')
    order by id;
    BEGIN
    DBMS_OUTPUT.PUT_LINE('==================================================================================================================================');
    --print the report header
    DBMS_OUTPUT.PUT_LINE('Summary Report No.3: Training Class Active Schedules Summary Report');
    FOR r_class IN class_cursor LOOP
    --print the header or subsection
    select sum(enrolments) into v_cur_c_tot_enrolments from class_schedule where class_id = r_class.id;
    IF v_most_enrolments < v_cur_c_tot_enrolments OR v_most_enrolments = 0
    THEN v_most_enrolments := v_cur_c_tot_enrolments; v_most_pop_cid := r_class.id;
    END IF;
    IF v_least_enrolments > v_cur_c_tot_enrolments OR v_least_enrolments = 0
    THEN v_least_enrolments := v_cur_c_tot_enrolments; v_least_pop_cid := r_class.id;
    END IF;
    DBMS_OUTPUT.PUT_LINE('******************************************************************************************');
    DBMS_OUTPUT.PUT_LINE('CLASS_ID: '  || r_class.id ||'     '|| 'CLASS_NAME: '  || r_class.name ||'     '||'CAPACITY: '  || r_class.max_attendees ||'     '||'TOTAL_ENROLMENTS: '  || v_cur_c_tot_enrolments);
    DBMS_OUTPUT.PUT_LINE(rpad('____________', 12) || lpad('____________', 12) || lpad('____________________', 20) || lpad('____________________', 20) || lpad('____________',12) || lpad('____________',12));
    DBMS_OUTPUT.PUT_LINE(rpad('SCHEDULE_ID', 12) || lpad('TRAINER_ID',12) || lpad('START_TIME', 20) || lpad('END_TIME',20) || lpad('ENROLMENTS',12) || lpad('ATTENDANCE',12));
    DBMS_OUTPUT.PUT_LINE(rpad('____________', 12) || lpad('____________',12) || lpad('____________________', 20) || lpad('____________________', 20) || lpad('____________',12) || lpad('____________',12));
    FOR r_cs IN (select id,to_char(start_time,'DD-MM-YYYY HH24:Mi') as start_time, to_char(end_time,'DD-MM-YYYY HH24:Mi') as end_time, enrolments from class_schedule where class_id = r_class.id order by id)
    LOOP
    select trainer_id into v_cur_tid from trainer_schedule where event_type='c' and event_id = r_cs.id;
    select count(training_session.id) into v_cur_cs_attendance
    from training_session, class_schedule
    where training_session.attended = 'y' and
    training_session.type='c'and
    to_char(training_session.start_time,'DD-MM-YYYY HH24:Mi') = to_char(class_schedule.start_time,'DD-MM-YYYY HH24:Mi') and
    class_schedule.id = r_cs.id;
    DBMS_OUTPUT.PUT_LINE(rpad(r_cs.id, 12) || lpad(v_cur_tid,12) || lpad(r_cs.start_time, 20) || lpad(r_cs.end_time,20) || lpad(r_cs.enrolments,12) || lpad(v_cur_cs_attendance,12));
    END LOOP;
    END LOOP;
    DBMS_OUTPUT.PUT_LINE('******************************************************************************************');
    DBMS_OUTPUT.PUT_LINE('******************************************************************************************');
    DBMS_OUTPUT.PUT_LINE('MOST_POPULAR_CLASS:  '||v_most_pop_cid||'      TOTAL_ENROLMENTS_TO_DATE: '||v_most_enrolments);
    DBMS_OUTPUT.PUT_LINE('LEAST_POPULAR_CLASS: '||v_least_pop_cid||'      TOTAL_ENROLMENTS_TO_DATE: '||v_least_enrolments);
    DBMS_OUTPUT.PUT_LINE('==================================================================================================================================');
    END;
    /

    Hi,
    you could use Dynamic SQL /Execute immediate to run DDL from a stored procedure.
    http://download-uk.oracle.com/docs/cd/B10501_01/appdev.920/a96624/11_dynam.htm
    Could you please tell why do you want to create a materialized view in stored procedure ?
    How frequently you will runt this procedure . It would is better to create a MV once and use it.
    thanks

  • Insert Multiple records using Database adapter with Stored procedure func

    Hi All,
    I want to insert multiple records on a database using a stored procedure. I wanted to insert those records using a Database Adapter and the Database adapter should be invoked by a Mediator.
    Can somebody suggest me with ideas whether it can be acheived with OOB capabtilities in SOA suite or not?
    Thanks for your help in advance.
    Thanks,
    Shiv

    The use case you want to achieve is feature supported by the DBAdapter and it is possible to invoke the same from mediator.
    Please have a look at the oracle documentation and you should be able to get the necessary information.
    The below links should help you as well:
    http://download.oracle.com/docs/cd/E15523_01/integration.1111/e10231/adptr_db.htm
    http://blogs.oracle.com/ajaysharma/2011/03/using_file_adapter_database_adapter_and_mediator_component_in_soa_11g.html
    There are some video tutorials as well :)
    http://www.youtube.com/watch?v=dFldS-fDx70 This should also help
    Thanks,
    Patrick

  • How to use DATETIME parameters in stored procedure?

    I can not define a variable or parameters
    with data type of DATETIME
    when I define stored procedure using Developer/2000.
    Does Oracle not support DATETIME?
    null

    Chen Honghua (guest) wrote:
    : I can not define a variable or parameters
    : with data type of DATETIME
    : when I define stored procedure using Developer/2000.
    : Does Oracle not support DATETIME?
    Oracle supports DATETIME data type.
    "DATETIME" data type is stored in "DATE" data type.
    if you want to DEFINE "10-Jan-1998 10:20" :
    declare
    dummy_date date:=to_date('10-jan-1998 10:00','DD-MON-YYYY
    HH24:MI');
    BEGIN
    END;
    null

  • How to use SPOOL in a stored procedure

    Hi,
    I need to SPOOL the out put of a curson into a file. Please help me to do this. But this is not working.
    declare
    SET DEFINE ON;
    DEFINE SPOOL_FILE='chain.lst'
    cursor c1(var_chn_cnt number) is select owner,TABLE_NAME from dba_tables where CHAIN_CNT>var_chn_cnt order by owner;
    begin
    for c1_var in c1(0)
    loop
    DBMS_OUTPUT.ENABLE(1000000);
    SPOOL &SPOOL_FILE
    --Step 1
    DBMS_OUTPUT.PUT_LINE('set echo on;');
    DBMS_OUTPUT.put_line(chr(13));
    DBMS_OUTPUT.PUT_LINE('ANALYZE TABLE '||c1_var.owner||'.'||c1_var.table_name||' LIST CHAINED ROWS;');
    DBMS_OUTPUT.put_line(chr(13));
    --Step 2
    DBMS_OUTPUT.PUT_LINE('CREATE TABLE '||c1_var.owner||'.'||'CHNTEMP_'||c1_var.table_name||' AS SELECT * FROM '||
    c1_var.table_name||' WHERE ROWID IN (SELECT HEAD_ROWID FROM '||c1_var.owner||'.'||
    'CHAINED_ROWS WHERE TABLE_NAME='''||c1_var.table_name||''' and OWNER='''||c1_var.owner||''||');');
    DBMS_OUTPUT.put_line(chr(13));
    --Step 3
    DBMS_OUTPUT.PUT_LINE('DELETE FROM '||c1_var.owner||'.'||c1_var.table_name||' WHERE ROWID IN (SELECT HEAD_ROWID FROM '||
    c1_var.owner||'.'||'CHAINED_ROWS WHERE TABLE_NAME='''||c1_var.table_name||''' and OWNER='''||c1_var.owner||''||';');
    DBMS_OUTPUT.put_line(chr(13));
    --Step 4
    DBMS_OUTPUT.PUT_LINE('DROP TABLE '||c1_var.owner||'.'||'CHNTEMP_'||c1_var.table_name||';');
    DBMS_OUTPUT.put_line(chr(13));
    --Step 5
    DBMS_OUTPUT.put_line('TRUNCATE TABLE '||c1_var.owner||'.'||'CHAINED_ROWS;');
    DBMS_OUTPUT.put_line(chr(13));
    DBMS_OUTPUT.PUT_LINE('set echo off;');
    DBMS_OUTPUT.put_line('-------------------------------------------------------------------------------------------------');
    end loop;
    --EXCEPTION
    --WHEN OTHERS THEN
    -- raise_application_error(-20001,'An error was encountered - '||SQLCODE||' -ERROR- '||SQLERRM);
    end;
    Regards,
    Mat.

    Hi, Mat,
    Sorry, the answer is the same as it was in [your other thread|http://forums.oracle.com/forums/message.jspa?messageID=3610719#3610719].
    You can't start SPOOLing insided PL/SQL.
    Give the SPOOL command before you start PL/SQL, as Alex, Sundar and I showed you.
    If you really do need to do file I/O from within PL/SQL, use util_file instead of dbms_output. With utl_file you can name, open, read, write and close files from PL/SQL. You can have several output files open at once, if you want to. See the [PL/SQL Packages and Types manual|http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28419/u_file.htm#BABGGEDF] for details.

  • In SQLScript, how to use EXEC to call another procedure with parameters in procedure?

    Hi experts,
    In SQLScript, How to use EXEC to call another procedure with input and output parameters in procedure?thanks very much

    Hi Sagar,
    thank you! I generate another procedure with an input parameter and an output parameter in a procedure. Then i need to call the generated procedure using EXEC. Here is my code:
    create procedure ftest1(out sum_num bigint)
    as
    begin
    declare fa_output bigint;
    declare v_sql_drop varchar(200);
    declare v_sql varchar(500);
    declare cursor c_cursor1 for select num from TABLE1;
    --v_sql_drop := 'drop procedure fe';
    --exec v_sql_drop;
    v_sql := 'create procedure fe(in i_num bigint,out o_num bigint) as begin';
    v_sql := :v_sql || ' o_num := :i_num * 2 + :i_num * :i_num;';
    v_sql := :v_sql || ' end';
    exec v_sql;
    open c_cursor1;
    for c_item as c_cursor1 do
    exec 'call fe(c_item.num,o_num=>fa_output)';
    if sum_num is null then
    sum_num := fa_output;
    else
    sum_num := :sum_num + fa_output;
    end if;
    end for;
    close c_cursor1;
    end;
    The underline code is using exec to call the generated procedure. But this method cannot work. Any suggestion? thanks again!

  • How to use union statement with declare & set function?

    Hi Experts,
            i  have small query about how to use union statement with declare & set function?
    Example as below :
    DECLARE @name AS date
    Declare @name2  AS date
    /* SELECT FROM [2013].[dbo].[OINV] T0 */
    /* WHERE */
    SET @name = /* T0.DocDate */ '[%1]'
    SET @name2 = /* T0.DocDate */ '[%2]'
    select  '2013',t5.U_salmannm,t1.CardName,t2.sumapplied as CollectionAmount,t2.DcntSum ,t3.DocTotal as InvoiceTotal,
    datediff(dd,t3.DocDate,t1.Docdate) as Days
    from 2013.dbo.orct t1
    inner join 2013.dbo.RCT2 t2 on t1.DocNum = t2.DocNum
    left join 2013.dbo.oinv t3 on
    t3.docentry = t2.baseAbs
    inner join 2013.dbo.ocrd t4 on t1.Cardcode = t4.CardCode
    inner join [2013].[dbo].[@CQ_RTSM] t5 on t4.U_BeatCode = t5.U_RoutCode
    where t2.DcntSum <> 0.000000 and t3.DocDate between [%1] and [%2]
    Union
    /* SELECT FROM [2014].[dbo].[OINV] T0 */
    /* WHERE */
    SET @name = /* T0.DocDate */ '[%1]'
    SET @name2 = /* T0.DocDate */ '[%2]'
    select  '2014',t5.U_salmannm,t1.CardName,t2.sumapplied as CollectionAmount,t2.DcntSum ,t3.DocTotal as InvoiceTotal,
    datediff(dd,t3.DocDate,t1.Docdate) as Days
    from 2014.dbo.orct t1
    inner join 2014.dbo.RCT2 t2 on t1.DocNum = t2.DocNum
    left join 2014.dbo.oinv t3 on
    t3.docentry = t2.baseAbs
    inner join 2014.dbo.ocrd t4 on t1.Cardcode = t4.CardCode
    inner join [2014].[dbo].[@CQ_RTSM] t5 on t4.U_BeatCode = t5.U_RoutCode
    where t2.DcntSum <> 0.000000 and t3.DocDate between [%1] and [%2]

    You have to create stored procedure in SQL only .
    Like u must have create for Crystal .
    You can execute procedure in query manager but you have to enter parameter manually..
    example
    Exec @Test '20140101' '20140501'
    Every time user has to enter it manually in yyyymmdd format in case of date parameters.
    Example
    Create Proc [@Test]
    as begin
    DECLARE @name AS date
    Declare @name2  AS date
    /* SELECT FROM [2013].[dbo].[OINV] T0 */
    /* WHERE */
    select  '2013',t5.U_salmannm,t1.CardName,t2.sumapplied as CollectionAmount,t2.DcntSum ,t3.DocTotal as InvoiceTotal,
    datediff(dd,t3.DocDate,t1.Docdate) as Days
    from 2013.dbo.orct t1
    inner join 2013.dbo.RCT2 t2 on t1.DocNum = t2.DocNum
    left join 2013.dbo.oinv t3 on
    t3.docentry = t2.baseAbs
    inner join 2013.dbo.ocrd t4 on t1.Cardcode = t4.CardCode
    inner join [2013].[dbo].[@CQ_RTSM] t5 on t4.U_BeatCode = t5.U_RoutCode
    where t2.DcntSum <> 0.000000 and t3.DocDate between @Name and @Name2
    Union
    /* SELECT FROM [2014].[dbo].[OINV] T0 */
    /* WHERE */
    select  '2014',t5.U_salmannm,t1.CardName,t2.sumapplied as CollectionAmount,t2.DcntSum ,t3.DocTotal as InvoiceTotal,
    datediff(dd,t3.DocDate,t1.Docdate) as Days
    from 2014.dbo.orct t1
    inner join 2014.dbo.RCT2 t2 on t1.DocNum = t2.DocNum
    left join 2014.dbo.oinv t3 on
    t3.docentry = t2.baseAbs
    inner join 2014.dbo.ocrd t4 on t1.Cardcode = t4.CardCode
    inner join [2014].[dbo].[@CQ_RTSM] t5 on t4.U_BeatCode = t5.U_RoutCode
    where t2.DcntSum <> 0.000000 and t3.DocDate between
    between @Name and @Name2
    end

  • Executing a report with stored procedure causes error

    Hello,
    I've got a .NET application where a report gets generated from an .rpt template using Crystal Reports. A template has been created using the fields from stored procedure. While creating the template, I've been working with my DEV environment DB server, and with that server the .rpt has been saved. Within the Designer, I can preview the report, all working fine.
    Using the template with my application, if I set in the code for crystal connection to use the same DB server as has been saved with the .rpt, the report runs and I do get the result in my application as expected. But if I move my code to other environment, using another DB server (but not changing anything in the .rpt), while running the report in the application I get the following error:
    Exception: CrystalDecisions.CrystalReports.Engine.InternalException
    Message: Failed to open a rowset.
    Details: ADO Error Code: 0x
    Source: Microsoft OLE DB Provider for SQL Server
    Description: Could not find stored procedure 'BreachOfAgg'.
    SQL State: 42000
    Native Error:
    Failed to open a rowset.
    Error in File C:\Windows\TEMP\Breach of Aggregate Stop Loss {196B84E5-7DAE-465E-A12D-5C70DDC04CE5}.rpt:
    Failed to open a rowset.
    Source: CrystalDecisions.ReportAppServer.DataSetConversion
       at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
       at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
       at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportOptions options)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToHttpResponse(ExportOptions options, HttpResponse response, Boolean asAttachment, String attachmentName)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToHttpResponse(ExportFormatType formatType, HttpResponse response, Boolean asAttachment, String attachmentName)
       at IFG.ReportsModule.Reporter.CrystalReporter.Export(OutputType outputType, HttpResponse response, String reportName, Boolean asAttachment)
       at IFG.ReportsModule.Reporter.CrystalReporter.Export(OutputType outputType, HttpResponse response, String reportName)
       at IFG.ReportsModule.Proxies.CrystalReporterProxy.ShowResult(OutputType outputType, HttpContext context, CrystalReporter cr)
       at IFG.ReportsModule.Proxies.CrystalReporterProxy.ExecuteReport(ParametersValues parameters, OutputType outputType, HttpContext context)
       at IFG.Web.GetReport.GenerateReport(Int64 reportID) in d:\Jure\PSL\iFish\IFISHRSF\IFISHRSF0100\Root\5. Development\IFISH Portal\SDRMA New\Portal\web\admin\RSF\GetReport.aspx.cs:line 82
       at IFG.Web.GetReport.Page_Load(Object sender, EventArgs e) in d:\Jure\PSL\iFish\IFISHRSF\IFISHRSF0100\Root\5. Development\IFISH Portal\SDRMA New\Portal\web\admin\RSF\GetReport.aspx.cs:line 48
    Nested Exception
    Exception: System.Runtime.InteropServices.COMException
    Message: Failed to open a rowset.
    Details: ADO Error Code: 0x
    Source: Microsoft OLE DB Provider for SQL Server
    Description: Could not find stored procedure 'BreachOfAgg'.
    SQL State: 42000
    Native Error:
    Failed to open a rowset.
    Error in File C:\Windows\TEMP\Breach of Aggregate Stop Loss {196B84E5-7DAE-465E-A12D-5C70DDC04CE5}.rpt:
    Failed to open a rowset.
       at CrystalDecisions.ReportAppServer.Controllers.ReportSourceClass.Export(ExportOptions pExportOptions, RequestContext pRequestContext)
       at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
    If I open in the Crystal Designer the rpt and change the DB to my new server, and then run the report in the application using that same new server, the report runs ok and I do get the results. As well, I don't have this problem using tables or views in the report. Independent of what server has been used while created the .rpt in the Designer, I get the report ran and presented according to the server that I point to within my code.
    I hope someone can help me out with thi.
    Thank you.
    Jure

    Hi Jure,
    All I can suggest now is you try this [app|http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes_boj/sdn_oss_boj_bi/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes%7B6163636573733d36393736354636443646363436353344333933393338323636393736354637333631373036453646373436353733354636453735364436323635373233443330333033303331333533353333333933323331%7D.do]:
    It will get the connection if you need.
    If that doesn't work the purchase a support and Rep can connect to your PC to see what is going on...
    Thanks
    Don

  • 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

  • Using VIEW inside a stored procedure

    Hi,
    So I have a View designed in one file that validates someone who is authorized.
    Then I have a stored procedure to display authorized stationeries created before a given date. Its takes a parameter @CreatedOn.
    How can I use VIEW in my stored procedure so I can display all the authorized which are set 1 before a given date?
    My VIEW:
    ALTER VIEW vw_AuthorizedStationeries AS
    SELECT Authorized
    FROM dbo.Stationeries
    WHERE Authorized = 1
    And my stored procedure:
    CREATE PROCEDURE usp_stationeries (@CreatedOn datetime)ASBEGINSELECTFROMENDGO
    Thanks!

    Try something like below, You need to replace CreatedDate column with appropriate date column in your table.
    1. Alter the view to get the required date:
    ALTER VIEW vw_AuthorizedStationeries AS
    SELECT Authorized, CreatedDate
    FROM dbo.Stationeries
    WHERE Authorized = 1
    2. Alter SP:
    CREATE PROCEDURE usp_stationeries (@CreatedOn datetime)
    AS
    BEGIN
    SELECT Authorized
    FROM vw_AuthorizedStationeries
    WHERE CreatedDate <= @CreatedOn
    END
    GO
    OR
    You can pull required information directly from your table:
    CREATE PROCEDURE usp_stationeries (@CreatedOn datetime)
    AS
    BEGIN
    SELECT Authorized
    FROM dbo.Stationeries
    WHERE CreatedDate <= @CreatedOn and Authorized = 1
    END
    GO
    If this post answers your query, please click "Mark As Answer" or "Vote as Helpful".

  • How to call a sql server stored procedure from oracle

    Hi all,
    Please anybody tell me how to call a sql server stored procedure from oracle.
    I've made an hsodbc connection and i can do insert, update, fetch data in sql server from oracle. But calling SP gives error. when I tried an SP at oracle that has line like
    "dbo"."CreateReceipt"@hsa
    where CreateReceipt is the SP of sql server and hsa is the DSN, it gives the error that "dbo"."CreateReceipt" should be declared.
    my database version is 10g
    Please help me how can i call it... I need to pass some parameters too to the SP
    thanking you

    hi,
    thank you for the response.
    when i call the sp using DBMS_HS_PASSTHROUGH, without parameters it works successfully, but with parameters it gives the following error
    ORA-28500: connection from ORACLE to a non-Oracle system returned this message:
    [Generic Connectivity Using ODBC][Microsoft][ODBC SQL Server Driver]Invalid parameter number[Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index (SQL State: S1093; SQL Code: 0)
    my code is,
    declare
    c INTEGER;
    nr INTEGER;
    begin
    c := DBMS_HS_PASSTHROUGH.OPEN_CURSOR@hsa;
    DBMS_HS_PASSTHROUGH.PARSE@hsa(c, 'Create_Receipt(?,?)');
    DBMS_HS_PASSTHROUGH.BIND_VARIABLE@hsa(c,1,'abc');
    DBMS_HS_PASSTHROUGH.BIND_VARIABLE@hsa(c,2,'xyz');
    nr:=DBMS_HS_PASSTHROUGH.EXECUTE_NON_QUERY@hsa(c);
    DBMS_HS_PASSTHROUGH.CLOSE_CURSOR@hsa(c);
    end;
    Create_Receipt is the sp which requires two parameters.
    please give me a solution
    thanking you
    sreejith

  • Problem With Stored Procedure

    Post Author: Ranjith.403
    CA Forum: General
    Hi,
    Am new to crystal reports with stored procedures
    am created a report using a stored procedure in oracle. In that Stored Procedure am Using a temporary table.
    After inserting values into the table am assigning to ref cursor.
    Refcursor having fields like item,onhandstock,purchase rate
    This report working fine in oracle version 9.2.0.1.0 where comes to oracle version 9.2.0.8.0 it's giving the varchar values correctly.
    The Number values are showing as 0.
    Help me to solve it.
    Thanks in Advance,
    Ranjith

    Try modularising this large procedure into smaller procedures and functions, and determine which part is causing you trouble.

Maybe you are looking for

  • How do I install the sim card?

    How do I install the sim card on the 5s?

  • Presentation only on one Monitor?

    I am preparing a Presentation for 2 Beamers (Left & Right). But also the new Keynote Provides only one Monitor Output 8(. I cant present my Stage 1600x600 on my two Monitor Outputs (Left 800x600, Right 800x600 ). I have tryed the Matrox TripleHead2Go

  • Customisation for PO Release (different Values for different Doc Types)

    Dear Experts, I need to configure for PO release procedure where in the Characteristics would be Plant (2 Plants), Doc Type (3 types - Standard PO, Imports PO & Capital PO) and Value (2 stage release: 0-100000 & >100000 INR for Std PO, 0-200000 & >20

  • Can not Open exe file that is created by Labview 2010 SP1

    Hi Everyone, My Operating system is XP .. I installed .net latest version but I can not open exe file. I try to open  exe file, then  crashes , quits without seeing any interface. I tried with another computer whose o.s is xp too. I can open exe file

  • Connecting to a specific SQL Server instance?

    Hi all, I create a new connection for SQL Server, specify the host and the port number that SQL Browser is listening on (my servers have dynamic ports, not static), and I can connect succesfully to the local SQL Server Instance on that machine, which