{"id":25356,"date":"2023-04-17T06:54:00","date_gmt":"2023-04-17T04:54:00","guid":{"rendered":"https:\/\/expert-only.com\/?p=25356"},"modified":"2023-05-12T10:55:15","modified_gmt":"2023-05-12T08:55:15","slug":"transform-columns-into-rows-with-ssis","status":"publish","type":"post","link":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/","title":{"rendered":"Transform columns into rows with SSIS UNPIVOT"},"content":{"rendered":"\n<h4 class=\"wp-block-heading has-text-align-center\" id=\"h-transform-columns-in-a-sql-server-table-into-rows-with-the-ssis-unpivot-transformation-component\"><strong><em>Transform columns in a SQL Server table into rows with the SSIS Unpivot transformation component.<\/em><\/strong><\/h4>\n\n\n\n<p>Transforming SQL Server table columns into rows with the SSIS Unpivot transformation component.a To transform columns into rows with the SSIS Unpivot component, it is not necessary to know the T-SQL UNPIVOT operator. Indeed, it is more convenient to write a selection query on data stored vertically rather than horizontally. Here is how to transform columns into rows with the SSIS Unpivot component. To manage the data in a SQL table with flexibility, it is therefore advisable to store the data in rows rather than in column names.<\/p>\n\n\n\n<p>The latter case makes the database structure less manageable. Even though in terms of disk space and performance, on month-to-month data, storing 12 times fewer rows can be useful on SQL projects.<\/p>\n\n\n\n<p>First of all, the purpose of this tutorial is to transform monthly data <a href=\"https:\/\/en.wikipedia.org\/wiki\/Column-oriented_DBMS\" target=\"_blank\" rel=\"noreferrer noopener\">stored in columns<\/a> to an inline table. The source table therefore has 12 columns of data, one for each month of the year. The target table has two separate columns, one column for storing the month name and one column for storing the sales amount.<\/p>\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 ez-toc-wrap-center counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#1-create-the-source-table-with-the-columns-to-change-to-rows-using-ssis\" >1. Create the source table with the columns to change to rows using SSIS<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#2-insert-monthly-sales-data-stored-in-columns\" >2. Insert monthly sales data stored in columns<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#3-create-the-target-table-to-store-data-in-rows\" >3. Create the target table to store data in rows<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#4-add-the-ssis-ole-db-and-unpivot-components\" >4. Add the SSIS OLE DB and UNPIVOT components<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#5-configure-the-source-table-and-column-mappings\" >5. Configure the source table and column mappings<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#6-configure-the-ssis-unpivot-transformation\" >6. Configure the SSIS Unpivot transformation<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#7-manage-the-truncation-warning-displayed-by-ssis\" >7. Manage the truncation warning displayed by SSIS<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#8-set-up-the-target-table-with-the-row-structure\" >8. Set up the target table with the row structure<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#9-run-the-ssis-package-and-transform-columns-to-rows\" >9. Run the SSIS package and transform columns to rows<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#10-compare-source-columns-with-the-target-row-using-ssms\" >10. Compare source columns with the target row using SSMS<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"1-create-the-source-table-with-the-columns-to-change-to-rows-using-ssis\"><\/span>1. Create the source table with the columns to change to rows using SSIS<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Start by creating the dataset to have all the elements in hand and understand this example before adapting it to a more concrete case. The objective is to provide all the material in this tutorial to focus on the Unpivot component and its operation.<\/p>\n\n\n\n<p>From an SSMS connection, execute the following SQL code, which is of type LDD (Data Definition Language). This creates the table <em>dbo.Sales_Monthly_In_Columns<\/em> with one column of data per month and one row per year.<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"mssql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">CREATE TABLE [dbo].[Sales_Monthly_In_Columns]\n(\n  [CustomerID] int NOT NULL,\n  [YearID]     nvarchar(20) NOT NULL,\n  [January]    numeric(10,2)  NULL,\n  [February]   numeric(10,2)  NULL,\n  [March]      numeric(10,2)  NULL,\n  [April]      numeric(10,2)  NULL,\n  [May]        numeric(10,2)  NULL,\n  [June]       numeric(10,2)  NULL,\n  [July]       numeric(10,2)  NULL,\n  [August]     numeric(10,2)  NULL,\n  [September]  numeric(10,2)  NULL,\n  [October]    numeric(10,2)  NULL,\n  [November]   numeric(10,2)  NULL,\n  [December]   numeric(10,2)  NULL\n  CONSTRAINT [SalesMonthlyColumnsPK] \n    PRIMARY KEY CLUSTERED (\n      [CustomerID], [YearID] ASC\n    )\n);\nGO<\/pre>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"2-insert-monthly-sales-data-stored-in-columns\"><\/span>2. Insert monthly sales data stored in columns<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Then insert the dataset with sales for the years 2021 and 2022 in the previously created table. The data covers 8 different customers, uniquely identified by the customer number, <em>CustomerID<\/em>.<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"mssql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">INSERT [dbo].[Sales_Monthly_In_Columns] VALUES (1, N'2021', 221.80, 2658.80, 2485.00, 6302.80, 7605.60, 5288.50, 3335.20, 5216.40, 4372.20, 9815.60, 5479.00, 9212.10 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (1, N'2022', 7575.90, 6662.60, 1464.60, 7011.10, 3978.30, 4101.10, 5964.80, 2619.60, 4482.00, 3874.00, 3171.80, 1610.70 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (2, N'2021', 6263.30, 1952.50, 9110.00, 5433.30, 1177.90, 9418.80, 8657.90, 5264.80, 595.80, 6332.50, 3268.50, 3413.50 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (2, N'2022', 2969.90, 3022.70, 1626.10, 9396.30, 8723.30, 9784.80, 9084.10, 3366.40, 8784.50, 1313.50, 7135.00, 8379.10 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (3, N'2021', 2618.90, 5898.70, 7929.10, 5614.40, 7561.80, 5545.80, 2666.50, 2229.70, 1500.50, 6051.40, 1992.20, 1060.80 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (3, N'2022', 2433.10, 8977.80, 9414.60, 4195.10, 6623.20, 1783.40, 1480.30, 4175.00, 2497.20, 6332.10, 6839.20, 145.50 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (4, N'2021', 7170.40, 3507.00, 9154.70, 4465.00, 1109.30, 1905.70, 7980.70, 9227.50, 2166.00, 2988.30, 6353.80, 9448.70 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (4, N'2022', 3287.60, 1805.70, 2068.20, 8353.40, 1378.70, 4689.10, 4720.00, 5643.60, 2722.50, 5539.00, 5494.60, 1790.60 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (5, N'2021', 3336.20, 7451.40, 1656.60, 978.30, 8794.60, 7568.30, 3547.80, 8382.20, 3068.10, 7882.30, 5726.60, 9693.10 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (5, N'2022', 1365.70, 3680.60, 8256.40, 5379.20, 1075.50, 2852.70, 4520.80, 7253.10, 3285.60, 705.10, 2134.60, 7437.00 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (6, N'2021', 1421.30, 2552.40, 174.20, 9158.00, 8138.50, 8458.30, 6548.90, 4805.80, 3026.50, 8127.40, 6626.40, 1035.70 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (6, N'2022', 2253.40, 1107.30, 9349.30, 3751.80, 9320.90, 2485.60, 435.30, 6358.10, 733.10, 1015.90, 7780.70, 6232.40 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (7, N'2021', 3971.30, 1538.20, 7727.50, 4494.10, 6314.70, 640.10, 6070.30, 5926.00, 7013.10, 2119.20, 3188.20, 4474.20 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (7, N'2022', 7082.40, 3010.10, 8716.00, 8493.50, 1782.80, 3023.20, 3897.60, 1752.80, 5952.30, 8430.40, 6643.10, 6276.10 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (8, N'2021', 7279.40, 4494.40, 7045.30, 4253.30, 6702.40, 9017.20, 810.00, 7891.80, 663.10, 5771.40, 3190.10, 6130.00 );\nINSERT [dbo].[Sales_Monthly_In_Columns] VALUES (8, N'2022', 8253.70, 7844.60, 3655.80, 1046.10, 290.10, 5580.40, 3572.70, 9926.10, 6213.90, 7622.80, 3414.60, 4581.40 );\n<\/pre>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"3-create-the-target-table-to-store-data-in-rows\"><\/span>3. Create the target table to store data in rows<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Now create the second SQL table, this time with the months in rows. The grouping columns, i.e. customer number and year are still present.<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"mssql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">CREATE TABLE [dbo].[Sales_Monthly_In_Lines]\n(\n  [CustomerID]  int NOT NULL,\n  [YearID]      nvarchar(20) NOT NULL,\n  [MonthName]   nvarchar(10) NOT NULL,\n  [SalesAmount] numeric(10,2)  NULL\n  CONSTRAINT [SalesMonthlyLinesPK] \n    PRIMARY KEY CLUSTERED (\n      [CustomerID], [YearID], [MonthName] ASC\n    )\n);\nGO<\/pre>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"4-add-the-ssis-ole-db-and-unpivot-components\"><\/span>4. Add the SSIS OLE DB and UNPIVOT components <span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Here are a few key steps in this course for <strong>changing columns into rows with SSIS<\/strong> and the Unpivot transformation. That is, the configuration of the data flow. To do so, follow these prerequisite steps: <\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Open an existing SSIS package or <a href=\"https:\/\/expert-only.com\/lessons\/create-an-ssis-project-and-a-package-with-visual-studio-2019\/\"><strong>create a new project and package with Visual Studio<\/strong><\/a>.<\/li>\n\n\n\n<li>Create a <a href=\"https:\/\/expert-only.com\/lessons\/connect-to-sql-server-using-the-ssis-connection-manager\/\"><strong>connection to the SQL Server database<\/strong><\/a>, which is required to run the package.<\/li>\n\n\n\n<li>Then add a data flow and insert the three useful components listed below.<\/li>\n<\/ol>\n\n\n\n<p>3 components to add in the SSIS dataflow: <\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><em><strong>OLE DB Source<\/strong><\/em> : \u00e0 faire pointer sur la table <em><strong>Sales_Monthly_In_Columns<\/strong><\/em><\/li>\n\n\n\n<li><strong><em>Composant SSIS Unpivot<\/em><\/strong> : \u00e0 param\u00e9trer pour <strong><em>transposer les mois<\/em><\/strong> et leur valeur en lignes<\/li>\n\n\n\n<li><em><strong>OLE DB Destination<\/strong><\/em> : pointer sur la table cible <em><strong>Sales_Monthly_In_Lines<\/strong><\/em> avec la structure en lignes.<\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"680\" height=\"580\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-1-add-source-unpivot-target.jpg\" alt=\"Add an OLE DB Source, Unpivot and a Destination components to the SSIS data flow\" class=\"wp-image-13956\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-1-add-source-unpivot-target.jpg 680w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-1-add-source-unpivot-target-300x256.jpg 300w\" sizes=\"auto, (max-width: 680px) 100vw, 680px\" \/><figcaption class=\"wp-element-caption\"><em>Add an OLE DB Source, Unpivot and a Destination components to the SSIS data flow<\/em><\/figcaption><\/figure><\/div>\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"5-configure-the-source-table-and-column-mappings\"><\/span>5. Configure the source table and column mappings<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Simply select the source table created in the first step with the column structure as the source for the SSIS package.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"600\" height=\"380\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-2-source-data-in-columns.jpg\" alt=\"Select the source table with the columns to transform into rows\" class=\"wp-image-13970\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-2-source-data-in-columns.jpg 600w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-2-source-data-in-columns-300x190.jpg 300w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><figcaption class=\"wp-element-caption\"><em>Select the source table with the columns to transform into rows<\/em><\/figcaption><\/figure><\/div>\n\n\n<p>Also check the columns present from the <strong><em>Columns<\/em><\/strong> tab, all 12 months are present as in the screenshot below.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"600\" height=\"720\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-3-check-source-columns.jpg\" alt=\"Check the source columns to transpose using SSIS Unpivot\" class=\"wp-image-13978\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-3-check-source-columns.jpg 600w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-3-check-source-columns-250x300.jpg 250w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><figcaption class=\"wp-element-caption\"><em>Check the source columns to transpose using SSIS Unpivot<\/em><\/figcaption><\/figure><\/div>\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"6-configure-the-ssis-unpivot-transformation\"><\/span>6. Configure the SSIS Unpivot transformation<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Perform these 4 steps to configure the SSIS Unpivot component and change data from columns to rows. Each step number is inked to the screenshot below:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Select the aggregation columns with the Pass Through option: here it is <strong><em>CustomerID and YearID<\/em><\/strong>.<\/li>\n\n\n\n<li>Select all the columns to be transposed: the columns of the 12 months <strong><em>from January to December<\/em><\/strong>.<\/li>\n\n\n\n<li>Enter the name of the new column where to store the sales: <strong><em>SalesAmount<\/em><\/strong>.<\/li>\n\n\n\n<li>Type the name of the column for the pivot key, or store the name of the months: <strong><em>MonthName<\/em><\/strong>.<\/li>\n<\/ol>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-4-configure-unpivot-options.jpg\" alt=\"Configure the SSIS Unpivot component to turn columns into rows\" class=\"wp-image-13985\" width=\"660\" height=\"945\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-4-configure-unpivot-options.jpg 660w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-4-configure-unpivot-options-210x300.jpg 210w\" sizes=\"auto, (max-width: 660px) 100vw, 660px\" \/><figcaption class=\"wp-element-caption\"><em>Configure the SSIS Unpivot component to turn columns into rows<\/em><\/figcaption><\/figure><\/div>\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"7-manage-the-truncation-warning-displayed-by-ssis\"><\/span>7. Manage the truncation warning displayed by SSIS<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>As in many source components or data transformation components, SQL Server Integration Services assigns a default data type to the new columns which is (DT_WSTR,255). This causes this warning in the target component.<\/p>\n\n\n\n<p><strong><em>[OLE DB Destination] Warning: Truncation may occur due to inserting data from data flow column &#8220;MonthName&#8221; with a length of 255 to database column &#8220;MonthName&#8221; with a length of 10.<\/em><\/strong><\/p>\n\n\n\n<p>The warning is displayed because the new <em>MonthName<\/em> column output from the Unpivot block is of type DT_WSTR with a length of 255, while the column in the table is of type NVARCHAR(10).<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"720\" height=\"200\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-5-unpivot-truncation-warning.jpg\" alt=\"SSIS warning of data truncation after the Unpivot component\" class=\"wp-image-14005\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-5-unpivot-truncation-warning.jpg 720w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-5-unpivot-truncation-warning-300x83.jpg 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><figcaption class=\"wp-element-caption\"><em>SSIS warning of data truncation after the Unpivot component<\/em><\/figcaption><\/figure><\/div>\n\n\n<p>The solution to manage this behaviour and remove the warning is to change the type of the output column in the advanced editor of the Unpivot SSIS block.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>First <strong>right-click<\/strong> on the Unpivot SSIS component and choose <strong>Show Advanced Editor\u2026<\/strong> in the contextual menu. Then select the <strong>Input and Output Properties<\/strong> tab.<\/li>\n\n\n\n<li>From the <strong>Unpivot Output<\/strong> section, select the <em>MonthName<\/em> column to edit.<\/li>\n\n\n\n<li>Finally change the length from <strong>255 characters to 10 characters<\/strong>.<\/li>\n<\/ol>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"711\" height=\"622\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-6-change-pivot-key-data-length.jpg\" alt=\"Change the length of the pivot column in the advanced editor Unpivot SSIS\" class=\"wp-image-14018\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-6-change-pivot-key-data-length.jpg 711w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-6-change-pivot-key-data-length-300x262.jpg 300w\" sizes=\"auto, (max-width: 711px) 100vw, 711px\" \/><figcaption class=\"wp-element-caption\"><em>Change the length of the pivot column in the advanced editor Unpivot SSIS<\/em><\/figcaption><\/figure><\/div>\n\n\n<p>After this adaptation of the length to the target column type, the package can be executed smoothly and without warnings in the SSIS logs at each execution.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"8-set-up-the-target-table-with-the-row-structure\"><\/span>8. Set up the target table with the row structure<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Now open the destination and choose the second table with a row data structure.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-7-target-table-in-lines.jpg\" alt=\"Choose the table from the OLE DB Destination editor\" class=\"wp-image-14059\" width=\"600\" height=\"380\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-7-target-table-in-lines.jpg 600w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-7-target-table-in-lines-300x190.jpg 300w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><figcaption class=\"wp-element-caption\"><em>Choose the table from the OLE DB Destination editor<\/em><\/figcaption><\/figure><\/div>\n\n\n<p>Double check the mapping, and if necessary map the columns based on the column names. Note that we intentionally name the column the same way to make the mapping much easier and automated.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Open the OLE DB editor and <strong><em>right-click<\/em><\/strong><\/li>\n\n\n\n<li>Then select <strong><em>Map Items by Matching Names<\/em><\/strong><\/li>\n<\/ol>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"600\" height=\"520\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-8-check-target-mapping.jpg\" alt=\"V\u00e9rifier le mapping des colonnes SSIS depuis l'\u00e9diteur OLE DB\" class=\"wp-image-14055\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-8-check-target-mapping.jpg 600w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-8-check-target-mapping-300x260.jpg 300w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><figcaption class=\"wp-element-caption\">V\u00e9rifier le mapping des colonnes SSIS depuis l&#8217;\u00e9diteur OLE DB<\/figcaption><\/figure><\/div>\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"9-run-the-ssis-package-and-transform-columns-to-rows\"><\/span>9. Run the SSIS package and transform columns to rows<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Finally, run the package to rotate the 16 source lines into 16*12 lines, making a total of 192 lines.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"600\" height=\"480\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-9-execute-package.jpg\" alt=\"Transforming structured data from columns to rows with SSIS\" class=\"wp-image-14078\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-9-execute-package.jpg 600w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-9-execute-package-300x240.jpg 300w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><figcaption class=\"wp-element-caption\"><em>Transforming structured data from columns to rows with SSIS<\/em><\/figcaption><\/figure><\/div>\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"10-compare-source-columns-with-the-target-row-using-ssms\"><\/span>10. Compare source columns with the target row using SSMS<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>To check that the SSIS package is working properly, first connect to SSMS and run these two SQL queries.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Une premi\u00e8re requ\u00eate SQL pour <em><strong>lire la table source en colonnes<\/strong><\/em>.<\/li>\n\n\n\n<li>Une deuxi\u00e8me requ\u00eate SQL pour <strong><em>lire la table transform\u00e9e en lignes<\/em><\/strong>.<\/li>\n<\/ol>\n\n\n\n<ol class=\"wp-block-list\">\n<li>A first SQL query to <strong><em>read the source table in columns<\/em><\/strong>.<\/li>\n\n\n\n<li>A second SQL query to <strong><em>read the target table in rows<\/em><\/strong>, after the SSIS Unpivot execution.<\/li>\n<\/ol>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"mssql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">select * from [dbo].[Sales_Monthly_In_Columns];\n\nselect\t*\nfrom\t[dbo].[Sales_Monthly_In_Lines]\norder by YearID, CustomerID, MONTH(MonthName + ' 01, 1900');<\/pre>\n\n\n\n<p>Finally, the month amounts of the first table are present in the second table with data stored in a row structure.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"860\" height=\"760\" src=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-10-check-data-in-lines-ssms.jpg\" alt=\"Comparison of data stored in columns and rows after the SSIS Unpivot\" class=\"wp-image-14092\" srcset=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-10-check-data-in-lines-ssms.jpg 860w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-10-check-data-in-lines-ssms-300x265.jpg 300w, https:\/\/expert-only.com\/wp-content\/uploads\/2022\/10\/ssis-unpivot-data-10-check-data-in-lines-ssms-768x679.jpg 768w\" sizes=\"auto, (max-width: 860px) 100vw, 860px\" \/><figcaption class=\"wp-element-caption\"><em>Comparison of data stored in columns and rows after the SSIS Unpivot<\/em><\/figcaption><\/figure><\/div>\n\n\n<h3 class=\"wp-block-heading\">Conclusion on the SSIS Unpivot transformation<\/h3>\n\n\n\n<p>Transforming columns into rows with SSIS and the UNPIVOT transformation is therefore simple and guided, almost automatic. You just have to manage the length of the columns of the PIVOT keys. A prerequisite is to understand <a href=\"https:\/\/expert-only.com\/en\/t-sql\/sql-server-unpivot\/\">how the classic UNPIVOT operator works in T-SQL<\/a>.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Other techniques to pivot and unpivot data with Microsoft software<\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong><a href=\"https:\/\/expert-only.com\/en\/t-sql\/sql-server-pivot-query-example\/\">Pivoting data with a SQL Server query<\/a><\/strong><\/li>\n\n\n\n<li><a href=\"https:\/\/expert-only.com\/en\/excel\/pivot-excel-table\/\"><strong>Pivot data using Excel<\/strong><\/a><\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-embed is-type-wp-embed is-provider-sql-and-it-tutorials wp-block-embed-sql-and-it-tutorials\"><div class=\"wp-block-embed__wrapper\">\n<blockquote class=\"wp-embedded-content\" data-secret=\"JncdtxbCJh\"><a href=\"https:\/\/expert-only.com\/fr\/tutoriels-ssis\/\">Tutoriels SSIS pour d\u00e9butants<\/a><\/blockquote><iframe loading=\"lazy\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" title=\"&#8220;Tutoriels SSIS pour d\u00e9butants&#8221; &#8212; SQL and IT Tutorials\" src=\"https:\/\/expert-only.com\/fr\/tutoriels-ssis\/embed\/#?secret=EcLJrZjHPR#?secret=JncdtxbCJh\" data-secret=\"JncdtxbCJh\" width=\"500\" height=\"282\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe>\n<\/div><\/figure>\n","protected":false},"excerpt":{"rendered":"<div class=\"mh-excerpt\"><p>Transform columns in a SQL Server table into rows with the SSIS Unpivot transformation component. Transforming SQL Server table columns into rows with the SSIS Unpivot transformation component.a To transform columns into rows with the SSIS Unpivot component, it <a class=\"mh-excerpt-more\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/\" title=\"Transform columns into rows with SSIS UNPIVOT\">&#8230;<\/a><\/p>\n<\/div>","protected":false},"author":1,"featured_media":10664,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[516],"tags":[],"class_list":{"0":"post-25356","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-ssis"},"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.7 (Yoast SEO v26.2) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Transform columns into rows with SSIS UNPIVOT - MS BI<\/title>\n<meta name=\"description\" content=\"Integration Services package to transform SQL Server columns into rows using the SSIS UNPIVOT transformation similar to the T-SQL operator.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Transform columns into rows with SSIS UNPIVOT\" \/>\n<meta property=\"og:description\" content=\"Integration Services package to transform SQL Server columns into rows using the SSIS UNPIVOT transformation similar to the T-SQL operator.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/\" \/>\n<meta property=\"og:site_name\" content=\"SQL and IT Tutorials\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/ExpertOnlyCom\/\" \/>\n<meta property=\"article:published_time\" content=\"2023-04-17T04:54:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-05-12T08:55:15+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1920\" \/>\n\t<meta property=\"og:image:height\" content=\"1080\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Expert-Only\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@expert_only\" \/>\n<meta name=\"twitter:site\" content=\"@expert_only\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Expert-Only\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"9 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/\"},\"author\":{\"name\":\"Expert-Only\",\"@id\":\"https:\/\/expert-only.com\/en\/#\/schema\/person\/406a9576b52944f018739a42046873ef\"},\"headline\":\"Transform columns into rows with SSIS UNPIVOT\",\"datePublished\":\"2023-04-17T04:54:00+00:00\",\"dateModified\":\"2023-05-12T08:55:15+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/\"},\"wordCount\":1219,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/expert-only.com\/en\/#organization\"},\"image\":{\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg\",\"articleSection\":[\"SSIS\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/\",\"url\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/\",\"name\":\"Transform columns into rows with SSIS UNPIVOT - MS BI\",\"isPartOf\":{\"@id\":\"https:\/\/expert-only.com\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg\",\"datePublished\":\"2023-04-17T04:54:00+00:00\",\"dateModified\":\"2023-05-12T08:55:15+00:00\",\"description\":\"Integration Services package to transform SQL Server columns into rows using the SSIS UNPIVOT transformation similar to the T-SQL operator.\",\"breadcrumb\":{\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#primaryimage\",\"url\":\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg\",\"contentUrl\":\"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg\",\"width\":1920,\"height\":1080},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"en\",\"item\":\"https:\/\/expert-only.com\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Transform columns into rows with SSIS UNPIVOT\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/expert-only.com\/en\/#website\",\"url\":\"https:\/\/expert-only.com\/en\/\",\"name\":\"SQL and IT Tutorials\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/expert-only.com\/en\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/expert-only.com\/en\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/expert-only.com\/en\/#organization\",\"name\":\"Expert-Only\",\"url\":\"https:\/\/expert-only.com\/en\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/expert-only.com\/en\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/expert-only.com\/wp-content\/uploads\/2017\/09\/cropped-logo_Expert-Only.jpg\",\"contentUrl\":\"https:\/\/expert-only.com\/wp-content\/uploads\/2017\/09\/cropped-logo_Expert-Only.jpg\",\"width\":381,\"height\":174,\"caption\":\"Expert-Only\"},\"image\":{\"@id\":\"https:\/\/expert-only.com\/en\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/ExpertOnlyCom\/\",\"https:\/\/x.com\/expert_only\",\"https:\/\/www.youtube.com\/channel\/UCMS5sR_FwAetB0FmciNvUaA\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/expert-only.com\/en\/#\/schema\/person\/406a9576b52944f018739a42046873ef\",\"name\":\"Expert-Only\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/expert-only.com\/en\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/084b15660763ff5b13bb60b2f52f97bb?s=96&d=identicon&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/084b15660763ff5b13bb60b2f52f97bb?s=96&d=identicon&r=g\",\"caption\":\"Expert-Only\"}}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Transform columns into rows with SSIS UNPIVOT - MS BI","description":"Integration Services package to transform SQL Server columns into rows using the SSIS UNPIVOT transformation similar to the T-SQL operator.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/","og_locale":"en_US","og_type":"article","og_title":"Transform columns into rows with SSIS UNPIVOT","og_description":"Integration Services package to transform SQL Server columns into rows using the SSIS UNPIVOT transformation similar to the T-SQL operator.","og_url":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/","og_site_name":"SQL and IT Tutorials","article_publisher":"https:\/\/www.facebook.com\/ExpertOnlyCom\/","article_published_time":"2023-04-17T04:54:00+00:00","article_modified_time":"2023-05-12T08:55:15+00:00","og_image":[{"width":1920,"height":1080,"url":"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg","type":"image\/jpeg"}],"author":"Expert-Only","twitter_card":"summary_large_image","twitter_creator":"@expert_only","twitter_site":"@expert_only","twitter_misc":{"Written by":"Expert-Only","Est. reading time":"9 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#article","isPartOf":{"@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/"},"author":{"name":"Expert-Only","@id":"https:\/\/expert-only.com\/en\/#\/schema\/person\/406a9576b52944f018739a42046873ef"},"headline":"Transform columns into rows with SSIS UNPIVOT","datePublished":"2023-04-17T04:54:00+00:00","dateModified":"2023-05-12T08:55:15+00:00","mainEntityOfPage":{"@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/"},"wordCount":1219,"commentCount":0,"publisher":{"@id":"https:\/\/expert-only.com\/en\/#organization"},"image":{"@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#primaryimage"},"thumbnailUrl":"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg","articleSection":["SSIS"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/","url":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/","name":"Transform columns into rows with SSIS UNPIVOT - MS BI","isPartOf":{"@id":"https:\/\/expert-only.com\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#primaryimage"},"image":{"@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#primaryimage"},"thumbnailUrl":"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg","datePublished":"2023-04-17T04:54:00+00:00","dateModified":"2023-05-12T08:55:15+00:00","description":"Integration Services package to transform SQL Server columns into rows using the SSIS UNPIVOT transformation similar to the T-SQL operator.","breadcrumb":{"@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#primaryimage","url":"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg","contentUrl":"https:\/\/expert-only.com\/wp-content\/uploads\/2022\/09\/gears-B88132008B1_1920x1080.jpg","width":1920,"height":1080},{"@type":"BreadcrumbList","@id":"https:\/\/expert-only.com\/en\/ssis\/transform-columns-into-rows-with-ssis\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"en","item":"https:\/\/expert-only.com\/en\/"},{"@type":"ListItem","position":2,"name":"Transform columns into rows with SSIS UNPIVOT"}]},{"@type":"WebSite","@id":"https:\/\/expert-only.com\/en\/#website","url":"https:\/\/expert-only.com\/en\/","name":"SQL and IT Tutorials","description":"","publisher":{"@id":"https:\/\/expert-only.com\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/expert-only.com\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/expert-only.com\/en\/#organization","name":"Expert-Only","url":"https:\/\/expert-only.com\/en\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/expert-only.com\/en\/#\/schema\/logo\/image\/","url":"https:\/\/expert-only.com\/wp-content\/uploads\/2017\/09\/cropped-logo_Expert-Only.jpg","contentUrl":"https:\/\/expert-only.com\/wp-content\/uploads\/2017\/09\/cropped-logo_Expert-Only.jpg","width":381,"height":174,"caption":"Expert-Only"},"image":{"@id":"https:\/\/expert-only.com\/en\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/ExpertOnlyCom\/","https:\/\/x.com\/expert_only","https:\/\/www.youtube.com\/channel\/UCMS5sR_FwAetB0FmciNvUaA"]},{"@type":"Person","@id":"https:\/\/expert-only.com\/en\/#\/schema\/person\/406a9576b52944f018739a42046873ef","name":"Expert-Only","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/expert-only.com\/en\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/084b15660763ff5b13bb60b2f52f97bb?s=96&d=identicon&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/084b15660763ff5b13bb60b2f52f97bb?s=96&d=identicon&r=g","caption":"Expert-Only"}}]}},"_links":{"self":[{"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/posts\/25356","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/comments?post=25356"}],"version-history":[{"count":0,"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/posts\/25356\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/media\/10664"}],"wp:attachment":[{"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/media?parent=25356"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/categories?post=25356"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/expert-only.com\/en\/wp-json\/wp\/v2\/tags?post=25356"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}