SQL and a backlog report by site

Post Author: ck1938
CA Forum: WebIntelligence Reporting
Hi, I had to create a backlog reprort a few months back and the only way I could get the data to organize properly was to create a sql statement that had the months predefined as below: SELECT  sum(1),  '2006-10',  SEA_ERSSQL.dbo.HD_CALL.CALL_IDFROM  SEA_ERSSQL.dbo.HD_CALLWHERE  (   substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CREATION_TIME, 120),1,7)  <  '2006-10'   AND   (    SEA_ERSSQL.dbo.HD_CALL.CONDITION  <>  'Closed'    OR    substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CLOSE_DATE, 120),1,7)  >=  '2006-10'   )  )GROUP BY  substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CREATION_TIME, 120),1,7),   SEA_ERSSQL.dbo.HD_CALL.CALL_IDUnionSELECT  sum(1),  '2006-11',  SEA_ERSSQL.dbo.HD_CALL.CALL_IDFROM  SEA_ERSSQL.dbo.HD_CALLWHERE  (   substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CREATION_TIME, 120),1,7)  <  '2006-11'   AND   (    SEA_ERSSQL.dbo.HD_CALL.CONDITION  <>  'Closed'    OR    substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CLOSE_DATE, 120),1,7)  >=  '2006-11'   )  )GROUP BY  substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CREATION_TIME, 120),1,7),   SEA_ERSSQL.dbo.HD_CALL.CALL_IDUnionSELECT  sum(1),  '2006-12',  SEA_ERSSQL.dbo.HD_CALL.CALL_IDFROM  SEA_ERSSQL.dbo.HD_CALLWHERE  (   substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CREATION_TIME, 120),1,7)  <  '2006-12'   AND   (    SEA_ERSSQL.dbo.HD_CALL.CONDITION  <>  'Closed'    OR    substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CLOSE_DATE, 120),1,7)  >=  '2006-12'   )  )GROUP BY  substring(CONVERT(VARCHAR,SEA_ERSSQL.dbo.HD_CALL.CREATION_TIME, 120),1,7),   SEA_ERSSQL.dbo.HD_CALL.CALL_ID
What I'm being asked to do now is to create a backlog
report based on sites.  We have several hundred that are grouped by a
condition called Site ID.  I originally tried modifying the SQL dates only
but soon realized I would need a way for the SQL to accommodate the ongoing
changes since the person running the report could choose one site or one
hundred and the predefined SQL would not change to allow for these
changes.  Does anyone have any ideas on how to build a backlog report that
would provide the same results but allow variables or allow that piece of the
SQL to be modified?

si,
If you have 10 queries that each return a single value, you could combine them into one big query.
Each of your 10 queries could be a scalar subquery.
e.g:
SQL> select (select 1 from dual) A,
  2         (select 2 from dual) B,
  3         (select 3 from dual) C
  4    from dual;
         A          B          C                                               
         1          2          3  Then your report or chart could run off of that query.
Doug

Similar Messages

  • SQL Server 2008 R2 - Report Builder 3.0 - timeout using shared data source and stored procedure

    I select the shared datasource from the data source propeties dialog, test the connection and everything is good.
    I add a dataset by selecting "use a dataset embedded in my report" option within the Dataset properties dialog.
    I select the newly added data source, click the "Stored procedure" query type and drop down the list box and select my intended stored procedure.
    the timeout for the dataset is "0" seconds.
    I click the "OK" button and I'm presented with the parameters to the stored procedure.
    I enter valid data for the parameters and click the "OK" button.
    I then get the following error message after 30 seconds:
    The problem is, all of the timeouts, that I'm aware of, have values of zero (no timeout) or high enough values that 30 seconds isn't even close to the timeout.
    I think the smallest timeout we have is 120 seconds.
    I have searched this site and many others and the solutions all involve altering the stored procedure to get the fields into report builder and then revert the stored procedure back to its original form.
    To me, this is NOT a solution.  
    I have too many stored procedures that need to be brought into Report Builder.
    I need a real solution.
    Thank you for you time, Tim Caldwell.
    Timothy E Caldwell

    I don't mean to be rude, but really, check to see if the stored procedure can return data rows???
    Maybe I'm not being clear enough.
    The stored procedure runs perfectly fine.
    it runs perfectly fine in the production environment and the test environment.
    I can access the stored procedure in several ways and have it return correct data.
    I can even trick report builder into creating a dataset with parameters and run the stored procedure that way.
    What I cannot do, is to get report builder to not timeout after 30 seconds on the initial creation of a dataset with a Query type of stored procedure.
    I have seen this issues posted again and again and again on may different sites and the "solution" is to simplifiy the stored procedure by creating a stored procedure that has a create table and a select in the stored procedure and that's it.  After
    report builder creates the dataset the developer then has to replace the simplified stored procedure with the actual stored procedure and everything works fine after that.
    HOWEVER, having to go through this process for 70 or more stored procedures is ridiculous.
    It would appear that there is something within report builder itself that is causing this issue.
    The SQL Script included is an example of a stored procedure that will not create fields create a dataset with fields and parameters in Report Builder 3.0:
    USE [CRUM_IT]
    GO
    /****** Object: StoredProcedure [dbo].[COGNOS_Level5ScriptSP] Script Date: 11/17/2014 08:02:26 ******/
    SET ANSI_NULLS ON
    GO
    SET QUOTED_IDENTIFIER ON
    GO
    ALTER procedure [dbo].[COGNOS_Level5ScriptSP]
    @CompanyCode varchar(8) = null,
    @GetSiblings varchar(1) = 'N'
    as
    Begin
    -- get emergency contact info
    select *
    into #tmp_Contacts
    from
    (select
    ConEEID,
    con.connamelast as [Emer Contact Last Name],
    con.connamefirst as [Emer Contact First Name],
    con.connamemiddle as [Emer Contact Middle Initial/Name]--,
    ,ROW_NUMBER() over (Partition by ConEEID order by ConNameLast)as rn
    ,ISNULL(
    case when con.conphonepreferred = 'H'
    then '(' + substring(con.conphonehomenumber, 1, 3) + ')' + substring(con.conphonehomenumber, 4, 3) + '-' + substring(con.conphonehomenumber, 7, 4)
    else '(' + substring(con.conphoneothernumber , 1, 3) + ')' + substring(con.conphoneothernumber , 4, 3) + '-' + substring(con.conphoneothernumber , 7, 4)
    end,
    ) as [Emergency Phone]
    from [ultiprosqlprod1].[ultipro_crum].dbo.Contacts con
    where con.ConIsEmergencyContact='y'
    and con.ConIsActive='y'
    ) A
    where A.rn = 1
    CREATE TABLE #tmp_CompanyCodes (CompanyCode varchar(8))
    If @GetSiblings = 'Y'
    Begin
    INSERT INTO #tmp_CompanyCodes (CompanyCode)
    EXEC [z_GetClientNumbers_For_ParentOrg_By_ClientNumber] @CompanyCode
    End
    INSERT INTO #tmp_CompanyCodes
    values (@CompanyCode)
    select *
    into #tmp_Company
    from [ultiprosqlprod1].[ultipro_crum].dbo.Company
    where cmpcompanycode in (select CompanyCode from #tmp_CompanyCodes)
    select distinct
    cmpcompanycode as [Client ID],
    CmpCompanyDBAName as [Client Name],
    eec.eecEmplStatus AS [Employment Status],
    eec.eecEmpNo AS [Employee Num],
    rtrim(eep.eepNameLast) AS [Last Name],
    rtrim(eep.eepNameFirst) AS [First Name],
    isnull(rtrim(ltrim(eep.eepNameMiddle)), '') AS [Middle Initial/Name],
    rtrim(eep.eepAddressLine1) AS [Address Line 1],
    isnull(rtrim(eep.eepAddressLine2), '') AS [Address Line 2],
    eep.eepAddressCity AS [City],
    eep.eepAddressState AS [State],
    CASE
    WHEN len(eep.eepAddressZipCode) > 5 and charindex(eep.eepAddressZipCode, '-', 1) = 0
    THEN substring(eep.eepAddressZipCode, 1, 5)
    ELSE rtrim(eep.eepAddressZipCode)
    END AS [Zip code],
    CASE
    WHEN len(eep.eepAddressZipCode) > 5 and charindex(eep.eepAddressZipCode, '-', 1) = 0
    THEN substring(eep.eepAddressZipCode, 6, 4)
    WHEN len(eep.eepAddressZipCode) > 5 and charindex(eep.eepAddressZipCode, '-', 1) > 0
    THEN substring(eep.eepAddressZipCode, charindex(eep.eepAddressZipCode, '-', 1) + 1, 4)
    WHEN len(eep.eepAddressZipCode) <= 5
    THEN ''
    END AS [ZIP + 4],
    substring(eep.eepSSN, 1, 3) + '-' + substring(eep.eepSSN, 4, 2) + '-' + substring(eep.eepSSN, 6, 4) AS [SSN],
    isnull(convert(VARCHAR(10), eep.eepDateOfBirth, 101), '') AS [Date Of Birth],
    eetFED.TAXCODE AS [FED Tax Code],
    eetFED.FILINGSTATUS AS [Fed Filing Status],
    eetFED.EXEMPTIONS AS [Fed Exemption Allowance],
    eetFED.ADDITIONAL AS [Additional Fed Withholding],
    eetSIT.TAXCODE AS [SIT Tax Code],
    eetSIT.FILINGSTATUS AS [State Filing Status],
    eetSIT.EXEMPTIONS AS [State Exemption Allowance],
    eetSIT.ADDITIONAL AS [Additional State Withholding],
    isnull('(' + substring(eep.eepPhoneHomeNumber, 1, 3) + ')' + substring(eep.eepPhoneHomeNumber, 4, 3) + '-' + substring(eep.eepPhoneHomeNumber, 7, 4), '') AS [Home Phone],
    isnull((SELECT cod.codDesc
    FROM [ultiprosqlprod1].[ultipro_crum].dbo.Codes cod WITH (NOLOCK)
    WHERE cod.codCode = eep.eepEthnicID
    AND cod.codDosTable = 'ETHNICCODE'), '') AS [Race-Origin], --eep.eepEthnicID AS [Race-Origin],
    eep.eepGender AS [Gender],
    isnull(convert(VARCHAR(10), eec.eecDateOfOriginalHire, 101), '') AS [Original Hire Date],
    isnull(convert(VARCHAR(10), eec.eecDateOfSeniority, 101), '') AS [Seniority Date],
    isnull(convert(VARCHAR(10), eec.eecDateOfTermination, 101), '') AS [Termination Date],
    isnull(eecTermType,'') as [Termination Type],
    isnull(TchDesc, '') as [Termination Reason],
    rtrim(eec.eecJobCode) AS [WC Code],
    isnull(eec.eecJobTitle, '') AS [Job Title],
    pgr.pgrPayFrequency AS [Pay Frequency],
    eec.eecFullTimeOrPartTime AS [Full/Part Time],
    eec.eecSalaryOrHourly AS [Pay Type],
    isnull(convert(MONEY, eec.eecHourlyPayRate), 0.00) AS [Hourly Rate],
    isnull(eec.eecAnnSalary, 0.00) AS [Annual Salary],
    [YTD Hours],
    isnull(eep.eepNameFormer, '') AS [Maiden Name],
    eec.eecLocation AS [Location ID],
    rtrim(eec.eecOrgLvl1) AS [Department ID],
    eec.eecorglvl2 AS [Cost Item],
    eec.eecorglvl3 as [Client Project],
    eec.eecPayGroup as [Pay Group],
    isnull(eepAddressEMail,' ') as [Email Address],
    isNull(BankName1,' ') as PrimaryBank,
    isNull(BankRoute1,' ') as PrimaryRouteNum,
    isNull(Account1,' ') as PrimaryAccount,
    isNull(AcctType1,' ') as PrimaryAcctType,
    isNull(DepositRule1,' ') as PrimaryDepositRule,
    isNull(BankName2,' ') as SecondaryBank,
    isNull(BankRoute2,' ') as SecondaryRouteNum,
    isNull(Account2,' ') as SecondaryAccount,
    isNull(AcctType2,' ') as SecondaryAcctType,
    isNull(DepositRule2,' ') as SecondaryDepositRule,
    isNull(
    CASE
    WHEN DepositRule2 = 'D'
    THEN '$' + convert(varchar, cast(EddAmtOrPct2 AS decimal(10,2)))
    WHEN DepositRule2 = 'P'
    THEN convert(varchar, cast((EddAmtOrPct2*100) AS decimal(10,0))) + '%'
    ELSE null
    END,' ') as SecondaryDepositAmount,
    isNull(BankName3,' ') as ThirdBank,
    isNull(BankRoute3,' ') as ThirdRouteNum,
    isNull(Account3,' ') as ThirdAccount,
    isNull(AcctType3,' ') as ThirdAcctType,
    isNull(DepositRule3,' ') as ThirdDepositRule,
    isNull(
    CASE
    WHEN DepositRule3 = 'D'
    THEN '$' + convert(varchar, cast(EddAmtOrPct3 AS decimal(10,2)))
    WHEN DepositRule3 = 'P'
    THEN convert(varchar, cast((EddAmtOrPct3*100) AS decimal(10,0))) + '%'
    ELSE null
    END,' ') as ThirdDepositAmount,
    Supervisor,
    eec.eecEEID AS [Employee EEID],
    eec.EecJobCode As [Job Code],
    isnull(eec.EecTimeclockID,' ') As [Time Clock ID],
    con.[Emer Contact Last Name],
    con.[Emer Contact First Name],
    con.[Emer Contact Middle Initial/Name],
    con.[Emergency Phone]
    from [ultiprosqlprod1].[ultipro_crum].dbo.empPers eep WITH (NOLOCK)
    inner join [ultiprosqlprod1].[ultipro_crum].dbo.empComp eec WITH (NOLOCK)
    ON eep.eepEEID = eec.eecEEID
    inner join #tmp_Company cmp WITH (NOLOCK)
    ON eec.eecCOID = cmp.cmpCOID
    inner join [ultiprosqlprod1].[ultipro_crum].dbo.PayGroup pgr WITH (NOLOCK)
    ON eec.eecPayGroup = pgr.pgrPayGroup
    left outer join [ultiprosqlprod1].[ultipro_crum].dbo.TrmReasn
    on tchCode = eecTermReason
    left join (select CAST(sum(isnull(eee.eeeYTDHrs,0.00))AS DECIMAL(18,2)) as [YTD Hours],
    eeeEEID,
    eeeCOID
    from [ultiprosqlprod1].[ultipro_crum].dbo.EmpEarn eee with (NOLOCK)
    group by eeeCOID,eeeEEID)eee
    on eec.eecEEID = eee.eeeEEID
    and eec.eecCOID = eee.eeeCOID
    left join (SELECT eetCOID AS COID,
    eetEEID AS EEID,
    eetTaxCode AS TAXCODE,
    eetFilingStatus AS FILINGSTATUS,
    eetExemptions AS EXEMPTIONS,
    eetExtraTaxDollars AS ADDITIONAL
    FROM [ultiprosqlprod1].[ultipro_crum].dbo.empTax WITH (NOLOCK)
    WHERE eetTaxCode = 'USFIT'
    )eetFED
    ON eec.eecCOID = eetFED.COID
    and eec.eecEEID = eetFED.EEID
    left join (SELECT eetCOID AS COID,
    eetEEID AS EEID,
    eetTaxCode AS TAXCODE,
    eetFilingStatus AS FILINGSTATUS,
    eetExemptions AS EXEMPTIONS,
    eetExtraTaxDollars AS ADDITIONAL
    FROM [ultiprosqlprod1].[ultipro_crum].dbo.empTax WITH (NOLOCK)
    WHERE eetTaxCode like '%SIT'
    AND eetIsWorkInTaxCode = 'Y'
    )eetSIT
    ON eec.eecCOID = eetSIT.COID
    and eec.eecEEID = eetSIT.EEID
    left outer join (SELECT eddCOID,
    eddEEID,
    eddEEBankName BankName1,
    eddEEBankRoute BankRoute1,
    eddAcct Account1,
    EddAcctType AcctType1,
    EddDepositRule DepositRule1,
    EddAmtOrPct EddAmtOrPct1
    FROM [ultiprosqlprod1].[ultipro_crum].dbo.EmpDirDp WITH (NOLOCK)
    WHERE eddSequence = '99')edd
    ON eec.eecCOID = edd.eddCOID
    and eec.eecEEID = edd.eddEEID
    left outer join (SELECT eddCOID,
    eddEEID,
    eddEEBankName BankName2,
    eddEEBankRoute BankRoute2,
    eddAcct Account2,
    EddAcctType AcctType2,
    EddDepositRule DepositRule2,
    EddAmtOrPct EddAmtOrPct2
    FROM [ultiprosqlprod1].[ultipro_crum].dbo.EmpDirDp WITH (NOLOCK)
    WHERE eddSequence = '01')edd2
    ON eec.eecCOID = edd2.eddCOID
    and eec.eecEEID = edd2.eddEEID
    left outer join (SELECT eddCOID,
    eddEEID,
    eddEEBankName BankName3,
    eddEEBankRoute BankRoute3,
    eddAcct Account3,
    EddAcctType AcctType3,
    EddDepositRule DepositRule3,
    EddAmtOrPct EddAmtOrPct3
    FROM [ultiprosqlprod1].[ultipro_crum].dbo.EmpDirDp WITH (NOLOCK)
    WHERE eddSequence = '02')edd3
    ON eec.eecCOID = edd3.eddCOID
    and eec.eecEEID = edd3.eddEEID
    left outer join (SELECT eecCOID,
    eecEEID,
    rtrim(eepNameLast) + ', ' +
    rtrim(eepNameFirst) + ' ' +
    isnull(rtrim(ltrim(eepNameMiddle)), '') AS [Supervisor]
    FROM [ultiprosqlprod1].[ultipro_crum].dbo.EmpComp WITH (NOLOCK)
    join [ultiprosqlprod1].[ultipro_crum].dbo.EmpPers with (NoLock)
    on eeceeid = eepeeid)eec2
    ON eec.eecSupervisorID = eec2.eecEEID
    left outer join #tmp_Contacts con
    on eep.eepEEID = con.ConEEID
    order by [Client ID],
    [Last Name],
    [First Name]
    drop table #tmp_Contacts
    END
    Timothy E Caldwell

  • Report on Sites, Lists and Libraries with Unique Permissions

    I would like to get a report on Sites, Pages, Lists, Libraries, Items and Documents under a Site Collection having Unique Permissions. What is the best way to accomplish that ?

    Finally catch your meaning. In SharePoint 2010, uniquely secured objects can be displayed on the permission settings page of the parent object(see my screenshots here
    http://cid-6f40fb61d28cf147.office.live.com/view.aspx/Technology/UniquePermission.docx
    ). And as you may already know, it seems only show inheritance broken within a site. I found it does not show unique permission of sub sites in a site collection.
    You may want something like a Broken Inheritance Report Jobs in SharePoint Administration Toolkit for SharePoint 2007 (http://blogs.msdn.com/b/sharepoint/archive/2009/08/27/announcing-the-fourth-release-of-the-microsoft-sharepoint-administration-toolkit.aspx
    ). However, I had not found it in SharePoint Administration toolkit for SharePoint 2010. 
    If you are currently in need of this kind of reports, you may try third party tools such as that from the Lightingtools(I am not familiar with it and don’t know
    if it will meet your requirement).
    Or you can back up the content database from and restore it to test environment to query. With the help of SQL Server profiler, I found that the stored procedure proc_SecChangeToUniqueScope(http://msdn.microsoft.com/en-us/library/dd358095(PROT.13).aspx
    ) is called when you break permission inheritance. You can find more information around this store procedure by searching:
    http://www.bing.com/search?q=site%3Amsdn.microsoft.com+proc_SecChangeToUniqueScope
    And you can make use of database comparison tools such as that from the visual studio 2010 premium/ultimate to compare the content database before and after the site
    permission inheritance is broken to learn what tables to query (of cause, you should do all this in test environment).

  • Daily & Monthly Backlog Reports and Printing program

    •     <b>Labeling program for Deliveries</b>: This program picks all deliveries created/updated on the current day, validates them by checking whether they have the required labeling information. If the program finds that the labeling information is missing, it populates WMS structures (header & detail) for further.
    •     <b>Daily & Monthly Backlog Reports and Printing program</b>: This program calls 2 separate reports (Daily & Qtrly. Backlog Reports), based on user selection, and directly prints the reports as well as converts them to PDF format and emails them as attachments to the MD.
              Please provide me the solution.

    For First program :
    Use table LIKP (SD Document: Delivery Header Data) & LIPS(item Data) for fetch inf all the data for selected date use field ERZET(Entry time) & ERDAT(Date creation of record) for created deliveries & refer TABLES - CDPOS and CDHDR for modified deliveries
    For Second object:
    Call multiple programs by using SUBMIT <program> with selection screen params.
    Print as per requirement by passing print parameters to Structure PRI_PARAMS &
       call function 'GET_PRINT_PARAMETERS'                     
       exporting destination = liprintr                         
                 mode        = 'CURRENT'                        
                 no_dialog   = 'X'                              
       importing out_parameters = pri_params.                       
    *To Convert ABAP List and SAP Script to PDF files use program - "RSTXPDFT4"
    ALSO REFER this nice weblog >
    /people/erwan.lebrun/blog/2007/04/16/tips-tricks-email-fax-through-the-same-output-type
    Hope it will help.
    Vishal
    Message was edited by:
            Vishal Tyagi

  • Tablespace size report for SQL and oracle servers

     
       Hi All
      is it possible to get tablespace size for all sql and oracle server in the form of report in SCOM.
      Regards
      Madhavi

    Oracle: Table size report of Oracle is depend on the MP which yu imported into SCOM
    SQL :
    1) Create a group which contains folowing dynamic rule
    2) Reporting workspace --> Microsoft Gneric Report --> Performace Detail
    3) in the parameter area, create a new series, add group which create in step 1) and select the rule: MSSQL XXX: Collect Database Allocated Size(MB)
    4) Run the report
    5) In the report, click actions and select "Performance details for every object"
    Roger

  • Concatenate results SQL query and CASE use Report Builder Reporting Services

    I need to concatenate the results from a SQL query that is using CASE.  The query is listed below.  I do not need permitsubtype but I need to concatenate the results from the permittype. 
    I tried deleting the permitsubtype query and it would not run correctly.  Please see the query and diagram below.  Any help is appreciated.
    select  PERMIT_NO
    ,(case when
      ISNULL(PERMITTYPE,'') = ''
      then 'Unassigned'
      else (select LTRIM(RTRIM(PERMITTYPE)))
      END) AS PERMITTYPE
    ,(case when
      ISNULL(PERMITSUBTYPE,'') = ''
      then 'Unassigned'
      else (select LTRIM(RTRIM(PERMITSUBTYPE)))
      END) AS PERMITSUBTYPE
     ,ISSUED
     ,APPLIED
     ,STATUS 
     ,SITE_ADDR 
     ,SITE_APN
     ,SITE_SUBDIVISION
     ,OWNER_NAME
     ,CONTRACTOR_NAME
     ,ISNULL(JOBVALUE,0) AS JOBVALUE
     ,FEES_CHARGED
     ,FEES_PAID
    ,BLDG_SF
    from Permit_Main
    where ISSUED between @FromDate and @ToDate

    Hi KittyCat101,
    As per my understanding, you used case when statement in the query, you do not need to display permitsubtype in the report, but when you tried to delete permitsubtype from the query, it could not run correctly. In order to improve the efficiency of troubleshooting,
    I need to ask several questions:
    “I tried deleting the permitsubtype query and it would not run correctly.” As we can see, it has no effect to delete permitsubtype from the query you provided, could you please provide complete sql query for the report?
    Could you please provide detailed information about the report? I would be appreciated it if you could provide sample data and screenshot of the report.
    Please provide some more detailed information of your requirements.
    This may be a lot of information to ask for at one time. However, by collecting this information now, it will help us move more quickly toward a solution.
    Thanks,
    Wendy Fu

  • A strange issue on PL/SQL and Crystal report

    A Crystal rpt file (version=8.5) is called through CRAXDRT.DLL by a VB6 exe. This rpt file has two linked sub-reports. There are 3 Oracle stored procedures behind the main report and two sub-reports. I found that the stored procedure behind the main report is always called twice within the same Oracle session when the VB based report is run. Did someone else ever meet the similar situation and know why?
    Thanks in advance!

    Thanks for your response. In fact, the stored procedure for the main report is responsible for querying data and inserting them into a oracle table (report table); the stored procedures for the sub-reports only summarize the data stored in the above report table. The main stored procedure are not called in the stored procedures for the sub-reports. I attach a field consisting of the current Oracle PL/SQL session number and system time to each recod in the report table. So I can trace the process of inserting data by the main stored procedure and found that the main stored procedure actually insert the same data twice within the same Oracle session.
    Thanks

  • Sql query to find backgorund jobs and their associated reports

    Hi Guys
    is there any possibility to find job (jobname) their scheduling and the corresponding reports with their variant via sql queries?
    Looking up the tables tbt-something only show %NEWSTEP for the INTREPORT value, so this isn´t clearifying at all.
    Maybe you could tell me the tables where the reports and their variants are saved.
    Cheers
    Fabi

    hi check this...
    go to the table TIBCO
    there you will find
    jobname
    jobgroup
    report name
    job status
    but there is no varient specification and
    %NEWSTEP is the report name

  • Regarding Booking ,Billing and Backlog report

    Hi,
    I am trying to excute the BBB report through Bex in BW.
    <b>Descripition</b>: I have created 1 report called  Booking,Billig and Backlog report
    Main problem ;Intercompany Invoices are not showing as billings
    <b>Scenario:</b>
    a)  Sales Order 300007887 created in US01 Sales Org. Delivery is out of a Canadian Plant.
    b)  Intercompany Billing 900024929 that Canada created to Bill the US is not showing as billings for the Canadian Company Code.
    US Company code is 0801 and canada company code is 0870.
    I have created sales orders and intercompany billings  as   kefigures .
    And i have taken Charcterstic company code as 'Filter'
    Salesorders for US (0801) intercompany billing for canada(0870)
    When i excute the query with  US Company code (0801) it will show report with all sales orders.
    But with canda companycode (0870)  it will not show  the iniernal billings
    Could you please give the soloution abt this.
    Thanks
    Sri

    Hi Ravi,
    Thank you for your mail but we dont have<b> Order type charcterstic</b> in my infoprovider.
    Regards,
    Sridhar

  • Learning sql and pssql ,xml,forms and report

    ihave learned sql and plsql i donot Xml and forms and reports  how to learn by own by easy method
    by sql and psql we have learned from basic to higher ,weather things going from book to online (any other way to practising and understanding the concepts)

    learning sql and pssql ,xml,forms and repojavascript:;learning sql and pssql ,xml,forms and reportrt for beginners

  • Please give good for learning sql and pl/sql site

    Hi All,
    please give good reference site for learning sql and pl/sql, your suggestion would be appreciated.

    http://tahiti.oracle.com/
    http://www.oracle.com/pls/db112/homepage?remark=tahiti
    http://download.oracle.com/docs/cd/E11882_01/appdev.112/e10766/toc.htm
    http://download.oracle.com/docs/cd/E11882_01/server.112/e17118/toc.htm
    http://download.oracle.com/docs/cd/E11882_01/appdev.112/e17126/toc.htm

  • There are two iMacs connected through same router in my house but one refuses to login to facebook and other logged in sites. local techies are bemused, I have just reinstalled OSX and still have the problem. Login page recycles and no errors reported.

    There are two iMacs connected through same router in my house but one refuses to login to facebook and other logged in sites. Local techies are bemused, I have just reinstalled OSX and still have the problem. Login page recycles, I get no further and no errors reported. Safari, Opera and Firefox. Deleted cookies and chain but still no action.

    If you have not already done so, read the router's user manual troubleshooting section and/or contact its customer service department/forums. 
    If still having problems, post back w/details of all you have tried to resolve the problems along w/the troubleshooting solutions that the "local techies" had you try.
     

  • EDITING SQL SCRIPT IN CRYSTAL REPORTS

    I just installed Version 12 and am trying to edit SQL scripts in Crystal Reports that were created in Version 8.  When opening the Database tab on the Main Menu, the Query Panel is greyed out and not accessible.  I can view the SQL Query but cannot edit it.  If someone can advise me what to do I would be very appreciative.
    Edited by: Frank Romano on Mar 18, 2009 4:17 PM

    Hi Frank,
    Here is the SAP Note that says that you cannot edit SQL from Crystal 9 and later
    Symptom
    In Crystal Reports (CR) 8.5 and earlier, it is possible to edit the SQL statement in the 'Show SQL Query' dialog box. Doing so allows the report designer to modify the SQL statement that CR generates. Starting with Crystal Reports version 9, users are no longer able to modify the SQL in the 'Show SQL Query' window.
    How can you control the SQL statement that Crystal Reports sends to the database?
    Resolution
    To control the SQL statement that Crystal Reports 9 and later uses, use the 'Add Command' feature to create a Command Object. The 'Add Command' feature replaces the ability to edit SQL statements in the 'Show SQL Query' dialog box. Use this dialog box to write your own SQL command (query) which will be represented in Crystal Reports as a Table object.
    More Information
    Additional information about creating and using Command Objects ('Add Command') can be found on our support site and within the Online Help file contained in Crystal Reports.
    On our support site search for the technical brief, cr_query_engine.pdf and knowledge base article c2016641 at
    http://support.businessobjects.com/search
    Keywords
    OBJECT ADD COMMAND EDIT SHOW SQL QUERY DATABASE ACCESS MENU MODIFY SQL Crystal Reports Show SQL query Command object , c2017389
    Regards,
    Raghavendra

  • Dynamically pass the username and password to report server to invoke reports

    Hi
    The scenario is as follows:-
    9iAS is installed under - Windows 2000 (web server and report Server 6i) and everything works fine.
    We have developed a page using pl/sql cartrige (oracle 8i), from that a report is invoked with some parameters. However, the userid and password is stored under keymap file (cgicmd.dat).
    Is there anyway to pass dynamically the username and password to report server in order to invoke the report.?
    Can any one advise?
    null

    Check out
    http://serverfault.com/questions/371907/can-you-pass-user-pass-for-http-basic-authentication-in-url-parameters
    Kind regards,
    Margriet Bruggeman
    Lois & Clark IT Services
    web site: http://www.loisandclark.eu
    blog: http://www.sharepointdragons.com

  • SQL Developer user defined reports (appropriate utilization)

    I have used SQL developer on a limited basis but I have never created a user defined report. Can someone compare and contrast the
    types of user defined reports that can be created via SQL developer versus the types of user defined reports that can be created via
    a tool such as Crystal Reports or similar tool.

    Hi user7753875 -
    I agree with reidelme that it won't match the capabilities for fancy organisation/output of tools like Crystal Reports, but you can do interrelated parent/multiple child reports.
    Check out the Reports tab on the SQL Developer Exchange for some examples of what other users have done with this.
    Brian Jeffries
    SQL Developer Team
    Edited by: bjeffrie on Jun 3, 2011 5:01 PM
    Turns out no one has used that in a long time. You will have to do some interpretive cut/past from xml given by web site & report editor in SQL Developer. Here is the "Who" report (master+2 child reports) from the exchange in a format you can use the import function from "User Defined Reports" on.
    <?xml version="1.0" encoding="UTF-8" ?>
    <displays>
    <display id="57507b3a-0130-1000-8008-a9fec67b8254" type="" style="table" enable="true">
         <name><![CDATA[Who]]></name>
         <description><![CDATA[
    A Report to show active seesion and some details about there activities. Includes 2 Child-reports for Active SQL and PID for the process supporting the session.
    ]]></description>
         <tooltip><![CDATA[Who is logged in and what is he doing]]></tooltip>
         <drillclass><![CDATA[null]]></drillclass>
         <CustomValues>
         </CustomValues>
         <query>
              <sql><![CDATA[SELECT sid, serial#, username, status, server, machine, program FROM v$session order by sid]]></sql>
         </query>
         <display id="null" type="Child" style="Table" enable="true">
              <name><![CDATA[ActiveSQL]]></name>
              <description><![CDATA[]]></description>
              <tooltip><![CDATA[]]></tooltip>
              <drillclass><![CDATA[null]]></drillclass>
              <CustomValues>
                   <TYPE>null</TYPE>
              </CustomValues>
              <query>
                   <sql><![CDATA[select c.spid b1, b.osuser c1, b.username c2, b.sid b2, b.serial# b3, a.sql_text,b.status,to_char(b.logon_time, 'DD-MON-YYYY HH24:MI:SS') from v$sqltext a, v$session b, v$process c where a.address = b.sql_address and b.paddr = c.addr and a.hash_value = b.sql_hash_value and b.sid = :SID order by c.spid,a.hash_value,a.piece]]></sql>
                   <binds>
                        <bind id="SID">
                             <prompt><![CDATA[SID]]></prompt>
                             <tooltip><![CDATA[SID]]></tooltip>
                             <value><![CDATA[NULL_VALUE]]></value>
                        </bind>
                   </binds>
              </query>
         </display>
         <display id="null" type="Child" style="Table" enable="true">
              <name><![CDATA[Process]]></name>
              <description><![CDATA[]]></description>
              <tooltip><![CDATA[]]></tooltip>
              <drillclass><![CDATA[null]]></drillclass>
              <CustomValues>
                   <TYPE>null</TYPE>
              </CustomValues>
              <query>
                   <sql><![CDATA[select p.spid,p.addr,s.sid,s.server,p.username,s.osuser,p.program,t.value/1024/1024 PGA_Mb from v$process p,v$session s,v$sesstat t where p.addr=s.paddr and s.sid=t.sid and s.sid = :SID and t.statistic#=20]]></sql>
                   <binds>
                        <bind id="SID">
                             <prompt><![CDATA[SID]]></prompt>
                             <tooltip><![CDATA[SID]]></tooltip>
                             <value><![CDATA[NULL_VALUE]]></value>
                        </bind>
                   </binds>
              </query>
         </display>
    </display>
    </displays>
    Edited by: bjeffrie on Jun 3, 2011 5:01 PM

Maybe you are looking for

  • Problem Previewing Spry in Browser

    Hi, I've been following the Adobe online tutorials, and I'm failing miserably with Spry. Even the pre-worked, finished example files will not display properly in Internet Explorer 7. I refer to the files regarding "Using the Spry Framework for Ajax"

  • Need help with SQL Query (query for certain IDs in a table and then IDs not in result set)

    OK. This is hard to explain but that may be my problem in constructing the query. I have a table that has a list of jobs. The jobs information in this table, among other things, is a short description of the job itself (think "title" in phrase form),

  • My mac book pro will not boot up

    my MBpro will not boot up when turned on, it continues the reading process, and just continues to run.  I would like to power up using control keys, and bypass loading programs or a testing mode.

  • Adobe Reader plugin(Acrobat) won't install and Update in FF4

    if I try to open FF4 and go to a pdf file Adobe Reader 10 will open then freeze FF4... I then went to Plugin check.. says Adobe Acrobat needs an Update.. I d/l it 3x.. still comes up as needing an upadate after restarting FF4... it just won't take it

  • I have a pdf with a line graph that opens slow

    I have a pdf with a line graph. When users open this it is very slow (30 seconds or more). Once this pdf is open, zooming or scrolling through pages takes just as long to accomplish as open the document. I am assuming this is due to the graph needing