none
How to union the 2 sharepoint columns from 2 dataset into single column in dataset using ssrs expression

    Question

  • For Example.

    I have 3 columns in SharePoint ex: ID,Email ID 1,Email ID 2

    ID   Email ID 1         Email ID 2      

    1,  xx@ msn.com , yy@live.com

    2, aa@ gmail.com , aa@live.com

    3, yy@ msn.com , ww@yahoo.com

    I have captured Email ID 1 in one Dataset1 and Email ID 2 in Dataset2,My required result is

    Email ID

    xx@ msn.com

    yy@live.com

    aa@ gmail.com

    aa@live.com

    yy@ msn.com

    ww@yahoo.com

    Any help is really appreciated.

    Thank you

    Sunday, October 06, 2013 7:11 AM

Answers

  • Hi Support,

    In this case, you can inserte a row under each detail row (Right-click the handle of the detail row>Insert Row>Inside Group-Below)

    Then use the expression below on the new inserted row.
    =Lookup(Fields!ID.Value,Fields!ID.Value,Fields!EmailID2.Value,"DataSet2")

    If you have any questions, please feel free to ask.

    Regards,


    Charlie Liao
    TechNet Community Support

    Tuesday, October 08, 2013 9:03 AM
    Moderator

All replies

  • Hi Support,

    From your description, you want to display the data from different dataset on one tablix, right?

    In Reporting Services, we can use lookup function to display data from different datasets on one tablix. In you scenario, it seem that the ID column exist on both dataset, in this case, we can use the expression below to display Email ID 2 on the dataset 1 tablix.
    =Fields!EmailID1.Value & VbCrlf & Lookup(Fields!ID.Value,Fields!ID.Value,Fields!EmailID2.Value,"DataSet2")

    If you have any questions, please feel free to ask.

    Regards,

     


    Charlie Liao
    TechNet Community Support

    Tuesday, October 08, 2013 7:15 AM
    Moderator
  • Hi Charles,

    It is not working as intended , now result displays as both data set first value in one row

    Email ID

     

    xx@ msn.com

    yy@live.com

     

     

     

     

     


    My Expecting result is like this 

    Email ID

     

    xx@gmail.com

     

    aa@ gmail.com

     

    yy@ msn.com

     

    ww@yahoo.com

     

    Thanks


    • Edited by SP Support Tuesday, October 08, 2013 7:56 AM Change Scrrens
    Tuesday, October 08, 2013 7:53 AM
  • Hi Support,

    In this case, you can inserte a row under each detail row (Right-click the handle of the detail row>Insert Row>Inside Group-Below)

    Then use the expression below on the new inserted row.
    =Lookup(Fields!ID.Value,Fields!ID.Value,Fields!EmailID2.Value,"DataSet2")

    If you have any questions, please feel free to ask.

    Regards,


    Charlie Liao
    TechNet Community Support

    Tuesday, October 08, 2013 9:03 AM
    Moderator