Using the Update command but does not update the column in the table

Asked

Viewed 34 times

0

I used the following command :

update cliente set telefone = '969843225' where nome = 'João da silva';

Afterward:

select * from cliente;

Did not update the record.

Image of the records: inserir a descrição da imagem aqui

  • When you do the select * from cliente where nome = 'João da silva' returns the correct record?

  • not just set the changes

  • Rectifying it back Empty

  • So that’s the problem

  • but as if in the figure I have given phone 333-5648

  • You are missing the identification column in your table (ID) or customer code. When you put this column you can update by this column and not by name...

  • but , as it is a demonstration class the update should act . funny functional in the online udmy here nothing rs

  • If select with Where does not work with its name update will not work either.

  • Put the ID and update by the ID, see:http://sqlfiddle.com/#! 9/30636e/1

  • thanks truth. I just could not understand the reason . because in the course he makes good here needs the ID

Show 5 more comments
No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.