Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8594

Re: how to insert an non exist current year( monthly) columns in the cross tab XIR2

$
0
0

There is no way to do this without having the month/year data available for the missing months.  I usually use a calendar table in my database for this reason.

 

However, since you can't make changes to your database, you could potentially add this data to an Excel spreadsheet and use that data to provide the missing values.  For example, you would have something like the following rows in your spreadsheet:

 

StartDate     EndDate

1/1/2014      1/31/2014

2/1/2014      2/28/2014

...

12/1/2014     12/31/2014

 

Don't link the spreadsheet to your data - Crystal will throw a warning that this is generally not supported, but you can ignore the warning.  Then, in the Select Expert, edit the selection formula and add something like this:

 

(

IsNull({MyTable.DateField}) or

( {MyTable.DateField} in {ExcelTable.StartDate} to {ExcelTable.EndDate})

)

 

 

Note where I've put the parentheses - because of the "or" this won't work with any additional selection criteria without them.

 

 

Now, change the date in your CrossTab to be the StartDate field from the Excel file.

 

 

-Dell


Viewing all articles
Browse latest Browse all 8594

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>