Jump to content

[SOLVED] SQL Table Problem.....


Verbat

Recommended Posts

I need 1 of the fields in the table to save numbers in it, and it includes all kind of numbers like 100, 0.22, 5.67 and so on.

Now when i sort this field it shows the 5.67 first then the 100 and then the 0.22.

 

I tryed to change the Type of the field to INT but then it removes everything after the . so it shows me 100, 0, 5.

 

How can i solve this?

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/86747-solved-sql-table-problem/
Share on other sites

i know i will get told off here but see if it works with varchar i know its not fir numbers.

No it doesnt work with Varchar but i fixed it :)

All you have to do is use DECIMAL for the Type and Change the Length/Values to 10,2 the number after the , means number of numbers after the . :)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.