Progressive Insurance

  www.progressive.com
  www.progressive.com

Interview Question

Data Analyst Interview

how to merge two data sets by sql or data steps

Answer

Interview Answer

1 Answer

0

In SQL, you can use JOIN and UNION or UNION ALL to merge tables. Since the question is about DataSets, it may be related to the .NET data representation model described in ADO.NET. DataSet in .NET has a Merge method, which allows it to merge two datasets into one.

When dealing with large aggregations of data, merging two datasets may not alwatys be such a great idea, as the memory footprint of your operation becomes much bigger. On the other hand, if you are trying to repetitively select data from the two datasets, and performance is an issue, then merging them may indeed be the answer.

Anonymous on May 10, 2010

Add Answers or Comments

To comment on this, Sign In or Sign Up.