Qlik Community

Qlik DataMarket Discussions

Discussion Board for collaboration regarding Qlik DataMarket.

Not applicable

problem with putting a condition about Table name

hi everybody, i have to load different tabs like these:

i have different point of sales and i dont't have an ID inside each point of sales' files.

i need a field that allow me to identified these point of sales for each table.

Trieste:

LOAD TipoDoc,

     NumDoc,

     Famiglia,

     DescFamiglia,

     CodicePLU,

     DescrizionePLU,

     Pezzi,

     Year(DtMov) as Anno,

     Month(DtMov) as Mese,

     Day(DtMov) as Giorno,

     NomeOperatore

FROM

[\\192.168.10.11\d$\CASSE\CasseCei_QW\68474\]TBVENDPC_*.CSV

(txt, codepage is 1252, embedded labels, delimiter is ';', msq);

Udine:

LOAD TipoDoc,

     NumDoc,

     Famiglia,

     DescFamiglia,

     CodicePLU,

     DescrizionePLU,

     Pezzi,

     Year(DtMov) as Anno,

     Month(DtMov) as Mese,

     Day(DtMov) as Giorno,

     NomeOperatore

FROM

[\\192.168.10.11\d$\CASSE\CasseCei_QW\68475\]TBVENDPC_*.CSV

(txt, codepage is 1252, embedded labels, delimiter is ';', msq)

i hope i was clear..... thanks

Tags (1)
3 Replies
MVP
MVP

Re: problem with putting a condition about Table name

May be like this?

Trieste:

LOAD TipoDoc,

    NumDoc,

    Famiglia,

    DescFamiglia,

    CodicePLU,

    DescrizionePLU,

    Pezzi,

    Year(DtMov) as Anno,

    Month(DtMov) as Mese,

    Day(DtMov) as Giorno,

    NomeOperatore,

    'Trieste' as TableName,

    FileBaseName() as SourceCSV

FROM

[\\192.168.10.11\d$\CASSE\CasseCei_QW\68474\]TBVENDPC_*.CSV

(txt, codepage is 1252, embedded labels, delimiter is ';', msq);

Udine:

LOAD TipoDoc,

    NumDoc,

    Famiglia,

    DescFamiglia,

    CodicePLU,

    DescrizionePLU,

    Pezzi,

    Year(DtMov) as Anno,

    Month(DtMov) as Mese,

    Day(DtMov) as Giorno,

    NomeOperatore,

    'Udine' as TableName,

    FileBaseName() as SourceCSV

FROM

[\\192.168.10.11\d$\CASSE\CasseCei_QW\68475\]TBVENDPC_*.CSV

(txt, codepage is 1252, embedded labels, delimiter is ';', msq);

Not applicable

Re: problem with putting a condition about Table name

yes, great! it works, thanks!

MVP
MVP

Re: problem with putting a condition about Table name

Awesome, please close the thread by marking the correct answer in that caseQlik Community Tip: Marking Replies as Correct or Helpful

Best,

Sunny

Community Browser