Friday, November 24, 2006
DBA Job Interview Question #2 - User-Defined Datatypes
Here's our second Question and Answer in our series on DBA Job Interview Questions:
THE WRONG ANSWER: This would involve something along the lines of, "You should always use them whenever..." That's just me though (my personality) - I just don't tend to like/get-along with people who speak about complex topics in absolutes; i.e., "I always...", "I never...", etc.
THE RIGHT ANSWER: Just about anything else that shows me that you (a) understand what they are, and (b) can describe when they might be used, and (c) describes any experience that you've had using them. It would be totally fine to give an answer that involves defining the UDT, describing a scenario that could benefit from it, and then saying, "I've actually never worked on a database that used UDTs so I don't really have an opinion of them." I would much rather hear an honest answer than for someone to try to B.S. me on using UDTs.
UDTs have their place. Personally I don't like to use them but, if someone makes a good case for why they chose a UDT, I can totally understand the seduction of using a UDT. The worst thing someone could do when answering this question would be to lie and explain a scenario in which they used a UDT because I would, of course, ask them about it in detail. I'm a curious guy - I want to know why you chose the UDT and if there were any problems with it. There are some pretty significant problems with using UDTs when it comes to change management and, if you could not identify at least one major pitfall of UDTs, then I'd have to assume that you were don't have that much experience with them or that your experience is "surface-level." That would take you down a peg in my book.
It would be totally fine to answer something like, "Yes, I have used them but it was very surface-level. I really wasn't in charge/didn't-have-to work with the day-to-day management of the UDT." Then I wouldn't really question you further.
Technorati Tags: Scott Whigham, Whigham, SQL Server, SQL Server 2005, SQL Server, Microsoft SQL Server
Have you used user-defined datatypes before? If so, what are your thoughts?If I were the interviewer, I would ask this question in an earnest manner; I really want to know your thoughts on using UDTs. This is one of those questions that does have a wrong answer IMO but you would have to really blunder into it. I would ask this question because I'm looking to see what your experience level is and, of course, to see if you make the mistake of answering it poorly.
THE WRONG ANSWER: This would involve something along the lines of, "You should always use them whenever..." That's just me though (my personality) - I just don't tend to like/get-along with people who speak about complex topics in absolutes; i.e., "I always...", "I never...", etc.
THE RIGHT ANSWER: Just about anything else that shows me that you (a) understand what they are, and (b) can describe when they might be used, and (c) describes any experience that you've had using them. It would be totally fine to give an answer that involves defining the UDT, describing a scenario that could benefit from it, and then saying, "I've actually never worked on a database that used UDTs so I don't really have an opinion of them." I would much rather hear an honest answer than for someone to try to B.S. me on using UDTs.
UDTs have their place. Personally I don't like to use them but, if someone makes a good case for why they chose a UDT, I can totally understand the seduction of using a UDT. The worst thing someone could do when answering this question would be to lie and explain a scenario in which they used a UDT because I would, of course, ask them about it in detail. I'm a curious guy - I want to know why you chose the UDT and if there were any problems with it. There are some pretty significant problems with using UDTs when it comes to change management and, if you could not identify at least one major pitfall of UDTs, then I'd have to assume that you were don't have that much experience with them or that your experience is "surface-level." That would take you down a peg in my book.
It would be totally fine to answer something like, "Yes, I have used them but it was very surface-level. I really wasn't in charge/didn't-have-to work with the day-to-day management of the UDT." Then I wouldn't really question you further.
Technorati Tags: Scott Whigham, Whigham, SQL Server, SQL Server 2005, SQL Server, Microsoft SQL Server