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

Announcements
Qlik and ServiceNow Partner to Bring Trusted Enterprise Context into AI-Powered Workflows. Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Operações entre QVDs

Boa tarde!

Possuo o seguinte comando

select data, codigo, guia from tabela1 where data = 'YYYY/MM'

MINUS

select data, codigo, guia from tabela2 where data = 'YYYY/MM'

Gostaria de saber como realizar este comando fazendo a busca por qvd.. ou seja...

load data, codigo, guia from tab1.qvd where data = 'YYYY/MM'

MINUS

load data, codigo, guia from tab2.qvd where data = 'YYYY/MM'

Existe esta possibilidade?

Labels (1)
1 Reply
rbecher
Partner - Master III
Partner - Master III

Boa noite,

MINUS não é possível. Tente usar "not existe":

Primeiro:

Tmp:
LOAD DISTINCT data & codigo & guia AS LOOKUP
FROM tab2.qvd
WHERE data = 'YYYY/MM';


Então:

Result:
LOAD data, codigo, guia
FROM tab1.qvd
WHERE not exists(LOOKUP, data & codigo & guia)
and data = 'YYYY/MM';
DROP TABLE Tmp;


Espero que isso ajude.

- Ralf



Data & AI Engineer at Orionbelt.ai - a GenAI Semantic Layer Venture, Inventor of Astrato Engine