Live data from Hacker News

Our SQL interview questions

jitbit.com

51–60 of 227 posts

Re: Our SQL interview questions

#51

I'm not a SQL Developer, but anytime I get questions for which Google has answers to be found in 5 minutes or less, I'm quite hesitant to work there. I respect interviews that go along the lines of: "What would you do if..." after giving a detailed description of their environment. But then again I'm a tools/OSes admin, so maybe it makes more sense for my job description. But anytime guys are too focused on third opt…

3rd paragraph of article: "Some people might say it is too basic, but that's not the point. The test's job is not to tell genius and rockstars from "normal" devs. The purpose is to save you time and quickly filter out DB-experienced guys from the ones that just claim to be."

Rockstar questions would start with window functions.

(Not it!)

Re: Our SQL interview questions

#52

I'm not a SQL Developer, but anytime I get questions for which Google has answers to be found in 5 minutes or less, I'm quite hesitant to work there. I respect interviews that go along the lines of: "What would you do if..." after giving a detailed description of their environment. But then again I'm a tools/OSes admin, so maybe it makes more sense for my job description. But anytime guys are too focused on third opt…

An interview is a conversation, which is a very high bandwidth medium of information exchange. But in order to get to the level of conversation, both parties need to be speaking the same language. What this test establishes is the baseline level of common language that makes it even possible to have a conversation about SQL databases. Someone who can't handle these sorts of questions is not someone I can usefully have a conversation about SQL with. I can teach them, and sometimes it's useful to have a pedagogical sort of interview; but for a standard, "can you do this job" interview, no, I need to be able to establish a baseline level of common understanding.

Re: Our SQL interview questions

#53

I'm not a SQL Developer, but anytime I get questions for which Google has answers to be found in 5 minutes or less, I'm quite hesitant to work there. I respect interviews that go along the lines of: "What would you do if..." after giving a detailed description of their environment. But then again I'm a tools/OSes admin, so maybe it makes more sense for my job description. But anytime guys are too focused on third opt…

I don't run a school. Anytime a web-developer does not know basic sql or other basic knowledge, I refuse to pay salary, and even deduct the 1$ per minute. That five minutes just cost you $10

Bet you have one happy bunch of motivated developers working for you... that's an 'interesting' management style.

Re: Our SQL interview questions

#54
post #48

Earlier quoted context omitted.

In a business setting, the conceptual/relational, logical and physical design of a database happens far less often than querying such databases. Indeed, one of the reasons normalisation is such a Big Deal to relational bigots like me is that it makes SQL's querying tools much more useful and versatile.

True story, but such questions are just senseless. If someone knows about set-theory and the ideas behind query-languages, knowing SQL isn't a deal breaker, it's just a nice to have.

Folk generally don't study relational algebra, on its own, for fun.

Re: Our SQL interview questions

#55

"List employees (names) who have a bigger salary than their boss" SELECT e1.Name FROM Employees e1 LEFT OUTER JOIN Employees e2 ON (e1.BossID = e2.EmployeeID) WHERE e1.Salary > e2.Salary "List departments that have less than 3 people in it" SELECT d.Name, COUNT(e.EmployeeID) FROM Department d LEFT OUTER JOIN Employees e ON (d.DepartmentID = e.DepartmentID) GROUP BY d.Name HAVING COUNT(e.EmployeeID) "List all departme…

> people often do an "inner join" leaving out empty departments Empty departments have less than 3 people

correct. Edited.

Re: Our SQL interview questions

#56
post #24

Earlier quoted context omitted.

I made the tables quick to go through them. It could do with more data really but its got a few rows. https://gist.github.com/abkr/5662615

I had the same idea, but in an SQL Fiddle http://sqlfiddle.com/#!1/778bb/5

Didn't even know that there was such a thing as SQL Fiddle. That's going to come in handy, beyond this quiz, thanks.

Re: Our SQL interview questions

#57
post #27

Which book would you recommend for learning this stuff? I'm not very interested in 800-p. gorillas; there surely must be something short, not too theoretical, and to the point.

I enjoyed SQL Antipatterns by Bill Karwin. Very easy to read and offers some practical approaches to common issues.

Re: Our SQL interview questions

#58
post #34

Earlier quoted context omitted.

Careful using that terminology. You'll get false negatives on people who still think in terms of *= syntax, and will tell you that the words "left", "outer", and "join" are all redundant and probably don't belong in SQL in the first place. I used to be one of those guys, but I'm much less grumpy about it these days so I'd still pass your test. I have a sad suspicion that I'm on the progressive end of the spectrum whe…

Yep, I've done a lot of PL/SQL programming, and we've always used (+)= syntax and joins with all the tables after commas and all the joining conditions after WHERE. Now I work on different project and we use join syntax, but I could easily imagine people that do joins all day, and not know JOIN .. ON .. syntax.

I came to Oracle after it adopted the ANSI syntax, so that's what I use. So my experience is the opposite of yours -- when I see the (+) I need to look up the syntax to remember if it's left or right outer.

Re: Our SQL interview questions

#60

I'm not a SQL Developer, but anytime I get questions for which Google has answers to be found in 5 minutes or less, I'm quite hesitant to work there. I respect interviews that go along the lines of: "What would you do if..." after giving a detailed description of their environment. But then again I'm a tools/OSes admin, so maybe it makes more sense for my job description. But anytime guys are too focused on third opt…

Keep in mind that most of the time there are different solutions for a problem. They all finish the job but some are better than others.

Knowing why and which solution is best will get you the job.

Post reply on HN