Novice Novice - 1 year ago 88
MySQL Question

How to convert values into Thousands in the Backend

I have a text box with an extension of thousands.

In the text box the user enters only "7" for 7000 and "10" for 10000 and "75" for 75000. The values of 7000, 10000 has to be stored in our database. How can we do this?

As of Initial step, I have created a normal database connection to store values in the database. My databse will store only values in the format of 7,10,75 as user entered but not of multiplication*1000

But I would like to store it in the form of thousands. Could you let me know how to code this in the database?


Raj Raj
Answer Source

Multiply it by 1000 while entering. eq

$sql="insert into database.table values($number)";
//query to database
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download