Handling database calculations with a php page

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

3 tables hold money value but they are inputed into
the database without the dollar symbol (without $). 
So the value could be 3.00 etc...  

I want to calculate by adding (+) them together.  A
username is in each table.  So only the username
matching in each table must calculate.  So if in table
1 username Chris has 3.00 and in table 2 Chris has
5.00 we need to add the two together.

If you value equals 0 or NULL or blank it should
either a) ignore it or b) add it as a zero.

What is the best PHP code to use for this inside a PHP
code?

Thanks!

Find local movie times and trailers on Yahoo! Movies.
http://au.movies.yahoo.com

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux