I'm in need of some help finding the latest inventory of each product. It turns out that in the clause I made, it is returning all the sales related to that product, being that I only need the last one ... The sales are ordered by id. I've made...
I am implementing a simple replication form of two tables or more. I have the replication table that has the name of the table to be replicated and id.
To feed the replication table I have a trigger on each table that will be replicated b...
See below a java code to save a SQL command return in PostgreSQL. The command is EXPLAIN ANALYZE.
The problem is that by saving this to the database, it loses the line breaks. Someone would know how to help me solve this, that is, so that when d...
I need to migrate from sql server 2017 to postgreSQL , but I have never used postgreSQL and am having difficulty.
I need to convert an array json to values that are inserted into the table.
In sql server I used a insert with...
I'm developing a Java system with Spring Boot and created the table as not null as you can see:
CREATE TABLE categoria (
codigo BIGSERIAL,
nome VARCHAR(50) NOT NULL,
PRIMARY KEY(codigo)
);
The problem was that getting a...
I'm trying to import an Xls file into the PostGresSql database, however
when I run the submit on the page itself, the error below occurs:
Undefined offset: 1 in C: \ wamp \ www \ projects ... line 59
Below is the code:
<div clas...
I'm trying to connect the bank to SpringBoot and I'm finding that my problem is here:
# ===============================
# = DATA SOURCE
# ===============================
# Set here configurations for the database connection
spring.datasource.u...
I would like to know how many records in my database, but do not return the quantity.
Look at the records in my database
SQLcommandSelectcount(*)ascontaRegistrosfromtb_produtoswhereprod_nomelike'%"+ +"%';
Result
I have this select:
select
DISTINCT (clients.name) as nomeempresa,
payments.amount_paid as pagamento,
receipts.original_amount as recebimento
FROM
payments,
receipts,
receipt_status,
payment_status,
clients
WHERE
pay...