<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How do I 'unpivot' a table? in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265030#M44693</link>
    <description>&lt;P&gt;I'm trying to figure out how to implement this. I'm new to Talend and evaluating it for an upcoming project. The project has a bunch of legacy tables that will need to be unpivoted.&lt;BR /&gt;So, for example, I'd like to start with a table like this:&lt;BR /&gt;TrxId Name Amt1 Amt2 Amt3&lt;BR /&gt;1 Car 10 45 50&lt;BR /&gt;2 Truck 30 60 15&lt;BR /&gt;And end up with a table like this:&lt;BR /&gt;TrxId Name AmountType Amount&lt;BR /&gt;1 Car Amt1 10&lt;BR /&gt;1 Car Amt2 45&lt;BR /&gt;1 Car Amt3 50&lt;BR /&gt;2 Truck Amt1 30&lt;BR /&gt;2 Truck Amt2 60&lt;BR /&gt;2 Truck Amt3 15&lt;BR /&gt;Note that TrxId and Name are 'passed through' while the Amt1,2,3 columns are pivoted on a new column AmountType.&lt;BR /&gt;I'm not sure if I'm using the exact terminology here. Any help would be greatly appreciated.&lt;BR /&gt;Thanks.&lt;/P&gt;</description>
    <pubDate>Sat, 16 Nov 2024 14:11:10 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2024-11-16T14:11:10Z</dc:date>
    <item>
      <title>How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265030#M44693</link>
      <description>&lt;P&gt;I'm trying to figure out how to implement this. I'm new to Talend and evaluating it for an upcoming project. The project has a bunch of legacy tables that will need to be unpivoted.&lt;BR /&gt;So, for example, I'd like to start with a table like this:&lt;BR /&gt;TrxId Name Amt1 Amt2 Amt3&lt;BR /&gt;1 Car 10 45 50&lt;BR /&gt;2 Truck 30 60 15&lt;BR /&gt;And end up with a table like this:&lt;BR /&gt;TrxId Name AmountType Amount&lt;BR /&gt;1 Car Amt1 10&lt;BR /&gt;1 Car Amt2 45&lt;BR /&gt;1 Car Amt3 50&lt;BR /&gt;2 Truck Amt1 30&lt;BR /&gt;2 Truck Amt2 60&lt;BR /&gt;2 Truck Amt3 15&lt;BR /&gt;Note that TrxId and Name are 'passed through' while the Amt1,2,3 columns are pivoted on a new column AmountType.&lt;BR /&gt;I'm not sure if I'm using the exact terminology here. Any help would be greatly appreciated.&lt;BR /&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 14:11:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265030#M44693</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-11-16T14:11:10Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265031#M44694</link>
      <description>If this doesn't exist I'd help make it a component. 
&lt;BR /&gt;The pseudo looks like:
&lt;BR /&gt;Let the user select the columns to be unpivoted. 
&lt;BR /&gt;Let the user specify a name for the . (AmountType in above example).
&lt;BR /&gt;Let the user sepcify a name for the . (Amount in the above example).
&lt;BR /&gt;For Each inputRow
&lt;BR /&gt;{
&lt;BR /&gt;For Each ColumnToUnpivot
&lt;BR /&gt;{
&lt;BR /&gt;Create a new OutputRow (schema: input - ColumnsToUnpivot + 2 new columns )
&lt;BR /&gt;Pass values for columns not in ColumnsToUnpivot from inputRow through to outputRow.
&lt;BR /&gt;Set the value of 'TypeColumn' to ColumnToUnpivot's name.
&lt;BR /&gt;Set the value of 'ValueColumn' to ColumnToUnpivot's value.
&lt;BR /&gt;}
&lt;BR /&gt;}
&lt;BR /&gt;Can someone help me get from A -&amp;gt; B on this one? Like I said I'm new to Talend but I don't imagine this would be that hard.</description>
      <pubDate>Thu, 23 Oct 2008 20:33:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265031#M44694</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-23T20:33:09Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265032#M44695</link>
      <description>Hello
&lt;BR /&gt;Here comes a Java scenario, please see the screenshots.
&lt;BR /&gt;Input file:
&lt;BR /&gt;
&lt;B&gt;&lt;BR /&gt;TrxId;Name;Amt1;Amt2;Amt3&lt;BR /&gt;1;Car;10;45;50&lt;BR /&gt;2;Truck;30;60;15&lt;BR /&gt;3;Shong;10;20;30&lt;BR /&gt;&lt;/B&gt;
&lt;BR /&gt;Result:
&lt;BR /&gt;
&lt;B&gt;Starting job topic_4500 at 11:14 24/10/2008.&lt;BR /&gt;1|Car|Amt1|10&lt;BR /&gt;1|Car|Amt2|45&lt;BR /&gt;1|Car|Amt3|50&lt;BR /&gt;2|Truck|Amt1|30&lt;BR /&gt;2|Truck|Amt2|60&lt;BR /&gt;2|Truck|Amt3|15&lt;BR /&gt;3|Shong|Amt1|10&lt;BR /&gt;3|Shong|Amt2|20&lt;BR /&gt;3|Shong|Amt3|30&lt;BR /&gt;Job topic_4500 ended at 11:14 24/10/2008. &lt;BR /&gt;&lt;/B&gt;
&lt;BR /&gt;Feel free to post your question!
&lt;BR /&gt;Best regards
&lt;BR /&gt; shong</description>
      <pubDate>Fri, 24 Oct 2008 05:02:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265032#M44695</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-24T05:02:50Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265033#M44696</link>
      <description>thanks shong, 
&lt;BR /&gt;i was looking for this. 
&lt;BR /&gt;i have a post here: 4492 
&lt;BR /&gt;in my case, i have multiple keys,; so i will try your technique and post back. 
&lt;BR /&gt;however, would it not be more future prove to have a component to handle this type of scenario. 
&lt;BR /&gt;i for one, have plenty of flat-files with similar structures.</description>
      <pubDate>Fri, 24 Oct 2008 12:01:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265033#M44696</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-24T12:01:14Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265034#M44697</link>
      <description>Thank you for your answer shong. Sorry it took me a few days to get back. 
&lt;BR /&gt;I have a few more questions: 
&lt;BR /&gt;-Can you explain the purpose of file_inputdelimited2? 
&lt;BR /&gt;-Is there anyway to add multiple rows to an output without using an iterate flow? I really want to make this a component and I believe this would be required. Is this just a limitation of TOS? 
&lt;BR /&gt;Thanks again.</description>
      <pubDate>Tue, 28 Oct 2008 14:41:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265034#M44697</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-28T14:41:42Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265035#M44698</link>
      <description>Hello 
&lt;BR /&gt; 
&lt;BLOCKQUOTE&gt; 
 &lt;TABLE border="1"&gt; 
  &lt;TBODY&gt; 
   &lt;TR&gt; 
    &lt;TD&gt;Can you explain the purpose of file_inputdelimited2?&lt;/TD&gt; 
   &lt;/TR&gt; 
  &lt;/TBODY&gt; 
 &lt;/TABLE&gt; 
&lt;/BLOCKQUOTE&gt; 
&lt;BR /&gt;Generally, if there is a output component in a job, it must has a input component, so inputdelimited2 is a input component here and it should only contain one row, because we just want to output the assigned value one time for each value of tForEach. You will see the difference and know why if you write two rows or more than in inputdelimited2. 
&lt;BR /&gt; 
&lt;BLOCKQUOTE&gt; 
 &lt;TABLE border="1"&gt; 
  &lt;TBODY&gt; 
   &lt;TR&gt; 
    &lt;TD&gt;Is there anyway to add multiple rows to an output without using an iterate flow? I really want to make this a component and I believe this would be required. Is this just a limitation of TOS?&lt;/TD&gt; 
   &lt;/TR&gt; 
  &lt;/TBODY&gt; 
 &lt;/TABLE&gt; 
&lt;/BLOCKQUOTE&gt; 
&lt;BR /&gt;No, there isn't a component can do that. 
&lt;BR /&gt;Best regards 
&lt;BR /&gt; 
&lt;BR /&gt; shong</description>
      <pubDate>Wed, 29 Oct 2008 08:52:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265035#M44698</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-29T08:52:24Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265036#M44699</link>
      <description>I think this will be very useful as a component. I use Informatica quite a bit and this will be almost like the "normalizer" component the Power Center has. Please do consider it. I can put the request in if no one has done it so far. 
&lt;BR /&gt;Thanks. 
&lt;BR /&gt;Sean</description>
      <pubDate>Wed, 29 Oct 2008 17:20:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265036#M44699</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-29T17:20:50Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265037#M44700</link>
      <description>Just to throw this out there: SSIS also has a similar transform (called 'unpivot'). Not being able to do this cleaning is making it a bit difficult to migrate to TOS.&lt;BR /&gt;TOS, in general, is great though.&lt;BR /&gt;Keep up the good work everyone,&lt;BR /&gt;Dane</description>
      <pubDate>Wed, 29 Oct 2008 18:37:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265037#M44700</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-29T18:37:21Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265038#M44701</link>
      <description>I think TOS is one of the best ETL tools. Obviously, Informatica has been around for a very long time and enterprises pay $100K just for connectors. I use both though I am more familiar with Informatica based on number of years I have been using it. 
&lt;BR /&gt;TOS has a lot of flexibility built in and wealth of connectors. But there are still few things that I feel we need to bring over from Informatica. One is the Normalizer (unpivot). Another is Router that can send rows to multiple targets with very little coding. 
&lt;BR /&gt;Sean</description>
      <pubDate>Wed, 29 Oct 2008 19:50:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265038#M44701</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-29T19:50:54Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265039#M44702</link>
      <description>1) We DO have a tNormalize. It's available in the Processing family. 
&lt;BR /&gt;BTW This component is actually generating many rows from one row. 
&lt;BR /&gt;Here is the result that can be easily generated with your input and this component 
&lt;BR /&gt;1|Car|10 
&lt;BR /&gt;1|Car|45 
&lt;BR /&gt;1|Car|50 
&lt;BR /&gt;2|Truck|30 
&lt;BR /&gt;2|Truck|60 
&lt;BR /&gt;2|Truck|15 
&lt;BR /&gt;So this component is probably missing a little option to process your data exactly like you want. 
&lt;BR /&gt;That's why, shong gave you a more complicate example. 
&lt;BR /&gt;2) When you have specific needs, you candevelop your own components. 
&lt;BR /&gt;This is noty very easy but this can be done if you take the time to think about it. 
&lt;BR /&gt;The main requirement to write a component, is to really understand Java. This is not the case of mose ETL users. 
&lt;BR /&gt;3) That's also why we have a 
&lt;A href="http://talendforge.org/bugs" target="_blank" rel="nofollow noopener noreferrer"&gt;bugtracker&lt;/A&gt; where you can ask for new features. 
&lt;BR /&gt;In this place you can directly interfer on Talend's roadmap with your requests. 
&lt;BR /&gt;Maybe in some cases, we don't do it immediately, but in most of the cases, we try to do our best and you see your new feature less than 4 month after in the main product. 
&lt;BR /&gt;If you have urgent need we also have solutions (but I'm sorry this will cost a few money) 
&lt;BR /&gt;Sean, I definetely believe that you will never have such a public place with any proprietary editor. Even when you pay $100K just for the connectors... 
&lt;BR /&gt;Regards,</description>
      <pubDate>Wed, 29 Oct 2008 21:39:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265039#M44702</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-29T21:39:58Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265040#M44703</link>
      <description>mhirt, 
&lt;BR /&gt;I hope you did not misunderstand my note as a criticism. I use Informatica because the company I consult with (a Fortune 500 shop), that is the only official tool. For my other clients, I use ToS which I find is very flexible. I think Informatica is a white elephant. In fact asking for $100K for a connector is a joke (I think it was Lotus Dominos connector). Here we can easily write such a connector. So you guys rock. 
&lt;BR /&gt;I did miss the tNormalize component as I was not dealing with such an issue at this time. That is my oversight and given shong's explanation, I thought this was not possible to do. I'll definitely try it out. 
&lt;BR /&gt;I have also requested features using bug tracker and actually gotten them added very fast (thanks to plegall). 
&lt;BR /&gt;I am trying to read up and get a better understanding of Java as that will give me more flexibility with this tool and enable me to write new connectors/transforms. My limited expertise with Java is something of a limiting factor. 
&lt;BR /&gt;Regards, 
&lt;BR /&gt;Sean</description>
      <pubDate>Thu, 30 Oct 2008 02:26:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265040#M44703</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-30T02:26:53Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265041#M44704</link>
      <description>mhirt, 
&lt;BR /&gt;As with psm2000, by no means is my suggestion a criticism. I think TOS is great and the public exchange is fantastic. I agree, I won't be able to get this flexibility and openness with a proprietary system. However, for this project a proprietary system, even with its limitations, might be the best bet. 
&lt;BR /&gt;tNormalize is missing a lot more than a little option to format the data. It doesn't bring the column names with it, which is a key part of an 'unpiviot' component. From where I sit, I'm not sure if this is possible with the current core. The work around provided, is just that, a work around. This project requires a lot of these transformations and that's certainly not an easy/clean way to do it. 
&lt;BR /&gt;My original posts were asking 2 things: is there an existing way to do this? If not, how do I go about building one? I'm a developer and I'd be interested in contributing. I'm really just looking for an 'in theory you can do this' go-ahead before I spend time trying to learn the inner workings of the framework and build this myself. 
&lt;BR /&gt;So, with your understanding, which is far greater than mine, do you think I can use tNormalize as a template for an 'unpivot' component? Or is something going to stop me from finishing the job? Is it possible to bring the column names with it? 
&lt;BR /&gt;From what I understand now, this feature can't be built using the 'component' extensibility point. If this is not the case, could someone let me know, in pseudo, what steps I need to take? 
&lt;BR /&gt;Thanks, 
&lt;BR /&gt;Dane</description>
      <pubDate>Thu, 30 Oct 2008 14:12:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265041#M44704</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-10-30T14:12:39Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265042#M44705</link>
      <description>Hello Sean and Dane 
&lt;BR /&gt;Don't misunderstand me . I like when the product is criticized. I strongly believe that this is is the goal of an Open Source product. 
&lt;BR /&gt; 
&lt;BLOCKQUOTE&gt; 
 &lt;TABLE border="1"&gt; 
  &lt;TBODY&gt; 
   &lt;TR&gt; 
    &lt;TD&gt;tNormalize is missing a lot more than a little option to format the data. It doesn't bring the column names with it, which is a key part of an 'unpiviot' component. From where I sit, I'm not sure if this is possible with the current core.&lt;/TD&gt; 
   &lt;/TR&gt; 
  &lt;/TBODY&gt; 
 &lt;/TABLE&gt; 
&lt;/BLOCKQUOTE&gt; 
&lt;BR /&gt;This can be done with the existing core and this is not really difficult to implement. 
&lt;BR /&gt; 
&lt;BLOCKQUOTE&gt; 
 &lt;TABLE border="1"&gt; 
  &lt;TBODY&gt; 
   &lt;TR&gt; 
    &lt;TD&gt;So, with your understanding, which is far greater than mine, do you think I can use tNormalize as a template for an 'unpivot' component? Or is something going to stop me from finishing the job? Is it possible to bring the column names with it?&lt;/TD&gt; 
   &lt;/TR&gt; 
  &lt;/TBODY&gt; 
 &lt;/TABLE&gt; 
&lt;/BLOCKQUOTE&gt; 
&lt;BR /&gt;Don't believe that I don't want you to have the pleasure to develop a component but I have just put a tUnpivot base on the tNormalize in the 
&lt;A href="https://community.qlik.com/s/feed/0D53p00007vCpLLCA0" target="_blank" rel="nofollow noopener noreferrer"&gt;https://community.talend.com/t5/Archive/CSV-file-problem/td-p/166946&lt;/A&gt;. It's not very difficult but sincerely, it's maybe a little difficult as a first component. 
&lt;BR /&gt;I have only added an option to tNormalize in Advanced Settings. 
&lt;BR /&gt;Please tell me if it works like you want. 
&lt;BR /&gt;Regards,</description>
      <pubDate>Sat, 01 Nov 2008 01:10:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265042#M44705</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2008-11-01T01:10:31Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265043#M44706</link>
      <description>Thank you for this post. I was able to bring across my Key Column labels using this example, and avoided the tUnPivot and other pain I had there. 
&lt;BR /&gt;I modified this example as follows: 
&lt;BR /&gt;1. added a duplicate Input Delimited that skipped zero header rows, and has a limit of just 1. In other words, it only reads the header row (to get the column names) 
&lt;BR /&gt;2. added a tJavaRow from #1, doing a global PUT of the column headers. Just like the global PUT of the the Amt values in this example. 
&lt;BR /&gt;3. linked #1 ITERATE to the given example, hooking it into the tFileInputDelimited starting point. 
&lt;BR /&gt;Now I have the column headers flowing through alongside the "amount" values from the cross tab. 
&lt;BR /&gt;4. modify the tJavaRow to PUT a string I will parse later in tMap. For me, this is: globalMap.put("Amt1",globalMap.get("ColHeader1") + ";" + row1.amt1); etc through to as many as you need. 
&lt;BR /&gt;The ForEach is unchanged, essentially now providing a parse-able string (semi-colon delimited for me). Now modify the tMap to parse out the combo-value. 
&lt;BR /&gt;5. modify tMap. For ease of readability, I added a variable to get the value from the ForEach: Var.theValue = (String) globalMap.get(((String) globalMap.get("tForeach_1_CURRENT_VALUE"))). Now modify the mapping to parse out the "left" and "right" pieces of the string using the semicolon delimiter. Left side = "StringHandling.LEFT(Var.theValue,StringHandling.INDEX(Var.theValue,";")) ", right side = "StringHandling.RIGHT(Var.theValue,StringHandling.LEN(Var.theValue) - 1 - StringHandling.INDEX(Var.theValue,";")) ". I stored the "left" side into one of the output columns, and stored the "right" side into the other output column. 
&lt;BR /&gt;There you go. The column header labels are 'repeated' into a column. You can modify this as you need, to have as many extra columns headers you like. Just pull them out as per steps 1-3, and then concat them into a parse-able string as per step 4. Pull them back out again as per step 5. 
&lt;BR /&gt;I hope this helps. 
&lt;BR /&gt;--Eric</description>
      <pubDate>Mon, 09 Nov 2009 20:27:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265043#M44706</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2009-11-09T20:27:45Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265044#M44707</link>
      <description>Hi,
&lt;BR /&gt;I have a similar requirement but with a little twist. I have all my metrics coming in one excel sheet in 3 different tables, see the first half of the image attached. 
&lt;BR /&gt;I wish to bring the Months and Years down, and move my 3 Metrics like DSO, etc in the columns, see second half of the image attached. 
&lt;BR /&gt;Kindly suggest how could i achieve the same. 
&lt;BR /&gt;Also the columns in the source i.e months and years would change once in a year when a new year's data would be added, and the old year's data would be removed keeping only 5 years of data at a time. 
&lt;BR /&gt;Your help would be really appreciated.
&lt;BR /&gt;
&lt;BR /&gt;Thanks in advance,
&lt;BR /&gt;Diwakar</description>
      <pubDate>Wed, 31 Aug 2011 11:34:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265044#M44707</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-08-31T11:34:48Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265045#M44708</link>
      <description>Your screenprint seems a bit dodgy: totals don't add up; the numbers don't align between the input and output; you refer to 5 years' data but there are 5 months... 
&lt;BR /&gt;I've assumed that's just because it's not a true example. The following is designed for 5 columns of values and 3 metrics but can be extended for more. There are other assumptions about sorting etc, which can be tweaked as needed. I've avoided tUnpivotRow as I prefer to only use "official" components, even though that might make the job design simpler. 
&lt;BR /&gt;tJavaRow_3 
&lt;PRE&gt;output_row.Metric = input_row.Metric;&lt;BR /&gt;output_row.Country = input_row.Country;&lt;BR /&gt;output_row.Value1 = input_row.Value1;&lt;BR /&gt;output_row.Value2 = input_row.Value2;&lt;BR /&gt;output_row.Value3 = input_row.Value3;&lt;BR /&gt;output_row.Value4 = input_row.Value4;&lt;BR /&gt;output_row.Value5 = input_row.Value5;&lt;BR /&gt;if (tos_count_tFileInputExcel_1&amp;lt;3)&lt;BR /&gt;	globalMap.put(tos_count_tFileInputExcel_1==1?"Years":"Months",new String[] {input_row.Value1,input_row.Value2,input_row.Value3,input_row.Value4,input_row.Value5});&lt;/PRE&gt; 
&lt;BR /&gt;tFilterRow: Country Not Equal To "Country" And Country Not Equal To "Total" 
&lt;BR /&gt;tJavaRow_4 
&lt;PRE&gt;String[] Years  = (String[])globalMap.get("Years");&lt;BR /&gt;String[] Months = (String[])globalMap.get("Months");&lt;BR /&gt;output_row.Metric = input_row.Metric;&lt;BR /&gt;output_row.State = input_row.Country;&lt;BR /&gt;output_row.Values =  Years+","+Months+","+input_row.Value1+";"&lt;BR /&gt;					+Years+","+Months+","+input_row.Value2+";"&lt;BR /&gt;					+Years+","+Months+","+input_row.Value3+";"&lt;BR /&gt;					+Years+","+Months+","+input_row.Value4+";"&lt;BR /&gt;					+Years+","+Months+","+input_row.Value5+";";&lt;/PRE&gt; 
&lt;BR /&gt;tNormalize_1: Values separated by ";" 
&lt;BR /&gt;tExtractDelimitedFields_1: Values separated by ","</description>
      <pubDate>Thu, 01 Sep 2011 01:25:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265045#M44708</guid>
      <dc:creator>alevy</dc:creator>
      <dc:date>2011-09-01T01:25:57Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265046#M44709</link>
      <description>&lt;BLOCKQUOTE&gt;
 &lt;TABLE border="1"&gt;
  &lt;TBODY&gt;
   &lt;TR&gt;
    &lt;TD&gt;Hello&lt;BR /&gt;Here comes a Java scenario, please see the screenshots.&lt;BR /&gt;Input file:&lt;BR /&gt;&lt;B&gt;&lt;BR /&gt;TrxId;Name;Amt1;Amt2;Amt3&lt;BR /&gt;1;Car;10;45;50&lt;BR /&gt;2;Truck;30;60;15&lt;BR /&gt;3;Shong;10;20;30&lt;BR /&gt;&lt;/B&gt;&lt;BR /&gt;Result:&lt;BR /&gt;&lt;B&gt;Starting job topic_4500 at 11:14 24/10/2008.&lt;BR /&gt;1|Car|Amt1|10&lt;BR /&gt;1|Car|Amt2|45&lt;BR /&gt;1|Car|Amt3|50&lt;BR /&gt;2|Truck|Amt1|30&lt;BR /&gt;2|Truck|Amt2|60&lt;BR /&gt;2|Truck|Amt3|15&lt;BR /&gt;3|Shong|Amt1|10&lt;BR /&gt;3|Shong|Amt2|20&lt;BR /&gt;3|Shong|Amt3|30&lt;BR /&gt;Job topic_4500 ended at 11:14 24/10/2008. &lt;BR /&gt;&lt;/B&gt;&lt;BR /&gt;Feel free to post your question!&lt;BR /&gt;Best regards&lt;BR /&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; shong&lt;/TD&gt;
   &lt;/TR&gt;
  &lt;/TBODY&gt;
 &lt;/TABLE&gt;
&lt;/BLOCKQUOTE&gt;
&lt;BR /&gt;Hi shong,
&lt;BR /&gt;can you explain your job?
&lt;BR /&gt;Got the same problem:
&lt;BR /&gt;
&lt;B&gt;ID;Column1,Column2,Column3;...;Column99&lt;BR /&gt;1;25;28;54;...;89&lt;BR /&gt;2;85;65;89;...;78&lt;/B&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;B&gt;expected output:&lt;/B&gt;
&lt;BR /&gt;
&lt;B&gt;ID;Column1&lt;BR /&gt;1;25&lt;BR /&gt;1;28&lt;BR /&gt;1;54&lt;BR /&gt;...&lt;BR /&gt;1;89&lt;BR /&gt;2;85&lt;BR /&gt;2;65&lt;BR /&gt;2;89&lt;BR /&gt;...&lt;BR /&gt;2;78&lt;/B&gt;</description>
      <pubDate>Mon, 01 Jun 2015 15:23:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265046#M44709</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-01T15:23:11Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265047#M44710</link>
      <description>screenshots missing. can someone help me on this?? thanks in Advance</description>
      <pubDate>Fri, 29 Dec 2017 13:42:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265047#M44710</guid>
      <dc:creator>kmrprvn</dc:creator>
      <dc:date>2017-12-29T13:42:34Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265048#M44711</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt; 
&lt;P&gt;Please have a look at this article about:&lt;A title="https://community.talend.com/t5/Migration-Configuration-and/Converting-columns-to-rows/ta-p/21658/jump-to/first-unread-message" href="https://community.qlik.com/s/article/ka03p0000006EZhAAM" target="_self"&gt;https://community.talend.com/t5/Migration-Configuration-and/Converting-columns-to-rows/ta-p/21658/jump-to/first-unread-message&lt;/A&gt;.&lt;/P&gt; 
&lt;P&gt;Best regards&lt;/P&gt; 
&lt;P&gt;Sabrina&lt;/P&gt;</description>
      <pubDate>Tue, 02 Jan 2018 06:42:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265048#M44711</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-02T06:42:44Z</dc:date>
    </item>
    <item>
      <title>Re: How do I 'unpivot' a table?</title>
      <link>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265049#M44712</link>
      <description>Hi Shong, 
&lt;BR /&gt; 
&lt;BR /&gt;i am facing the issue , I need to unpivot the data. i ahve referred to your answer but could not find the screenshots. 
&lt;BR /&gt;Could you please share the screenshots once again. 
&lt;BR /&gt; 
&lt;BR /&gt;Thanks &amp;amp; Regards, 
&lt;BR /&gt;Har**bleep**ha.</description>
      <pubDate>Mon, 17 Sep 2018 13:11:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/How-do-I-unpivot-a-table/m-p/2265049#M44712</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-09-17T13:11:02Z</dc:date>
    </item>
  </channel>
</rss>

