Cross tab Date Column Grouping

Hi,
I have a cross tab in my report which displays no of tickets opened grouped by day, week or Month, grouping is done based on a parameter GroupBy, which has Day, Week, Month values
Incident   Jun -99  Jul-99
Priority1      10          20
Priority2      45          23
if user selects day or week, cross tab should display column in dd/mm/yy format, if its month, MMM-yy format.
I have created formula which returns a date type
GroupBy = Day then Opendate
GroupBy = Week then opendate -dayofweek(opendate)+1
GroupBy = date(year(opendate),month(opendate),1)
and used this date formula as column in cross tab. I tried to format using custom date style...but its not working in cross tab.
if I use totext to format the date formula, data will not be in sorted order...ex, its showing jul-99 before jun-99
can anyone help?
Thanks in Advance,
Jyothi

You can avoid multiple cross tabs by using the Display String expression under Field Formatting.  The expression that is entered in this field is what is displayed as the field value in the report.  Use the same logic as you are using for calculating the value, except return CStr(CurrentFieldValue, <format>), where <format> is the formatting code for the desired date format based on GroupBy.
HTH,
Carl

Similar Messages

  • Single and Double Underlines When Showing Cross Tab Data

    Hi,
    I am trying to generate an XML Publisher rtf report in which I need to show the cross tab data which is in number format underlined and totals as double underlined. Is there a way to do that;
    I am using XML Publisher 5.6.2 version , Build 45 and I am trying to manage this on Windows XP, Excel 2003 environments.
    Thanks and regards.

    Can you generate a crosstab that looks like you want to show in the Template Builder for Word?
    It should generate a separate line - but 5.6.2 is so long ago, I don't remember what the pivot table
    wizard did at this time.
    Unfortunatley, we do support for text only single underlines - border can have double lines.
    Klaus

  • Create CROSS-TAB Arrange Column data (sort Data)

    Dear,
    I have created CROSS-TAB and left axix has has data like
    aa
    bb
    cc
    dd
    but i want result like
    cc
    aa
    bb
    dd
    Please quide me how to arrange data with my own will.
    Regards

    I've found that when the sort is out of the order I want, it's necessary to set up a calculation that sets a key to use instead of the field value.
    So case when field = 'ccc' then 'a. ccc'
    when field = 'aaa' then 'b. aaa'
    and so on.
    That initial character then forms the basis of the default crosstab sort.

  • Cross tab - change column name

    Hi,
    I would like to change on my dashboard the name of the column in cross tab based on design studio.
    I know that it is possible to do that on back-end side and provide desired names in query selection but I will need to to that on Design Studio level.
    Does anyone tell me if it is possible ?
    Thanks
    Marcin

    Hi Marcin,
    here's additional CSS for it
    .sapzencrosstab-ColumnHeaderArea .sapzencrosstab-HeaderCellDefault:first-child{
      visibility: hidden;
    .sapzencrosstab-ColumnHeaderArea .sapzencrosstab-HeaderCellDefault:first-child:after {
      visibility: visible;
      content: "column new name";

  • Cross tab data is getting multiplied if i use multiple queris in asingle report

    HI,
      i am using multiple queris for displaying data and graphs(charts).
      my requirement is to display 2 charts and data in crosstab in a single report.
      all the three thing (2charts and crosstab) will use diffrent values.
    I am writing 3 sql queries for getting appropriate values for charts and crosstab.
      Now the problem, both charts and crosstab are taking the values of all 3 queris
    i.e if i added crosstab  first to the report values are coming correctly. After  that if i add graph cross tab values are getting changed and graph values are not getting properly.
    if i add graph first then its coming correctly.
    if i tried to add all 3 components then values are going cores...... ?

    When you say you are writing 3 sql queries what do you mean? Are you creating 3 SQL command objects in the database expert? If so this is your problem, Crystal will pull a cartesian product through (this is every possible combinatin of rows from the 3 queries).
    If your 2 graphs and 1 crosstab are based on different datasets the way to approach this is to create each on a seperate report, then create a new blank report and add each of your 3 reports as subreports in the report footer.
    Hope this helps,
    Toby

  • Date column group by 15 minute interval using SQL

    I am using Oracle 9i DB, I have a large table containing several rows with following example data. Each row identifies a transaction.
    Transaction_id, status, completed_date
    1667050 SUCCEEDED 4-Dec-03 00:00:44
    1667091 SUCCEEDED 4-Dec-03 00:05:45
    6670930 SUCCEEDED 4-Dec-03 00:09:46
    4359066 SUCCEEDED 4-Dec-03 00:10:46
    this table consists of rows for a 24 hour day period.
    I need to write a SQL query to generate a report to give me a count of transactions 24 hour period grouped into 15 minute or half hour period.
    for example
    count time_interval
    5000 00:00:00 - 00:14:59
    2345 00:15:00 - 00:29:59
    and so on
    I am new to SQL and so am having a hard time figuring out which function or how to group date column to achieve the end result. I would be grateful if someone could throw some suggestions.

    This should help.
    http://asktom.oracle.com/pls/ask/f?p=4950:8:::::F4950_P8_DISPLAYID:4222062043865

  • Record no/Serial no in cross tab based on grouping

    Hi Experts,
    How to get Record no/Serial no in cross tab based on grouping

    CR 2013 support pack 2 version 14.1.2.1121.
    Kindly check the screen shot

  • Cross tab - Rank column

    I am trying to create a column that represents the rank of a row based on a column.  So if I have schools like Harvard, Princeton, Yale and each school is on the left and they have values of tuition, cost of living.  I would like to display two different columns of rank on the same crosstab.  One rank based on tuition and the other cost of living
    Princeton-----100000 -
    30000
    Yale--8000--
    10000
    I would like to CR to calculate the rank of the schools based on the tuition then the cost of living.
    Any ideas? Is there a function that does rank based on column values in CR?

    There are different methods to achieve the ranking effect.One method is given in below link
    http://evtechpartners.com/home/blog/3-ranking-in-crystal-reports-2008
    Hope this helps
    Regards,
    Bilahari M

  • Can we apply sorting on Column values in Cross tab??

    Can we apply sorting on Column values in Cross tab??
    Following is the scenario with me.
    I have 2 fields and one formula.
    Fields are HostName and Username.
    Formula is status which categorizes the Authorized and Unauthorized events.
    And in the Summary Field, I am calculating the total number of events.
    In cross tab, Fields are marking the Rows of the cross tab and Formula is making the Columns(Authorized and Unauthorized ) of the cross tab.
    Since in cross tab data is grouped from left to right and sorted by default. I want to remove this default sorting and want to put sorting on the formula for Unauthorized events.
    Is there any way to fulfill this requirement?

    Hi,
    You can assign a number to each Unauthorised field e.g
    Rank   Unauthorised
    1         A
    2         BC
    3         DF
    5         TD
    6         GF
    Then add "Rank" to the crostab Columns before the Unauthorised  field. Then you can control the sorting order on your crosstab.
    Hope this helps
    Regards
    Dotun

  • Filtering Key Figures/Columns in a Cross Tab Component

    Hello All,
    I am creating a P&L Statement for Better/Worse comparisions, and I have to show only three columns at a time based on User Drop Down Selections.
    Here is my Bex Query Out put looks like.  The Rows part is "Structure" and Columns are "Cell Restrictions".
    Now, the CrossTab component has to show only Two columns at a time, based on user selections. Here is my desired output. User will Select either ' Avg' Rate or 'End Rate'. Based on that selction, Actual's will show in the First Column and based on Selection from Second DROPDOWN for Budget/Forecast/PY, the Second Column has to be displayed.
    Is there any DropDown Component or CrossTab Component Options are there to Filter the Columns based on User Selections ?
    Appreciate your help. This is the Crucial Chart for the whole Dashboard.
    Thanks,
    Sonti.

    Hi Tammy,
    Thanks for your quick reply.
    Can it be done dynamically without the User touching it ? My Cross Tab has to show values based on the Selctions. But, I couldn't find the code to restrict Cross Tab data.
    I have to code for Dropdown box --> On Select, to check / Un check the KF's in the Filter Panel Component. And in Filter Panel Comoponent, --> On Select, DATASOURCE.setFilterExt("KF1", "KF2").
    And assign the data source to Cross Tab.
    Please correct me if I am wrong.
    Regards,
    Sonti.

  • BI Publisher Pivot Table or Cross Tab

    Hai All,
    I have a doubt in developing a Matrix report in XML. I have developed a matrix report in RDF and the output is coming fine in RDF. I have generated the XML file which looks like this. I need to develop the report which displays employee details followed by the allowance which are dynamic.
    - <XXHRPRF>
    - <LIST_G_SUMRESULT_VALUE>
    - <G_SUMRESULT_VALUE>
    - <LIST_G_EMPLOYEE_NUMBER>
    - <G_EMPLOYEE_NUMBER>
    <EMPLOYEE_NUMBER>100026</EMPLOYEE_NUMBER>
    <PERSON_ID>80</PERSON_ID>
    <NATIONALITY>USA</NATIONALITY>
    <NATIONAL_IDENTIFIER />
    <UNIFIED_ID />
    <FULL_NAME>Thomas H Mathew</FULL_NAME>
    <ORGANIZATION_NAME>Corporate Affairs</ORGANIZATION_NAME>
    <PENSION_FUND_ID />
    <CS_SNO>1</CS_SNO>
    <CF_PENSION_CONTRIBUTION>3637.5</CF_PENSION_CONTRIBUTION>
    <CP_PENSION_COMP_CONTR>10912.5</CP_PENSION_COMP_CONTR>
    <CP_TOTAL_SALARY>72750</CP_TOTAL_SALARY>
    <CF_TOTAL_CONTRIBUTION>14550</CF_TOTAL_CONTRIBUTION>
    - <LIST_G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>1</TAG>
    <ELEMENT_NAME>Basic Salary</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>39650</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>2</TAG>
    <ELEMENT_NAME>Housing Allowance</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>25000</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>3</TAG>
    <ELEMENT_NAME>Child allowance</ELEMENT_NAME>
    <LIST_G_PERSON_ID />
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>4</TAG>
    <ELEMENT_NAME>Social allowance</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>700</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>5</TAG>
    <ELEMENT_NAME>Excess Allowance</ELEMENT_NAME>
    <LIST_G_PERSON_ID />
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>6</TAG>
    <ELEMENT_NAME>Additional</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>7400</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    </LIST_G_ELEMENT_NAME>
    </G_EMPLOYEE_NUMBER>
    - <G_EMPLOYEE_NUMBER>
    <EMPLOYEE_NUMBER>100030</EMPLOYEE_NUMBER>
    <PERSON_ID>82</PERSON_ID>
    <NATIONALITY>Canada</NATIONALITY>
    <NATIONAL_IDENTIFIER />
    <UNIFIED_ID />
    <FULL_NAME>Sara Wilson</FULL_NAME>
    <ORGANIZATION_NAME>Human Resources</ORGANIZATION_NAME>
    <PENSION_FUND_ID />
    <CS_SNO>2</CS_SNO>
    <CF_PENSION_CONTRIBUTION>1203.75</CF_PENSION_CONTRIBUTION>
    <CP_PENSION_COMP_CONTR>3611.25</CP_PENSION_COMP_CONTR>
    <CP_TOTAL_SALARY>316575</CP_TOTAL_SALARY>
    <CF_TOTAL_CONTRIBUTION>4815</CF_TOTAL_CONTRIBUTION>
    - <LIST_G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>1</TAG>
    <ELEMENT_NAME>Basic Salary</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>19600</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>2</TAG>
    <ELEMENT_NAME>Housing Allowance</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>22500</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>3</TAG>
    <ELEMENT_NAME>Child allowance</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>600</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>4</TAG>
    <ELEMENT_NAME>Social allowance</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>800</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>5</TAG>
    <ELEMENT_NAME>Excess Allowance</ELEMENT_NAME>
    <LIST_G_PERSON_ID />
    </G_ELEMENT_NAME>
    - <G_ELEMENT_NAME>
    <TAG>6</TAG>
    <ELEMENT_NAME>Additional</ELEMENT_NAME>
    - <LIST_G_PERSON_ID>
    - <G_PERSON_ID>
    <RESULT_VALUE>3075</RESULT_VALUE>
    </G_PERSON_ID>
    </LIST_G_PERSON_ID>
    </G_ELEMENT_NAME>
    </LIST_G_ELEMENT_NAME>
    </LIST_G_EMPLOYEE_NUMBER>
    </G_SUMRESULT_VALUE>
    </LIST_G_SUMRESULT_VALUE>
    <CF_PERIOD>MAR-2009</CF_PERIOD>
    - <XXHRPRF>
    I need to develop a cross tab format in RTF using template builder. Can we get this in matrix report using the standard wizard given in template builder or else it should be done manual. If it can be done through wizard can u please explain the process.
    And one more think what is the latest version of template builder available. In few cases its given as pivot table and in few its given as cross tab. I confused by that.
    This seems to be basic doubt, but please guide me.
    Regards

    i,
    I am developing cross tab report with group in BI Publisher(i.e matrix with group above report in report builder).
    My req.is
    Country1
    region1 region2 region3 --- (level1 column)
    d1 d2 d3 d1 d2 d3 d1 d2 d3 --(level2 column)
    Row1 10 15 18 24 38 40 36 35 78 --data
    Row2 -- -- -- --- --- -- - -- -- --
    regions(level1 columns) and d1,d2,d3(level2 columns) are data depenent on XML data.
    d1,d2 d3 may change in number based on data.Also we have page break on country.
    We could able to achieve in report builder but in Bi Publisher we are unable to achieve the same.
    Wizard in BI Publisher gives only one level of measure(region) only.
    Currently we are using BI Publisher template builder version 10.1.3.2.1
    Need help in this regard ASAP.
    Thanks in advance.

  • Displaying Alternate row as colored in Cross tab

    Hi,
    I have a report where I need to display alternate rows as colored.
    There is some data in detail section followed by a cross tab in the report header section.
    While I am able to display alternate rows as colored in Detail secction for displaying alternate colored rows in Cross tab data I need some help.
    Data in cross tab is like this
                  history geography
    Tammy   90          60
    Sid         80          50
    Julia       70        40
    In cross tab for displaying alternate colored rows ie for alternate student names  I am using two formulas
    - for displaying row values I am using this one
    whileprintingrecords;
    numbervar d;
    d := iif(d=100,255,100);
    color(255,255,d);
    For displaying alternate colored inner cells ie marks  I am using this formula
    whileprintingrecords;
    numbervar c;
    c := iif(c =255,100,255);
    color(255,255,c)
    I got these formulas after doing Googling
    My cross tab is present in report footer and in the generated report it comes separeated in two pages.
    In the first page data for Tammy and Sid is displayed while Julia is displayed on next page.
    Now the Tammy is coming as yellow colored and as expected Sid is coming as white colored. However Julia which is on next page is coming as white , but logically it should have come as yellow. On the other hand my column data ie marks column is coming fine. Data for tammy and sid is coming as alternately colored and data is Julia on the next page is coming as yellow(as data for Sid is in white)
    I am not able to understand why this is happening and what is the correct way to do alternate row coloring in cross tabs
    Edited by: thunderball10 on Aug 26, 2010 11:57 AM
    Edited by: thunderball10 on Aug 26, 2010 12:00 PM

    Where is your variable c being reset.
    If in page header or group header and you have repaet group header on new page then c will be reset on each page.
    If In groupheader try adding this to reset formula
    if not inrepeatedgroupheader then
    Ian

  • Cross Tab Question

    I am trying to add a cross tab to a report. The page set up is 8 1/2 X 11 - Portrait.
    My cross tab data is very wide and runs onto new pages. I would like to keep it together on one page.
    Is there a way to wrap the cross tab, or keep on one page?

    Travis,
    There is a way to wrap crosstabs.
    Do this:
    For the item you are placing as your crosstab column, create this formula called @Each Column:
    WhileReadingRecords;
    Global Numbervar ColumnNo := ColumnNo + 1
    Next, create another formula that you will use as your grouping for this column, call it @ColumnGrouping.
    EvaluateAfter ({@Each Column});
    Global Numbervar ColumnNo;
    Int((ColumnNo - 1)/6)
    Insert a group on formula @ColumnGrouping and place your crosstab in there.  In the example above, you will see it will wrap for every 6 columns.
    I hope this helps,
    Regards,
    Zack H.

  • Suppressing levels in cross tab.

    Hello All,
    I have a project requirenment for one of the client and currently using CR 2008 for creating dynamic reports based on a finance database for profitabilty Analysis. I have been using lot of Web-Elements functionality in my crystal application and its going good to an extent, the only issue i have been experiencing is the dynamic change of the cross tab data based on prompts.
    Its a 4 level application where in users are prompted to select a specific level outta the 4 levels, they can select either few or all. Now, the issue is, in my cross tab i have mentioned all the 4 levels in my row field and the data is displayed according to the users selection through prompts, it works fine. But however if user does not select level 3 or 4 or any one of them then the specific cross tab row is displayed empty. I have tried selecting the option suppress empty rows under customize tab but that doesnt seem to work.
    I want only those levels to be displayed which are selected by users and suppress the rest, the empty rows in cross tab looks kinda odd to see. I am unable to figure out the formula string for the same.
    Any help will be appreciated. Thank you

    Hi
    Cross tab is nothing but a tabular representation of data.
    It displays zero values only when there is no data for the combination of corresponding row and column.
    We can not suppress this however we can display some string like "No data for this" or something else as per requirement.
    For this, do the below:
    - Right click on the summary value field on the cross tab -> Format Field.
    - Under Common Tab, click on X-2 for Display string. This would open the formula editor.
    - Put the below formula there:
    if IsNull(summary database field) then "No data for here"
         else "" & currentfieldvalue;
    You can change the display string as per requirement.
    Hope this helps!!
    Regards
    Sourashree

  • How to add an image or static text in the header of EACH page of a cross-Tab report

    Post Author: rtutus
    CA Forum: General
    Hi, I use Crustal 11.0.
    I have a cross Tab. I display the items on the left column and the months horizontally, the items are grouped by category field. The values are the sum of quantities are displayed for each month. Like this:
                             Items         Jan       Feb       March .....................Total
    Category 1                       
                             Item11         val11     Val12      Val13                     Total values
                             Item12         val21     Val22      Val23                     Total values
                             Item13         val31     Val32      Val33                     Total values
    Category 2                       
                             Item21         val11     Val12      Val13                     Total values
                             Item22         val21     Val22      Val23                     Total values
                             Item23         val31     Val32      Val33                     Total values
    Category 3                       
                             Item31         val11     Val12      Val13                     Total values
                             Item32         val21     Val22      Val23                     Total values
                             Item33         val31     Val32      Val33                     Total values
    The problem, I want to add a page header for each page of the report.
    When Crystal reports first displays my cross-tab in the designer, CR displays the cross tab in the Report header section. I d like to add text or image for each page and not only at the begining of my Cross-Tab.
    If I just add an image or text at the top of the report designer, which is my report header, I get the image or text only on the begining of the 1st page of my report but never in the other following pages.
    If I try to work around the problem and move the cross Tab to a group section instead, and then put the Image in the group header, I get what I want, but the problem is that:
    The columns header: Jan, February....December are displayed for each group of my report and not only in the beginning of the report. I get something like this:
                             Items         Jan       Feb       March .....................Total
    Category 1                       
                             Item11         val11     Val12      Val13                     Total values
                             Item12         val21     Val22      Val23                     Total values
                             Item13         val31     Val32      Val33                     Total values
                             Items         Jan       Feb       March .....................Total
    Category 2                       
                             Item21         val11     Val12      Val13                     Total values
                             Item22         val21     Val22      Val23                     Total values
                             Item23         val31     Val32      Val33                     Total values
                             Items         Jan       Feb       March .....................Total
    Category 3                       
                             Item31         val11     Val12      Val13                     Total values
                             Item32         val21     Val22      Val23                     Total values
                             Item33         val31     Val32      Val33                     Total values
    You see the months get duplicated. Any way, my real need is to add an image or text in the header of EACH page of a cross-Tab report.
    Thanks a lot for your help.

    Hi Divya,
    you could do for example in the wdDoInit() of the view
    wdContext.currentContextElement().setPicture("picture.gif");
    Now you assign this context variable to the Tab using the Tab_header's imageSource-Property. When you click on its value column, you see a button with three dots on it. If you click on this button, you will get all context nodes and attributes for this View. Usable variables are clearly marked, you now choose the one named Picture or what ever name you prefer to use. But it must correspond to the one set in the wdDoInit.
    I think setting a picture (not necessarily for the tab-page) is done in one of the excellent tutorials. If you are a newcomer I strongly recommend doing some of the tutorials.  I have learned tremendously from them.
    Hope this helped
    Harald

Maybe you are looking for

  • Is possible to transfer ratings from a practically identical itunes library

    Hi I have recently transferred my library from my PC to a new mac. I tried to do this using back discs I had created in itunes but they appear to have corrupted. So I just copied everything across by a portable hard drive but the thought of rating 70

  • Sales order /billing

    Hello My sales order type is zmf , i want to dispatch the material from sales order  but it should not allow create commercial invoice i want to create only proforma invoice from it kindly guide how to do it . sales order/obd/proforma invoice. Kindly

  • Deleting applied archives from standby

    Hello Guys, We have oracle 10g rel 2 on hp-ux I feel this common question for dataguard implementation Just want to check best way of deleting archives automatically from standby database,i have 2 methods in mind as below 1)At os level shell script-f

  • Convert a date to string

    hi, I have a got a date d = Wed Nov 05 00:00:00 GMT 2008 i need to convert this into a string of the format MM/dd/yyyy.

  • CFLOOP In CFGRID

    I am populating the grid from a query that displays the perosn's name, date of attachment and attachment name, etc etc. I am offering the option to delete these attachments based on two criteria. 1. The session.role is the administrator role. 2. The