Hello everyone .
I am going to have interview next week on SQL .I have search material for interview preparation but do not get satisfactory material.I tried with hacker rank and there i was unable to solve many problem .I feel quite unsatisfied with it and in trap of brainstorming that am i prepare for that ?Friends please suggest .
Hello everyone .
What level of SQL are you at and wanting to learn/practice? You can use tools such as https://sqlzoo.net in order to practice the basics.
Is it a SQL developer/dba position you are looking at, if so there will be probably be more detailed question. Otherwise knowing the basic data types, joins and structure of a SQL query and which order it is processed in should set you in good stead. Let me know if you have any more specific questions.
Make sure you understand Group By and Having concepts, they are often used to try and catch interviewees out but don’t worry about not being an expert. Make sure you give it your best and if you get any questions wrong, take the time in the interview to ask how you performed and if you got any questions incorrect ask the interviewer to explain what they would do. It shows that you are keen to learn and improve your skills. A lot of the time employers want to hire for passion and potential rather than current skill level, anyone can be taught, what’s exciting is finding someone that wants to learn.
Two years ago I applied for an SQL Data Analyst position. I had a general phone interview and then they brought me into their office for an in-person interview. When I arrived, they took me into a room and gave me one piece of paper (seen below) and another one with the following information and 4 questions. They gave me a laptop with the same 4 questions on it and then told me to type out the correct SQL code below each question. I had 45 minutes to answer the questions. When I thought I had them all correct, I was to tell them “I am finished”. After I finished, they reviewed the answers and told me if I got them correct. I asked for a copy of the data and the questions, and they let me keep them.
See if you can only spend 45 minutes to answer the questions. I was not allowed internet access, so Stack Overflow was not possible. Feel free to post your answers here on the forum or any questions/clarifications you may have regarding the questions.
(note: this is just a sample of some records within each table. assume each table has thousands of records)
Get the names of all salespeople and the total sales revenue they have made. For users who did not make any sales, please display this as 0.
Get the names of all salespeople with total order amounts above $700
Get the names of all the salespeople who have made a sale to someone within industry B
Which date did each salesperson make their highest sale and what was the amount? Result should be salesperson, date, amount.
Hi thanks for writing .The link which you have send its very beneficial .I do not know which level of questions they will asked but i think its a start of my career so they must keep it basics .But the material which you have send consists of easy to medium level .Don’t you think so? I’m supposed to prepare for data mapping questions too .Do you know any resource on it ?
Hi Thank you very much , i will do these questions when i am finish with my preparation .I’will let you know about it .
Help Please: My first technical Interview
Great questions to practice on, thanks for posting @rmdawson71
Do this guide do not have answer keys.I get stuck at some questions but unable to find answers for them .
I haven’t checked out SQLZoo myself, but I heard good things about it. Online review for example.
Good luck @M-Areeb ! Be strong!
I’ve set up a postgres 9.6 sqlfiddle for people to try their solutions to these sql questions
postgres 9.6 reference is here
Thanks for taking the time to set this up. It would have been nice to have access to the data this way in my interview. I was expected to write out my sql statements without testing them first.