Jump to content

[SOLVED] MySQL subtract Add to table columns for one value


$username

Recommended Posts

Hello All,

    So I have 2 Columns in my table Total and Paid

 

I want to subbtract them so that it will tell me the total. These will have more then one value in the rows

 

Total    Paid

100        50

200        25

300        10

-------------

600    -  85  =  515

 

Is there a mysql way or a PHP way of doing this?

 

Thanks

Brett

 

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.