Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

Remove the last row / Max Row

I have a table of file names and I want to load all files except last file (max number). I will use "for loop" to load files. How can I remove last row from the table

FileName

1

2

3

4

I want

FileName

1

2

3

Tags (2)
1 Solution

Accepted Solutions
Not applicable

Re: Remove the last row / Max Row

Hi

Please have a look this one.

Thanks

3 Replies
Not applicable

Re: Remove the last row / Max Row

Hi

Please have a look this one.

Thanks

Not applicable

Re: Remove the last row / Max Row

Hi Naskar,

Can you please explain the procedure to achieve.

As I'm using personal edition.

Thanks in Advance.

Regards,

Pavan.

Not applicable

Re: Remove the last row / Max Row

Hi

Please try this script :

Loading data form Source :

Temp_Data:
LOAD FileName,
rowno() as Recno
FROM
Data2.xlsx
(
ooxml, embedded labels, table is Sheet1);
Find the last record form source:
LoadMax:
Load max(Recno) as Recno1 Resident Temp_Data;

Let vMaxNo=Peek('Recno1',0,'LoadMax');

Data:
NoConcatenate
LOAD
*
Resident Temp_Data where Recno<>$(vMaxNo);

Drop tables Temp_Data,LoadMax;

Thanks

Community Browser