Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Two tables together and where

Hi there,

I have the following problem.

I have two tables:

WH_START:
LOAD RecNo() as Recno,
WM.ID as ID,
WM.DATE as DATE,
WM.MUTATION as MUTATION,
RESIDENT WM
WHERE WM.MUTATION = 'WA'
OR WM.MUTATION = 'NA'
OR WM.MUTATION = 'WI';

WH_END:
LOAD RecNo() as Recno,
WM.ID as ID,
WM.DATE as DATE,
WM.MUTATION as MUTATION,
RESIDENT WM
WHERE NOT WM.MUTATION = 'WA'
AND NOT WM.MUTATION = 'NA'
AND NOT WM.MUTATION = 'WI';

Like you see both tables are from the same "mother" table.

The together they are the mother table 😉

Now is the problem that I want to make a new table from all the rows from the first table and add the rows from the second one.
where (WH_START.Recno + 1) = WH_END.Recno
and WH_START.ID = WH_END.ID

Here i have a example

[View:http://community.qlik.com/cfs-file.ashx/__key/CommunityServer.Discussions.Components.Files/11/1104.MUTATION.xls:550:0]

I hope somebody can help me.

1 Solution

Accepted Solutions
deepakk
Partner - Specialist III
Partner - Specialist III

Hi ,

Join the two table using join key word.

eg:

Load

recno() as StartRecono,

id

from table 1

join

load

recono() as endRecno,

id from Table2

Keep the ID field name as same and change rest of the fields from the both the tables to a different names.

I hope this helps

View solution in original post

2 Replies
deepakk
Partner - Specialist III
Partner - Specialist III

Hi ,

Join the two table using join key word.

eg:

Load

recno() as StartRecono,

id

from table 1

join

load

recono() as endRecno,

id from Table2

Keep the ID field name as same and change rest of the fields from the both the tables to a different names.

I hope this helps

Not applicable
Author

Tnx I think that will work for me 😉