I have a Report that is pulling in SharePoint list data and displaying it in a PDF.
The data source for the report is grabbing the xml results from the sharepoint service using the CAML query below.
The CAML query for lookup fields returns ID#Description (13#Washington). The issue we are having is that from BIDS and the DBServer/Reports the field is displaying fine. When calling SSRS programmicatlly the field is returning ID# and is missing the description.
Any idea why it not returning all the data for the field through the web service while it works fine in BIDS and the Reports website. This issue happens for all lookup fields.
CAML Query
<Query><Method Namespace="http://schemas.microsoft.com/sharepoint/soap/" Name="GetListItems"><Parameters><Parameter Name="listName"><DefaultValue>{listguid}</DefaultValue></Parameter><Parameter Name="viewName"><DefaultValue>{viewguid}</DefaultValue></Parameter></Parameters></Method><ElementPath IgnoreNamespaces="True"> GetListItemsResponse/GetListItemsResult/listitems/data/row{@ows_ID,@ows_Creation_x0020_Date,@ows_Department}</ElementPath><SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetListItems</SoapAction></Query>
Code that calls report that doesn't work.
Dim reportLocation As String = "/Reports/TestReport" Dim format As String = "PDF" Dim result() As Byte Dim params As New List(Of SQLRS.ParameterValue) Dim par As New SQLRS.ParameterValue par.Name = "CustomerID" par.Value = Request.QueryString("CustomerID") params.Add(par) Dim creds As New System.Net.NetworkCredential creds.Domain = ConfigurationManager.AppSettings("SSRSAccountDomain") creds.Password = ConfigurationManager.AppSettings("SSRSAccountPass") creds.UserName = ConfigurationManager.AppSettings("SSRSAccountName") Dim ws As New SQLRS.ReportingService ws.Credentials = System.Net.CredentialCache.DefaultCredentials result = ws.Render(reportLocation, format, Nothing, Nothing, params.ToArray, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing) Response.Clear() Response.Buffer = True Response.ContentType = "application/pdf" Response.BinaryWrite(result) Response.End()