Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
TimoHart
Contributor III
Contributor III

New Table from 3 filtered CSV files (Transpose - Line by Line)

Hello, 

brand new Qlik User with a massive project ... 

Reinvent a running application using QLIK instead of hardcoded C# . We do have this hardcoded C# exe file which forwards 3 CSV files line by line into a new SQL Master-table. Applying filters deleting empty rows and transpose the data structure. Acctually the transpose function is the major reason we do this line by line. 

Now how will I be able to create this master table in Qlik. The attached picture is just a sample of the first part of the original code - creating the Mastertable from filterd Project table.  Transposing is not shown yet. But I need to know if it is possible at all. 

In Qlik I hardly codes anything yet. BUT in fact what I did so far is not even working out . The where statement is not considered and the table PROJEKTE looks very poor compared to the original CSV there is a lot of data missing. 

Dont be confused because of the xls file extension .. it is a CSV format delimiter Tab. 

Best regards 

Timo  

 

 

Labels (3)
1 Solution

Accepted Solutions
marcus_sommer

Also the opposite of a crosstable-statement is available, see: The Generic Load - Qlik Community - 1473470

But AFAIK it's quite rare that such a data-structure is useful and beneficial against "normal" structures especially in a final data-model and the UI. I suggest not to try to transfer a SQL scheme and/or any programming logic 1:1 to Qlik else to be open to the native features of Qlik especially the associative data-model. 

View solution in original post

16 Replies
vincent_ardiet_
Specialist
Specialist

This is not very clear to me, however, if your goal is to transpose a row of data in multiple rows, I don't think you will be able to do it in a single pass on Qlik neither.
Could you share dummy data how what you have in entry and of what you expect to have in output?

tabletuner
Creator III
Creator III

Maybe you can have a look at the crosstable() function. It is used a lot to transpose tables.

TimoHart
Contributor III
Contributor III
Author

Thank you for your answer... attached I uploaded 2 screenshoots. First shows replication of the actual SAP datasource as a CSV extract. Within this you'll find for each Order (WBS) several network actions (oper/Act)

--> e.g. 34, 45, 100,70etc...

 Second screenshot shows the "final" transposed datatable / mastertable - the network activities are within one row of the corresponding order. 

The source "Order" and "Network Activity" is listed in 2 separet CSV Files / eventually 2 Separete Data Base Tables / SAP Transactions. The linking key is the Order Number (part of the first 11digits of WBS (X)+ the Item (part of last 8digits(Y)) ). 

Q/0XXXXXXXXX-00YY-142

Hope you'll be able to follow this explanation. And even more looking forward to find a solution. 

Best Regards 

Timo 

TimoHart
Contributor III
Contributor III
Author

Hi...  thank you for this idea. If you check my reply to vincent and follow my description you would tell me again that this crosstable () funktion is suitable for me ? 

Where can I study the syntax or have a look on examples .. 

Thanks a lot 

Regards Timo  

TimoHart
Contributor III
Contributor III
Author

Hi again tabletuner...  I checked the crosstable function on the net and even this seems to work perferct to transposte columns in to rows , my problem is completly vise versa. I will need to "filter" and transpose ROW - data into columns . I attached a screenshot trying to explane.. for better understanding. Thanks anyway for the crossfunction hint. Best Regards Timo

TimoHart
Contributor III
Contributor III
Author

Here I add the code of the transpose part .   Will this be possible during data load or is it eventually possible during sheet creation to skript this? 

marcus_sommer

Also the opposite of a crosstable-statement is available, see: The Generic Load - Qlik Community - 1473470

But AFAIK it's quite rare that such a data-structure is useful and beneficial against "normal" structures especially in a final data-model and the UI. I suggest not to try to transfer a SQL scheme and/or any programming logic 1:1 to Qlik else to be open to the native features of Qlik especially the associative data-model. 

TimoHart
Contributor III
Contributor III
Author

to summerice the problem  Statement see here : 

tabletuner
Creator III
Creator III

Timo, you marked the answer of Marcus as solwved. But now you are posting a new post. Is your problem solved or not?  If not I will have a look at it.