Updating salary for different departments using cursor


25-Sep-2019 23:54

For information on the use of PL/SQL records with SQL to update and insert data, see "Inserting PL/SQL Records into the Database" and "Updating the Database with PL/SQL Record Values".

For additional information on assigning values to PL/SQL variables, see "Assigning a SQL Query Result to a PL/SQL Variable".

In addition to static SQL discussed in this chapter, PL/SQL also supports dynamic SQL, which enables you to execute SQL data definition, data control, and session control statements dynamically.

Previous post we have explained detailed about different types of cursors.

At the end of a transaction that makes database changes, Oracle makes all the changes permanent or undoes them all.

If your program fails in the middle of a transaction, Oracle detects the error and rolls back the transaction, restoring the database to its former state. However, there are limitations on the use of pseudocolumns, including the restriction on the use of some pseudocolumns in assignments or conditional tests.

You might use sequence numbers to give each row a unique identifier, and refer to those identifiers from other rows to set up parent-child relationships. PL/SQL declares a cursor implicitly for all SQL data manipulation statements, including queries that return only one row.

If you want precise control over query processing, you can declare an explicit cursor in the declarative part of any PL/SQL block, subprogram, or package.

( Note:- Only 3 departments has employees, so total 6 employees shown in the output ) When writing nested cursor make sure 1.



If you're tired of trying to meet Paris Texas women at bars and clubs, it's time to join the thousands of Paris Texas singles who are already online making dates and finding love in Paris Texas.… continue reading »


Read more

Your reliance and use of the site's information and services provided, is therefore available at your own risk, and is your responsibility, in its entirety.… continue reading »


Read more

We partner with third party advertisers, who may use tracking technologies to collect information about your activity on sites and applications across devices, both on our sites and across the Internet.… continue reading »


Read more

In order to use this service , you must verify your age ( only for persons older than 18 years).… continue reading »


Read more

Our chats allow responsible sharing of pictures and videos. Even adults should take care when giving out information in chatrooms.… continue reading »


Read more

I was recently scammed by a STEVEN **, whom I fell in love with for over 10 months, he took all my savings and loans, lost my house and car in the process, he keeps asking for more money to come see me and things from where he is keeps coming up, claimed to live in OK and Michigan and went to both addresses.… continue reading »


Read more

Step1: Create a profile in one minutes,add photos and describe your ideal partner.… continue reading »


Read more

If you want to meet a hot granny available for webcam sex shows, visit granny free cams live 24/7.… continue reading »


Read more