[thelist] Increment every value in table (MySQL)

Barry Woolgar barry at burnthebook.co.uk
Tue Jan 6 04:58:42 CST 2009


> I have a table with only numbers in it and I want to increase every value
by 35%.

Assuming MySQL:

UPDATE table SET `field` = `field` * 1.35;

Be sure to back up first, just in case my brain is also not functioning...
;)

Barry

-----Original Message-----
From: thelist-bounces at lists.evolt.org
[mailto:thelist-bounces at lists.evolt.org] On Behalf Of Chris Price
Sent: 06 January 2009 10:48
To: thelist at lists.evolt.org
Subject: [thelist] Increment every value in table (MySQL)

Hi

This must be really simple but my brain is not functioning.

I have a table with only numbers in it and I want to increase every 
value by 35%.

What would be the simplest query string?
-- 

Kind Regards


  Chris Price
  Choctaw

chris.price at choctaw.co.uk <mailto:chris.price at choctaw.co.uk>
www.choctaw.co.uk <http://www.choctaw.co.uk>

Tel. 01524 825 245
Mob. 0777 451 4488

Beauty is in the Eye of the Beholder while
Excellence is in the Hand of the Professional

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

 >> Sent on behalf of Choctaw Media Ltd <<

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Choctaw Media Limited is a company registered in
England and Wales with company number 04627649

Registered Office: Lonsdale Partners, Priory Close,
St Mary's Gate, Lancaster LA1 1XB . United Kingdom

-- 

* * Please support the community that supports you.  * *
http://evolt.org/help_support_evolt/

For unsubscribe and other options, including the Tip Harvester 
and archives of thelist go to: http://lists.evolt.org 
Workers of the Web, evolt ! 




More information about the thelist mailing list