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

Announcements
Note: You may notice some temporary visual or styling issues in the Community. Our vendor is actively investigating.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How to fill column (A) based on corresponding column (B)

Hi Community,

My dataset includes financial transactions, for example a few columns:

Dataset.PNG

I would like to fill column CREDITOR with "1000" because JOURNALNUMBER is equel to other rows.

Could anyone help me with this please? Thanks a lot!

Grtz,

Pascal

3 Replies
OmarBenSalem
Partner - Champion II
Partner - Champion II

Would this work?

Capture.PNG

OmarBenSalem
Partner - Champion II
Partner - Champion II

or this?

Capture.PNG

t:

load * Inline [

CREDITOR,COSTPLACE,JOURNALNUMBER

1000,,20180001

,4000,20180001

200,4000,20180001

2000,300,20180002

,3000,20180002

500,4000,20180003

];

NoConcatenate

load  if(len(CREDITOR)=0,peek(CREDITOR),CREDITOR) as CREDITOR_New,

CREDITOR,

JOURNALNUMBER , COSTPLACE Resident t Order by JOURNALNUMBER;

drop Table t;

quriouss
Creator III
Creator III

Would it work to do a JOIN?

(untested:)

Table1:

Load

     CREDITOR as CREDITORTEMP,

     COSTPLACE,

     JOURNALNUMBER

From file.qvd;

Left Join (Table1)

Load

     CREDITORTEMP as CREDITOR,

     JOURNALNUMBER

Resident Table1

Where Isnotnull (CREDITOR);

Drop Field CREDITORTEMP;