Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
camilo
Contributor III
Contributor III

Join two tables

Hi, I think this is very basic, but if someone can help me I would be very gratefull. I want to join two tables with the same fields:

Ex.

Table 1:

A      B       C

xxx   22    33

Table 2:

A      B       C

YYY   22    43

And I want to create

Table 3:

A      B       C

xxx   22    33

YYY   22    43

Thanks for your help!

1 Solution

Accepted Solutions
martin59
Specialist II
Specialist II

Hi,

Table2 is already concatenate with table1 because they have the same structure

To simplify, you can do this :

Table1:

LOAD *

FROM

(ooxml, embedded labels, table is Hoja1);

Concatenate (Table1)

LOAD *

FROM

(ooxml, embedded labels, table is Hoja1);


Hope that helps you

View solution in original post

5 Replies
nagaiank
Specialist III
Specialist III

This is called concatenation. You can do it as follows:

Table3:

NoConcatenate LOAD * Resident Table1;

Concatenate (Table3) LOAD * Resident Table2;

camilo
Contributor III
Contributor III
Author

Hi, I´m trying to use concatenate in the following example but y got an error msg:

Example:

Test1

abc
pepe1010
jaime1010

Test2

abc
pepe1010
camilo1010

Then  I create the following qvw:

Table1:

LOAD *

FROM

(ooxml, embedded labels, table is Hoja1);

Table2:

LOAD *

FROM

(ooxml, embedded labels, table is Hoja1);

Table3:

NoConcatenate LOAD * Resident Table1;

Concatenate (Table3) LOAD * Resident Table2;

---------------------------

When I load this example I get the following error:

"Table not found

Concatenate (Table3) LOAD * Resident Table2"

Anyway the qvw finish loading with a sinc key (which has all the parameters), and now I have two tables, Table3 and Table1 both equivalents.

martin59
Specialist II
Specialist II

Hi,

Table2 is already concatenate with table1 because they have the same structure

To simplify, you can do this :

Table1:

LOAD *

FROM

(ooxml, embedded labels, table is Hoja1);

Concatenate (Table1)

LOAD *

FROM

(ooxml, embedded labels, table is Hoja1);


Hope that helps you

camilo
Contributor III
Contributor III
Author

Thanks Martin,

It worked prefectly, just one more question, ¿I can concatenate as many tables as I need, using your answer,  as long as they have the same structure?

For example:

Table1:
LOAD *
FROM

(ooxml, embedded labels, table is Hoja1);

Concatenate (Table1)
LOAD *
FROM

(ooxml, embedded labels, table is Hoja1);

Concatenate (Table1)
LOAD *
FROM

(ooxml, embedded labels, table is Hoja1);

martin59
Specialist II
Specialist II

Yes, you can concatenate as many tables you want.

But you can do this :

Table1:

LOAD *

FROM

(ooxml, embedded labels, table is Hoja1);

And you'll load all xlsx files whiwh name begins by "test "

Hope that helps you !