Oracle UPDATE Question -


Can the update described below be completed in an UPDATE statement?

By entering on the code> users.name = operators.op_name the operator.name_id value with the Users.name_id value. Both Users.name and operators.op_name have a unique .

I know that the situation described below is not the "best practice" to follow, but this is a very simple example of what I am trying to do: i.e. value from any other included table Along with updating a field. Table: User user_id name - -------------- 34 Billy 43 Jimi 50 Table: Operators (before update) op_id op_id user_id ------------- ------- ----- 12 Billy 35 35 Jimmy 46 33 99 table: operators (after update) op_id op_name name_id ------------------

  updated operators SET user_id = (Select U.USUR_ID user U ou ou.op_name = U.N.M.) Where in OOP_Name (from selection name user)  

in Oracle 10 G , more efficient:

  Users in the operator are using U (Uyaman) = O.O.P.name) when updated, user_id = U.UG_ID  

Comments

Popular posts from this blog

oracle - The fastest way to check if some records in a database table? -

php - multilevel menu with multilevel array -

jQuery UI: Datepicker month format -