Hi all,


Is it possible in mysql 3.23 to update a row and revert a column back to its default value. Not the default value for the type, but the value defined as the column default.


for example a column is defined as :
picture_name VARCHAR(25) NOT NULL DEFAULT 'no_photo.gif'
if someone removes their picture, I want the value to revert back to 'no_photo.gif'. However, as the default value changes across installations of our application, I can't explicitly set the column:
UPDATE pictures SET picture_name='no_photo.gif'; <-- can't do this
I need to do something like:
UPDATE pictures SET picture_name=DEFAULT; <-- don't think this is possible
or:
UPDATE pictures SET picture_NAME=NULL; <-- ideally mysql would revert to 'no_photo.gif', but it uses the type default of an empty string


Is this possible?

thanks,
-jk


-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to