Created
October 1, 2019 01:38
-
-
Save HenriqueMitsuo/64b739bfc170b8bb1b4fb115c535027f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT DISTINCT produto_nome, estabelecimento_nome, item_valor, item_unidade, unidadetipo.tipo_descricao | |
FROM cotacaoitem | |
INNER JOIN cotacao ON cotacaoitem.item_cotacao | |
INNER JOIN estabelecimento ON cotacao.cotacao_estabelecimento = estabelecimento_codigo | |
INNER JOIN produto ON cotacaoitem.item_produto = produto.produto_codigo | |
INNER JOIN unidadetipo ON cotacaoitem.item_unidade = unidadetipo.tipo_codigo | |
WHERE cotacao.cotacao_datavalidade <= NOW() | |
ORDER BY produto_nome |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment