No data on Crystal Report in C# VS2008

Hey guys,

I have been working on a crystal report for a couple of weeks now and have not been able to get data to appear.  I have a couple of table adapters that show data but when I attach them to a report and click on the browse data button it is blank for all items.  I have looked in google to no avail.  I am stumped!!!!!!!!  I have made other reports before and they were created fairly easily.  There must be a setting or something that has changed????

Any help would be greatly appreciated.

Jerry
JDL129Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

mlmccCommented:
Are you joining the adapters?

Are you filtering in the report?

mlmcc
0
JDL129Author Commented:
mlmcc!!!  Thanks for the post!!

This is the code in my adapter:

SELECT        tblRXNEW.CUSTKEY, tblRXNEW.RXNUM, tblRXNEW.RecordNum, tblCustomers.Fullname, tblRXNEW.DRUG, tblRXNEW.FACEQTY, tblRXNEW.Alpha, tblRXNew.CostPD, tblRXNew.Copay, tblRXNew.RetailPrice, tblRXNEW.PRINTED
FROM            tblCustomers INNER JOIN
                         tblRXNEW ON tblCustomers.CKEY = tblRXNEW.CUSTKEY
WHERE        (tblRXNEW.NH = 'Y') AND (tblRXNEW.PRINTED = '0')

Thanks again,
Jerry
0
mlmccCommented:
So there is only 1 data adapter for the report?

DOes the report have a filter?

Is there saved data in the report?
When you run if you click REFRESH do you get data?

mlmcc
0
CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

JDL129Author Commented:
Only 1 data adapter.
Report doesn't have a filter.
As far as I know it doesn't have saved data.  I have tried to find a way to implement 'discardsaveddata' but have been unsuccessful.
I ran it and clicked refresh and still only had the header information.

Normally when I created a report (its probably been a year or so and with a previous version of VS)  I could open the report in design view and click the tabs at the bottom to display a version that would show the data and it would ask me to log in.  This one doesn't.  Is there some setting in here that would make the report log into the database?

Thanks for the post!!!

Jerry
0
mlmccCommented:
I have not built reports that way so I don't know if there are options to use.

mlmcc
0
JDL129Author Commented:
How would you build the reports?

Jerry
0
mlmccCommented:
I have only used the full versions so I don't build them in VS.  That is one of the ways to build them in VS.  There apparently is a change in the latest version.


Here is a method that works passing the recordset to the report rather than attaching table adapters

http://www.emoreau.com/Entries/Articles/2006/09/Feeding-Crystal-Reports-from-your-application.aspx

mlmcc
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
James0628Commented:
I've only run reports from CR, so I can't help with the VS aspect, but to just throw a couple of basic ideas out there ...

 I take it that the query works outside of CR?

 You could try it without the Where, just to see if anything changes.

 And if that doesn't work, you could try removing the Inner Join, and remove the tblRXNEW columns from the Select, and see if you get any data from that.

 James
0
JDL129Author Commented:
Thanks guys!!!  I'm up and running!!!
0
James0628Commented:
I'm curious (and the answer might help someone else) ...

 What was the solution?  Did you find a problem with your query, or change your app to feed a dataset to the report, or was it something else?

 James
0
JDL129Author Commented:
James,

I never could make it work from a table adapter inside C# so I created a stored procedure in sqlServer and it worked right off the bat.  I could see the data in the adapter but when I tried to browse to the data in CR it was blank.  Ya'll's suggestions made me do a little more searching and I found that all my other Crystal Reports were fed with stored procedures.

Thanks a bunch for the help!!

Jerry
0
James0628Commented:
OK.  Thanks for letting us know.  Like I said, that information may help someone else.

 James
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
C#

From novice to tech pro — start learning today.