Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

elena888
Valued Contributor

How to delete some records

Hi!

I have a question regarding delete records during the load, based on the type of some attributes.

Please find attached data and the precise question.

Thanks!

Elena

Tags (2)
1 Solution

Accepted Solutions
MVP
MVP

Re: How to delete some records

Directory;

source:

LOAD ID%,      BARCODE,      TYPE,      NUMBER

FROM

sampledata.xlsx

(ooxml, embedded labels, header is 1 lines, table is Foglio1)

where len(trim(ID%)) > 0;

final:

NoConcatenate load *

Resident source

where

TYPE <> 'DOM'

or ((TYPE = 'DOM') and (Peek(ID%) <> ID% or Peek(TYPE)<>TYPE))

order by ID%, TYPE, NUMBER desc;

DROP Table source;

3 Replies

Re: How to delete some records

Hi,

Here is solution.

Regards,

Kaushik Solanki

MVP
MVP

Re: How to delete some records

Directory;

source:

LOAD ID%,      BARCODE,      TYPE,      NUMBER

FROM

sampledata.xlsx

(ooxml, embedded labels, header is 1 lines, table is Foglio1)

where len(trim(ID%)) > 0;

final:

NoConcatenate load *

Resident source

where

TYPE <> 'DOM'

or ((TYPE = 'DOM') and (Peek(ID%) <> ID% or Peek(TYPE)<>TYPE))

order by ID%, TYPE, NUMBER desc;

DROP Table source;

elena888
Valued Contributor

Re: How to delete some records

Thank you very much, it's very good, but Massimo's solution it's simpler for my purpose.

Thank you to both!

Elena

Community Browser