Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

ericarru
Contributor

Load data from Two or more Tables simultaneously

Hi, the idea behind my question is so simple, and I think that the solution will be so. I have two tables loaded from excels with different data and, to create a 3rd one I need to access on both simultaneously :

Table 1:   [Product Serial Number]

                [Failure Date]

Table 2:  [Product Serial Number]

               [Product Installation Date]

My aim is to create a 3rd table with the amount of time between [Failure Date] - [Installation Date] as a variable.

Nowadays my solution is to left joint table 1 and table 2 but what I want is to have It in separate if it is possible.

Tags (1)
11 Replies

Re: Load data from Two or more Tables simultaneously

If you want you can use a mapping table and the applymap function. See this blog post: Don't join - use Applymap instead


talk is cheap, supply exceeds demand
kalyanivintha1
Contributor II

Re: Load data from Two or more Tables simultaneously

Hi,

you can use the resident load,

Table3:

load

[Failure Date] - [Installation Date] as a variable

resident Table1:

resident Table2;

ericarru
Contributor

Re: Load data from Two or more Tables simultaneously

Thank You very much, but, is in this case better the double resident load (if it really exists) if the map is not used in anywhere else?

ericarru
Contributor

Re: Load data from Two or more Tables simultaneously

Thank you very much, but this code is not accepted by my QV Smiley Frustrated

kalyanivintha1
Contributor II

Re: Load data from Two or more Tables simultaneously

Ok,

after applying resident load......

you got any error message or

what is our error exactly?

and

why your application not accepted this,is there any reason?

Re: Load data from Two or more Tables simultaneously

Why do you think you need a double resident load?


talk is cheap, supply exceeds demand
ericarru
Contributor

Re: Load data from Two or more Tables simultaneously

Well, the solution you propose is really good, but maybe I do not need to  create a map table and by loading the data from the two tables at the same time is enough to construct by new variable. Actually is just the most obvious (but maybe not the best) option to pick the data from the two tables. 

Highlighted
ericarru
Contributor

Re: Load data from Two or more Tables simultaneously

Qlikview does not liked it and just load the first table. I tryed with " : " and " ; "  on each of the statements but it does not work. Simply, when you write the code the "resident" words is not in blue and when you load qlikview tells you that he does not found the field related to the second resident.

kalyanivintha1
Contributor II

Re: Load data from Two or more Tables simultaneously

Hello Eric,

I think,

this error means,

qlikview not allows the two resident statements in single table.(means we can't use the to resident statement side by side).

and

its better to combined the table1 and table2  as a single table(Table1)with using any join statement or with concatenation statement,

then use the resident load,

Table3:

load

[Failure Date] - [Installation Date] as a variable

resident Table1;



Thanq.


Community Browser