Return Return       Update Update       PDF PDF     

Database : Statistics of activity Database : Statistics of activity
datid
oid(10)
datname
name(2147483647)
pid
int4(11)
leader_pid
int4(11)
usesysid
oid(10)
usename
name(2147483647)
application_name
text(2147483647)
client_addr
inet(2147483647)
client_hostname
text(2147483647)
client_port
int4(11)
backend_start
timestamptz(35)
xact_start
timestamptz(35)
query_start
timestamptz(35)
state_change
timestamptz(35)
wait_event_type
text(2147483647)
wait_event
text(2147483647)
state
text(2147483647)
backend_xid
xid(2147483647)
backend_xmin
xid(2147483647)
query_id
int8(20)
query
text(2147483647)
backend_type
text(2147483647)
5postgres896 10rdsadminpg_cron scheduler   2025-06-01 22:10:25.23949-03   ExtensionExtension   804233201376169930 pg_cron launcher
  897 10rdsadmin    2025-06-01 22:10:25.239681-03   ActivityLogicalLauncherMain     logical replication launcher
16450fiscal8205 16402postgresfiscal-intelligence-sped-analises-job10.0.16.217 423072025-08-20 09:17:02.00411-03 2025-08-20 09:17:02.038292-032025-08-20 09:17:02.038302-03ClientClientReadidle   COMMITclient backend
5postgres28825 3333668727rdsproxyadmin 10.0.16.46 80832025-08-20 05:20:00.088931-03 2025-08-20 09:18:40.9292-032025-08-20 09:18:40.929291-03ClientClientReadidle  2731926746234896378SELECT current_setting('transaction_read_only') AS transaction_read_only, current_setting('max_connections') AS max_connections, EXTRACT(EPOCH FROM now() - pg_postmaster_start_time()) AS uptime;client backend
5postgres28828 3333668727rdsproxyadmin 10.0.16.225 232232025-08-20 05:20:00.182059-03 2025-08-20 09:18:40.514281-032025-08-20 09:18:40.514373-03ClientClientReadidle  2731926746234896378SELECT current_setting('transaction_read_only') AS transaction_read_only, current_setting('max_connections') AS max_connections, EXTRACT(EPOCH FROM now() - pg_postmaster_start_time()) AS uptime;client backend
5postgres28829 3333668727rdsproxyadmin 10.0.16.91 300952025-08-20 05:20:00.325848-03 2025-08-20 09:18:40.758898-032025-08-20 09:18:40.75897-03ClientClientReadidle  2731926746234896378SELECT current_setting('transaction_read_only') AS transaction_read_only, current_setting('max_connections') AS max_connections, EXTRACT(EPOCH FROM now() - pg_postmaster_start_time()) AS uptime;client backend
3333716331revizia1550 16402postgresgo-sped-api10.0.16.217 550412025-08-20 09:14:04.058796-03 2025-08-20 09:17:34.362458-032025-08-20 09:17:34.377168-03ClientClientReadidle   
select distinct e.cnpj
from empresa e
inner join conta_empresa ce on ce.empresa_id = e.id
inner join conta c on c.id = ce.conta_id
where substr(e.cnpj,1,8) = $1
and c.status in ('ATIVO', 'TRIAL')
and c.deleted = false
and e.deleted = false
and ce.deleted = false
client backend
5postgres28830 3333668727rdsproxyadmin 10.0.20.107 206352025-08-20 05:20:00.344789-03 2025-08-20 09:18:40.218835-032025-08-20 09:18:40.21892-03ClientClientReadidle  2731926746234896378SELECT current_setting('transaction_read_only') AS transaction_read_only, current_setting('max_connections') AS max_connections, EXTRACT(EPOCH FROM now() - pg_postmaster_start_time()) AS uptime;client backend
5postgres21304 3333668727rdsproxyadmin 10.0.20.66 282452025-08-20 04:54:00.930344-03 2025-08-20 09:18:40.903327-032025-08-20 09:18:40.903413-03ClientClientReadidle  2731926746234896378SELECT current_setting('transaction_read_only') AS transaction_read_only, current_setting('max_connections') AS max_connections, EXTRACT(EPOCH FROM now() - pg_postmaster_start_time()) AS uptime;client backend
3333716331revizia16722 16402postgresmensageria-api10.0.16.91 164632025-08-20 08:44:01.115353-03 2025-08-20 09:18:32.341912-032025-08-20 09:18:32.342125-03ClientClientReadidle    client backend
5postgres28831 3333668727rdsproxyadmin 10.0.16.217 148932025-08-20 05:20:00.356067-03 2025-08-20 09:18:40.383506-032025-08-20 09:18:40.383591-03ClientClientReadidle  2731926746234896378SELECT current_setting('transaction_read_only') AS transaction_read_only, current_setting('max_connections') AS max_connections, EXTRACT(EPOCH FROM now() - pg_postmaster_start_time()) AS uptime;client backend
16450fiscal31055 16402postgresfiscal-intelligence-sped-analises-job10.0.20.107 221852025-08-20 09:09:05.607264-03 2025-08-20 09:18:40.608801-032025-08-20 09:18:40.61025-03ClientClientReadidle   COMMITclient backend
5postgres28836 3333668727rdsproxyadmin 10.0.16.55 560092025-08-20 05:20:00.567165-03 2025-08-20 09:18:40.700556-032025-08-20 09:18:40.700634-03ClientClientReadidle  2731926746234896378SELECT current_setting('transaction_read_only') AS transaction_read_only, current_setting('max_connections') AS max_connections, EXTRACT(EPOCH FROM now() - pg_postmaster_start_time()) AS uptime;client backend
5postgres28837 3333668727rdsproxyadmin 10.0.16.232 645812025-08-20 05:20:00.789194-03 2025-08-20 09:18:40.52158-032025-08-20 09:18:40.52166-03ClientClientReadidle  2731926746234896378SELECT current_setting('transaction_read_only') AS transaction_read_only, current_setting('max_connections') AS max_connections, EXTRACT(EPOCH FROM now() - pg_postmaster_start_time()) AS uptime;client backend
16450fiscal1019 16402postgrespostgres_fdw127.0.0.1 255962025-08-20 09:13:00.711606-03 2025-08-20 09:17:44.167409-032025-08-20 09:17:44.167431-03ClientClientReadidle  -4518006279650829961ABORT TRANSACTIONclient backend
16450fiscal6094 16402postgrespostgres_fdw127.0.0.1 336422025-08-20 09:16:01.00217-03 2025-08-20 09:16:27.054381-032025-08-20 09:16:27.05441-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents2982 16402postgrescfe-job-download-documentos-recorrentes10.0.20.66 124392025-08-20 07:03:02.694032-03 2025-08-20 09:18:19.853842-032025-08-20 09:18:19.855307-03ClientClientReadidle   COMMITclient backend
16450fiscal8398 16402postgreslambda-go-revizia-metrics10.0.20.107 594812025-08-20 09:18:05.790771-03 2025-08-20 09:18:06.99175-032025-08-20 09:18:06.995952-03ClientClientReadidle  -6488867169811202377
WITH numeracoes AS (
SELECT
COUNT(CASE WHEN nu.utilizado = 'SIM' THEN 1 END) AS qtd_numeracao_utilizada,
COUNT(CASE WHEN nu.utilizado = 'NAO' THEN 1 END) AS qtd_numeracao_disponivel
FROM numeracao_utilizada nu
JOIN controle_numeracao cn ON nu.controle_numeracao_id = cn.id
WHERE cn.id = (SELECT MAX(id) FROM controle_numeracao)
),
notas_emitidas AS (
SELECT
to_char(data_rps, 'YYYY-MM') AS periodo,
COUNT(1) AS quantidade_notas_emitidas
FROM dados_emissao_nfse
WHERE serie_rps = '01SN'
GROUP BY to_char(data_rps, 'YYYY-MM')
ORDER BY to_char(data_rps, 'YYYY-MM') DESC
LIMIT 1
)
SELECT
n.qtd_numeracao_utilizada QtdUtilizada,
n.qtd_numeracao_disponivel QtdDisponivel,
ne.periodo Periodo,
ne.quantidade_notas_emitidas QtdNotasEmitidas
FROM numeracoes n
CROSS JOIN notas_emitidas ne
client backend
3333716331revizia8399 16402postgreslambda-go-revizia-metrics10.0.16.91 296812025-08-20 09:18:05.930963-03 2025-08-20 09:18:07.46934-032025-08-20 09:18:20.722719-03ClientClientReadidle  957357389483338053
select e.cnpj as CNpj,
(dsc is null) as NovaEmpresa,
dsc.data_inicio as DataInicio,
dsc.data_fim as DataFim
from certificado c
left join lateral (select ce2.id,
ce2.certificado_id,
ce2.empresa_id,
ce2.created_at
from conta_empresa ce2
left join empresa e2 on (ce2.empresa_id = e2.id)
where ce2.certificado_id = c.id
and ce2.empresa_id = (select e3.id
from empresa e3
inner join conta_empresa ce3 on e3.id = ce3.empresa_id
inner join certificado c3 on ce3.certificado_id = c3.id
where substring(e3.cnpj,1,8) = substring(e2.cnpj,1,8)
and c3.data_expiracao > NOW()
and e3.tipo_empresa = 'MATRIZ'
limit 1)
and c.data_expiracao > NOW()
and e2.tipo_empresa = 'MATRIZ'
order by created_at desc
limit 1) ce on (true)
left join empresa e on (ce.empresa_id = e.id)
left join download_sped_controle_empresa dsc on (dsc.conta_empresa_id = ce.id)
where ce.id is not null
and e.tipo_empresa = 'MATRIZ'
order by (dsc is null), dsc.data_inicio, ce.created_at desc
client backend
1665815312documents8208 16402postgresnfe-lambda-aws10.0.16.55 220292025-08-20 09:17:02.389778-03 2025-08-20 09:18:33.483154-032025-08-20 09:18:33.485624-03ClientClientReadidle   COMMITclient backend
16450fiscal31053 16402postgresfiscal-intelligence-sped-analises-job10.0.16.232 212492025-08-20 09:09:05.197884-03 2025-08-20 09:16:32.962443-032025-08-20 09:16:32.962468-03ClientClientReadidle   COMMITclient backend
3333716331revizia24034 16402postgrescore-api10.0.20.66 70252025-08-20 08:56:05.133393-03 2025-08-20 09:18:40.945226-032025-08-20 09:18:40.945269-03ClientClientReadidle   COMMITclient backend
16450fiscal8431 16402postgresfiscal-intelligence-sped-job10.0.16.91 279452025-08-20 09:18:13.104156-03 2025-08-20 09:18:40.960921-032025-08-20 09:18:40.960995-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents1023 16402postgrescte-lambda-aws10.0.16.46 42792025-08-20 09:13:02.251755-03 2025-08-20 09:18:38.556649-032025-08-20 09:18:38.55898-03ClientClientReadidle   COMMITclient backend
1665815312documents645 16402postgresintegracao-fluxo-pagamento-worker10.0.16.232 229092025-08-20 09:12:08.070522-03 2025-08-20 09:18:38.615791-032025-08-20 09:18:38.615803-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents3673 16402postgresPostgreSQL JDBC Driver10.0.16.91 86012025-08-20 09:15:10.05127-03 2025-08-20 09:18:27.881435-032025-08-20 09:18:28.301667-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, ARRAY_TO_STRING( ARRAY( select distinct item.produto -> 'prod' ->> 'cfop' as cfop from jsonb_array_elements(d.data -> 'nfe' -> 'infNFe' -> 'det') WITH ORDINALITY item(produto) ), ', ' ) as cfops, cast(d.data -> 'nfe' -> 'infNFe' -> 'ide' ->> 'nnf' as int8) AS numeroNota FROM document d WHERE d.cnpj_issuer = $1 AND d.data_emissao BETWEEN ($2) AND ($3) AND ($4 = 'nao_filtrar_ie' OR d.data -> 'nfe' -> 'infNFe' -> 'emit' ->> 'ie' =$5) AND (d.data_entrada_saida IS NULL OR d.data_entrada_saida BETWEEN ($6) AND ($7)) AND d.type IN ('NFE_4_0', 'NFE_3_1') AND EXISTS ( SELECT 1 FROM document_status ds WHERE d.key = ds.key AND d.cnpj_issuer = ds.cnpj_issuer AND d.protocol = ds.protocol AND d.nsu = ds.nsu AND d.type = ds.type and ds.status <> '2' ) ORDER BY d.data_emissao LIMIT $8 OFFSET $9 client backend
1665815312documents31613 16402postgresintegracao-fluxo-pagamento-worker10.0.16.225 165852025-08-20 09:10:01.869961-03 2025-08-20 09:18:41.028278-032025-08-20 09:18:41.029387-03ClientClientReadidle   ROLLBACKclient backend
16450fiscal31060 16402postgresPostgreSQL JDBC Driver10.0.28.38 438882025-08-20 09:09:06.036666-03 2025-08-20 09:09:07.31668-032025-08-20 09:09:07.316729-03ClientClientReadidle   SET application_name = 'PostgreSQL JDBC Driver'client backend
1665815312documents31160 16402postgrescfe-job-download-documentos-recorrentes10.0.16.232 587092025-08-20 09:09:19.968707-03 2025-08-20 09:18:22.902679-032025-08-20 09:18:22.90398-03ClientClientReadidle   COMMITclient backend
1665815312documents8209 16402postgresnfe-lambda-aws10.0.16.55 385972025-08-20 09:17:02.403481-03 2025-08-20 09:18:39.448429-032025-08-20 09:18:39.450833-03ClientClientReadidle   COMMITclient backend
1665815312documents12117 16402postgresnfe-lambda-aws10.0.16.232 247492025-08-20 08:35:02.577845-03 2025-08-20 09:17:43.481932-032025-08-20 09:17:43.484423-03ClientClientReadidle   COMMITclient backend
1665815312documents1601 16402postgresnfe-lambda-aws10.0.16.55 471352025-08-20 09:14:10.182228-03 2025-08-20 09:17:02.420688-032025-08-20 09:17:02.422692-03ClientClientReadidle   COMMITclient backend
1665815312documents1024 16402postgresPostgreSQL JDBC Driver10.0.16.232 564592025-08-20 09:13:02.540252-03 2025-08-20 09:16:33.324764-032025-08-20 09:16:33.326081-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, ARRAY_TO_STRING( ARRAY( select distinct item.produto -> 'prod' ->> 'cfop' as cfop from jsonb_array_elements(d.data -> 'nfe' -> 'infNFe' -> 'det') WITH ORDINALITY item(produto) ), ', ' ) as cfops, cast(d.data -> 'nfe' -> 'infNFe' -> 'ide' ->> 'nnf' as int8) AS numeroNota FROM document d WHERE d.cnpj_issuer = $1 AND d.data_emissao BETWEEN ($2) AND ($3) AND ($4 = 'nao_filtrar_ie' OR d.data -> 'nfe' -> 'infNFe' -> 'emit' ->> 'ie' =$5) AND (d.data_entrada_saida IS NULL OR d.data_entrada_saida BETWEEN ($6) AND ($7)) AND d.type IN ('NFE_4_0', 'NFE_3_1') AND EXISTS ( SELECT 1 FROM document_status ds WHERE d.key = ds.key AND d.cnpj_issuer = ds.cnpj_issuer AND d.protocol = ds.protocol AND d.nsu = ds.nsu AND d.type = ds.type and ds.status <> '2' ) ORDER BY d.data_emissao LIMIT $8 OFFSET $9 client backend
5postgres18477 16402postgrespgAdmin 4 - DB:postgres10.0.28.38 489942025-08-14 23:15:09.263878-03 2025-08-14 23:15:56.206301-032025-08-14 23:15:56.206759-03ClientClientReadidle  -5131504417054470966/*pga4dash*/
SELECT
gid,
database,
owner,
transaction,
pg_catalog.to_char(prepared, 'YYYY-MM-DD HH24:MI:SS TZ') AS prepared
FROM
pg_catalog.pg_prepared_xacts
ORDER BY
gid, database, owner
client backend
16450fiscal6097 16402postgrespostgres_fdw127.0.0.1 336522025-08-20 09:16:01.151983-03 2025-08-20 09:16:05.008258-032025-08-20 09:16:05.008308-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
16450fiscal3680 16402postgresfiscal-intelligence-sped-analises-job10.0.16.232 351252025-08-20 09:15:12.860917-032025-08-20 09:18:39.566095-032025-08-20 09:18:39.566471-032025-08-20 09:18:39.566471-03ClientClientWriteactive 792182431  SELECT bkl.index, bkl.native_line AS nativeLine, bkl.parent_line_id AS parentLineId FROM book_keeping_line bkl WHERE bkl.book_keeping_id = $1 AND bkl.identifier = $2 AND bkl.cnpj_raiz = SUBSTRING($3, 1, 8) client backend
1665815312documents3699 16402postgresnfse-lambda-aws10.0.16.46 374312025-08-20 09:15:16.014104-03 2025-08-20 09:17:13.250697-032025-08-20 09:17:13.253943-03ClientClientReadidle   COMMITclient backend
16450fiscal31097 16402postgresPostgreSQL JDBC Driver10.0.28.38 438982025-08-20 09:09:10.32877-03 2025-08-20 09:09:11.620179-032025-08-20 09:09:11.620202-03ClientClientReadidle   SET application_name = 'PostgreSQL JDBC Driver'client backend
1665815312documents8212 16402postgresnfse-lambda-aws10.0.16.91 291772025-08-20 09:17:04.753407-03 2025-08-20 09:17:13.682288-032025-08-20 09:17:13.684141-03ClientClientReadidle   COMMITclient backend
16450fiscal6098 16402postgresfiscal-intelligence-sped-job10.0.16.217 512232025-08-20 09:16:01.237676-03 2025-08-20 09:16:36.84524-032025-08-20 09:16:36.845462-03ClientClientReadidle   COMMITclient backend
16450fiscal3700 16402postgresfiscal-intelligence-api10.0.16.225 652032025-08-20 09:15:20.475612-03 2025-08-20 09:18:15.246403-032025-08-20 09:18:15.246426-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents1175 16402postgresPostgreSQL JDBC Driver10.0.20.66 122192025-08-20 09:13:14.179583-03 2025-08-20 09:16:19.199613-032025-08-20 09:16:19.207144-03ClientClientReadidle   SELECT doc.key, cast(doc.data -> 'nfe' -> 'infNFe' -> 'total' -> 'icmsTot' ->> 'vicms' as numeric) as valor_icms, cast(doc.data -> 'nfe' -> 'infNFe' -> 'total' -> 'icmsTot' ->> 'vipi' as numeric) as valor_ipi FROM document doc WHERE doc.type in ('NFE_3_1', 'NFE_4_0') and doc.key in ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11) and data_emissao between $12 and $13 and cast(doc.data -> 'nfe' -> 'infNFe' -> 'total' -> 'icmsTot' ->> 'vicms' as numeric) > 0client backend
16384rdsadmin2827 10rdsadminPostgreSQL JDBC Driver  -12025-08-06 22:36:26.318279-03 2025-08-20 09:18:38.31221-032025-08-20 09:18:38.312228-03ClientClientReadidle   SELECT value FROM rds_heartbeat2client backend
16450fiscal31129 16402postgresPostgreSQL JDBC Driver10.0.28.38 388862025-08-20 09:09:13.985644-03 2025-08-20 09:09:15.281422-032025-08-20 09:09:15.281434-03ClientClientReadidle   SET application_name = 'PostgreSQL JDBC Driver'client backend
1665815312documents27196 16402postgresnfe-lambda-aws10.0.16.46 186892025-08-20 09:02:03.358514-03 2025-08-20 09:17:28.675282-032025-08-20 09:17:28.677497-03ClientClientReadidle   COMMITclient backend
1665815312documents787 16402postgrescfe-job-download-documentos-recorrentes10.0.16.55 39032025-08-20 09:12:24.177484-03 2025-08-20 09:18:19.767316-032025-08-20 09:18:19.768244-03ClientClientReadidle   COMMITclient backend
16450fiscal8213 16402postgresprocessador-linhas-sped-job10.0.16.55 375572025-08-20 09:17:05.127449-03 2025-08-20 09:17:05.634541-032025-08-20 09:17:05.634592-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents30310 16402postgresmensageria-api10.0.16.232 73052025-08-20 09:08:21.929428-03 2025-08-20 09:17:05.234631-032025-08-20 09:17:05.234667-03ClientClientReadidle    client backend
5postgres8914 16402postgrespgAdmin 4 - CONN:979965810.0.28.38 436582025-08-19 14:09:01.738165-03 2025-08-20 07:48:07.234469-032025-08-20 07:48:07.234535-03ClientClientReadidle   SELECT oid, pg_catalog.format_type(oid, NULL) AS typname FROM pg_catalog.pg_type WHERE oid = ANY($1) ORDER BY oid;client backend
3333716331revizia20292 16402postgres 10.0.28.38 433362025-08-19 22:25:37.452045-03 2025-08-20 09:18:37.148667-032025-08-20 09:18:37.148694-03ClientClientReadidle  7088996947831101750ROLLBACKclient backend
1665815312documents1602 16402postgresnfe-lambda-aws10.0.20.107 134432025-08-20 09:14:10.200008-03 2025-08-20 09:18:33.416386-032025-08-20 09:18:33.419052-03ClientClientReadidle   COMMITclient backend
1665815312documents18079 16402postgresmensageria-api10.0.16.55 171072025-08-20 08:47:10.662814-03 2025-08-20 09:18:40.665343-032025-08-20 09:18:40.666867-03ClientClientReadidle   COMMITclient backend
16384rdsadmin3019 10rdsadmin   -12025-08-06 22:37:26.899544-03 2025-08-20 09:18:40.571572-032025-08-20 09:18:40.57167-03ClientClientReadidle  3694949039461716331COMMITclient backend
3333716331revizia31615 16402postgrescore-api10.0.20.66 484552025-08-20 09:10:02.775984-03 2025-08-20 09:17:01.025786-032025-08-20 09:17:01.025855-03ClientClientReadidle   COMMITclient backend
16450fiscal22396 3305731552dev_rafael_carvalhopgAdmin 4 - CONN:161606910.0.28.38 589722025-08-19 18:59:10.168301-03 2025-08-19 18:59:12.08893-032025-08-19 18:59:12.096196-03ClientClientReadidle  -6488867169811202377UPDATE public.document_analysis
SET status = 'ERROR'
WHERE status = 'PROCESSING'
AND updated_at < NOW() - INTERVAL '1 hour';
client backend
3333716331revizia8440 16402postgrespostgres_fdw127.0.0.1 460222025-08-20 09:18:15.598734-03 2025-08-20 09:18:16.670253-032025-08-20 09:18:16.670432-03ClientClientReadidle  -4518006279650829961ABORT TRANSACTIONclient backend
1665815312documents3929 16402postgrescfe-job-download-documentos10.0.16.232 616212025-08-20 09:15:34.832859-03 2025-08-20 09:18:39.590121-032025-08-20 09:18:39.590176-03ClientClientReadidle    client backend
1665815312documents26849 16402postgrescfe-job-download-documentos-recorrentes10.0.16.225 324032025-08-20 09:01:06.686214-03 2025-08-20 09:18:22.889152-032025-08-20 09:18:22.890387-03ClientClientReadidle   COMMITclient backend
1665815312documents1603 16402postgresnfe-lambda-aws10.0.20.107 303772025-08-20 09:14:10.202498-03 2025-08-20 09:18:38.750732-032025-08-20 09:18:38.753543-03ClientClientReadidle   COMMITclient backend
3333716331revizia1604 16402postgresnfe-lambda-aws10.0.16.91 336992025-08-20 09:14:10.41794-03 2025-08-20 09:18:33.554926-032025-08-20 09:18:33.555513-03ClientClientReadidle   SELECT ce.conta_id FROM conta_empresa ce INNER JOIN empresa e ON ce.empresa_id = e.id INNER JOIN conta c on ce.conta_id = c.id WHERE e.cnpj IN ($1, $2) AND c.status = 'ATIVO' AND c.id <> 1 LIMIT 1client backend
1665815312documents8447 16402postgrescfe-job-download-documentos-recorrentes10.0.20.66 277072025-08-20 09:18:19.716081-03 2025-08-20 09:18:19.843492-032025-08-20 09:18:19.843525-03ClientClientReadidle   COMMITclient backend
16450fiscal4302 16402postgresfiscal-intelligence-sped-api10.0.16.232 259912025-08-20 09:15:42.084067-03 2025-08-20 09:18:16.009092-032025-08-20 09:18:16.009136-03ClientClientReadidle   ROLLBACKclient backend
3333716331revizia8448 16402postgresrvz-sintegra-job10.0.16.55 367532025-08-20 09:18:20.455448-03 2025-08-20 09:18:40.973453-032025-08-20 09:18:40.973474-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents8215 16402postgreslambda-go-revizia-metrics10.0.20.107 497792025-08-20 09:17:05.610824-03 2025-08-20 09:18:07.116297-032025-08-20 09:18:07.404754-03ClientClientReadidle  4519062602456696998select Count(*) as "Qtd", Status, recorrente as "Recorrente"
from cfe_periodo_importacao_job
where 1=1
and data_fim <= now()
and status in ('PENDENTE','CONCLUIDO','EM_PROCESSAMENTO','COM_ERRO','COM_ERRO_PERMANENTE') --COM_ERRO_PERMANENTE,SEM_CERTIFICADO
and status is not null
group by status, recorrente
client backend
3333716331revizia7241 16402postgrescore-api10.0.16.91 554312025-08-20 08:26:10.789835-03 2025-08-20 09:18:40.26754-032025-08-20 09:18:40.267596-03ClientClientReadidle   COMMITclient backend
1665815312documents3714 16402postgrescfe-job-download-documentos10.0.16.46 199032025-08-20 09:15:26.335485-03 2025-08-20 09:18:40.586957-032025-08-20 09:18:40.586981-03ClientClientReadidle    client backend
3333716331revizia8449 16402postgresrvz-sintegra-job10.0.20.66 158532025-08-20 09:18:20.455813-03 2025-08-20 09:18:40.97711-032025-08-20 09:18:40.977184-03ClientClientReadidle   ROLLBACKclient backend
16450fiscal31157 16402postgresPostgreSQL JDBC Driver10.0.28.38 389022025-08-20 09:09:19.464498-03 2025-08-20 09:09:20.721296-032025-08-20 09:09:20.721312-03ClientClientReadidle   SET application_name = 'PostgreSQL JDBC Driver'client backend
16450fiscal6099 16402postgresfiscal-intelligence-sped-job10.0.16.225 578072025-08-20 09:16:01.273896-03 2025-08-20 09:17:47.830375-032025-08-20 09:17:47.830501-03ClientClientReadidle   COMMITclient backend
1665815312documents1609 16402postgresnfe-lambda-aws10.0.16.46 137592025-08-20 09:14:14.268127-03 2025-08-20 09:18:33.557739-032025-08-20 09:18:33.560091-03ClientClientReadidle   COMMITclient backend
3333716331revizia8458 16402postgresrvz-sintegra-job10.0.20.66 610712025-08-20 09:18:20.492223-032025-08-20 09:18:41.028515-032025-08-20 09:18:41.028628-032025-08-20 09:18:41.028628-03  active 792182431 select dadossinte0_.id as id1_0_, dadossinte0_.cnpj as cnpj2_0_, dadossinte0_.data_importacao as data_imp3_0_, dadossinte0_.inscricao_estadual as inscrica4_0_, dadossinte0_.mensagem as mensagem5_0_, dadossinte0_.situacao_cnpj as situacao6_0_, dadossinte0_.situacao_inscricao_estadual as situacao7_0_, dadossinte0_.tipo_inscricao_estadual as tipo_ins8_0_, dadossinte0_.ultima as ultima9_0_ from dados_sintegra dadossinte0_ where dadossinte0_.cnpj=$1client backend
16450fiscal8216 16402postgreslambda-go-revizia-metrics10.0.16.91 607432025-08-20 09:17:05.75125-03 2025-08-20 09:17:06.771771-032025-08-20 09:17:06.776473-03ClientClientReadidle  -6488867169811202377
WITH numeracoes AS (
SELECT
COUNT(CASE WHEN nu.utilizado = 'SIM' THEN 1 END) AS qtd_numeracao_utilizada,
COUNT(CASE WHEN nu.utilizado = 'NAO' THEN 1 END) AS qtd_numeracao_disponivel
FROM numeracao_utilizada nu
JOIN controle_numeracao cn ON nu.controle_numeracao_id = cn.id
WHERE cn.id = (SELECT MAX(id) FROM controle_numeracao)
),
notas_emitidas AS (
SELECT
to_char(data_rps, 'YYYY-MM') AS periodo,
COUNT(1) AS quantidade_notas_emitidas
FROM dados_emissao_nfse
WHERE serie_rps = '01SN'
GROUP BY to_char(data_rps, 'YYYY-MM')
ORDER BY to_char(data_rps, 'YYYY-MM') DESC
LIMIT 1
)
SELECT
n.qtd_numeracao_utilizada QtdUtilizada,
n.qtd_numeracao_disponivel QtdDisponivel,
ne.periodo Periodo,
ne.quantidade_notas_emitidas QtdNotasEmitidas
FROM numeracoes n
CROSS JOIN notas_emitidas ne
client backend
1665815312documents3715 16402postgrescfe-job-download-documentos10.0.16.217 173072025-08-20 09:15:26.335802-03 2025-08-20 09:18:25.587397-032025-08-20 09:18:25.587422-03ClientClientReadidle    client backend
1665815312documents25971 16402postgrescfe-job-download-documentos10.0.16.46 161212025-08-20 08:58:49.835401-03 2025-08-20 09:18:40.587173-032025-08-20 09:18:40.587215-03ClientClientReadidle    client backend
3333716331revizia8217 16402postgreslambda-go-revizia-metrics10.0.16.46 129452025-08-20 09:17:05.89454-03 2025-08-20 09:17:07.922892-032025-08-20 09:17:20.851286-03ClientClientReadidle  957357389483338053
select e.cnpj as CNpj,
(dsc is null) as NovaEmpresa,
dsc.data_inicio as DataInicio,
dsc.data_fim as DataFim
from certificado c
left join lateral (select ce2.id,
ce2.certificado_id,
ce2.empresa_id,
ce2.created_at
from conta_empresa ce2
left join empresa e2 on (ce2.empresa_id = e2.id)
where ce2.certificado_id = c.id
and ce2.empresa_id = (select e3.id
from empresa e3
inner join conta_empresa ce3 on e3.id = ce3.empresa_id
inner join certificado c3 on ce3.certificado_id = c3.id
where substring(e3.cnpj,1,8) = substring(e2.cnpj,1,8)
and c3.data_expiracao > NOW()
and e3.tipo_empresa = 'MATRIZ'
limit 1)
and c.data_expiracao > NOW()
and e2.tipo_empresa = 'MATRIZ'
order by created_at desc
limit 1) ce on (true)
left join empresa e on (ce.empresa_id = e.id)
left join download_sped_controle_empresa dsc on (dsc.conta_empresa_id = ce.id)
where ce.id is not null
and e.tipo_empresa = 'MATRIZ'
order by (dsc is null), dsc.data_inicio, ce.created_at desc
client backend
16450fiscal15994 16402postgrespgAdmin 4 - CONN:754989310.0.28.38 534582025-08-19 18:42:28.407682-03 2025-08-19 21:23:36.591822-032025-08-20 07:48:02.876154-03ClientClientReadidle  1558538948540241973CALL delete_empresa_limpeza(3)client backend
1665815312documents6145 16402postgreslambda-go-revizia-metrics10.0.16.225 384932025-08-20 09:16:05.652364-03 2025-08-20 09:16:06.668868-032025-08-20 09:16:07.040473-03ClientClientReadidle  4519062602456696998select Count(*) as "Qtd", Status, recorrente as "Recorrente"
from cfe_periodo_importacao_job
where 1=1
and data_fim <= now()
and status in ('PENDENTE','CONCLUIDO','EM_PROCESSAMENTO','COM_ERRO','COM_ERRO_PERMANENTE') --COM_ERRO_PERMANENTE,SEM_CERTIFICADO
and status is not null
group by status, recorrente
client backend
1665815312documents24084 16402postgresdownload-document-api10.0.16.46 496512025-08-20 08:56:12.320679-03 2025-08-20 09:18:00.392413-032025-08-20 09:18:00.392526-03ClientClientReadidle  -4199849316459484872DISCARD ALL;client backend
1665815312documents8473 16402postgresPostgreSQL JDBC Driver10.0.20.107 503572025-08-20 09:18:23.156838-03 2025-08-20 09:18:27.888965-032025-08-20 09:18:28.338036-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, ARRAY_TO_STRING( ARRAY( select distinct item.produto -> 'prod' ->> 'cfop' as cfop from jsonb_array_elements(d.data -> 'nfe' -> 'infNFe' -> 'det') WITH ORDINALITY item(produto) ), ', ' ) as cfops, cast(d.data -> 'nfe' -> 'infNFe' -> 'ide' ->> 'nnf' as int8) AS numeroNota FROM document d WHERE d.cnpj_addressee = $1 AND d.data_emissao BETWEEN ($2) AND ($3) AND (d.data_entrada_saida IS NULL OR d.data_entrada_saida BETWEEN ($4) AND ($5)) AND d.type IN ('NFE_4_0', 'NFE_3_1') AND ($6 = 'nao_filtrar_ie' OR d.data -> 'nfe' -> 'infNFe' -> 'dest' ->> 'ie' =$7) AND EXISTS ( SELECT 1 FROM document_status ds WHERE d.key = ds.key AND d.cnpj_issuer = ds.cnpj_issuer AND d.protocol = ds.protocol AND d.nsu = ds.nsu AND d.type = ds.type AND ds.status not in ('3','2') AND ( COALESCE( ( SELECT CASE WHEN ds.manifestation IS NOT NULL THEN ds.manifestation WHEN item.historico ->> 'eventCode' IN ('210200','210210','210220','210240') THEN item.historico ->> 'eventCode' WHEN regexp_replace(item.historico ->> 'description', '[^0-9]', '', 'gi') in ('210200','210210','210220','210240') THEN regexp_replace(item.historico ->> 'description', '[^0-9]', '', 'gi') END FROM jsonb_array_elements(ds.history) WITH ORDINALITY item(historico) WHERE item.historico ->> 'eventType' IN ('NFE_EVENT_MANIFESTATION','NFE_EVENT') ORDER BY item.historico ->> 'eventAt' DESC LIMIT 1 ) , ds.manifestation ) is null OR COALESCE( ( SELECT CASE WHEN ds.manifestation IS NOT NULL THEN ds.manifestation WHEN item.historico ->> 'eventCode' IN ('210200','210210','210220','210240') THEN item.historico ->> 'eventCode' WHEN regexp_replace(item.historico ->> 'description', '[^0-9]', '', 'gi') in ('210200','210210','210220','210240') THEN regexp_replace(item.historico ->> 'description', '[^0-9]', '', 'gi') END FROM jsonb_array_elements(ds.history) WITH ORDINALITY item(historico) WHERE item.historico ->> 'eventType' IN ('NFE_EVENT_MANIFESTATION','NFE_EVENT') ORDER BY item.historico ->> 'eventAt' DESC LIMIT 1 ) , ds.manifestation ) NOT IN ('210240','210220') ) ) AND EXISTS ( SELECT 1 FROM jsonb_array_elements(d.data -> 'nfe' -> 'infNFe' -> 'det') WITH ORDINALITY item(produto) WHERE substring(item.produto -> 'prod' ->> 'cfop', 1, 1) IN ('5','6','7') ) ORDER BY d.data_emissao LIMIT $8 OFFSET $9 client backend
1665815312documents27203 16402postgresnfe-lambda-aws10.0.16.232 483732025-08-20 09:02:05.184655-03 2025-08-20 09:16:45.229534-032025-08-20 09:16:45.231635-03ClientClientReadidle   COMMITclient backend
16450fiscal31291 16402postgresPostgreSQL JDBC Driver10.0.28.38 332162025-08-20 09:09:29.006096-03 2025-08-20 09:09:30.462983-032025-08-20 09:09:30.463002-03ClientClientReadidle   SET application_name = 'PostgreSQL JDBC Driver'client backend
1665815312documents1377 16402postgrescfe-importar-sqs10.0.16.225 477232025-08-20 09:13:46.387608-03 2025-08-20 09:17:56.345361-032025-08-20 09:17:56.346856-03ClientClientReadidle   COMMITclient backend
1665815312documents3728 16402postgresPostgreSQL JDBC Driver10.0.16.55 63772025-08-20 09:15:28.458614-03 2025-08-20 09:18:24.002367-032025-08-20 09:18:24.006629-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, d.data -> 'cte' -> 'infCte' -> 'ide' ->> 'cfop' as cfops, cast(d.data -> 'cte' -> 'infCte' -> 'ide' ->> 'nct' as int8) AS numeroNota FROM document d WHERE d.data_emissao BETWEEN ($1) AND ($2) AND d.type IN ('CTE','CTE_OS') AND ($3 = 'nao_filtrar_ie' OR d.data -> 'cte' -> 'infCte' -> 'dest' ->> 'ie' =$4) AND ( ( d.cnpj_cpf_tomador = $5 AND EXISTS ( SELECT 1 FROM document_status ds WHERE d.key = ds.key AND d.cnpj_issuer = ds.cnpj_issuer AND d.protocol = ds.protocol AND d.nsu = ds.nsu AND d.type = ds.type AND ds.status <> '3' AND (ds.manifestation is null or ds.manifestation not in ('610110')) ) ) OR ( d.cnpj_issuer = $6 ) ) ORDER BY d.data_emissao LIMIT $7 OFFSET $8 client backend
1665815312documents27031 16402postgresnfse-lambda-aws10.0.16.232 216892025-08-20 09:01:26.419613-03 2025-08-20 09:18:34.416983-032025-08-20 09:18:34.419722-03ClientClientReadidle   COMMITclient backend
3333716331revizia27205 16402postgresnfe-lambda-aws10.0.16.46 530072025-08-20 09:02:05.558803-03 2025-08-20 09:18:33.580421-032025-08-20 09:18:33.581012-03ClientClientReadidle   SELECT ce.conta_id FROM conta_empresa ce INNER JOIN empresa e ON ce.empresa_id = e.id INNER JOIN conta c on ce.conta_id = c.id WHERE e.cnpj IN ($1, $2) AND c.status = 'ATIVO' AND c.id <> 1 LIMIT 1client backend
1665815312documents8474 16402postgresPostgreSQL JDBC Driver10.0.16.225 546072025-08-20 09:18:23.170247-03 2025-08-20 09:18:24.002682-032025-08-20 09:18:24.009359-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, ARRAY_TO_STRING( ARRAY( select distinct item.produto -> 'prod' ->> 'cfop' as cfop from jsonb_array_elements(d.data -> 'infCFe' -> 'det') WITH ORDINALITY item(produto) ), ', ' ) as cfops, cast(d.data -> 'infCFe' -> 'ide' ->> 'ncFe' as int8) AS numeroNota FROM document d WHERE d.cnpj_issuer = $1 AND d.data_emissao BETWEEN ($2) AND ($3) AND ($4 = 'nao_filtrar_ie' OR d.data -> 'infCFe' -> 'emit' ->> 'ie' =$5) AND d.type LIKE 'CFE_0%' ORDER BY d.data_emissao LIMIT $6 OFFSET $7 client backend
3333716331revizia1390 16402postgresrvz-sintegra-job10.0.20.66 310532025-08-20 09:13:46.813938-03 2025-08-20 09:18:40.962757-032025-08-20 09:18:40.962812-03ClientClientReadidle   ROLLBACKclient backend
16450fiscal3733 16402postgresfiscal-intelligence-api10.0.16.55 550352025-08-20 09:15:28.698899-03 2025-08-20 09:18:20.519783-032025-08-20 09:18:20.519802-03ClientClientReadidle   ROLLBACKclient backend
3333716331revizia18486 16402postgrespgAdmin 4 - CONN:836570210.0.28.38 490062025-08-14 23:15:11.693939-03 2025-08-14 23:15:17.31823-032025-08-14 23:15:17.318249-03ClientClientReadidle   SELECT oid, pg_catalog.format_type(oid, NULL) AS typname FROM pg_catalog.pg_type WHERE oid = ANY($1) ORDER BY oid;client backend
1665815312documents31230 16402postgrescfe-job-download-documentos10.0.16.232 314252025-08-20 09:09:23.554757-03 2025-08-20 09:18:24.831191-032025-08-20 09:18:24.831377-03ClientClientReadidle    client backend
1665815312documents8511 16402postgresPostgreSQL JDBC Driver10.0.16.91 254232025-08-20 09:18:27.833096-03 2025-08-20 09:18:27.949872-032025-08-20 09:18:27.953706-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, d.data -> 'cte' -> 'infCte' -> 'ide' ->> 'cfop' as cfops, cast(d.data -> 'cte' -> 'infCte' -> 'ide' ->> 'nct' as int8) AS numeroNota FROM document d WHERE d.data_emissao BETWEEN ($1) AND ($2) AND d.type IN ('CTE','CTE_OS') AND ($3 = 'nao_filtrar_ie' OR d.data -> 'cte' -> 'infCte' -> 'dest' ->> 'ie' =$4) AND ( ( d.cnpj_cpf_tomador = $5 AND EXISTS ( SELECT 1 FROM document_status ds WHERE d.key = ds.key AND d.cnpj_issuer = ds.cnpj_issuer AND d.protocol = ds.protocol AND d.nsu = ds.nsu AND d.type = ds.type AND ds.status <> '3' AND (ds.manifestation is null or ds.manifestation not in ('610110')) ) ) OR ( d.cnpj_issuer = $6 ) ) ORDER BY d.data_emissao LIMIT $7 OFFSET $8 client backend
3333716331revizia1206 16402postgrescertificado-api10.0.20.107 418792025-08-20 09:13:23.739325-03 2025-08-20 09:17:29.494866-032025-08-20 09:17:29.494928-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents3022 16402postgresmensageria-api10.0.20.66 267712025-08-20 08:19:38.209884-03 2025-08-20 09:16:53.783974-032025-08-20 09:16:53.783993-03ClientClientReadidle   COMMITclient backend
1665815312documents31629 16402postgresnfse-lambda-aws10.0.20.66 32932025-08-20 09:10:04.533589-03 2025-08-20 09:18:25.333644-032025-08-20 09:18:25.337509-03ClientClientReadidle   COMMITclient backend
1665815312documents8546 16402postgrescte-lambda-aws10.0.20.107 602152025-08-20 09:18:30.163689-03 2025-08-20 09:18:30.407196-032025-08-20 09:18:30.408439-03ClientClientReadidle   COMMITclient backend
1665815312documents1617 16402postgresnfe-lambda-aws10.0.16.91 15912025-08-20 09:14:18.650064-03 2025-08-20 09:18:18.024022-032025-08-20 09:18:18.027051-03ClientClientReadidle   COMMITclient backend
1665815312documents31630 16402postgrescte-lambda-aws10.0.16.91 236032025-08-20 09:10:04.810451-03 2025-08-20 09:18:38.521268-032025-08-20 09:18:38.523395-03ClientClientReadidle   COMMITclient backend
3333716331revizia6154 16402postgreslambda-go-revizia-metrics10.0.16.55 590252025-08-20 09:16:05.910138-03 2025-08-20 09:16:07.137298-032025-08-20 09:16:21.082117-03ClientClientReadidle  957357389483338053
select e.cnpj as CNpj,
(dsc is null) as NovaEmpresa,
dsc.data_inicio as DataInicio,
dsc.data_fim as DataFim
from certificado c
left join lateral (select ce2.id,
ce2.certificado_id,
ce2.empresa_id,
ce2.created_at
from conta_empresa ce2
left join empresa e2 on (ce2.empresa_id = e2.id)
where ce2.certificado_id = c.id
and ce2.empresa_id = (select e3.id
from empresa e3
inner join conta_empresa ce3 on e3.id = ce3.empresa_id
inner join certificado c3 on ce3.certificado_id = c3.id
where substring(e3.cnpj,1,8) = substring(e2.cnpj,1,8)
and c3.data_expiracao > NOW()
and e3.tipo_empresa = 'MATRIZ'
limit 1)
and c.data_expiracao > NOW()
and e2.tipo_empresa = 'MATRIZ'
order by created_at desc
limit 1) ce on (true)
left join empresa e on (ce.empresa_id = e.id)
left join download_sped_controle_empresa dsc on (dsc.conta_empresa_id = ce.id)
where ce.id is not null
and e.tipo_empresa = 'MATRIZ'
order by (dsc is null), dsc.data_inicio, ce.created_at desc
client backend
1665815312documents19774 16402postgresnfe-lambda-aws10.0.16.91 31652025-08-20 08:51:15.156388-03 2025-08-20 09:17:42.332185-032025-08-20 09:17:42.334508-03ClientClientReadidle   COMMITclient backend
1665815312documents31317 16402postgresnfe-lambda-aws10.0.20.107 392012025-08-20 09:09:34.923248-03 2025-08-20 09:17:14.243032-032025-08-20 09:17:14.245719-03ClientClientReadidle   COMMITclient backend
1665815312documents1216 16402postgresnfse-lambda-aws10.0.20.107 476892025-08-20 09:13:26.153707-03 2025-08-20 09:18:29.561057-032025-08-20 09:18:29.563781-03ClientClientReadidle   COMMITclient backend
3333716331revizia3844 16402postgresnfe-lambda-aws10.0.20.66 352372025-08-20 09:15:30.478998-03 2025-08-20 09:18:33.824938-032025-08-20 09:18:33.825528-03ClientClientReadidle   SELECT ce.conta_id FROM conta_empresa ce INNER JOIN empresa e ON ce.empresa_id = e.id INNER JOIN conta c on ce.conta_id = c.id WHERE e.cnpj IN ($1, $2) AND c.status = 'ATIVO' AND c.id <> 1 LIMIT 1client backend
1665815312documents8584 16402postgrescte-lambda-aws10.0.20.66 583352025-08-20 09:18:36.826622-03 2025-08-20 09:18:37.160663-032025-08-20 09:18:37.162872-03ClientClientReadidle   COMMITclient backend
1665815312documents1620 16402postgresnfe-lambda-aws10.0.16.91 117872025-08-20 09:14:18.761888-03 2025-08-20 09:18:07.892561-032025-08-20 09:18:07.894769-03ClientClientReadidle   COMMITclient backend
1665815312documents32230 16402postgresnfe-lambda-aws10.0.16.232 403312025-08-20 09:11:04.221765-03 2025-08-20 09:17:32.786922-032025-08-20 09:17:32.789609-03ClientClientReadidle   COMMITclient backend
1665815312documents8098 16402postgrescfe-job-queue-api10.0.16.225 362272025-08-20 08:28:08.963585-03 2025-08-20 09:18:25.435278-032025-08-20 09:18:25.435363-03ClientClientReadidle    client backend
1665815312documents8601 16402postgrescte-lambda-aws10.0.16.91 145152025-08-20 09:18:38.389783-032025-08-20 09:18:41.009115-032025-08-20 09:18:41.009177-032025-08-20 09:18:41.009177-03  active 792182431 select key from document where key = $1 and type = $2 and protocol = $3 and data_emissao between $4 and $5 limit 1client backend
1665815312documents4173 16402postgresdocument-api10.0.16.225 565472025-08-20 08:22:04.165332-03 2025-08-20 09:16:27.932672-032025-08-20 09:16:27.932762-03ClientClientReadidle   COMMITclient backend
16450fiscal29636 16402postgresfiscal-intelligence-sped-job10.0.16.217 28952025-08-20 09:07:18.058637-03 2025-08-20 09:17:17.530811-032025-08-20 09:17:17.53087-03ClientClientReadidle   COMMITclient backend
3333716331revizia6231 16402postgrescore-api10.0.20.107 223852025-08-20 09:16:07.783864-03 2025-08-20 09:18:33.576521-032025-08-20 09:18:33.576532-03ClientClientReadidle   COMMITclient backend
3333716331revizia32395 16402postgrescore-api10.0.20.107 519412025-08-20 09:11:07.042417-03 2025-08-20 09:17:01.026349-032025-08-20 09:17:01.026406-03ClientClientReadidle   COMMITclient backend
1665815312documents32494 16402postgrescfe-job-download-documentos10.0.16.55 23912025-08-20 09:11:10.202644-03 2025-08-20 09:18:40.467562-032025-08-20 09:18:40.467773-03ClientClientReadidle    client backend
1665815312documents8237 16402postgresnfse-lambda-aws10.0.16.55 183352025-08-20 09:17:13.086203-03 2025-08-20 09:18:39.571983-032025-08-20 09:18:39.574894-03ClientClientReadidle   COMMITclient backend
1665815312documents30508 16402postgresdownload-document-api10.0.20.107 538252025-08-20 09:08:40.260523-03 2025-08-20 09:18:33.252249-032025-08-20 09:18:33.252335-03ClientClientReadidle  -4199849316459484872DISCARD ALL;client backend
16450fiscal11185 3305731552dev_rafael_carvalhopgAdmin 4 - CONN:855161510.0.28.38 573242025-08-20 07:29:17.958147-03 2025-08-20 07:32:41.753815-032025-08-20 07:32:41.753842-03ClientClientReadidle   SELECT oid, pg_catalog.format_type(oid, NULL) AS typname FROM pg_catalog.pg_type WHERE oid = ANY($1) ORDER BY oid;client backend
1665815312documents1622 16402postgresnfe-lambda-aws10.0.16.217 449252025-08-20 09:14:19.429062-03 2025-08-20 09:16:48.606211-032025-08-20 09:16:48.609171-03ClientClientReadidle   COMMITclient backend
16450fiscal4500 16402postgreslambda-go-revizia-metrics10.0.16.46 167632025-08-20 09:15:43.589705-03 2025-08-20 09:16:06.589242-032025-08-20 09:16:06.592982-03ClientClientReadidle  -6488867169811202377
WITH numeracoes AS (
SELECT
COUNT(CASE WHEN nu.utilizado = 'SIM' THEN 1 END) AS qtd_numeracao_utilizada,
COUNT(CASE WHEN nu.utilizado = 'NAO' THEN 1 END) AS qtd_numeracao_disponivel
FROM numeracao_utilizada nu
JOIN controle_numeracao cn ON nu.controle_numeracao_id = cn.id
WHERE cn.id = (SELECT MAX(id) FROM controle_numeracao)
),
notas_emitidas AS (
SELECT
to_char(data_rps, 'YYYY-MM') AS periodo,
COUNT(1) AS quantidade_notas_emitidas
FROM dados_emissao_nfse
WHERE serie_rps = '01SN'
GROUP BY to_char(data_rps, 'YYYY-MM')
ORDER BY to_char(data_rps, 'YYYY-MM') DESC
LIMIT 1
)
SELECT
n.qtd_numeracao_utilizada QtdUtilizada,
n.qtd_numeracao_disponivel QtdDisponivel,
ne.periodo Periodo,
ne.quantidade_notas_emitidas QtdNotasEmitidas
FROM numeracoes n
CROSS JOIN notas_emitidas ne
client backend
3333716331revizia32356 16402postgrescore-api10.0.20.107 338852025-08-20 09:11:06.849808-03 2025-08-20 09:18:40.2501-032025-08-20 09:18:40.250332-03ClientClientReadidle   COMMITclient backend
3333716331revizia16715 16402postgrespgAdmin 4 - DB:revizia10.0.28.38 363162025-08-16 16:50:06.247273-03 2025-08-20 09:18:02.91434-032025-08-20 09:18:02.919365-03ClientClientReadidle  4653323128169443287/*pga4dash*/
SELECT 'session_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Total",
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE state = 'active' AND datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Active",
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE state = 'idle' AND datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Idle"
) t
UNION ALL
SELECT 'tps_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(xact_commit) + sum(xact_rollback) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Transactions",
(SELECT sum(xact_commit) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Commits",
(SELECT sum(xact_rollback) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Rollbacks"
) t
UNION ALL
SELECT 'ti_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(tup_inserted) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Inserts",
(SELECT sum(tup_updated) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Updates",
(SELECT sum(tup_deleted) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Deletes"
) t
UNION ALL
SELECT 'to_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(tup_fetched) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Fetched",
(SELECT sum(tup_returned) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Returned"
) t
UNION ALL
SELECT 'bio_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(blks_read) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Reads",
(SELECT sum(blks_hit) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 3333716331)) AS "Hits"
) t
client backend
1665815312documents8604 16402postgrescte-lambda-aws10.0.16.46 413172025-08-20 09:18:38.489542-03 2025-08-20 09:18:38.810963-032025-08-20 09:18:38.81329-03ClientClientReadidle   COMMITclient backend
16450fiscal27360 16402postgresfiscal-intelligence-api10.0.16.225 440152025-08-20 09:02:16.368809-03 2025-08-20 09:18:14.863391-032025-08-20 09:18:14.863422-03ClientClientReadidle   COMMITclient backend
1665815312documents1226 16402postgresmensageria-api10.0.20.107 551392025-08-20 09:13:30.772369-03 2025-08-20 09:18:20.447404-032025-08-20 09:18:20.447442-03ClientClientReadidle    client backend
1665815312documents1227 16402postgresdownload-document-api10.0.16.232 34952025-08-20 09:13:31.757633-03 2025-08-20 09:18:37.568721-032025-08-20 09:18:37.568798-03ClientClientReadidle    client backend
16450fiscal20029 16402postgresfiscal-intelligence-sped-analises-job10.0.16.225 603732025-08-20 08:51:50.451686-03 2025-08-20 09:18:40.731467-032025-08-20 09:18:40.733174-03ClientClientReadidle   COMMITclient backend
1665815312documents30511 16402postgresdownload-document-api10.0.16.225 105392025-08-20 09:08:40.32224-03 2025-08-20 09:18:31.448993-032025-08-20 09:18:31.449103-03ClientClientReadidle  -4199849316459484872DISCARD ALL;client backend
16450fiscal16043 16402postgrespgAdmin 4 - CONN:381667910.0.28.38 361882025-08-19 18:42:42.079285-03 2025-08-19 21:23:35.241255-032025-08-20 07:48:01.061957-03ClientClientReadidle  -2828850295681666026CALL delete_empresa_limpeza(2)client backend
3333716331revizia8614 16402postgresrvz-sintegra-job10.0.16.55 342592025-08-20 09:18:40.936345-03 2025-08-20 09:18:40.984183-032025-08-20 09:18:40.984646-03ClientClientReadidle   ROLLBACKclient backend
3333716331revizia8613 16402postgresrvz-sintegra-job10.0.16.55 44032025-08-20 09:18:40.936044-03 2025-08-20 09:18:40.986431-032025-08-20 09:18:40.986488-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents1629 16402postgresnfe-lambda-aws10.0.20.66 31372025-08-20 09:14:21.941433-03 2025-08-20 09:17:31.991441-032025-08-20 09:17:31.994294-03ClientClientReadidle   COMMITclient backend
1665815312documents6232 16402postgresdocument-api10.0.16.55 608692025-08-20 09:16:07.802745-03 2025-08-20 09:18:17.183072-032025-08-20 09:18:17.183107-03ClientClientReadidle   COMMITclient backend
3333716331revizia28394 16402postgrescore-api10.0.16.55 445652025-08-20 09:04:35.464356-03 2025-08-20 09:18:33.578811-032025-08-20 09:18:33.578937-03ClientClientReadidle   COMMITclient backend
3333716331revizia871 16402postgresrvz-sintegra-job10.0.16.46 73912025-08-20 09:12:40.083074-03 2025-08-20 09:17:07.542439-032025-08-20 09:17:07.542512-03ClientClientReadidle    client backend
3333716331revizia6202 16402postgresgo-sped-api10.0.16.46 239072025-08-20 09:16:06.99836-03 2025-08-20 09:16:07.022147-032025-08-20 09:16:07.036941-03ClientClientReadidle   
select distinct e.cnpj
from empresa e
inner join conta_empresa ce on ce.empresa_id = e.id
inner join conta c on c.id = ce.conta_id
where substr(e.cnpj,1,8) = $1
and c.status in ('ATIVO', 'TRIAL')
and c.deleted = false
and e.deleted = false
and ce.deleted = false
client backend
1665815312documents6463 16402postgresdocument-api10.0.16.232 497432025-08-20 09:16:13.204794-03 2025-08-20 09:18:33.899818-032025-08-20 09:18:33.907615-03ClientClientReadidle   COMMITclient backend
1665815312documents6539 16402postgresdocument-api10.0.16.232 70012025-08-20 09:16:13.789071-03 2025-08-20 09:16:28.244264-032025-08-20 09:16:28.244299-03ClientClientReadidle   COMMITclient backend
1665815312documents32497 16402postgrescfe-job-download-documentos10.0.20.66 580032025-08-20 09:11:12.099872-03 2025-08-20 09:18:40.966787-032025-08-20 09:18:40.966824-03ClientClientReadidle    client backend
3333716331revizia28447 16402postgrescfe-importar-sqs10.0.20.107 229872025-08-20 09:04:48.00743-03 2025-08-20 09:16:45.184643-032025-08-20 09:16:45.184771-03ClientClientReadidle    client backend
3333716331revizia8631780216402postgresrvz-sintegra-job   2025-08-20 09:18:41.025204-032025-08-20 09:18:41.024046-032025-08-20 09:18:41.024292-032025-08-20 09:18:41.026707-03  active 792182431 select dadossinte0_.id as id1_0_, dadossinte0_.cnpj as cnpj2_0_, dadossinte0_.data_importacao as data_imp3_0_, dadossinte0_.inscricao_estadual as inscrica4_0_, dadossinte0_.mensagem as mensagem5_0_, dadossinte0_.situacao_cnpj as situacao6_0_, dadossinte0_.situacao_inscricao_estadual as situacao7_0_, dadossinte0_.tipo_inscricao_estadual as tipo_ins8_0_, dadossinte0_.ultima as ultima9_0_ from dados_sintegra dadossinte0_ where dadossinte0_.cnpj=$1parallel worker
1665815312documents6444 16402postgresdocument-api10.0.16.46 568572025-08-20 09:16:12.96979-03 2025-08-20 09:16:27.716739-032025-08-20 09:16:27.716772-03ClientClientReadidle   COMMITclient backend
1665815312documents16239 16402postgresnfe-lambda-aws10.0.16.225 48032025-08-20 08:43:14.309561-03 2025-08-20 09:17:35.546668-032025-08-20 09:17:35.548924-03ClientClientReadidle   COMMITclient backend
3333716331revizia8632780216402postgresrvz-sintegra-job   2025-08-20 09:18:41.025554-032025-08-20 09:18:41.024046-032025-08-20 09:18:41.024292-032025-08-20 09:18:41.026896-03  active 792182431 select dadossinte0_.id as id1_0_, dadossinte0_.cnpj as cnpj2_0_, dadossinte0_.data_importacao as data_imp3_0_, dadossinte0_.inscricao_estadual as inscrica4_0_, dadossinte0_.mensagem as mensagem5_0_, dadossinte0_.situacao_cnpj as situacao6_0_, dadossinte0_.situacao_inscricao_estadual as situacao7_0_, dadossinte0_.tipo_inscricao_estadual as tipo_ins8_0_, dadossinte0_.ultima as ultima9_0_ from dados_sintegra dadossinte0_ where dadossinte0_.cnpj=$1parallel worker
1665815312documents27383 16402postgresdocument-api10.0.16.46 300332025-08-20 09:02:18.963988-03 2025-08-20 09:16:27.937458-032025-08-20 09:16:27.937491-03ClientClientReadidle   COMMITclient backend
3333716331revizia22388 16402postgresnfe-lambda-aws10.0.16.217 412812025-08-20 08:54:15.2612-03 2025-08-20 09:17:02.728954-032025-08-20 09:17:02.729504-03ClientClientReadidle   SELECT ce.conta_id FROM conta_empresa ce INNER JOIN empresa e ON ce.empresa_id = e.id INNER JOIN conta c on ce.conta_id = c.id WHERE e.cnpj IN ($1, $2) AND c.status = 'ATIVO' AND c.id <> 1 LIMIT 1client backend
1665815312documents8238 16402postgresnfse-lambda-aws10.0.16.217 123192025-08-20 09:17:13.10691-03 2025-08-20 09:18:31.034584-032025-08-20 09:18:31.03696-03ClientClientReadidle   COMMITclient backend
1665815312documents28108 16402postgresnfe-lambda-aws10.0.16.217 409312025-08-20 09:03:33.065836-03 2025-08-20 09:16:48.604625-032025-08-20 09:16:48.606961-03ClientClientReadidle   COMMITclient backend
3333716331revizia23776 16402postgrespgAdmin 4 - CONN:170045610.0.28.38 560182025-08-19 15:43:53.625876-03 2025-08-19 15:48:11.087938-032025-08-19 15:48:11.087997-03ClientClientReadidle  -4364344397713342668commit transaction;client backend
1665815312documents27384 16402postgresdocument-api10.0.16.232 646952025-08-20 09:02:18.966847-03 2025-08-20 09:16:28.004568-032025-08-20 09:16:28.004632-03ClientClientReadidle   COMMITclient backend
1665815312documents29658 16402postgrescfe-job-download-documentos-recorrentes10.0.20.107 170012025-08-20 09:07:24.55271-03 2025-08-20 09:16:20.60537-032025-08-20 09:16:20.606668-03ClientClientReadidle   COMMITclient backend
3333716331revizia27385 16402postgrescore-api10.0.16.91 426612025-08-20 09:02:19.03848-03 2025-08-20 09:17:08.701015-032025-08-20 09:17:08.701125-03ClientClientReadidle  -4199849316459484872DISCARD ALL;client backend
16450fiscal16061 16402postgrespgAdmin 4 - CONN:381667910.0.28.38 456642025-08-19 18:42:46.056255-03 2025-08-19 21:23:31.857188-032025-08-20 07:47:59.242134-03ClientClientReadidle  -7402057875979027787CALL delete_empresa_limpeza(1)client backend
1665815312documents29196 16402postgresmensageria-api10.0.16.225 269532025-08-20 09:06:11.829993-032025-08-20 09:18:40.685062-032025-08-20 09:18:40.685218-032025-08-20 09:18:40.685219-03IODataFileReadactive 792182431 select solicitaca0_.id as id1_11_, solicitaca0_.cnpj as cnpj2_11_, solicitaca0_.codigo_ibge as codigo_i3_11_, solicitaca0_.data_conclusao as data_con4_11_, solicitaca0_.data_final as data_fin5_11_, solicitaca0_.data_inicial as data_ini6_11_, solicitaca0_.data_solicitacao as data_sol7_11_, solicitaca0_.inscricao_municipal as inscrica8_11_, solicitaca0_.numero_final as numero_f9_11_, solicitaca0_.numero_inicial as numero_10_11_, solicitaca0_.quantidade_documentos as quantid11_11_, solicitaca0_.stacktrace as stacktr12_11_, solicitaca0_.status as status13_11_, solicitaca0_.tipo as tipo14_11_, solicitaca0_.ultimo_numero as ultimo_15_11_ from solicitacao_download_nfse solicitaca0_ where solicitaca0_.cnpj=$1 and solicitaca0_.codigo_ibge=$2 and solicitaca0_.tipo=$3 and (solicitaca0_.status in ($4 , $5)) order by solicitaca0_.data_final desc limit $6client backend
1665815312documents6441 16402postgresdocument-api10.0.16.225 376992025-08-20 09:16:12.966963-03 2025-08-20 09:18:17.189478-032025-08-20 09:18:17.189529-03ClientClientReadidle   COMMITclient backend
1665815312documents8239 16402postgresnfse-lambda-aws10.0.16.46 509912025-08-20 09:17:13.17328-03 2025-08-20 09:18:32.545161-032025-08-20 09:18:32.548369-03ClientClientReadidle   COMMITclient backend
1665815312documents6518 16402postgresdocument-api10.0.16.55 66252025-08-20 09:16:13.73843-03 2025-08-20 09:18:17.209973-032025-08-20 09:18:17.209989-03ClientClientReadidle   COMMITclient backend
1665815312documents28689 16402postgrescfe-job-download-documentos10.0.16.55 577932025-08-20 09:05:09.82107-03 2025-08-20 09:18:31.228166-032025-08-20 09:18:31.228259-03ClientClientReadidle    client backend
3333716331revizia28450 16402postgrescfe-importar-sqs10.0.16.91 17112025-08-20 09:04:48.076823-03 2025-08-20 09:17:55.185532-032025-08-20 09:17:55.185563-03ClientClientReadidle    client backend
1665815312documents30536 16402postgresdownload-document-api10.0.20.107 33352025-08-20 09:08:40.806884-03 2025-08-20 09:18:20.524467-032025-08-20 09:18:20.524627-03ClientClientReadidle   COMMITclient backend
16450fiscal1351 16402postgresprocessador-linhas-sped-api10.0.16.91 267152025-08-20 09:13:39.898218-03 2025-08-20 09:18:40.65622-032025-08-20 09:18:40.656281-03ClientClientReadidle   COMMITclient backend
1665815312documents6551 16402postgresdocument-api10.0.16.46 162892025-08-20 09:16:13.819085-03 2025-08-20 09:18:33.645779-032025-08-20 09:18:33.645851-03ClientClientReadidle   COMMITclient backend
1665815312documents3757 16402postgrescfe-job-download-documentos-recorrentes10.0.16.46 524612025-08-20 09:15:29.528262-03 2025-08-20 09:17:29.571434-032025-08-20 09:17:29.571453-03ClientClientReadidle   COMMITclient backend
1665815312documents27387 16402postgrescfe-job-download-documentos-recorrentes10.0.16.232 482012025-08-20 09:02:19.370379-03 2025-08-20 09:18:22.858454-032025-08-20 09:18:22.859674-03ClientClientReadidle   COMMITclient backend
5postgres21980 3305731552dev_rafael_carvalhopgAdmin 4 - DB:postgres10.0.28.38 341702025-08-19 18:58:23.351203-03 2025-08-20 07:29:06.492323-032025-08-20 07:29:06.495577-03ClientClientReadidle  -3012509240442274851/*pga4dash*/
SELECT 'session_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT count(*) FROM pg_catalog.pg_stat_activity) AS "Total",
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE state = 'active') AS "Active",
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE state = 'idle') AS "Idle"
) t
UNION ALL
SELECT 'tps_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(xact_commit) + sum(xact_rollback) FROM pg_catalog.pg_stat_database) AS "Transactions",
(SELECT sum(xact_commit) FROM pg_catalog.pg_stat_database) AS "Commits",
(SELECT sum(xact_rollback) FROM pg_catalog.pg_stat_database) AS "Rollbacks"
) t
UNION ALL
SELECT 'ti_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(tup_inserted) FROM pg_catalog.pg_stat_database) AS "Inserts",
(SELECT sum(tup_updated) FROM pg_catalog.pg_stat_database) AS "Updates",
(SELECT sum(tup_deleted) FROM pg_catalog.pg_stat_database) AS "Deletes"
) t
UNION ALL
SELECT 'to_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(tup_fetched) FROM pg_catalog.pg_stat_database) AS "Fetched",
(SELECT sum(tup_returned) FROM pg_catalog.pg_stat_database) AS "Returned"
) t
UNION ALL
SELECT 'bio_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(blks_read) FROM pg_catalog.pg_stat_database) AS "Reads",
(SELECT sum(blks_hit) FROM pg_catalog.pg_stat_database) AS "Hits"
) t
client backend
16450fiscal22003 3305731552dev_rafael_carvalhopgAdmin 4 - DB:fiscal10.0.28.38 335162025-08-19 18:58:25.1666-03 2025-08-20 09:17:43.973091-032025-08-20 09:17:43.978139-03ClientClientReadidle  -6488867169811202377/*pga4dash*/
SELECT 'session_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Total",
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE state = 'active' AND datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Active",
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE state = 'idle' AND datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Idle"
) t
UNION ALL
SELECT 'tps_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(xact_commit) + sum(xact_rollback) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Transactions",
(SELECT sum(xact_commit) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Commits",
(SELECT sum(xact_rollback) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Rollbacks"
) t
UNION ALL
SELECT 'ti_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(tup_inserted) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Inserts",
(SELECT sum(tup_updated) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Updates",
(SELECT sum(tup_deleted) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Deletes"
) t
UNION ALL
SELECT 'to_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(tup_fetched) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Fetched",
(SELECT sum(tup_returned) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Returned"
) t
UNION ALL
SELECT 'bio_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(blks_read) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Reads",
(SELECT sum(blks_hit) FROM pg_catalog.pg_stat_database WHERE datname = (SELECT datname FROM pg_catalog.pg_database WHERE oid = 16450)) AS "Hits"
) t
client backend
1665815312documents29197 16402postgresmensageria-api10.0.20.107 283952025-08-20 09:06:11.830273-03 2025-08-20 09:16:02.200397-032025-08-20 09:16:02.201367-03ClientClientReadidle   COMMITclient backend
1665815312documents6527 16402postgresdocument-api10.0.20.66 62852025-08-20 09:16:13.769518-03 2025-08-20 09:16:28.005395-032025-08-20 09:16:28.005421-03ClientClientReadidle   COMMITclient backend
1665815312documents28695 16402postgrescfe-job-download-documentos10.0.16.217 501272025-08-20 09:05:10.573211-03 2025-08-20 09:18:40.831295-032025-08-20 09:18:40.831374-03ClientClientReadidle    client backend
16450fiscal26601 16402postgrespgAdmin 4 - CONN:820239810.0.28.38 481982025-08-15 06:43:24.036689-03 2025-08-15 06:45:26.126218-032025-08-15 06:45:26.126249-03ClientClientReadidle   SELECT oid, pg_catalog.format_type(oid, NULL) AS typname FROM pg_catalog.pg_type WHERE oid = ANY($1) ORDER BY oid;client backend
3333716331revizia28173 16402postgresrvz-sintegra-job10.0.16.217 334072025-08-20 09:03:42.959757-03 2025-08-20 09:17:32.315985-032025-08-20 09:17:32.316011-03ClientClientReadidle    client backend
1665815312documents8240 16402postgresnfe-lambda-aws10.0.20.107 51612025-08-20 09:17:14.204204-03 2025-08-20 09:17:43.200982-032025-08-20 09:17:43.203575-03ClientClientReadidle   COMMITclient backend
1665815312documents7243 16402postgresPostgreSQL JDBC Driver10.0.16.46 225492025-08-20 09:16:19.173762-03 2025-08-20 09:18:27.851314-032025-08-20 09:18:28.070742-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, ARRAY_TO_STRING( ARRAY( select distinct item.produto -> 'prod' ->> 'cfop' as cfop from jsonb_array_elements(d.data -> 'infCFe' -> 'det') WITH ORDINALITY item(produto) ), ', ' ) as cfops, cast(d.data -> 'infCFe' -> 'ide' ->> 'ncFe' as int8) AS numeroNota FROM document d WHERE d.cnpj_issuer = $1 AND d.data_emissao BETWEEN ($2) AND ($3) AND ($4 = 'nao_filtrar_ie' OR d.data -> 'infCFe' -> 'emit' ->> 'ie' =$5) AND d.type LIKE 'CFE_0%' ORDER BY d.data_emissao LIMIT $6 OFFSET $7 client backend
16450fiscal956 16402postgrespgAdmin 4 - CONN:322867310.0.28.38 427522025-08-19 17:51:57.679838-03 2025-08-19 21:23:38.10587-032025-08-20 07:48:05.07522-03ClientClientReadidle  5416383927653580847CALL delete_empresa_limpeza(4)client backend
1665815312documents20043 16402postgresdocument-api10.0.16.46 465732025-08-20 08:51:51.175005-03 2025-08-20 09:18:17.191138-032025-08-20 09:18:17.191358-03ClientClientReadidle   COMMITclient backend
3333716331revizia872 16402postgresrvz-sintegra-job10.0.20.107 316932025-08-20 09:12:40.08355-03 2025-08-20 09:17:01.78342-032025-08-20 09:17:01.784534-03ClientClientReadidle   COMMITclient backend
16450fiscal28717 16402postgresfiscal-intelligence-sped-analises-job10.0.16.91 281692025-08-20 09:05:11.391672-03 2025-08-20 09:18:36.801807-032025-08-20 09:18:36.801822-03ClientClientReadidle   COMMITclient backend
16450fiscal4187 16402postgresfiscal-intelligence-sped-api10.0.16.232 446732025-08-20 09:15:41.2669-03 2025-08-20 09:17:02.910646-032025-08-20 09:17:02.912261-03ClientClientReadidle   COMMITclient backend
3333716331revizia32510 16402postgrescore-api10.0.20.66 332972025-08-20 09:11:13.773729-03 2025-08-20 09:18:40.222921-032025-08-20 09:18:40.222933-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents31701 16402postgrescfe-job-download-documentos10.0.20.107 526152025-08-20 09:10:11.65452-03 2025-08-20 09:16:26.690469-032025-08-20 09:16:26.690516-03ClientClientReadidle    client backend
1665815312documents27128 16402postgresnfe-lambda-aws10.0.16.55 643812025-08-20 09:01:45.378884-03 2025-08-20 09:17:02.532061-032025-08-20 09:17:02.535078-03ClientClientReadidle   COMMITclient backend
1665815312documents32519 16402postgrescte-lambda-aws10.0.16.55 472612025-08-20 09:11:14.156856-03 2025-08-20 09:18:37.946615-032025-08-20 09:18:37.948963-03ClientClientReadidle   COMMITclient backend
16450fiscal7276 16402postgrespostgres_fdw127.0.0.1 427082025-08-20 09:16:19.529035-03 2025-08-20 09:16:24.959801-032025-08-20 09:16:24.959826-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
16450fiscal7287 16402postgrespostgres_fdw127.0.0.1 427122025-08-20 09:16:19.712689-03 2025-08-20 09:16:24.326101-032025-08-20 09:16:24.326129-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
16450fiscal3570 16402postgrespgAdmin 4 - DB:fiscal10.0.28.38 341142025-08-19 10:32:47.541758-03 2025-08-20 07:48:05.074329-032025-08-20 07:48:05.074506-03ClientClientReadidle  -6488867169811202377SELECT pg_cancel_backend(956);client backend
1665815312documents8241 16402postgrespostgres_fdw127.0.0.1 315522025-08-20 09:17:14.839837-03 2025-08-20 09:17:22.370614-032025-08-20 09:17:22.371845-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents8261 16402postgresnfe-lambda-aws10.0.16.46 399492025-08-20 09:17:28.645963-03 2025-08-20 09:18:40.37317-032025-08-20 09:18:40.375542-03ClientClientReadidle   COMMITclient backend
16450fiscal29702 16402postgresesocial-totalizador-fgts-empregador-importar-from-sqs10.0.16.232 390932025-08-20 09:07:28.889795-03 2025-08-20 09:18:29.256647-032025-08-20 09:18:29.256666-03ClientClientReadidle   COMMITclient backend
1665815312documents24456 16402postgresdocument-api10.0.16.225 290172025-08-20 08:56:45.626502-03 2025-08-20 09:16:28.011469-032025-08-20 09:16:28.011502-03ClientClientReadidle   COMMITclient backend
3333716331revizia26365 16402postgresrvz-sintegra-job10.0.16.91 539032025-08-20 09:00:21.185189-03 2025-08-20 09:17:02.317203-032025-08-20 09:17:02.317353-03ClientClientReadidle    client backend
1665815312documents8305 16402postgresnfe-lambda-aws10.0.16.225 347012025-08-20 09:17:35.512997-03 2025-08-20 09:18:40.314209-032025-08-20 09:18:40.316608-03ClientClientReadidle   COMMITclient backend
16450fiscal7294 16402postgrespostgres_fdw127.0.0.1 427142025-08-20 09:16:19.798549-03 2025-08-20 09:16:19.879728-032025-08-20 09:16:19.879763-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents18257 16402postgresmensageria-api10.0.16.217 52092025-08-20 08:47:32.568259-03 2025-08-20 09:18:31.801861-032025-08-20 09:18:31.801934-03ClientClientReadidle    client backend
1665815312documents6570 16402postgresdocument-api10.0.16.46 37112025-08-20 09:16:13.861465-03 2025-08-20 09:18:17.21361-032025-08-20 09:18:17.213661-03ClientClientReadidle   COMMITclient backend
1665815312documents7359 16402postgrescfe-job-download-documentos-recorrentes10.0.20.107 538232025-08-20 09:16:20.607322-03 2025-08-20 09:18:26.128241-032025-08-20 09:18:26.129348-03ClientClientReadidle   COMMITclient backend
16450fiscal924 16402postgreslambda-go-revizia-metrics10.0.16.225 193092025-08-20 09:12:43.583523-03 2025-08-20 09:16:43.582209-032025-08-20 09:16:43.582483-03ClientClientReadidle  -6488867169811202377
select id, type, file_name
from book_keeping
where status in ('READING','READING_WITH_PRIORITY')
order by created_at, updated_at
client backend
16450fiscal8248 16402postgresfiscal-intelligence-sped-job10.0.16.225 443312025-08-20 09:17:22.552998-03 2025-08-20 09:17:56.051032-032025-08-20 09:17:56.051092-03ClientClientReadidle   COMMITclient backend
1665815312documents31714 16402postgrescte-lambda-aws10.0.20.66 575252025-08-20 09:10:13.317613-032025-08-20 09:18:40.942429-032025-08-20 09:18:41.027013-032025-08-20 09:18:41.027088-03ClientClientReadidle in transaction792186818 8244427782796884113UPDATE document_status SET status = $1, type = $2, nsu = $3, cnpj_issuer = $4, protocol = $5, manifestation = $6, canceled_at = $7, cce_events = $8, cce_updated_at = $9, history = CAST($10 AS JSONB) WHERE key = $11client backend
16450fiscal7395 16402postgrespostgres_fdw127.0.0.1 427242025-08-20 09:16:21.068919-03 2025-08-20 09:16:21.340643-032025-08-20 09:16:21.340676-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
16450fiscal7431 16402postgrespostgres_fdw127.0.0.1 427462025-08-20 09:16:21.571723-03 2025-08-20 09:16:21.670429-032025-08-20 09:16:21.670468-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
16450fiscal7386 16402postgrespostgres_fdw127.0.0.1 427222025-08-20 09:16:20.969081-03 2025-08-20 09:16:21.052061-032025-08-20 09:16:21.052096-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents8310 16402postgrescfe-job-download-documentos10.0.16.225 96672025-08-20 09:17:36.229469-03 2025-08-20 09:18:26.227832-032025-08-20 09:18:26.22802-03ClientClientReadidle    client backend
16450fiscal7440 16402postgrespostgres_fdw127.0.0.1 427562025-08-20 09:16:21.689963-03 2025-08-20 09:16:21.908545-032025-08-20 09:16:21.90857-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
16450fiscal29262 16402postgresecac-darf-job-download-documentos10.0.16.232 102172025-08-20 09:06:25.27998-03 2025-08-20 09:18:37.417875-032025-08-20 09:18:37.417911-03ClientClientReadidle    client backend
1665815312documents30569 16402postgresdocument-api10.0.16.46 464552025-08-20 09:08:41.444149-03 2025-08-20 09:16:42.399253-032025-08-20 09:16:42.401765-03ClientClientReadidle   COMMITclient backend
16450fiscal8331 16402postgreslambda-go-revizia-metrics10.0.16.55 102312025-08-20 09:17:43.586453-03 2025-08-20 09:17:43.611081-032025-08-20 09:17:43.612581-03ClientClientReadidle  -6488867169811202377
select id, type, file_name
from book_keeping
where status in ('READING','READING_WITH_PRIORITY')
order by created_at, updated_at
client backend
16450fiscal27529 16402postgresfiscal-intelligence-core-job10.0.16.46 208672025-08-20 09:02:31.680148-03 2025-08-20 09:16:37.134942-032025-08-20 09:16:37.135164-03ClientClientReadidle   ROLLBACKclient backend
16450fiscal7412 16402postgrespostgres_fdw127.0.0.1 427322025-08-20 09:16:21.363994-03 2025-08-20 09:16:21.549473-032025-08-20 09:16:21.549501-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents1526 16402postgrescfe-importar-sqs10.0.20.107 585812025-08-20 09:13:55.971701-03 2025-08-20 09:18:01.826759-032025-08-20 09:18:01.827935-03ClientClientReadidle   COMMITclient backend
16450fiscal28229 16402postgrescfe-importar-sqs10.0.16.46 128312025-08-20 09:03:50.058135-03 2025-08-20 09:17:55.185101-032025-08-20 09:17:55.185154-03ClientClientReadidle    client backend
3333716331revizia5831 16402postgresmensageria-api10.0.16.55 486852025-08-20 09:15:55.419502-03 2025-08-20 09:16:02.321015-032025-08-20 09:16:02.321096-03ClientClientReadidle    client backend
1665815312documents31744 16402postgrescfe-job-download-documentos-recorrentes10.0.16.91 129872025-08-20 09:10:16.671194-03 2025-08-20 09:18:25.089494-032025-08-20 09:18:25.090454-03ClientClientReadidle   COMMITclient backend
1665815312documents1648 16402postgresnfe-lambda-aws10.0.16.55 31832025-08-20 09:14:26.846786-03 2025-08-20 09:17:02.532577-032025-08-20 09:17:02.535106-03ClientClientReadidle   COMMITclient backend
16450fiscal7459 16402postgrespostgres_fdw127.0.0.1 427582025-08-20 09:16:21.922281-03 2025-08-20 09:16:22.008288-032025-08-20 09:16:22.008315-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
16450fiscal7470 16402postgrespostgres_fdw127.0.0.1 427602025-08-20 09:16:22.025265-03 2025-08-20 09:16:23.965968-032025-08-20 09:16:23.965998-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
5postgres3723 16402postgrespgAdmin 4 - DB:postgres10.0.28.38 387542025-08-19 10:33:57.773971-03 2025-08-20 09:18:36.314569-032025-08-20 09:18:36.318672-03ClientClientReadidle  -3012509240442274851/*pga4dash*/
SELECT 'session_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT count(*) FROM pg_catalog.pg_stat_activity) AS "Total",
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE state = 'active') AS "Active",
(SELECT count(*) FROM pg_catalog.pg_stat_activity WHERE state = 'idle') AS "Idle"
) t
UNION ALL
SELECT 'tps_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(xact_commit) + sum(xact_rollback) FROM pg_catalog.pg_stat_database) AS "Transactions",
(SELECT sum(xact_commit) FROM pg_catalog.pg_stat_database) AS "Commits",
(SELECT sum(xact_rollback) FROM pg_catalog.pg_stat_database) AS "Rollbacks"
) t
UNION ALL
SELECT 'ti_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(tup_inserted) FROM pg_catalog.pg_stat_database) AS "Inserts",
(SELECT sum(tup_updated) FROM pg_catalog.pg_stat_database) AS "Updates",
(SELECT sum(tup_deleted) FROM pg_catalog.pg_stat_database) AS "Deletes"
) t
UNION ALL
SELECT 'to_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(tup_fetched) FROM pg_catalog.pg_stat_database) AS "Fetched",
(SELECT sum(tup_returned) FROM pg_catalog.pg_stat_database) AS "Returned"
) t
UNION ALL
SELECT 'bio_stats' AS chart_name, pg_catalog.row_to_json(t) AS chart_data
FROM (SELECT
(SELECT sum(blks_read) FROM pg_catalog.pg_stat_database) AS "Reads",
(SELECT sum(blks_hit) FROM pg_catalog.pg_stat_database) AS "Hits"
) t
client backend
16450fiscal18540 16402postgresfiscal-intelligence-sped-analises-job10.0.16.55 33372025-08-20 08:48:39.313687-03 2025-08-20 09:18:40.68932-032025-08-20 09:18:40.690742-03ClientClientReadidle   COMMITclient backend
1665815312documents31805 16402postgresnfe-lambda-aws10.0.20.66 203952025-08-20 09:10:19.658105-03 2025-08-20 09:17:44.167096-032025-08-20 09:17:44.16946-03ClientClientReadidle   COMMITclient backend
1665815312documents1699 16402postgresnfe-lambda-aws10.0.20.66 375012025-08-20 09:14:29.861511-03 2025-08-20 09:16:58.78449-032025-08-20 09:16:58.787282-03ClientClientReadidle   COMMITclient backend
16450fiscal1704 16402postgresfiscal-intelligence-sped-analises-job10.0.16.91 264032025-08-20 09:14:32.671841-03 2025-08-20 09:16:31.035965-032025-08-20 09:16:31.037036-03ClientClientReadidle   COMMITclient backend
1665815312documents1730 16402postgresnfe-lambda-aws10.0.16.225 435472025-08-20 09:14:36.938816-03 2025-08-20 09:17:35.546929-032025-08-20 09:17:35.549953-03ClientClientReadidle   COMMITclient backend
16450fiscal8335 16402postgresfiscal-intelligence-sped-analises-job10.0.20.66 85832025-08-20 09:17:46.741986-03 2025-08-20 09:18:03.818488-032025-08-20 09:18:03.818572-03ClientClientReadidle    client backend
16450fiscal1527 16402postgresfiscal-intelligence-sped-job10.0.20.107 574512025-08-20 09:13:57.864128-032025-08-20 09:16:21.720309-032025-08-20 09:18:41.024858-032025-08-20 09:18:41.028302-03ClientClientReadidle in transaction792182431792182431-7619687138498640239insert into document_analysis_issues (created_at, created_by, deleted, updated_at, updated_by, analysis_type_result_id, document_analysis_id, result_param) values ($1, $2, $3, $4, $5, $6, $7, $8)
RETURNING *
client backend
16450fiscal7489 16402postgrespostgres_fdw127.0.0.1 427722025-08-20 09:16:22.273061-03 2025-08-20 09:16:24.742381-032025-08-20 09:16:24.742409-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
3333716331revizia8355 16402postgrespostgres_fdw127.0.0.1 392562025-08-20 09:17:49.325282-03 2025-08-20 09:17:50.392821-032025-08-20 09:17:50.392998-03ClientClientReadidle  -4518006279650829961ABORT TRANSACTIONclient backend
16450fiscal8356 16402postgrespostgres_fdw127.0.0.1 392602025-08-20 09:17:49.333183-03 2025-08-20 09:18:16.038601-032025-08-20 09:18:16.0387-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
16450fiscal1738 16402postgresfiscal-intelligence-api10.0.16.91 655172025-08-20 09:14:37.769485-03 2025-08-20 09:18:15.159207-032025-08-20 09:18:15.159273-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents1723 16402postgresnfe-lambda-aws10.0.16.217 300592025-08-20 09:14:36.131031-03 2025-08-20 09:16:48.597138-032025-08-20 09:16:48.599449-03ClientClientReadidle   COMMITclient backend
16450fiscal955 16402postgresfiscal-intelligence-sped-analises-job10.0.16.217 161092025-08-20 09:12:46.329138-032025-08-20 09:18:40.567282-032025-08-20 09:18:40.759173-032025-08-20 09:18:40.76072-03ClientClientReadidle in transaction792186814792182431-7619687138498640239insert into document_analysis_issues (created_at, created_by, deleted, updated_at, updated_by, analysis_type_result_id, document_analysis_id, result_param) values ($1, $2, $3, $4, $5, $6, $7, $8)
RETURNING *
client backend
1665815312documents27172 16402postgrescte-lambda-aws10.0.20.107 363892025-08-20 09:01:52.666665-03 2025-08-20 09:18:30.378199-032025-08-20 09:18:30.379621-03ClientClientReadidle   COMMITclient backend
1665815312documents29268 16402postgresdocument-api10.0.16.55 215652025-08-20 09:06:28.296377-03 2025-08-20 09:16:28.000044-032025-08-20 09:16:28.000075-03ClientClientReadidle   COMMITclient backend
16450fiscal8376 16402postgresfiscal-intelligence-sped-job10.0.20.107 177992025-08-20 09:17:56.05714-03 2025-08-20 09:18:41.028354-032025-08-20 09:18:41.028359-03ClientClientReadidle    client backend
1665815312documents28840 16402postgresecac-situacao-fiscal-api10.0.20.107 494352025-08-20 09:05:21.229298-03 2025-08-20 09:18:33.202862-032025-08-20 09:18:33.202948-03ClientClientReadidle    client backend
1665815312documents5333 16402postgrescfe-job-download-documentos10.0.16.91 469212025-08-20 08:23:49.553524-03 2025-08-20 09:18:38.588198-032025-08-20 09:18:38.588301-03ClientClientReadidle    client backend
1665815312documents1722 16402postgresnfe-lambda-aws10.0.16.217 171732025-08-20 09:14:36.130033-03 2025-08-20 09:18:32.972589-032025-08-20 09:18:32.975064-03ClientClientReadidle   COMMITclient backend
16450fiscal31902 16402postgrescfe-importar-sqs10.0.20.107 343432025-08-20 09:10:39.576146-03 2025-08-20 09:17:55.18905-032025-08-20 09:17:55.189132-03ClientClientReadidle    client backend
16450fiscal7498 16402postgrespostgres_fdw127.0.0.1 427882025-08-20 09:16:22.42308-03 2025-08-20 09:16:24.641707-032025-08-20 09:16:24.641839-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents29704 16402postgresesocial-totalizador-fgts-empregador-importar-from-sqs10.0.20.66 478852025-08-20 09:07:28.890314-03 2025-08-20 09:18:28.777804-032025-08-20 09:18:28.777874-03ClientClientReadidle    client backend
16450fiscal7515 16402postgrespostgres_fdw127.0.0.1 427902025-08-20 09:16:22.622104-03 2025-08-20 09:16:23.866867-032025-08-20 09:16:23.866894-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents1733 16402postgresnfe-lambda-aws10.0.16.225 305232025-08-20 09:14:36.973295-03 2025-08-20 09:18:33.544823-032025-08-20 09:18:33.54704-03ClientClientReadidle   COMMITclient backend
3333716331revizia29703 16402postgresesocial-totalizador-fgts-empregador-importar-from-sqs10.0.20.66 310712025-08-20 09:07:28.890048-03 2025-08-20 09:18:28.777968-032025-08-20 09:18:28.778022-03ClientClientReadidle    client backend
1665815312documents7718 16402postgresdocument-api10.0.16.232 550372025-08-20 09:16:25.259667-03 2025-08-20 09:16:27.960339-032025-08-20 09:16:27.960593-03ClientClientReadidle   COMMITclient backend
16450fiscal3639 16402postgresfiscal-intelligence-core-job10.0.16.225 489932025-08-20 09:14:55.079415-032025-08-20 09:17:02.128941-032025-08-20 09:18:24.084309-032025-08-20 09:18:24.08431-03  active792184897792182431-6488867169811202377 SELECT cnpj, cnpjRegistro, periodo, registro, codigoContaContabil, '' AS codigoItem, '' AS descricaoItem, valor, pisRestituir, cofinsRestituir, possivelCreditoTotal, taxaSelicAcumulada, possivelCreditoTotalAtualizado FROM ( SELECT bklF550.id, bklF010.cnpj, bklF010.cnpjRegistro, bklF010.periodo, 'F550' AS registro, bkl0500.json_line ->> 'codigo_conta_contabil' AS codigoContaContabil, CAST(bklF550.json_line ->> 'valor_total_receita' AS NUMERIC) AS valor, CAST(bklF550.json_line ->> 'valor_pis' AS NUMERIC) AS pisRestituir, CAST(bklF550.json_line ->> 'valor_cofins' AS NUMERIC) AS cofinsRestituir, CAST(bklF550.json_line ->> 'valor_pis' AS NUMERIC) + CAST(bklF550.json_line ->> 'valor_cofins' AS NUMERIC) AS possivelCreditoTotal, CAST(taxa_selic_acumulada(bklF010.periodo) AS NUMERIC) AS taxaSelicAcumulada, ((CAST(bklF550.json_line ->> 'valor_pis' AS NUMERIC) + CAST(bklF550.json_line ->> 'valor_cofins' AS NUMERIC)) * CAST(taxa_selic_acumulada(bklF010.periodo) / 100 AS NUMERIC)) + (CAST(bklF550.json_line ->> 'valor_pis' AS NUMERIC) + CAST(bklF550.json_line ->> 'valor_cofins' AS NUMERIC)) AS possivelCreditoTotalAtualizado, ( ( UPPER(bkl0500.json_line ->> 'nome_conta') LIKE '%REC%' AND UPPER(bkl0500.json_line ->> 'nome_conta') LIKE '%ALUGU%' ) OR ( UPPER(bklF550.json_line ->> 'informacao_complementar') LIKE '%REC%' AND UPPER(bklF550.json_line ->> 'informacao_complementar') LIKE '%ALUGU%' ) ) AS descricaoPresente FROM ( SELECT bk.id, bk.cnpj, bk.period AS periodo, bklF010.json_line ->> 'cnpj' AS cnpjRegistro, bklF010.index AS indiceInicialF010, ( SELECT bklint.index FROM book_keeping_line bklint WHERE bklint.identifier = 'F010' AND bklF010.book_keeping_id = bklint.book_keeping_id AND bklint.index > bklF010.index ORDER BY bklint.index LIMIT 1 ) AS indiceFinalF010 FROM book_keeping bk INNER JOIN book_keeping_line bklF010 ON bk.id = bklF010.book_keeping_id WHERE bklF010.book_keeping_id IN ($1) AND bk.cnpj = $2 AND bklF010.identifier = 'F010' ) bklF010 INNER JOIN book_keeping_line bklF550 ON bklF010.id = bklF550.book_keeping_id AND bklF550.cnpj_raiz = SUBSTRING($3, 1, 8) LEFT OUTER JOIN book_keeping_line bkl0500 ON bklF010.id = bkl0500.book_keeping_id AND bkl0500.cnpj_raiz = SUBSTRING($4, 1, 8) AND bkl0500.identifier = '0500' AND bkl0500.json_line ->> 'codigo_conta_contabil' = bklF550.json_line ->> 'codigo_conta_analitica_contabil' AND bkl0500.json_line ->> 'codigo_natureza_conta' = '04' AND bkl0500.json_line ->> 'codigo_conta_contabil_referenciada' IN ('3.11.01.05.01.19','3.01.01.01.01.08') WHERE bklF550.identifier = 'F550' AND bklF550.index > bklF010.indiceInicialF010 AND (bklF010.indiceFinalF010 IS NULL OR bklF550.index < bklF010.indiceFinalF010) AND CAST(bklF550.json_line ->> 'valor_base_calculo_pis' AS NUMERIC) <> 0 AND CAST(bklF550.json_line ->> 'valor_pis' AS NUMERIC) <> 0 AND CAST(bklF550.json_line ->> 'valor_base_calculo_cofins' AS NUMERIC) <> 0 AND CAST(bklF550.json_line ->> 'valor_cofins' AS NUMERIC) <> 0 ) resultado WHERE descricaoPresente = true ORDER BY id limit $5client backend
3333716331revizia7802 16402postgresrvz-sintegra-job10.0.16.225 52112025-08-20 09:16:26.562391-032025-08-20 09:18:41.024046-032025-08-20 09:18:41.024292-032025-08-20 09:18:41.024293-03  active 792182431 select dadossinte0_.id as id1_0_, dadossinte0_.cnpj as cnpj2_0_, dadossinte0_.data_importacao as data_imp3_0_, dadossinte0_.inscricao_estadual as inscrica4_0_, dadossinte0_.mensagem as mensagem5_0_, dadossinte0_.situacao_cnpj as situacao6_0_, dadossinte0_.situacao_inscricao_estadual as situacao7_0_, dadossinte0_.tipo_inscricao_estadual as tipo_ins8_0_, dadossinte0_.ultima as ultima9_0_ from dados_sintegra dadossinte0_ where dadossinte0_.cnpj=$1client backend
1665815312documents1906 16402postgresdocument-api10.0.16.46 566332025-08-20 09:14:46.127005-03 2025-08-20 09:18:33.603829-032025-08-20 09:18:33.603896-03ClientClientReadidle   COMMITclient backend
3333716331revizia8377 16402postgresgo-sped-api10.0.20.66 476532025-08-20 09:17:57.438704-03 2025-08-20 09:17:57.465942-032025-08-20 09:17:57.480604-03ClientClientReadidle   
select distinct e.cnpj
from empresa e
inner join conta_empresa ce on ce.empresa_id = e.id
inner join conta c on c.id = ce.conta_id
where substr(e.cnpj,1,8) = $1
and c.status in ('ATIVO', 'TRIAL')
and c.deleted = false
and e.deleted = false
and ce.deleted = false
client backend
1665815312documents30743 16402postgresnfe-lambda-aws10.0.16.225 181692025-08-20 09:08:42.870287-03 2025-08-20 09:17:35.535241-032025-08-20 09:17:35.53755-03ClientClientReadidle   COMMITclient backend
1665815312documents29761 16402postgresnfe-lambda-aws10.0.16.46 68812025-08-20 09:07:34.027726-03 2025-08-20 09:18:39.346952-032025-08-20 09:18:39.349829-03ClientClientReadidle   COMMITclient backend
1665815312documents7826 16402postgrescfe-job-download-documentos10.0.20.107 320092025-08-20 09:16:26.692108-03 2025-08-20 09:18:40.590333-032025-08-20 09:18:40.590457-03ClientClientReadidle    client backend
1665815312documents23923 16402postgresnfe-lambda-aws10.0.16.217 232792025-08-20 08:55:49.767794-03 2025-08-20 09:16:48.605451-032025-08-20 09:16:48.608093-03ClientClientReadidle   COMMITclient backend
1665815312documents2292 16402postgrescfe-importar-sqs10.0.16.217 244492025-08-20 09:14:46.925865-03 2025-08-20 09:17:54.773015-032025-08-20 09:17:54.774805-03ClientClientReadidle   COMMITclient backend
16450fiscal28231 16402postgrescfe-importar-sqs10.0.16.55 272412025-08-20 09:03:50.291871-03 2025-08-20 09:16:51.171267-032025-08-20 09:16:51.171356-03ClientClientReadidle    client backend
1665815312documents23991 16402postgresnfe-lambda-aws10.0.16.55 26552025-08-20 08:55:56.602757-03 2025-08-20 09:18:33.476382-032025-08-20 09:18:33.478708-03ClientClientReadidle   COMMITclient backend
3333716331revizia28233 16402postgrescfe-importar-sqs10.0.16.55 353172025-08-20 09:03:50.292506-03 2025-08-20 09:17:52.180614-032025-08-20 09:17:52.180711-03ClientClientReadidle    client backend
1665815312documents2085 16402postgresdocument-api10.0.16.232 374432025-08-20 09:14:46.486592-03 2025-08-20 09:18:33.602105-032025-08-20 09:18:33.602175-03ClientClientReadidle   COMMITclient backend
1665815312documents32552 16402postgrescte-lambda-aws10.0.16.232 361312025-08-20 09:11:21.62972-03 2025-08-20 09:18:39.552634-032025-08-20 09:18:39.553825-03ClientClientReadidle   COMMITclient backend
1665815312documents29023 16402postgresnfe-lambda-aws10.0.20.66 187812025-08-20 09:05:45.783539-03 2025-08-20 09:18:37.591953-032025-08-20 09:18:37.595075-03ClientClientReadidle   COMMITclient backend
16450fiscal8378 16402postgresfiscal-intelligence-sped-job10.0.16.232 40072025-08-20 09:17:57.899177-03 2025-08-20 09:18:38.42106-032025-08-20 09:18:38.421133-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents29025 16402postgresnfe-lambda-aws10.0.16.91 582792025-08-20 09:05:46.088713-03 2025-08-20 09:18:39.589519-032025-08-20 09:18:39.591554-03ClientClientReadidle   COMMITclient backend
1665815312documents32574 16402postgrescfe-job-download-documentos-recorrentes10.0.16.217 270352025-08-20 09:11:24.191029-03 2025-08-20 09:18:22.90999-032025-08-20 09:18:22.91145-03ClientClientReadidle   COMMITclient backend
3333716331revizia3156 16402postgresnfe-lambda-aws10.0.20.107 127752025-08-20 09:14:48.743192-03 2025-08-20 09:16:02.265367-032025-08-20 09:16:02.265584-03ClientClientReadidle   SELECT ce.conta_id FROM conta_empresa ce INNER JOIN empresa e ON ce.empresa_id = e.id INNER JOIN conta c on ce.conta_id = c.id WHERE e.cnpj IN ($1, $2) AND c.status = 'ATIVO' AND c.id <> 1 LIMIT 1client backend
1665815312documents32012 16402postgresdocument-api10.0.16.225 576012025-08-20 09:10:50.98523-032025-08-20 09:18:41.028707-032025-08-20 09:18:41.029571-032025-08-20 09:18:41.029571-03  active 792182431 select * from pg_stat_activityclient backend
1665815312documents7910 16402postgresPostgreSQL JDBC Driver10.0.16.232 451252025-08-20 09:16:33.277241-03 2025-08-20 09:18:24.020464-032025-08-20 09:18:24.02758-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, ARRAY_TO_STRING( ARRAY( select distinct item.produto -> 'prod' ->> 'cfop' as cfop from jsonb_array_elements(d.data -> 'nfe' -> 'infNFe' -> 'det') WITH ORDINALITY item(produto) ), ', ' ) as cfops, cast(d.data -> 'nfe' -> 'infNFe' -> 'ide' ->> 'nnf' as int8) AS numeroNota FROM document d WHERE d.cnpj_issuer = $1 AND d.data_emissao BETWEEN ($2) AND ($3) AND ($4 = 'nao_filtrar_ie' OR d.data -> 'nfe' -> 'infNFe' -> 'emit' ->> 'ie' =$5) AND (d.data_entrada_saida IS NULL OR d.data_entrada_saida BETWEEN ($6) AND ($7)) AND d.type IN ('NFE_4_0', 'NFE_3_1') AND EXISTS ( SELECT 1 FROM document_status ds WHERE d.key = ds.key AND d.cnpj_issuer = ds.cnpj_issuer AND d.protocol = ds.protocol AND d.nsu = ds.nsu AND d.type = ds.type and ds.status <> '2' ) ORDER BY d.data_emissao LIMIT $8 OFFSET $9 client backend
1665815312documents32695 16402postgresPostgreSQL JDBC Driver10.0.16.217 355012025-08-20 09:11:30.366295-03 2025-08-20 09:16:12.314079-032025-08-20 09:16:12.31889-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, d.data -> 'cte' -> 'infCte' -> 'ide' ->> 'cfop' as cfops, cast(d.data -> 'cte' -> 'infCte' -> 'ide' ->> 'nct' as int8) AS numeroNota FROM document d WHERE d.data_emissao BETWEEN ($1) AND ($2) AND d.type IN ('CTE','CTE_OS') AND ($3 = 'nao_filtrar_ie' OR d.data -> 'cte' -> 'infCte' -> 'dest' ->> 'ie' =$4) AND ( ( d.cnpj_cpf_tomador = $5 AND EXISTS ( SELECT 1 FROM document_status ds WHERE d.key = ds.key AND d.cnpj_issuer = ds.cnpj_issuer AND d.protocol = ds.protocol AND d.nsu = ds.nsu AND d.type = ds.type AND ds.status <> '3' AND (ds.manifestation is null or ds.manifestation not in ('610110')) ) ) OR ( d.cnpj_issuer = $6 ) ) ORDER BY d.data_emissao LIMIT $7 OFFSET $8 client backend
1665815312documents28973 16402postgrescte-lambda-aws10.0.16.225 565192025-08-20 09:05:35.727873-032025-08-20 09:18:41.017822-032025-08-20 09:18:41.018364-032025-08-20 09:18:41.018364-03  active 792182431 select key from document where key = $1 and type = $2 and protocol = $3 and data_emissao between $4 and $5 limit 1client backend
1665815312documents32011 16402postgresdocument-api10.0.16.55 538292025-08-20 09:10:50.984689-03 2025-08-20 09:16:27.979863-032025-08-20 09:16:27.979922-03ClientClientReadidle   COMMITclient backend
3333716331revizia7813 16402postgresrvz-sintegra-job10.0.20.66 328512025-08-20 09:16:26.593514-03 2025-08-20 09:18:40.959805-032025-08-20 09:18:40.959822-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents7717 16402postgresdocument-api10.0.20.107 340672025-08-20 09:16:25.256716-03 2025-08-20 09:18:33.607964-032025-08-20 09:18:33.608016-03ClientClientReadidle   COMMITclient backend
1665815312documents32745 16402postgrescte-lambda-aws10.0.16.217 202772025-08-20 09:11:41.089392-03 2025-08-20 09:18:38.056714-032025-08-20 09:18:38.059247-03ClientClientReadidle   COMMITclient backend
16450fiscal7913 16402postgresfiscal-intelligence-sped-analises-job10.0.16.225 486512025-08-20 09:16:33.67915-032025-08-20 09:16:41.692698-032025-08-20 09:18:41.024057-032025-08-20 09:18:41.02762-03ClientClientReadidle in transaction792183724792182431-7619687138498640239insert into document_analysis_issues (created_at, created_by, deleted, updated_at, updated_by, analysis_type_result_id, document_analysis_id, result_param) values ($1, $2, $3, $4, $5, $6, $7, $8)
RETURNING *
client backend
3333716331revizia32764 16402postgrescore-api10.0.20.107 265612025-08-20 09:11:43.607706-03 2025-08-20 09:18:33.577575-032025-08-20 09:18:33.577637-03ClientClientReadidle   COMMITclient backend
16450fiscal359 16402postgrescfe-importar-sqs10.0.16.217 108812025-08-20 09:11:45.319853-03 2025-08-20 09:17:52.218283-032025-08-20 09:17:52.218468-03ClientClientReadidle    client backend
16450fiscal29339 16402postgresfiscal-intelligence-api10.0.20.107 650172025-08-20 09:06:46.65192-03 2025-08-20 09:18:13.430086-032025-08-20 09:18:13.430104-03ClientClientReadidle   ROLLBACKclient backend
3333716331revizia29359 16402postgrescfe-importar-sqs10.0.16.46 552592025-08-20 09:06:51.717591-03 2025-08-20 09:16:48.460836-032025-08-20 09:16:48.461047-03ClientClientReadidle    client backend
16450fiscal8023 16402postgresfiscal-intelligence-core-job10.0.16.232 158092025-08-20 09:16:37.081826-03 2025-08-20 09:16:37.28436-032025-08-20 09:16:37.28442-03ClientClientReadidle   ROLLBACKclient backend
16450fiscal29360 16402postgrescfe-importar-sqs10.0.16.225 54732025-08-20 09:06:51.71785-03 2025-08-20 09:17:58.957191-032025-08-20 09:17:58.957281-03ClientClientReadidle    client backend
3333716331revizia371 16402postgrescfe-importar-sqs10.0.20.66 441612025-08-20 09:11:46.014345-03 2025-08-20 09:17:55.190017-032025-08-20 09:17:55.190157-03ClientClientReadidle    client backend
1665815312documents29361 16402postgrescfe-importar-sqs10.0.16.225 362972025-08-20 09:06:51.718098-03 2025-08-20 09:16:48.950464-032025-08-20 09:16:48.951839-03ClientClientReadidle   COMMITclient backend
1665815312documents370 16402postgrescfe-importar-sqs10.0.20.66 375592025-08-20 09:11:46.014078-03 2025-08-20 09:17:56.629782-032025-08-20 09:17:56.630875-03ClientClientReadidle   COMMITclient backend
1665815312documents25494 16402postgrescfe-job-download-documentos10.0.16.225 137872025-08-20 08:57:43.471105-03 2025-08-20 09:18:39.228201-032025-08-20 09:18:39.228231-03ClientClientReadidle    client backend
1665815312documents29362 16402postgrescfe-importar-sqs10.0.16.46 200012025-08-20 09:06:51.761595-03 2025-08-20 09:16:46.924174-032025-08-20 09:16:46.925512-03ClientClientReadidle   COMMITclient backend
16450fiscal8024 16402postgresfiscal-intelligence-core-job10.0.20.66 630932025-08-20 09:16:37.081827-03 2025-08-20 09:16:37.163959-032025-08-20 09:16:37.163993-03ClientClientReadidle   ROLLBACKclient backend
3333716331revizia29366 16402postgrescfe-importar-sqs10.0.16.225 21332025-08-20 09:06:52.214806-03 2025-08-20 09:16:51.171313-032025-08-20 09:16:51.171401-03ClientClientReadidle    client backend
3333716331revizia372 16402postgrescfe-importar-sqs10.0.16.217 413492025-08-20 09:11:46.038918-03 2025-08-20 09:17:58.955897-032025-08-20 09:17:58.956051-03ClientClientReadidle    client backend
16450fiscal962 16402postgresfiscal-intelligence-sped-analises-job10.0.20.66 354812025-08-20 09:12:47.283504-03 2025-08-20 09:18:34.208586-032025-08-20 09:18:34.209838-03ClientClientReadidle   COMMITclient backend
16450fiscal8025 16402postgresfiscal-intelligence-core-job10.0.20.66 460832025-08-20 09:16:37.093177-03 2025-08-20 09:18:15.65481-032025-08-20 09:18:15.654854-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents496 16402postgresPostgreSQL JDBC Driver10.0.16.217 588492025-08-20 09:11:52.887543-03 2025-08-20 09:16:12.301135-032025-08-20 09:16:12.310727-03ClientClientReadidle    SELECT d.key, d.cnpj_issuer AS cnpjIssuer, d.cnpj_addressee AS cnpjAddressee, ( SELECT ds.status FROM document_status ds WHERE d.cnpj_issuer = ds.cnpj_issuer AND d.nsu = ds.nsu AND d.key = ds.key AND d.protocol = ds.protocol AND d.type = ds.type ) status, d.type, d.data, d.info, d.imported_at AS importedAt, d.name_file AS nameFile, d.data_emissao AS dataEmissao, d.data_entrada_saida AS dataEntradaSaida, ARRAY_TO_STRING( ARRAY( select distinct item.produto -> 'prod' ->> 'cfop' as cfop from jsonb_array_elements(d.data -> 'infCFe' -> 'det') WITH ORDINALITY item(produto) ), ', ' ) as cfops, cast(d.data -> 'infCFe' -> 'ide' ->> 'ncFe' as int8) AS numeroNota FROM document d WHERE d.cnpj_issuer = $1 AND d.data_emissao BETWEEN ($2) AND ($3) AND ($4 = 'nao_filtrar_ie' OR d.data -> 'infCFe' -> 'emit' ->> 'ie' =$5) AND d.type LIKE 'CFE_0%' ORDER BY d.data_emissao LIMIT $6 OFFSET $7 client backend
1665815312documents29531 16402postgrescfe-importar-sqs10.0.16.46 362392025-08-20 09:06:59.434997-03 2025-08-20 09:16:52.09134-032025-08-20 09:16:52.092383-03ClientClientReadidle   COMMITclient backend
16450fiscal29520 16402postgresfiscal-intelligence-core-job10.0.16.232 137052025-08-20 09:06:56.16185-03 2025-08-20 09:17:36.87103-032025-08-20 09:17:36.871177-03ClientClientReadidle   ROLLBACKclient backend
1665815312documents29762 16402postgresnfe-lambda-aws10.0.16.46 348332025-08-20 09:07:34.045024-03 2025-08-20 09:17:28.670369-032025-08-20 09:17:28.672444-03ClientClientReadidle   COMMITclient backend
1665815312documents8026 16402postgresmensageria-api10.0.16.217 386872025-08-20 09:16:37.826942-032025-08-20 09:18:41.028088-032025-08-20 09:18:41.028319-032025-08-20 09:18:41.028354-03ClientClientReadidle in transaction 792182431 select solicitaca0_.id as id1_2_, solicitaca0_.cnpj as cnpj2_2_, solicitaca0_.codigo_status_resposta as codigo_s3_2_, solicitaca0_.data_fim_download as data_fim4_2_, solicitaca0_.data_inicio_download as data_ini5_2_, solicitaca0_.data_solicitacao as data_sol6_2_, solicitaca0_.data_ultima_resposta as data_ult7_2_, solicitaca0_.descricao_status_resposta as descrica8_2_, solicitaca0_.maximo_nsu_disponivel as maximo_n9_2_, solicitaca0_.mensagem_erro as mensage10_2_, solicitaca0_.nsu_inicio as nsu_ini11_2_, solicitaca0_.quantidade_documentos as quantid12_2_, solicitaca0_.status as status13_2_, solicitaca0_.ultimo_nsu_disponivel as ultimo_14_2_, solicitaca0_.ultimo_nsu_solicitado as ultimo_15_2_ from public.solicitacao_download_nfe solicitaca0_ where solicitaca0_.cnpj=$1 order by solicitaca0_.id desc limit $2client backend
3333716331revizia8027 16402postgrespostgres_fdw127.0.0.1 592562025-08-20 09:16:38.148799-03 2025-08-20 09:16:48.724769-032025-08-20 09:16:48.724796-03ClientClientReadidle  -4518006279650829961ABORT TRANSACTIONclient backend
16450fiscal8028 16402postgrespostgres_fdw127.0.0.1 592622025-08-20 09:16:38.152303-03 2025-08-20 09:18:27.288641-032025-08-20 09:18:27.288728-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents960 16402postgrescte-lambda-aws10.0.16.232 265452025-08-20 09:12:46.888991-03 2025-08-20 09:18:36.917898-032025-08-20 09:18:36.918037-03ClientClientReadidle   ROLLBACKclient backend
3333716331revizia8031 16402postgrespostgres_fdw127.0.0.1 592642025-08-20 09:16:38.721827-03 2025-08-20 09:18:30.102525-032025-08-20 09:18:30.102551-03ClientClientReadidle  -4518006279650829961ABORT TRANSACTIONclient backend
1665815312documents523 16402postgrescfe-importar-sqs10.0.16.55 611332025-08-20 09:11:55.816096-03 2025-08-20 09:17:53.786629-032025-08-20 09:17:53.787674-03ClientClientReadidle   COMMITclient backend
16450fiscal522 16402postgrescfe-importar-sqs10.0.16.91 355672025-08-20 09:11:55.815765-03 2025-08-20 09:17:52.180765-032025-08-20 09:17:52.180839-03ClientClientReadidle    client backend
3333716331revizia8046 16402postgrescertificado-api10.0.16.91 379732025-08-20 09:16:41.243533-03 2025-08-20 09:17:31.479858-032025-08-20 09:17:31.480001-03ClientClientReadidle    client backend
3333716331revizia8047 16402postgrescertificado-api10.0.20.66 645652025-08-20 09:16:41.243792-03 2025-08-20 09:18:37.567494-032025-08-20 09:18:37.56774-03ClientClientReadidle    client backend
1665815312documents8052 16402postgresmensageria-api10.0.16.91 153872025-08-20 09:16:42.818703-03 2025-08-20 09:18:03.645003-032025-08-20 09:18:03.646115-03ClientClientReadidle   COMMITclient backend
16450fiscal8063 16402postgresfiscal-intelligence-sped-analises-job10.0.16.225 649452025-08-20 09:16:46.645257-03 2025-08-20 09:18:03.643047-032025-08-20 09:18:03.643174-03ClientClientReadidle    client backend
16450fiscal8064 16402postgresfiscal-intelligence-sped-analises-job10.0.16.225 464952025-08-20 09:16:46.652927-03 2025-08-20 09:18:38.200133-032025-08-20 09:18:38.201456-03ClientClientReadidle   COMMITclient backend
3333716331revizia8068 16402postgrespostgres_fdw127.0.0.1 590482025-08-20 09:16:47.817846-03 2025-08-20 09:16:49.021387-032025-08-20 09:16:49.021564-03ClientClientReadidle  -4518006279650829961ABORT TRANSACTIONclient backend
16450fiscal8069 16402postgrespostgres_fdw127.0.0.1 590622025-08-20 09:16:47.839003-03 2025-08-20 09:16:47.915653-032025-08-20 09:16:47.915676-03ClientClientReadidle  5387600465647979654COMMIT TRANSACTIONclient backend
1665815312documents8060 16402postgresnfe-lambda-aws10.0.16.232 138732025-08-20 09:16:45.163079-03 2025-08-20 09:18:37.734106-032025-08-20 09:18:37.736497-03ClientClientReadidle   COMMITclient backend
1665815312documents8073 16402postgresnfe-lambda-aws10.0.16.217 452812025-08-20 09:16:48.554547-03 2025-08-20 09:17:43.222295-032025-08-20 09:17:43.224359-03ClientClientReadidle   COMMITclient backend
1665815312documents8074 16402postgresnfe-lambda-aws10.0.16.217 145112025-08-20 09:16:48.567461-03 2025-08-20 09:17:21.271207-032025-08-20 09:17:21.273719-03ClientClientReadidle   COMMITclient backend
1665815312documents8075 16402postgresnfe-lambda-aws10.0.16.217 639372025-08-20 09:16:48.588336-03 2025-08-20 09:18:35.901629-032025-08-20 09:18:35.904212-03ClientClientReadidle   COMMITclient backend
  888       2025-06-01 22:10:25.190835-03   ActivityBgWriterMain     background writer
  895       2025-06-01 22:10:25.239278-03   ActivityArchiverMain     archiver
  887       2025-06-01 22:10:25.190687-03   TimeoutCheckpointWriteDelay     checkpointer
  894       2025-06-01 22:10:25.23911-03   ActivityWalWriterMain     walwriter