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!

Trouble pulling in a 3 decimal position field via a stored procedure

Status
Not open for further replies.

wevans8827

Programmer
Jun 12, 2003
2
US
I’m hoping that someone else has encountered this issue before and has a simple solution.

I’m using a stored procedure to bring in data to my report. That works correctly, but one field I have defined in my stored procedure as being a numeric(8,3). When I run the stored procedure by itself it correctly pulls the data in with 3 decimal positions.

When I run the stored procedure via crystal I only get a rounded 2 decimal position value. Has anyone else experienced this before? All of my other numeric fields (with 2 decimal positions) are fine. I just can’t get this database field with 3 decimal positions to work correctly.

Thanks!
 
Hi, Have you checked the format of that field..Instead of using Default formats, try explicitly setting it to the one you want.

[profile]
 
I solved it. I was building a temp table in my stored procedure and had defined my problem field as a numeric(5,3).

I simply changed the definition to a char(9) and Crystal correctly brought in all 3 decimal positions to the report.

Thanks for you help.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top