Link to home
Start Free TrialLog in
Avatar of rajeeva_nagaraj
rajeeva_nagaraj

asked on

SSIS

Hi,

I have a query on SSIS, I have a SQL table (Productmaster) as below

OriginalProductIdProductName, Store1Code, Store2Code, Store3Code
001                         Apple                   101             201               301          
002                         Banana                 102             202               302
003                         Orange                  103             203               303


StoreMaster

StoreId  StoreName
1               S1
2               S2
3               S3

My Sales table
Store         ProductId      Qty      Amt
S1                 101              10         1000
S1                 102              10         1000
S1                 103                5           500
S2                 201                3           300
S2                 202                5           500
S2                 203                6           600
S3                 301                2           200
S3                 302                6           600
S3                 303                8           800

The output is combination of all the 3 tables
Storename    OriginalProductId        Qty          Amount
S1                        001                         10              1000
S1                        002                         10               1000
S1                        003                           5                  500
S2                        001                           3                   300
S2                        002                           5                   500
S2                        003                           6                   600
S3                        001                           2                    200
S3                        002                           6                     600
S3                        003                            8                     800

How can i do this with SSIS package, please its very urgent
Avatar of rsly
rsly
Flag of United States of America image

If you already have the query to create your report you can open up the Business Intelligence Development Studio, create a new Integration Services Project, then add in an Execute SQL Task object. Paste your query or queries to create your report into the Execute SQL Task object in the SQLStatement area. That's it. Then you can save your query to the server and execute it through a stored procedure or through a SQL Agent job.
ASKER CERTIFIED SOLUTION
Avatar of rajeeva_nagaraj
rajeeva_nagaraj

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of rajeeva_nagaraj
rajeeva_nagaraj

ASKER

I have found the way to fix the above issue by using the unpivot transformation