Solution:INSERT INTO CUSTOMERS (ID, NAME, AGE, ADDRESS, SALARY)VALUES (1, 'Ramesh', 32, 'Ahmedabad', 2000),(2, 'Khilan', 25, 'Delhi', 1500),(3, 'kaushik', 23, 'Kota', 2000),(4, 'Chaitali', 25, 'Mumbai', 6500),(5, 'Hardik', 27, 'Bhopal', 8500),(6, 'Komal', 22, 'MP', 4500),(7, 'Muffy', 24, 'Indore', 10000);2. Based on the customer table given above update the salary to 20000 whose salary is less thanthat.Solution:UPDATE CUSTOMERS SET SALARY=20000 WHERE SALARY<20000;Based on the customer table given above Fetch ID,3. Name and Salary fields from the CUSTOMERS table for a customer with name Hardik.Solution:SELECT ID, NAME, SALARY FROM CUSTOMERS WHERE NAME='Hardik';
Comments