URGENT: Question about merge and hash JOIN

  • Please help me with the following questions ….

    1) When joining two small row sets together on an inner join, which join type is generally preferred?

    a. Hash Join

    b. Merge Join

    c. Loop Join

    3) What is the difference between a hash join and a merge join?

    Thank you.

  • Hi,

    Ref this for your interview questions

    http://support.microsoft.com/kb/197297

  • Why is this urgent?

    http://sqlinthewild.co.za/index.php/2009/11/24/the-most-optimal-join-type/

    http://sqlinthewild.co.za/index.php/2007/12/30/execution-plan-operations-joins/

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • Thanks GilaMonster. I have applied for an internship and I was asked the question by an HR person in email. Thats why I said it is urgent.

  • arun.sas (12/4/2009)


    Hi,

    Ref this for your interview questions

    http://support.microsoft.com/kb/197297

    Thank You. That was helpful

  • daniel.phone (12/5/2009)


    Thanks GilaMonster. I have applied for an internship and I was asked the question by an HR person in email. Thats why I said it is urgent.

    It's usually faster to hit a search engine than to post here and wait for replies.

    Also, please note that, in general, people here won't give you answers to interview questions, they'll give you suggestions on where to look. The logic behind that is that we're not going to give people answers so that they can pass interviews and get jobs that they are not qualified for. We have before had people posting pages of questions from an interview/test

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • daniel.phone (12/4/2009)


    0 vote down

    star

    Please help me with the following questions as soon as possible….

    1) True or False, specifying a join hint will force join order?

    2) When joining two small row sets together on an inner join, which join type is generally preferred?

    a. Hash Join

    b. Merge Join

    c. Loop Join

    3) What is the difference between a hash join and a merge join?

    Thank you.

    So, this post was just fishing for answers to interview questions? I'd be very cautious about doing what you've just done to land a job. You don't think that people working at companies can do a search on their favorite questions? Or that they might be hanging out in these same forums? That's a pretty dangerous mechanism you're using to land the job. Some might call it dishonest.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

  • Grant Fritchey (12/7/2009)


    daniel.phone (12/4/2009)


    0 vote down

    star

    Please help me with the following questions as soon as possible….

    1) True or False, specifying a join hint will force join order?

    2) When joining two small row sets together on an inner join, which join type is generally preferred?

    a. Hash Join

    b. Merge Join

    c. Loop Join

    3) What is the difference between a hash join and a merge join?

    Thank you.

    So, this post was just fishing for answers to interview questions? I'd be very cautious about doing what you've just done to land a job. You don't think that people working at companies can do a search on their favorite questions? Or that they might be hanging out in these same forums? That's a pretty dangerous mechanism you're using to land the job. Some might call it dishonest.

    okay..okay..... I got the wrong idea at first and thought fellow experts would just tell me the answer! I got it. It wont happen again.

  • daniel.phone (12/7/2009)


    Grant Fritchey (12/7/2009)


    daniel.phone (12/4/2009)


    0 vote down

    star

    Please help me with the following questions as soon as possible….

    1) True or False, specifying a join hint will force join order?

    2) When joining two small row sets together on an inner join, which join type is generally preferred?

    a. Hash Join

    b. Merge Join

    c. Loop Join

    3) What is the difference between a hash join and a merge join?

    Thank you.

    So, this post was just fishing for answers to interview questions? I'd be very cautious about doing what you've just done to land a job. You don't think that people working at companies can do a search on their favorite questions? Or that they might be hanging out in these same forums? That's a pretty dangerous mechanism you're using to land the job. Some might call it dishonest.

    okay..okay..... I got the wrong idea at first and thought fellow experts would just tell me the answer! I got it. It wont happen again.

    Actually, if you go back over to ask.sqlservercentral.com you'll see that I did answer the question, directly, before I found out what it was for. It sounded like homework, but specific enough that I didn't mind providing some information.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

  • "FELLOW experts???"

    __________________________________________________

    Against stupidity the gods themselves contend in vain. -- Friedrich Schiller
    Stop, children, what's that sound? Everybody look what's going down. -- Stephen Stills

  • Please do not cross post and please make your own attempt to do work. the "fellow experts" are happy to help, but not do the work for you.

  • Number 6 (12/7/2009)


    "FELLOW experts???"

    my bad...fellow newbies! 🙂

  • I think you will find that the advice given by the experts here has been generous.

    Many of the people that have responded to you post are Interviewers and influential in the community. As an Interviewer, it is not uncommon practice to background check a candidate, nor to see if that candidate is trying to memorize Q&A for the interview, as well as to check forums to see what kind of involvement that person has in the community, and lastly - many employers will browse the web to see what they can dig up about a candidate regardless of forums or interview Q&A.

    When an Interviewer comes across a thread like this, it only hurts your chances of getting that job. If you don't know the information but know how to research the information and do the leg-work that the job requires, it will stand out for the employer and interviewer far more than to post questions in a forum expecting immediate results.

    Jason...AKA CirqueDeSQLeil
    _______________________________________________
    I have given a name to my pain...MCM SQL Server, MVP
    SQL RNNR
    Posting Performance Based Questions - Gail Shaw[/url]
    Learn Extended Events

Viewing 13 posts - 1 through 12 (of 12 total)

You must be logged in to reply to this topic. Login to reply