sql assessment_info.docx census beuro

3
Standard Interview Questions SQL Skills Exercise 1: How many courses is each faculty is teaching? The query should also display faculty's that are not taking any courses. Exercise 1.1: odify the query to display only those faculties whose name starts with !. Exercise 1.": odify the query from Exercise 1 to show only those faculty#s teaching more than $ courses. Faculty Course det ail  %aculty ( )*+, -ourse ( )*+, %aculty&a me -ourse&am e  %aculty&(e pt -ourse&start  &dt  %aculty d Exercise ": /hat is the largest store in each city? STORE City Store Size (sqt !!!" 0altimore ! " 0 1$ 2il3er 2pring - $ ( 1" (- E " % "" 4 5 !ssump tion: T a6le ame 7 store

Upload: utagore58

Post on 17-Feb-2018

217 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: SQL Assessment_Info.docx Census Beuro

7/23/2019 SQL Assessment_Info.docx Census Beuro

http://slidepdf.com/reader/full/sql-assessmentinfodocx-census-beuro 1/3

Standard Interview Questions

SQL Skills

Exercise 1: How many courses is each faculty is teaching? The query should alsodisplay faculty's that are not taking any courses.

Exercise 1.1: odify the query to display only those faculties whose name startswith !.

Exercise 1.": odify the query from Exercise 1 to show only those faculty#s teachingmore than $ courses.

Faculty Course_det

ail

 

%aculty&( )*+, -ourse&( )*+,

%aculty&a

me

-ourse&am

e

 

%aculty&(e

pt

-ourse&start

 &dt

 

%aculty&d

Exercise ":

/hat is the largest store in each city?

STORE

City StoreSize (sqt!!!"

0altimore ! "

0 1$

2il3er 2pring - $

( 1"

(- E "% ""

4 5

!ssumption: Ta6le ame 7 store

Page 2: SQL Assessment_Info.docx Census Beuro

7/23/2019 SQL Assessment_Info.docx Census Beuro

http://slidepdf.com/reader/full/sql-assessmentinfodocx-census-beuro 2/3

Exercise 8:

/hat is the current status and turnaround time)time taken to close the ticket, for

each ser3ice ticket?

Q#

Exercise 1: *lease descri6e some of the standard test cases that you would writeto

test a %!-T ta6le.

(imension ta6les: !ll data is loaded initially and then incremental loads e3ery day

for new9updated records

%act ta6le: (ata loaded incrementally e3ery day

Exercise ": ets say we ha3e a source ta6le *erson and a target dimention ta6le

(im&*erson. (im&*erson is loaded on daily 6asis 3ia an ET tool.t#s a straight pull. ;ou are asked to 3alidate the (im&*erson and you <nd out that there are

discrepencies in the no: of records from source to target. /hat steps you would

take to <gure out where the discrepencies are.

Page 3: SQL Assessment_Info.docx Census Beuro

7/23/2019 SQL Assessment_Info.docx Census Beuro

http://slidepdf.com/reader/full/sql-assessmentinfodocx-census-beuro 3/3

Only current data in di$ensional ta%le&

we need to compare target data with source data= )no history is maintained, >minus query

select from persons

minus

select from dim&persons 7 rows

'istorical data in di$ensional ta%le&

1,we need to ha3e only one acti3e record for e3ery id in dim&persons",we need to ha3e acti3e record with end&date null in dim&persons

8,we need to make sure the existing record end&date and acti3e indicator is

updated= with new row#s help