Tasks

You might also like

Download as xlsx, pdf, or txt
Download as xlsx, pdf, or txt
You are on page 1of 6

Basic SQL Tasks

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27

1
2
3
4
5
6
Basic Real-Time Tasks
1
2
3
4
5
6
7
8
9
DMaaS Project Requirements
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
Tasks
Basic SQL Tasks
create a structure table similar to existing table
create a duplicate copy of existing table including structure and data by name dup_existing_table ?
change the email column of employees table with 'not available' for those employees who belongs to the 'Accouning' department?
drop the column city from the table locations ?
insert 3 rows by a single insert statement ?
Is Truncate DDL or DML.Justify with example ?
Write a query to display any two columns with its alias names ?
Write a query to get the first three characters of first name of all employees ?
Write a query to find second highest salary from employee table ?
Write
Write a
a query
query to
to get unique
display the department ID fromlast_name)
name (first_name, employee table ?
and salary for all employees whose salary is not in the range 10,000 through
15,000 ?
Write a query to display the first_name of all employees who have both "a" and "c" in their first name ?
Write a query to display the last name of employees having 'e' as the third character ?
Write a query to get the highest, lowest, sum, and average salary of all employees ?
Write a query to get the difference between the highest and lowest salaries ?
Write a query to get the average salary for each job ID excluding any one role of employee?
Create a table with two primary keys?
Write
Write a
a query to displayto
SQL statement alldisplay
customers with
either a grade
those above
orders which100
are not issued on date 2012-09-10 and issued by the salesman whose ID is
5005 and below or those orders which purchase amount is 1000.00
Write a SQL statement to display salesman_id, name, city and commissionand below.
who gets the commission within the range more than 0.10%
and less than 0.12%
Write
Write a
a SQL
SQL statement
statement to
to find
find that customer
the highest with all amount
purchase information whose
ordered by name begin
the each with theon
customer letter 'B'.
a particular date with their ID, order date
and highest purchase amount.
Write a query to display distinct salesman and their cities.
Write a query to make a report of which salesman produce the largest and smallest orders on each date.
Write a query to create a view to getting a count of how many customers we have at each level of a grade.
Write
Write aa query to create a
SQL statement toview
makethat finds
a join onthe
thesalesman who hascustomer
tables salesman, the customer with theinhighest
and orders such a order of a the
form that day.same column of each table
will appear once and only the relational rows will come.
Advanced SQL Tasks
Write a trigger to insert or update a table when any insertion or updation operation is done on another table ?
Write a procedure to insert 1000 rows in a table ?
Write a PL/SQL block to avoid delete operation for a table ?
Write a procedure to update multiple rows at a time ?
Write
Write a
a trigger
trigger to
to update a tableinto
insert records whenever
a tableany
wheninsert
any operation is doneison another table ?
delete operation
performed on another table ?
Basic Real-Time Tasks
Write
Write a
a query
query to
to display
skip therange of the
nulls and salesthe
merge (High to low
result set or vice versa)

Write a query to remove duplicate records in the result set


Write a query to get the 2nd highest salary of the employee
How to get the middle row in the table
Write a query to trim the filename dynamically without using substring function
Write a query to replace the filename dynamically without using substring function
Write a query to get the cumulative sum of the salary for each employee
Write a query to get the 2nd least salary of the employee
DMaaS Project Requirements
create a procedure to archive the data older than 10 days
create a procedure to purge the data older than 10 days
Insert data from one table to another table from 2 different databases
Prepare a query to delete duplicate records in the table.
write a query to get the list of stores that are down for more than 48 hours
prepare a query to display the avg store health status for past 1 week
write a query to display the stores list which are not receiving any packages
write a query to show unhealthy stores count ( status = down,snmp listener error, n/w error)
write a query to display the file count for each dataflow at a time
write a query to get the list of stores that are down for more than 2 weeks
write a query to display the store deatils (ip address, store number, region, country_code) for the files in dmaas_file_transfer table
write a query to display the dmaas store migration count by market
write a query to display the dmaas store migration count by region
write a query to display the file transfer status which are success, failed, in_progress
Write a query to get the file transfer counts (Total files, success count, failed count, in_progress count)
Display the count of files transferred on every week

You might also like