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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Any way to display DECIMAL 20 field accurately? 1

Status
Not open for further replies.

mgallot

MIS
Jan 22, 2001
93
US
I'm looking for a solution to display a SQL Server Decimal 20 field. The number is correct in SQL Server but rounds when I try to display it in Crystal. Crystal ver is 9.2, SQL Server is 2000. At this point I've tried too many possible workarounds to list, and none have been the solution anyway. Has anyone been successful in displaying a decimal 20 field in Crystal?

SQL Server Data

31808077920473813
31808077920473806
31808077920473810

Crystal Browse Field Data

31808077920473800

All instances are displaying as 800 for the last 3 numbers
 
I never heard if you tried what Microsoft suggests, which is using a CAST or CONVERT.

Frankly I grew tired of the thread because you were fixated on trying hacks to get around it.

A CAST or CONVERT in a SQL Expression should provide what you need.

I had posted this, and then you were off trying to fix the data AFETR it was already incorrectly returned to Crystal, then you informed me that my solution wouldn't work because it's already returned by the database, which was wrong.

If you want help, respond to the suggestions offered.

-k

 
Oh my, you are a genius! I was actually trying all the suggestions but in formulas, not SQL Expressions, and they were always returning that same value. I was completely missing the SQL Expression suggestion. This solution worked. Fantastic job. Thanks.
 
<chuckling>

I'm the dumbest genius you'll ever meet, glad that it worked out.

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top