Appending data in a column from new table into existing table without any joins

#1

Hello there,

I seek support in transforming this table. As shown in the image, I am having “Table A” and “Table B”.
Each table is independent to another and there is no join at all.
Now as shown in the bottom picture, I need to copy the values from Table B and paste it in Table A repeatedly until all the rows are filled.

could any one suggest of proceeding this further!!

Regards,
Neelima

0 Likes

#2

Hi there,

I believe there are multiple ways of doing this but one could be you use Concatenate node on Table B (once or twice depending on the difference between rows in Table A and Table B). Then use Joiner with Inner Join and join on Row ID.

Something like this:
ManipulateData

Try it and if any questions or problems I can make you an example.

Br,
Ivan

2 Likes

#3

Hi @ngumpena, Neelima

I have created a suggestion to create the table you want. appending_data_tables.knwf (47.0 KB) . In this workflow the number of extra rows for table B to match the number of rows for table A is calculated. Then then you can use the Column Apender node and filter for the columns you need.

.
Hope this helps you proceeding this further.

gr. Hans

1 Like

#4

Hi,

I don’t know why you are doing this, but in case you are just faking or generating data, you could use the Random Matcher. It will just add the second tables column to rows rows from the first column.

1 Like

#5

Hi Hans,

could you explain me a bit please

0 Likes

#6

Hi Neelima

In my wf, the first step is to find how many rows Table A has more than Table B. That is done with the Extract Tables Dimension and a Math Formula node. These “extra” rows are extracted from Table B (node 1) and added to all the rows from Table B (Concatenate) . Now both tables have an equal number of rows an can be append via the Column Appender. Using the Column Filter you are able to choose the columns you want to use.

gr. Hans

0 Likes

closed #7

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

0 Likes