Click here to Skip to main content
Sign Up to vote bad
good
See more: SQLconversion
Set FormattedValue = CASE 
                         When rg.ReferredFieldType = 'NUM' Then              
                              CAST(#PointedMslValues.Value AS         
                              NUMERIC(18,cAST(rg.ReferredDecimalPoints) )
 
                     --more cases...
END
I am generating a dynamic query, which is giving error.
Actually it requires integer value, while casting not a column name.
Posted 6 Feb '13 - 19:35
Ali_1001.1K
Edited 6 Feb '13 - 20:07
Tadit Dash22.4K

Comments
Ankur\m/ - 7 Feb '13 - 3:54
The query seems wrong. The first CAST method should end after NUMERIC.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Your Filters
Interested
Ignored
     
0 Mohammed Hameed 268
1 OriginalGriff 261
2 Sergey Alexandrovich Kryukov 188
3 Mayur_Panchal 153
4 Santhosh G_ 108
0 Sergey Alexandrovich Kryukov 8,216
1 OriginalGriff 6,271
2 CPallini 3,528
3 Rohan Leuva 2,703
4 Maciej Los 2,234


Advertise | Privacy | Mobile
Web04 | 2.6.130516.1 | Last Updated 7 Feb 2013
Copyright © CodeProject, 1999-2013
All Rights Reserved. Terms of Use
Layout: fixed | fluid