Can you find the 5th error in this SQL Query? Please let us know in comments below!
@kristyowens22842 ай бұрын
amazing - still looking for the 5th error :D
@crickmoments37322 ай бұрын
Great video really liked it, please make more videos like this.
@LearnatKnowstar2 ай бұрын
Thank You. We will.
@whitecrowuk5752 ай бұрын
1. salary/12.0 - or convert both to decimal/float - otherwise it will discard decimal places 2. Total rate - need to cast as numerical type like decimal or integer first otherwise you’re concatenating strings 3. Case - second check needs to come first otherwise first will return true on first one meaning second condition would never happen. 4. DeptID condition needs to be with left join as we return dept name only if it’s 1-3 not filter out all records when this happens 5.Manager_ID 5 not 3 also null handling would be nice since we can see it occurs there and if we want to treat it as 5 then something like isnull(Manager_id,0) 5 would do the job (just mind you lose sargability that is index on that column would not be used leading to possibly poorer query performance). Ps realized this is not quiz and you provide the answers- good morning 😅