How do you update a table from another table in Oracle?

Asked by Last Modified  

Follow 2
Answer

Please enter your answer

"Rajesh Kumar N: Guiding Young Minds from 1 to 12 with Expertise and Care"

Use UPDATE ... SET ... (SELECT ...) or MERGE: Example using UPDATE with JOIN: UPDATE target t SET t.column1 = (SELECT s.column1 FROM source s WHERE s.id = t.id) WHERE EXISTS (SELECT 1 FROM source s WHERE s.id = t.id); Example using MERGE: MERGE INTO target t USING source s ON...
read more
Use UPDATE ... SET ... (SELECT ...) or MERGE: Example using UPDATE with JOIN: UPDATE target t SET t.column1 = (SELECT s.column1 FROM source s WHERE s.id = t.id) WHERE EXISTS (SELECT 1 FROM source s WHERE s.id = t.id); Example using MERGE: MERGE INTO target t USING source s ON (t.id = s.id) WHEN MATCHED THEN UPDATE SET t.column1 = s.column1; read less
Comments

I am a tutor since last 1 year

To update a table from another table in Oracle, you can use the UPDATE statement with a JOIN clause or a MERGE statement. The JOIN approach is suitable for simple updates, while the MERGE statement provides more control and flexibility, especially for handling insert, update, and delete operations.
read more
To update a table from another table in Oracle, you can use the UPDATE statement with a JOIN clause or a MERGE statement. The JOIN approach is suitable for simple updates, while the MERGE statement provides more control and flexibility, especially for handling insert, update, and delete operations. read less
Comments

C language Faculty (online Classes )

UPDATE tableA SET tableA. someColumn = tableB. otherColumn FROM tableA INNER JOIN tableB ON tableA.
Comments

View 1 more Answers

Related Questions

Hi what is the Normalization? and the types?
Normalization is the process of efficiently organizing data in a database. There are two goals of the normalization process: eliminating redundant data (for example, storing the same data in more than...
Anant
What is the value of obtaining the PeopleSoft certification?
Oracle certification always increases the Job opertunity with 25 to 30% salary hike.......
Sudharsan
0 0
5
How useful is oracle database ?
Any organisation needs a place to store all kind of information they interact with on daily basis whether it be customer data ..sales data or say your Facebook posts..it is paramount to have these information...
Afshiya
Do ORACLE/PLSQL is having scope in IT industry ? is it use full for a IT career?
Its depend in your choice. But MS SQL more prefer compare to Oracle.
Krishna

Now ask question in any of the 1000+ Categories, and get Answers from Tutors and Trainers on UrbanPro.com

Ask a Question

Related Lessons


Common mistake even experienced programmers make in Plsql.
Hope, you are aware of Procedures in Plsql. Let us discuss one simple thing which we should always remember while writing the datatype of a parameter for a procedure or a function. Eg: Create or replace...

Oracle Architecture - Introduction
As a Oracle developer or a DBA, you should know the in & out of it’s Architecture. Let’s keep it simple first and explore later. Oracle is a software or a program, so like any other program,...

How To Create The Java Souce In Oracle PLSQL?
Requirement: How to find the list of files in specified directory? Step1 : First find the JDK Install or not in the oracle, to find jdk version please run the below sql. SELECT dbms_java.get_ojvm_property(PROPSTRING=>'java.version')...

Recommended Articles

Database Administration is the process building, organizing and maintaining custom databases for meeting the specific data requirements of an organization. A Database Administrator (DBA) is the person in charge of all the procedures involved in database development, organization, retrieval and security. A DBA has to understand...

Read full article >

Almost all of us, inside the pocket, bag or on the table have a mobile phone, out of which 90% of us have a smartphone. The technology is advancing rapidly. When it comes to mobile phones, people today want much more than just making phone calls and playing games on the go. People now want instant access to all their business...

Read full article >

Software Development has been one of the most popular career trends since years. The reason behind this is the fact that software are being used almost everywhere today.  In all of our lives, from the morning’s alarm clock to the coffee maker, car, mobile phone, computer, ATM and in almost everything we use in our daily...

Read full article >

Information technology consultancy or Information technology consulting is a specialized field in which one can set their focus on providing advisory services to business firms on finding ways to use innovations in information technology to further their business and meet the objectives of the business. Not only does...

Read full article >

Looking for Oracle Training ?

Learn from the Best Tutors on UrbanPro

Are you a Tutor or Training Institute?

Join UrbanPro Today to find students near you