Skip to main content

Questions tagged [upsert]

UPSERT is a combination of UPDATE and INSERT, typically used in relational databases.

0 votes
0 answers
41 views

Not able to upsert in Chroma DB

I've been trying to upsert my dataset to Chroma DB but each time the code just terminates with upserting. collection = client.get_or_create_collection('data',embedding_function=...
AKSHAYA KRISHNA P's user avatar
1 vote
1 answer
47 views

Running an update() with parameters from df.to_dict() causes errors

I am attempting to implement a functionality whereby a table in a SQL Server database is updated as per the contents of a pandas dataframe. I check for overlapping IDs in the database table and in the ...
Malak Khan's user avatar
0 votes
0 answers
23 views

How to write insert query using CTE from another table in typeorm query builder

I'm trying to create an SQL query using typeorm's query builder but facing some issue with CTE express which will be the input query for the UPSERT statement Below is the SQL query that I would like ...
Rohit Khatri's user avatar
  • 2,000
0 votes
1 answer
43 views

Unique Constraint Failed In Upsert When Calling bulk_create with update_conficts

Im facing a unique constraint failed error with django. The objective of the api is, eithering creating or updating marks of the student, based on subject variation, exam_results and in bulk. For that,...
OzoneBht's user avatar
0 votes
0 answers
35 views

Need to upsert vectors in pinecone DB in Next JS

So I need help pushing vectors into the db, currently something is wrong with the await function here, I am getting an error. Here is my code for the pinecone.ts file that uploads to the db: import { ...
InfernalCoder's user avatar
0 votes
0 answers
43 views

How to upsert data in mysql in NodeJS

I'm using MySQL for the first time through a NodeJS application. I'm managing to insert into a table, but I'm attempting to adapt my code to upsert the data instead, if a value matches. I've been ...
SosijElizabeth's user avatar
0 votes
0 answers
19 views

How to Sink a Table Stream to postgres when it is getting group by in flink?

I am using Apache Flink 1.19 with java 17. When we do a group by on a data stream it gets continuously changed and updated. So when i want to sink the result to postgres i first try to convert it to ...
nilian's user avatar
  • 5
0 votes
1 answer
66 views

Upsert_all with uniqueness index constraint

I'm facing a dilemma. I've created a model with an wave_order column with uniqueness db index with wavable. wavable is a polymorphic (but we don't care actually). # migration create_table :...
brcebn's user avatar
  • 1,662
1 vote
1 answer
61 views

How to insert many rows of tags based on input array?

I have a table of posts, a table of hashtags, and a table linking posts to hashtags, like so: CREATE TABLE posts( id SERIAL PRIMARY KEY, post_data VARCHAR(128) NOT NULL ); CREATE TABLE hashtags ( id ...
learnandgrow's user avatar
1 vote
2 answers
43 views

Upsert on Conflict with sqlalchemy 2.x and Postgresql

I am using python to query an external api, transform the data and write it to a postgresql database internally. In that process, I am comparing the result from the api with existing data in the ...
chibisuketyan's user avatar
1 vote
1 answer
59 views

Error: ON CONFLICT DO UPDATE command cannot affect row a second time

I have connected the Express Javascript framework to PostgreSQL. I am building small file upload project. I have 100000 CSV data to upload and I have to do it fast. I have to insure that user_email is ...
Sohail Shaikh's user avatar
1 vote
1 answer
89 views

Confusion about what Room "Upsert" returns after a successful update

I read somewhere (can't remember the source) that Upsert usually returns -1 if an error occurs. Recently in my project I have observed that Upsert is returning -1 - even though the update is ...
TheSelfTaughtNoob's user avatar
1 vote
2 answers
110 views

Hibernate StatelessSession.upsert() based on @NaturalId

I have such entity with surrogate PK and unique key based on 3 varchar columns. public class InvoiceEntity { @Id @GeneratedValue private UUID id; @NaturalId private ...
Roman Oborin's user avatar
0 votes
0 answers
25 views

Unable to upsert data to salesforce from node js

I am trying to upsert records to Case object from node js app using jsforce.I am providing externalId field also as showing below. const upsertTest = async () => { const sfconn = await ...
shyama moneymohan's user avatar
0 votes
1 answer
24 views

Update a table only if updated field is higher

I'm triying to upload some files with incremental data. The tabla has a PK (_id), but this _id could appears in many files with different values. I'd like to load massively the files with a REPLACE ...
JJBB's user avatar
  • 1

15 30 50 per page
1
2 3 4 5
85