The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!
Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.
Have a better answer? Share it in a comment.
GetStringFromNumber(double
That is not the same data type as decimal(2, 2) as the error is saying. You could look at float or real (http://msdn.microsoft.com/en-us/library/ms173773.aspx), but if you need the more precise decimal you can just alter the function's signature.
Note: decimal(2, 2) will allow values .00 to .99. It means 2 digit decimal with both digits being after the period. Hopefully that is what you want.
Okay to fix the issue in the function, you can use the SqlDecimal type.
http://msdn.microsoft.com/en-us/library/ms131092.aspx
Note also it shows that you can use SqlDouble in your function and then that will equate to float in SQL Server.