How to make crosstab report in crystal report

Hi all ,
I want to make a crosstab report in crystal report
my query is like this
select YearDate.year ,
(currentasset.currentaset / currentliability.currentliability  ) as CurrentRatio
,(currentasset.currentaset - Inventory.Inventoryaset / currentliability.currentliability ) as QuickRatio
from
select distinct YEAR(JDT1.RefDate) as year from JDT1
)YearDate left join
select YEAR(JDT1.RefDate) as year,sum(JDT1.Debit - JDT1.Credit ) as currentaset from JDT1,OACT
where JDT1.Account = OACT.AcctCode
and OACT.AcctCode = '11'
group by YEAR(JDT1.RefDate)
)currentasset on YearDate.year = currentasset.year left join
select YEAR(JDT1.RefDate) as year,sum(JDT1.Debit - JDT1.Credit ) as Inventoryaset from JDT1,OACT
where JDT1.Account = OACT.AcctCode
and OACT.AcctCode = '11.05'
group by YEAR(JDT1.RefDate)
)Inventory on YearDate.year = Inventory.year left join
select YEAR(JDT1.RefDate) as year,sum(JDT1.Debit - JDT1.Credit ) as currentliability from JDT1,OACT
where JDT1.Account = OACT.AcctCode
and OACT.AcctCode = '21'
group by YEAR(JDT1.RefDate)
)currentliability on YearDate.year = currentliability.year  left join
order by YearDate.year
So if i view the data in sql server it should be like this
Year   CurrentRatio   quickRatio
2006               501                 100
2007              600                  200
2008             700                   300
2009             900                   400
I want to make a crosstab with the column is year . the Year is dynamic according to the selection
So if i select the year from  2007 to 2009
It should be like this in report
2007                2008              2009
CurrentRatio                 600                  700                  900
QuickRatio                    200                   300                 400
How can i make it in Crystal report ?
I have use the template in crosstab crystal report, but there is not suitable.
Can i make manually. ?
Thanks in advance
Regards
KK

Hi kevin,
thanks for your respond . Actually, it's work.
But i have some issue again.
How can i make a grouping
So the grouping per Item
For example                                                                               
                                                      2006                 2007                 2008
Group 1               Item A                5                        6                       7
                            Item B                7                        8                       9
Group 2              Item C                  9                       0                      0
                           Item D                 8                        8                      9
And another question, Is there always have row summary ? It seems that after the 2008 column, there is a total column, Can I remove this ?
Thanks in advance
regards
KK
Edited by: kah kian on Jun 2, 2011 4:17 PM

Similar Messages

  • How to make tree view in Crystal Reports

    Hi,
    We are using Crystal Reports XI R2.
    In ASP.Net, we are using tree view and same that we need display in Crystal Reports for reporting purpose.
    We have thee levels of records.
    I know the way making group by and sub group by to show in hierarchy level.
    How to achieve exact tree view in Crystal Reports as in ASP.Net
    Please give me some suggestions.
    Thanks and regards,
    Manjunath N. Jogin

    Create the report first.

  • Step- by- Step on How to Load Excel data into Crystal Reports?

    Hi Friends,
                      Can anyone send me a Step- by- Step on How to Load Excel data into Crystal Reports? Pls help me. Thanks in Advance.
    Vijay

    It's also important to 'prep' the excel file prior to connecting to it.
    Give the data tab a meaningful name
    Make sure the column headers are unique and that every column has a header
    Delete any blank tabs
    If you have trouble with Excel changing the data type of a field (say, a social security number you want to be a string value rather than a number so you don't lose leading zero) an alternative would be to save the spreadsheet file as a CSV, create a schema.ini to specify the data types for each column (example below) and use the same steps to connect except instead of choosing Excel 8.0, scroll to the bottom and choose Text.  You have to make sure the CSV file is in the same folder as the schema.ini file that defines the columns.
    Schema.ini example:
    200912PUSD.csv
    ColNameHeader=True
    Format=CSVDelimited
    MaxScanRows=25
    CharacterSet=OEM
    Col1=SSN Char Width 9
    Col2=LAST_NM Char Width 25
    Col3=FIRST_NM Char Width 25
    Col4=DOB Date
    Col5=STDNT_ID Char Width 10
    Col6=SORTKEY Char Width 10
    Col7=SCHOOL_NM Char Width 30
    Col8=OTHER_ID Integer
    Col9=GRADE Char Width 2
    The filename in the first line needs to have the []  brackets around it, but I couldn't get it to display in this forum correctly.
    Edited by: Eric Petersen on Jan 27, 2010 9:40 AM

  • How to hide Group Tree in Crystal Report Server.

    Hi all visitors
    i have created one crystal report and my report use group to summary the amount of each day.
    after i use group to summary, i used text box cover the group. so my group can't click anything.
    After that i upload my report to crystal report server, when i viewed my report and when i click on Group Tree, it will show the list of group (group date in crystal report) and it also can click. I don't want to show the Group Tree in Crystal Report Server.
    Anybody know how to hide group tree in crystal report server?
    Best Regards,

    Are you talking custom application, or infoview?  If it is custom app, you would have to look at the setToolPanelViewType method.  if its infoview, no direct way to change this that i know of.

  • How to view multiple reports using crystal reports 2008

    Hi ,
    I am working on vb6 project where in i am trying to generate reports using crystal reports 2008.
    For this , i am making use of Interop Form Wrapper class in vb6.
    I have a business requirement where in i need to view multiple reports  on my screen.
    please suggest me as to how this can be achieved.
    Thanks in Advance
    Regards,
    Ramnath

    Hi Ludek,
    I  am directly now using crystal report viewer control in my vb6 project.
    As mentioned in previous mail, i have created a Interop Wrapper class over crystal report viewer control in .Net using visual studio 2008 and i am making use of wrapper class in my vb6 project.
    I am able to access all the properties that have been defined in my Interop wrapper Class but the only stuff i need is to view multiple reports generated one after the another for a single button click Event.
    Please find below the code that iam using to load and generate reports.
    Note:
    1. frm is the instance of my Interop Wrapper Class built over CR viewer control
    2. All the user defined methods of Wrapper class that you see below will internally call the actual crystalreportviewer   properties defined in my Wrapper class
    Say for e.g   frm.DisplayToolbar(True) will internally  execute  crystalreportViewer1.DisplayToolbar = True
    frm.SetReportSource(strRptFilePath,0)          
    frm.SetSelectionFormula(strrecordSelectionFormula)
    frm.DisplayToolbar(True)               
    frm.ShowExportOption(True)
    frm.ShowPrintOption(True)
    frm.ShowRefreshOption(True)
    frm.ShowPAgeNavigateOption(True)
    frm.ShowZoomOption(True)
    frm.ShowParameterPanelOption(True)
    frm.Show()
    Thanks in Advance
    Regards,
    Ramnath

  • How to center the content in crystal report viewer?

    open crystal report viewer in winform, default at the left top
    after maxmium the winform window, content become at the center
    another odd thing is that i set window winform size 1208*1024 and crystal report view is fill
    then tried, content is not center any more
    How to center the content in crystal report viewer in code?
    Edited by: Mathew_666 on Oct 6, 2011 5:20 AM

    Since there is no control for center you'll need to do the math on your own. This is just a rough draft, but you'll get the idea.
    One of the things you'll need to figure out is your buffer to help you give a centered feel. We'll say that value is 50 in this case.
    Height
    int buffer = 50;
    int formHeight = 1000; // we'll assume a height of 1000 in this case
    int crystalTop = buffer;
    int crystalViewerHeight = formHeight - (buffer * 2); // buffer is at the top and bottom
    Width
    int formWidth = 1000; // we'll assume a width of 1000 in this case
    int crystalLeft = buffer;
    int crystalViewerWidth = formWidth - (buffer * 2); // buffer is at the top and bottom

  • How to make a CheckBox for a report parameter?

    Hi,
    How to make a CheckBox for a report parameter?
    thanx

    design ur parameters forms using forms and call ur report form there

  • How to make query base delivery monthly report  link with delivery return

    Hi,
    I have facing some problem in Sales delivery report monthly. Problem is:
    1) When i make Monthly query delivery report without any delivery return and AR Credit memo, it is Fine.
    2) When i make Monthly query delivery report with any delivery return and AR Credit memo, it is not showing proper. Its showing in report including return quantity or AR Credit memo quantity.
    So, How to make query base delivery monthly report  link with delivery return and AR Credit Memo?
    Please help me regarding this.
    Mizan
    Edited by: mizan700 on Dec 18, 2010 2:50 PM
    Edited by: mizan700 on Dec 18, 2010 2:50 PM

    Hi,
    try this.
    SELECT DISTINCt T1.CARDCODE, T1.CARDNAME , T1.DOCNUM DELIVERY#,T1.DocStatus 'DELIVERY STATUS', T1.DOCDATE 'DELIVERY Date', T1.DocTotal 'DELIVERY Total', T3.DOCNUM Return#,T3.DocStatus 'Return Status', T3.DOCDATE 'Return Date', T3.DocTotal 'Return Total',T5.DOCNUM Invoice#,T5.DocStatus 'Invoice Status', T5.DOCDATE 'Invoice Date', (T5.DocTotal-T5.VatSum-T5.TotalExpns-T5.DiscSum) 'Total Before Discount', T5.VatSum 'Tax', T5.TotalExpns 'Freight', (T5.DocTotal - T5.PaidToDate) 'Total Payment Due', T7.DOCNUM AS 'CREDIT MEMO#', T7.DOCDATE
    FROM DBO.DLN1 T0
    INNER JOIN DBO.ODLN T1 ON T1.DOCENTRY = T0.DOCENTRY
    LEFT JOIN DBO.RDN1 T2 ON T2.BASEENTRY = T1.DOCENTRY
    LEFT JOIN DBO.ORDN T3 ON T2.DOCENTRY = T3.DOCENTRY
    LEFT JOIN DBO.INV1 T4 ON T4.BASEENTRY = T1.DOCENTRY
    LEFT JOIN DBO.OINV T5 ON T5.DOCENTRY = T4.DOCENTRY
    LEFT JOIN DBO.RIN1 T6 ON T6.BASEENTRY = T5.DOCENTRY
    LEFT JOIN DBO.ORIN T7 ON T7.DOCENTRY = T6.DOCENTRY
    WHERE  T1.DOCDATE >= [%0] AND  T1.DOCDATE <= [%1]
    Thanks,
    Joseph

  • How to convert  PLD Report into Crystal Report

    Hello Experts,
                             I want to convert my  PLD Report into Crystal Report, but  i am not able to find the solution ,
                             so how can i do this and what are the  steps have to taken.
    Kindly give me the solution .
    Regards
    Rahul

    Hi Rahul........
    SAP has given a tool where you can convert your PLDs into Crystal Reports.......
    Please check the below link to download tool......
    http://www.sdn.sap.com/irj/scn/downloads?rid=/library/uuid/108305a7-1555-2d10-8289-9a178d441c71
    Regards,
    Rahul

  • How to set DbConnections when scheduling a crystal report using Crystal Reports Server Java SDK?

    Post Author: Manjula
    CA Forum: JAVA
    Hi,
    Trying to schedule a report using Crystal Reports Server Java SDK. Want to pass DBConnections from API, though passing DBConnections, the report is not being scheduled and says "Failed to retrieve data from the database.Details:&#91;Database Vendor Code:6550&#93;.
    Would be thankful if someone could answer my point as applicable.
    Here is the code attached.
    ISDKList dbLogons = oReport.getReportLogons();int dbLogonSize = dbLogons.size();
    for(int i=0; i<dbLogonSize; ++i) {
    IReportLogon dbLogon = (IReportLogon)dbLogons.get(i);
    dbLogon.setDatabaseName("DBname");
    dbLogon.setUserName("usrname");
    dbLogon.setPassword("pwd");
    Thanks in advance.

    Post Author: Manjula
    CA Forum: JAVA
    Ted,
    Thank you for your valuable information.
    First, tried scheduling on Central Management Console and then with the java code.It worked fine, but here is another question for you.
    On the Console, a report exists with ServerName and UserName harcoded and when trying to set ServerName and UserName from the java code, its throwing exception. Where as Password is not set on Console, am able to set password from java.
    And DatabaseName is not set on Console (non editable), unable to set the same from java too. Why is it so?
    So, my question is - though ServerName,DatabaseName,UserName,Password exists on the Console report, can't I override those parameters from java?
    Would be greatful if you answer my question and provide me some guidance.
    Thanks in advance.

  • How to Display Japanese character in Crystal Report 8.5

    Hi,
    I've some data stored in japanese language in sql server 2005 database using nvarchar datatype.
    When i execute store proc in sql server, it's showing japanese character properly in sql server. However, when i'm trying to display data in crystal report 8.5, it's showing ????? character.
    I've tried to change font to 'Arial Unicode MS (Japanese)',MS Gothic, MS UI Gothic, MS Mincho (Japanese) as per the search result available in  google. But not had any luck.
    Can anyone please provide any solution for this?
    Many Thanks.
    Kaushal

    when i tried to open below link
    https://websmp130.sap-ag.de/sap%28bD1lbiZjPTAwMQ==%29/bc/bsp/spn/bobj_download/main.htm
    It's not opening & displaying access denied message as below.
    403 Access denied
    You do not have the permissions to access this resource
    Error is logged with Tag:
    Just want to know, Is it possible to display japanese characters on report using crystal report 8.5?
    We've constraint to use only CR 8.5
    Regds,
    Kaushal

  • Font style issue with exporting report in Crystal Reports 2008

    Hi,
    I got stuck on the below issue for a while. Please can anyone help on this?
    When I designed and executed a report in Crystal Reports 2008 on my local PC, the font style and size used in charts were exactly what I was expecting.
    However, after I exported the report to our BusinessObjects CMC and displayed it in InfoView, the font style and size in charts looked quite different from what they were in CrystalReports.
    Any ideas of how to fix this issue?
    Thanks!
    BAI

    Hi Nanda Kishore,
    This is because you do not have proper rights on Business View Manager.  Whenever you create a dynamic parameter in crystal and try to save the report on BO, it creates a Business view automatically.  Now in your case, it is unable to create a business view due to insufficient rights.
    Go in Business View Manager u2013 Repository exploreru2014You will find Dynamic Cascading Prompts folderu2014Right click on that and go in rights and add your user information and give full rights.
    Also make sure that your BO and CR designer on same version and patch level.
    Thanks,
    Sastry

  • Open ECC report in Crystal Reports

    Hi,
    Question, hope you have some info on this...
    I want to try & open a custom report which is built in an ECC system (report is currently run as a "Yxxx" transaction) in Crystal Reports. Purpose is to further edit and format the report using Crystal Reports functions.
    Does anyone know what path to follow here? Do I have to set up a new connection for the given source system?
    Thanks for any tips advice.
    Ps. I have Crystal Reports 2008 and also the BI Integration Kit (not sure if this is used / required).
    Thanks,
    Willem

    There are transports that the SAP Integration Kit delivered.  you may have already installed this on your BW, but they would need to be installed on ECC if you want to query there.  Once these are installed, Crystal should be able to see an SAP - Table, Cluster, Function  Data Connection allowing you to connect to your ECC.
    You should review the SAP Integration Kit doc - it spells out authorizations required, how to handle security, etc.

  • Report containing 15 sub reports crashing - Crystal Reports 2008

    I am using Crystal report 2008 with all latest service packs applied. I have more then 20 different reports wich work absolutely fine and never crash. One of my report contains 15 sub reports since its bringing data from 15 different queries. This consistently keeps crashing everytime I try to run it. Not sure what could be the root cause.
    We are using Postgres database and connected to it with  ODBC connection using Microsoft DSN.
    - All Subreport data is being displayed on Report Footer
    - All subreports are included in the Main report  page header section. (I have also tried doing it on report footer section but it still crashes)
    I have tried searching through the forum and did not find similar issue resolutions. Did someone face similar problems before?
    The crash message is:
    "crw32.exe has encountered a problem and needs to close. We are sorry of the inconvenience."
    Error report contains this data:
    AppName: crw32.exe      AppVer: 12.2.0.290      ModName: psqlodbc35w.dll
    ModVer: 9.0.2.0      Offset: 0004c538
    I am using Windows XP
    Crystal Report Version Details:
    CR Developer Version 12.2.0.290
    Product Type: Full
    Let me know how can I debug this issue? Any help is appreciated.

    @Don - We performed extensive testing for this crash issue and found that now this crash is not happening only in one scenario. So we have partially fixed this.
    Now the report crashes if I get disconnected from database and reconnect. This is what happens
    1. open the report in crystal report 2008
    2. try to run the report when db is connected- it works fine.
    3. Now disconnect the database (we are using ssh tunnel to connect to db so we just close the tunnel)
    4. now try to refresh the report - it fails to retrieve data.
    5. Now close the report without saving it.
    6. Now Close Crystal Report.
    7. Now Connect the DB using ssh tunnel so crystal report can connect.
    8. Now open Crystal Report
    9. Launch the target report.
    10 Preview the report - it works for first time.
    11. Now do a refresh keeping same parameters - Report crashes here.
    - I tried these steps with some of my other reports and they do not crash.
    - Now I have only one report which contains a Postgres Query with date range,order by and a union join.
    - No subreports now - I am trying to run this one subreport as a standalone report which I created from scratch(using blank report wizard) and just copied the query.
    Any more pointers would help.

  • Creating Crystal Reports with Crystal Report Server XI

    Hello,
    I am new to Crystal Reports, i installed Crystal Reports Server XI R2 on Windows 2003 server with SP2 and was able to launch Inforview application and also Central Management Console Log On.
    I can also see some sample reports which are installed during installation.
    Now my next task is to create Crystal Reports using Crystal Report Server XI R2. How can we create a crystal report now by only using Crystal Report Server XI R2?
    Do we have to install some other application to create Crystal Reports? I donot see any link on my server which i can use to create crystal reports. The only links which i can see are :
    Business Objects-->
         Crystal Report Server-->
                            .Net Administration LaunchPad
                            .Net Infoview
                            Business View Manager
                            Central Configuration Manager
                            Data Source Migration Wizard
                            Data Source Migration Wizard Help
                            Import Wizard
                           Online Developer Library
                            Publishing Wizard
                            Registration Wizard
                           Release Notes
                           Repository Migration Wizard
    Please help
    Thanks
    Vipin

    Two ways to create reports:
    1) You install the Crystal reports Designer (CRW32.exe).
    With your Crystal Report Server, you should also have received a second CD that would have the CR designer.
    2) You use the RAS SDK and create reports on the fly using the RAS report creation APIs - .NET or Java. Since you are in the .NET developer forum, I assume you might be interested in the .NET RAS SDK. Here is a list of resources i would recommend:
    Links to samples are [here|https://www.sdn.sap.com/irj/scn/wiki?path=/display/bobj/netBusinessObjectsEnterpriseSDKSamples]
    [How to use the RAS SDK .NET with In-process RAS Server|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/10b840c0-623f-2b10-03b5-9d1913866b32]
    [Programing RAS|https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b050afe0-2fa5-2b10-658d-98f214ba6a4a]
    [Choose the Right SDK for the Right Task|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f006a5e6-7e64-2b10-8a84-8b15ca5cacfc]
    For more help, search these forums (there are some great posts in here), the [notes database|https://www.sdn.sap.com/irj/scn/advancedsearch?cat=sdn_ossnotes&query=&adv=true]
    [articles|https://www.sdn.sap.com/irj/sdn/businessobjects-articles] and [downloads|https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/bobj_download/main.htm]
    Ludek

Maybe you are looking for