RSS

Concatenate Two String Fields and Static Text-SSRS

13 May

This is my first SQL Server Reporting Services(SSRS) Report I have customized in Dynamics Ax.this report already contains 5  Data Sets in existing report and my requirement is given below:

Excise Charged at Notified rate of duty as per S.No 1 Notification No 34987/DL/CY dated the 04/01/2007

Excise Charged at Notified rate of duty as per S.No 2 Notification No 78987/DL/RT date the  06/02/2007

Excise Charged at Notified rate of duty as per S.No 3 Notification No 94587/DL/DK dated the 07/07/2007

As per requirement I have to display the static content with table fields.So I created a new table with Three fields  are Notification Serial Number,Notification Number and Notification Date and written get and set method in existing RDP class.

How to concatenate static text and table field:

At the beginning of expression I will put static text and I will concatenate it with empty space using + ” ” the trick is to use + and if we use hard coded string we need to enlose it using double quotes ” “. Next I will put + to concatenate my empty space with Notification Serial  Number field.See below final expression.

= “Excise Charged at Notified rate of duty as per S.No”+” “+Fields!NotificationSerialNumber.Value+” “+”Notification No
Concatinate Static Text and table field

 

this will display the result like this

Excise Charged at Notified rate of duty as per S.No 1 Notification No

NOTE: If you will try to add second table field in this using +” “+ it will display junk data on the  report.so to achieve follow below expression :

= “Excise Charged at Notified rate of duty as per S.No”+” “+Fields!NotificationSerialNumber.Value+” “+”Notification No” & ” ” & Fields!NotificationNumber.Value+” “+”dated the” &” “& Fields!NotificationDate.Value

Now it will display the report like this

Excise Charged at Notified rate of duty as per S.No 1 Notification No 34987/DL/CY Notification Date 04/01/2007

Excise Charged at Notified rate of duty as per S.No 2 Notification No 78987/DL/RT Notification Date 06/02/2007

Excise Charged at Notified rate of duty as per S.No 3 Notification No 94587/DL/DK Notification Date 07/07/2007

Advertisements
 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: