| From: | Ranier Vilela <ranier(dot)vf(at)gmail(dot)com> |
|---|---|
| To: | Leandro Guimarães Faria Corcete DUTRA <l(at)dutras(dot)org> |
| Cc: | Comunidade PostgreSQL Brasileira <pgsql-pt-geral(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: UPDATE COM SELECT |
| Date: | 2021-03-31 23:33:36 |
| Message-ID: | CAEudQAr=wtmTFLfGNrRHUSTVNADKqiDay59WXQP6646-svF5tA@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-pt-geral |
Em qua., 31 de mar. de 2021 às 20:08, Leandro Guimarães Faria Corcete DUTRA
<l(at)dutras(dot)org> escreveu:
> Le mer. 31 mars 2021 à 20:06, Ranier Vilela <ranier(dot)vf(at)gmail(dot)com> a
> écrit :
> > A "query" funciona parcialmente.
>
> Estrutura das tabelas?
>
Segue um exemplo contido das estruturas:
DROP TABLE IF EXISTS tbContas;
DROP TABLE IF EXISTS tbLancamentos;
CREATE TABLE tbContas (
ContaID INT PRIMARY KEY,
Debitos Numeric(18,2),
Creditos Numeric(18,2));
CREATE TABLE tbLancamentos (
ContaDebID INT,
ContaCrdID INT,
Valor Numeric(18,2));
INSERT INTO tbContas (ContaID) Values(6);
INSERT INTO tbContas (ContaID) Values(9);
INSERT INTO tbLancamentos (ContaDebID, ContaCrdID, Valor) Values(6, 9, 100);
INSERT INTO tbLancamentos (ContaDebID, ContaCrdID, Valor) Values(9, 6,
120);
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Arthur Nascimento | 2021-04-01 01:46:00 | Re: UPDATE COM SELECT |
| Previous Message | Leandro Guimarães Faria Corcete DUTRA | 2021-03-31 23:08:37 | Re: UPDATE COM SELECT |