Can we achieve this in Report RDL

  • I have a requirement where i need to concatenate values of multiple rows into single comma seperated field based on a common field in the same data set...Not sure if i made it clear ...

    2345 payoff s

    2345 loan s

    2345 Mortgage c

    2345 Title c

    I get something like this in my dataset from an oracle package which i dont have access to change....

    I need

    2345 Payoff,loan s

    2345 Mortgage,Title c

    in my report in a single row ... i could do it in storeprocedure but i dont have access to modify, all i can do is get the dataset as it is so i have to do this in RDL ...Can we do this .. any help would be great!!

    Thanks,

    Raj

  • Hi,

    If you would like to concatenate few fields, follow this process:

    Right click anywhere on the report area / canvas. Select Insert and then select Table (you can use textbox aswell).

    Click the table top left corner so it selects the table, now under properties (of this table), Select your table name under DataSetName property.

    Now right click on the first cell of the table and select Expression. Expression popup menu shows up.

    Under the "Set expression for: Value" section type the following formula to concatenate.

    =Fields!<YourFieldName1>.Value & " " & Fields!<YourFieldName2>.Value & "," & Fields!<YourFieldName3>.Value & " " & Fields!<YourFieldName4>.Value

    Now you can delete the rest of the cells & columns if they are not required.

    Hope this helps.

    regards

    Natraj

  • You exemple is great to concatenate different columns of the same row.

    What the OP wants is to contatenate the same column over multiple rows, grouped by the id.

    That is what my link does. Requires the use of code.

  • Thanks for the link.It worked !!!

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply