I have a stored procedure attached to a crystal report.
Is there a way to check the record count when the report is ran? In other words, I'd like to check if the record count = 0 if the stored procedure returned no records.
Yes, the lack of records displayed would be an indication that there no records. However, for the end user some kind of message to say so would be nice. Which leads me to the second part of your reply...
Recordcount > 0??? Seems to me that if it returns a count > than 0 then there are records.
RecordNumber will return a value of 1 even when no records are returned by the SP.
One way to accomplish this is to create a text object 'No records returned' and add a conditional suppression formula to test fagainst a filed which would always have data i.e.
Are you suggesting that in my stored procedure, if there are no records returned, I should insert a dummy record in my temp table and check against a field for a null value in Crystal Report?
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.