I have a table with various fields 2 of which contain a number between 1 and 50.
I need help setting up a script that will automatically take two set fields add them and insert the total into a third field for each indivdual record for all records in the table.
I'm stuck in creating this because some records will have 0 or NULL values.
Please help :)
I've think I may be able to do this purely in SQL but the closest i found was this:
Alter table Mytable add column Keywords varchar(255);
update Mytable set Keywords = concat(Categories, ' ', Tags);
Obviously I would not need to add the column etc. Either a PHP or SQL solution would be fantastic.
Example in case I'mm not explaining this well it's confusing me a lot
Column 1 - Field Value: 20
Colum 2 - Field Value 20
Add Colum 1 + Colum 2 = 40
Insert 40 into Colum 3
Thanks