1

I'm try to update some coloumn's cell in mysql.

when i execute this , value as number:

update tablename set contents=1 where contensid=218;

it is working.

but i execute value as a character:

update tablename set contents=text where contensid=218;

Please try again later or contact an Administrator. (1054)Unknown column 'text' in 'field list'

what i have to do update value as character ??

JacKy
  • 23
  • 1
  • 3
  • 8

2 Answers2

5

If you don't put your "text" inside '', query thinks it is a column in your table. So do this:

update tablename set contents='text' where contensid=218;
AliBZ
  • 4,039
  • 12
  • 45
  • 67
-1

Maybe your column is wrong,You will need check the column,and again comit.

john
  • 1