Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Format for year to display in grouping(SSRS) report Expand / Collapse
Author
Message
Posted Thursday, May 1, 2014 6:18 AM
SSC Journeyman

SSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC Journeyman

Group: General Forum Members
Last Login: Tuesday, October 28, 2014 3:46 PM
Points: 76, Visits: 156
Hello,
I have an SSRS report where I have a single dataset; I am using parameter as fiscal year.
only one parameter; My requirement was to create a ssrs report with fiscalyear group header.


suppose if I give parameter as 2011 it will display all the years data from 2011 to 2014 and its grouped on fiscal year(group header)

I created an ssrs report with group header my question is why I am facing error at fiscal year(I am not getting fiscal year : 2011) in group header; we have a column as FY_1 where its populating all the years..

I given the expression as -

="Fiscal Year : " + FORMAT(Fields!FY_1.Value,"yyyy")

when I display the report its getting Fiscal Year : yyyy

For the test case I just grouped with system name it working fine; only with fiscal year its not working.
Not sure why its not displaying. Any help..
Post #1566686
Posted Thursday, May 1, 2014 7:47 AM
SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Yesterday @ 9:59 PM
Points: 898, Visits: 5,708
Create a calculated column in your dataset for the year.

YEAR(SomeDate)

Then you should be able to group no problem.
Post #1566716
Posted Thursday, May 1, 2014 8:25 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Yesterday @ 6:26 AM
Points: 7,013, Visits: 7,179
"yyyy" formatting only works with date datatypes


Far away is close at hand in the images of elsewhere.

Anon.

Post #1566729
Posted Thursday, May 1, 2014 9:00 AM
SSC Journeyman

SSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC Journeyman

Group: General Forum Members
Last Login: Tuesday, October 28, 2014 3:46 PM
Points: 76, Visits: 156
Thank you for the reply, But its not working

I created a calculated field as Year and assigned FY_1 value field which is coming years from dataset


Some how not working showing as #Error when I preview the report.
Post #1566741
Posted Thursday, May 1, 2014 9:30 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Yesterday @ 6:26 AM
Points: 7,013, Visits: 7,179
If FY_1 is a year and assuming it is an int datatype then use the following expression

=String.Format("Fiscal Year : {0}",Fields!FY_1.Value)



Far away is close at hand in the images of elsewhere.

Anon.

Post #1566755
Posted Thursday, May 1, 2014 10:56 AM
SSC Journeyman

SSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC Journeyman

Group: General Forum Members
Last Login: Tuesday, October 28, 2014 3:46 PM
Points: 76, Visits: 156
Thank You So much..It got worked.
Post #1566790
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse