Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Issue loading tables.

The issue is explained in the PDF which is attached.

Any help is greatly appreciated, unsure of how to reach

the target without using some form of delete-statement.

1 Solution

Accepted Solutions
alexandros17
Partner - Champion III
Partner - Champion III

This is the script,

let me know

Tab1:

LOAD * Inline [

Nbr, Pnbr, Sek, mSek

1,1991,611,1

1,1992,612,1

];

Tab2:

NoConcatenate

LOAD * Inline [

Nbr, Pnbr, Sek, mSek

2,1991,612,0

1,1993,612,1

];

Tab_Tmp:

NoConcatenate

LOAD Nbr as Nbr1, Pnbr as Pnbr, Sek as Sek1, mSek as mSek1 Resident Tab1;

Join

LOAD Nbr as Nbr2, Pnbr as Pnbr, Sek as Sek2, mSek as mSek2 Resident Tab2;

DROP Tables Tab1, Tab2;

Tab_Final:

NoConcatenate

LOAD

  Pnbr,

  If(Nbr2=1 or Nbr2=2, Sek2, Sek1)   as Sek,

  If(Nbr2=1 or Nbr2=2, mSek2, mSek1) as mSek,

  1 as Nbr

Resident Tab_Tmp;

DROP Table Tab_Tmp;

View solution in original post

4 Replies
alexandros17
Partner - Champion III
Partner - Champion III

This is the script,

let me know

Tab1:

LOAD * Inline [

Nbr, Pnbr, Sek, mSek

1,1991,611,1

1,1992,612,1

];

Tab2:

NoConcatenate

LOAD * Inline [

Nbr, Pnbr, Sek, mSek

2,1991,612,0

1,1993,612,1

];

Tab_Tmp:

NoConcatenate

LOAD Nbr as Nbr1, Pnbr as Pnbr, Sek as Sek1, mSek as mSek1 Resident Tab1;

Join

LOAD Nbr as Nbr2, Pnbr as Pnbr, Sek as Sek2, mSek as mSek2 Resident Tab2;

DROP Tables Tab1, Tab2;

Tab_Final:

NoConcatenate

LOAD

  Pnbr,

  If(Nbr2=1 or Nbr2=2, Sek2, Sek1)   as Sek,

  If(Nbr2=1 or Nbr2=2, mSek2, mSek1) as mSek,

  1 as Nbr

Resident Tab_Tmp;

DROP Table Tab_Tmp;

Not applicable
Author

I'm rather new at this point.

If there was a possibility of the table containing

number 3 which would imply that rows in table1

would have to be removed, how would you approach the problem?

alexandros17
Partner - Champion III
Partner - Champion III

Simply add the control on num3 in your if ....

Not applicable
Author

I've been trying but I don't really know the syntax for the exclusion part

in the If-statement. I've attached an updated PDF if there is anyone

whom perhaps have an idea