Skip to main content

Questions tagged [insert-update]

A mixed flavour of data entry mode and data modification mode. It can be used when insert is required for case of non-existing data and modification if data exists.

insert-update
12 votes
2 answers
26k views

Insert or update a map

I have a std::map. Given a <key, value> pair, I need to: Modify the value in the map if the key exists, or Insert the pair into the map if the key does not exist yet. I'm doing it like this: ...
0 votes
1 answer
51 views

Batch update of records in MongoDB

I iterated over records in the batch step and in Batch Aggregator I wanted to update all of them at once in mongoDb. Is there a way to update them all together or I need to separately update each one ...
2 votes
1 answer
57 views

Microsoft Access SQL [duplicate]

I am looking for a solution to fill fields in an Access DB SQL statement. Any suggestions? Example of the dataset attached: Goal: I am looking for a solution to fill fields in an Access DB SQl ...
0 votes
2 answers
18k views

A Database Error Occurred Error Number: 1054 Unknown column... in 'field list'

I can't get my head round this... Controller: public function update() { $string = 'xml/gzip'; $xml = simplexml_load_file("compress.zlib://$string"); foreach ($xml->merchant as $...
0 votes
1 answer
148 views

Update SQL table using selection from another table

I want to update the values of a SQL table based on the value from another table where the two tables have a common ID. When I run my script it says it work. But when I check the table that should ...
0 votes
4 answers
13k views

C# MySQL Update - Datagridview

In a C# Windows Form I have two buttons; Query and Update. On that form is a datagridview where I put my MySQL results. In separation, when I click Query I get the results correctly. When I change a ...
-1 votes
0 answers
14 views

Updating Postgres Table using a Datastream in spark

I am using scala Api "2.12.15" of spark "3.5.0" and i am trying to use a data stream to update the rows of my Postgres table : my data stream and my table both has the same columns ...
1 vote
0 answers
32 views

How to add a new field to an existing Google contact in .NET

I write this post because I have a problem using the Google API. Google API Documentation release the code below for update a contact in .NET: (https://developers.google.com/google-apps/contacts/v3/#...
2 votes
3 answers
8k views

How to insert multiple rows in mysql

I have a table name :: users with id and name in mysql , the id is primary key with auto increment and name is varchar(50) and now i have a bunch of unique names almost 70 , how should i insert it in ...
0 votes
0 answers
44 views

SQLAlchemy ORM 2.0 - create audits (Insert/ Update/ Delete)

I am trying to create audits (get columns with values before and after Update) Update statement per ORM 2.0 style : engine = create_engine("sqlite:///sales.db", echo=True) Base = ...
2 votes
1 answer
584 views

Django REST PATCH request field is required problem

I have a Student model. And I want to update some specific fields. But when I go to update one or two fields but the other field value is as it is then which fields are not changing those fields show ...
1 vote
0 answers
40 views

Unable to Update Data in ScyllaDB

I'm encountering an issue while attempting to update data in ScyllaDB using Go. Below is the code snippet I'm using for updating a session record: func (q *Queries) EndSession(Sessionid string) error {...
3 votes
2 answers
3k views

INSERT ON DUPLICATE KEY UPDATE multiple rows at once

I'm using node.js and mysql. I'm trying to insert multiple rows with one query, and if the rows with that primary key already exist, update it. PK is exchange + currency1 + currency2. But only one ...
0 votes
1 answer
26 views

ORA-30926: unable to get a stable set of rows in the source tables when updating a a table in a database using another table in another database

I am trying to update a table in a database using another table in another database. This script was working fine until recently when I started getting the error: ORA-30926: unable to get a stable set ...
0 votes
2 answers
49 views

Update scenario is not working properly when using CASEs or IF statement ON DUPLICATE KEY UPDATE section in MySQL

I need to do bulk insert and update on MySQL so I used the ON DUPLICATE KEY UPDATE. I need to ignore the updated by and updated date fields as existing old data if there are no changes in those record'...

15 30 50 per page
1
2 3 4 5
88