Merger join and inner join

  • HI,

    I designed a SSIS package which should perform joining two tables and dump that content into another tabel. SO i used merge join task in SSIS for that and for my surprise it returned only some rows when compared to tsql query which is getting large number of rows(actual output rows). I verified everything in that pacage but couldn't find anything. So could anyone please let me know whether is there any difference between Mergejoin and inner join....

  • Offhand, there shouldn't be. That said, the merge join in SSIS tends to be a bit difficult the first few times you use it.

    If you post your actual query, and some screenshots/code from your objects in SSIS, we might be able to locate the difference for you.


    - Craig Farrell

    Never stop learning, even if it hurts. Ego bruises are practically mandatory as you learn unless you've never risked enough to make a mistake.

    For better assistance in answering your questions[/url] | Forum Netiquette
    For index/tuning help, follow these directions.[/url] |Tally Tables[/url]

    Twitter: @AnyWayDBA

  • Merge join is case sensitive. This is my guess as the culprit if you are joining on non-numeric columns, since a lot of sources aren't case sensitive. You could case your column to UPPER before joining and that could fix your issue.

    I would try to avoid joining on string columns because you have trim issues along with case sensitive issues and it is a lot slower, especially if you are working with large datasets.

    If all else fails you could do one of two things. Use your T-SQL query. Or if you are pulling from non-linked sources then you could stage your separate queries into tables on your SQL Server Environment and then join them in T-SQL and throw that query into a OLE DB Data Source component.

Viewing 3 posts - 1 through 2 (of 2 total)

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