This post will be short and sweet. What data type should you use to represent currencies in C#? – Decimal
If you use double, you will end up with rounding errors on more precise numbers, and if you are writing applications that support multiple currencies, namely currencies that use very large numbers, such as the Indonesia Rupiah ($1 = 9,345.8 Indonesian Rupiahs) you will also get doubles represented in scientific notation when they reach very large values (think trillions).
In C# use Decimal
Now for SQL Server 2005/2008 I believe the best practice would be to use the money datatype if you are dealing exclusively with U.S. dollars, otherwise you should use decimal to get more precise values.
Hey there, I think you most likely are able to help me. I have a MSSQL .ldf and .mdf file which I have to restore. Any opinions on how to do this? Regards
You should be able to attach an MDF file Delorse. Have you tried Googling this? There should be plenty of detailed instructions out there. Good luck!