Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello All,
I have the following data
| Header 1 | Header 2 |
|---|---|
| Subject | Value |
| A | 1 |
| Header 1 | Header 2 |
|---|---|
| Subject | Value |
| A | 2 |
| B | 2 |
| C | 3 |
| D | 3 |
In the first Table Since the Value of Subject A is ! i have no more entries, but in Table 2 Since the Value of A is 2 i have further more entries.
I have a requiriment where i need to add the other Three Subjects(B,C,D...) with Value 1 against each of them.
I'm not sure whether Peek or Lookup would suit my requiriment here.
Expected Result:
| Header 1 | Header 2 |
|---|---|
| Subject | Value |
| A | 1 |
| B | 1 |
| C | 1 |
| D | 1 |
| A | 2 |
| B | 2 |
| C | 3 |
| D | 3 |
Please help me out!!
May be this -
Table2:
LOAD Subject,
Value
FROM
[https://community.qlik.com/thread/299420]
(html, codepage is 1252, embedded labels, table is @2, filters(
Remove(Row, Pos(Top, 1))
));
Concatenate
Load Subject
Resident Table2;
NoConcatenate
Table1:
LOAD Subject,
Value
FROM
[https://community.qlik.com/thread/299420]
(html, codepage is 1252, embedded labels, table is @1, filters(
Remove(Row, Pos(Top, 1))
));
Let Valuevar = Peek('Value',0,'Table1');
NoConcatenate
Final:
Load Subject,
If(Len(Value)=0,'$(Valuevar)',Value) as Value
Resident Table2;
Drop table Table1,Table2;
Let Valuevar =;
Why not Just
Temp:
LOAD
Value
FROM
[https://community.qlik.com/thread/299420]
(html, codepage is 1252, embedded labels, table is @1, filters(
Remove(Row, Pos(Top, 1))
));
Table:
LOAD Subject,
Peek('Value',0,'Temp') as Value
FROM
[https://community.qlik.com/thread/299420]
(html, codepage is 1252, embedded labels, table is @2, filters(
Remove(Row, Pos(Top, 1))
));
Concatenate
Table:
LOAD Subject,
Value
FROM
[https://community.qlik.com/thread/299420]
(html, codepage is 1252, embedded labels, table is @2, filters(
Remove(Row, Pos(Top, 1))
));
Drop table Temp;