SQL Update
SQL Update Example One
Select Thespian_Last_Name, Thespian_First_Name
From Thespian_Film_Table
where Film_Title = "Monty Python and the Holy Grail";
Balin, Michael Chapman, Graham Cleese, John Gilliam, Terry Idle, Eric Jones, Terry
Update Thespian_Film_Table
Set Thespian_Last_Name = "Palin"
where Thespian_First_Name = "Michael"
and Thespian_Last_Name = "Balin";
Select Thespian_Last_Name, Thespian_First_Name
From Thespian_Film_Table
where Film_Title = "Monty Python and the Holy Grail";
Chapman, Graham Cleese, John Gilliam, Terry Idle, Eric Jones, Terry Palin, Michael
| Sign In |
| to add your own comment |
| Comment by TheMadProfessor Rate this Comment |
The UPDATE Anonymous mentions should work if the following things are true:
|
| Comment by Anonymous Rate this Comment |
It might depend on your specific flavour of SQL, but the following worked for me with Derby/Cloudscape/JavaDB:
|
| Comment by TheMadProfessor Rate this Comment |
No way to do this that I'm aware of with SQL alone. This sort of thing is more conducive to solving with an actual programming language such as PL/SQL, Transact-SQL, Visual Basic, etc. The typical methodology would be via a cursor (a term for a temporary table populated by the result set of a SELECT and traversed one row at a time):
|
| Comment by archive Rate this Comment |
I am looking for some SQL help, I am tring to change information in a table to
|