Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
ramdas
Posting Yak Master
181 Posts |
Posted - 2002-10-03 : 15:52:48
|
| Hi,I am running the SELECT MAX(Account_balance) FROM Account_data queryand get a response of 999.96 which is wrong. I looked at the data in the table the value is much higher, what could be wrong with the statement.ByeRamdas NarayananSQL Server DBA |
|
|
Andraax
Aged Yak Warrior
790 Posts |
Posted - 2002-10-03 : 15:57:36
|
| What datatype is the column Account_balance? If it's a string datatype (varchar, nvarchar etc) the sorting is done literally. If it is float or numeric it sound very strange... /Andraax |
 |
|
|
ramdas
Posting Yak Master
181 Posts |
Posted - 2002-10-03 : 16:34:04
|
| Hi,Thanks, The datatype is varchar since it was imported from a .csv file.ByeRamdas NarayananSQL Server DBA |
 |
|
|
robvolk
Most Valuable Yak
15732 Posts |
Posted - 2002-10-03 : 16:39:36
|
| You can import CSV data as numeric or date values, as long as they can be implicitly converted. If you need the data treated as numeric then you should change the column to match the appropriate datatype (money, int, float, etc.) |
 |
|
|
|
|
|