Hello Ive been running into an issue with postgresql not hitting index on
select queries.
Below is the sql query I used to test my issue.
CREATE TABLE idxtbl (
id BIGINT,
aint BIGINT,
btime TIMESTAMPTZ,
ctext TEXT,
dbool BOOLEAN,
PRIMARY KEY(id)
);
--Inserted 10 mil random data
/* TEST TIMESTAMP
Is there any way to check whether the row already exists before checking
constraints ? I still want it to fail if it turns out to be a new row
(which would violate the not null constraint), but updates the row if it
already exists.
Since if that is not possible, I would need to do a query to
Hi,
Basically I wanted to do a partial update inside pg (9.5), but it seems
that a partial update fails when not all of constraint is fulfilled (such
as the not null constraint)
Below are the sql queries I used,
CREATE TABLE jobs (
id integer PRIMARY KEY,
employee_name TEXT NOT NULL,