Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL View not showing results in CR

Status
Not open for further replies.

johnhugh

Technical User
Mar 24, 2010
702
SG
Hi, The application I'm writing my report for runs on SQL Server 2005 and uses CR XI R2 runtime.
I have created below view and joined to another table in my report.

In my Crystal Editor (V10), the report works correct. But when runing it from my application the below view seems to be ignored.
If I do not join my view to another table it works as well, but as soon a I join them the view is being ignored, but only in XI R2.
Just wondering why XI R2 would have any issues with the below.

SQL:
SELECT     i.FMTITEMNO, i.ITEMNO, i.[DESC], STUFF
                          ((SELECT     ' | ' + rtrim(s.MANITEMNO)
                              FROM         ICIOTH AS s
                              WHERE     s.ITEMNO = i.ITEMNO FOR XML PATH(''), TYPE ).value('.', 'varchar(max)'), 1, 3, '') AS MANUFACTURERS_NUMBER, 
                      CASE WHEN i.INACTIVE = 0 THEN 'Active' ELSE 'Inactive' END AS STATUS
FROM         ICITEM AS i
WHERE     (i.STOCKITEM = 1)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top