Questions tagged [insert]

Insert is an action to add information to a larger container that the information should reside within. Some examples include inserting a file into a file system, inserting a record into a database, or inserting an item into a list.

Insert is an action to add information to a larger container that the information should reside within. Some examples include inserting a file into a file system, inserting a row into a database, inserting an item into a list.

In programming languages, in the context of insertion of an item into a container (eg. arrays, linked lists), insert is normally used to denote addition of an item at an arbitrary point (by order of items) in the container. This is as opposed to append (add to end of container), or prepend (add to the front of the container).

Do not use this tag for questions regarding SQL INSERT statement. Use tag instead.

See also ,

14336 questions
3
votes
2 answers

INSERT query produces "Warning: mysqli_num_rows() expects parameter 1 to be mysqli_result, boolean given"

I am confused about why I am received the following message: mysqli_num_rows() expects parameter 1 to be mysqli_result, boolean given This question is different from previous queries because my query actually executes correctly (values were indeed…
andreea115
  • 53
  • 6
3
votes
1 answer

Inserting a value into an indentity column db2

Hi I try to insert data from a script into a DB2 table which has an identity column. I read that using the syntax: INSERT INTO SOME_TABLE OVERRIDING SYSTEM VALUE ... would work, but it doesn't. Here is the exact query: INSERT INTO SCHEMA.MYTABLE…
user2343647
  • 633
  • 6
  • 17
3
votes
2 answers

How do you insert data in Wordpress?

I tried to insert data to a table named Ships, but sadly it doesn't work. I pasted the code, to give you a better view about how I wrote my script. Any help is much appreciated!
Tolga Demir
  • 161
  • 2
  • 11
3
votes
6 answers

How to append distinct records from one table to another

How do I append only distinct records from a master table to another table, when the master may have duplicates. Example - I only want the distinct records in the smaller table but I need to insert/append records to what I already have in the…
sql_rookie
  • 31
  • 1
  • 2
3
votes
2 answers

MySQL insert String error - UTF-8?

I am inserting into a mysql database. I get the following error when trying to do the insert Incorrect string value: '\xF0\x9F\x87\xB7\xF0\x9F...' for column 'field_4' at row 1 I thought I had figured out this error by simply changing the column…
eric MC
  • 766
  • 2
  • 10
  • 36
3
votes
1 answer

MySQL INSERT ... ON DUPLICATE KEY not updating table with no errors or warnings

So I have the following table: mysql> show create table user_api_skills \G *************************** 1. row *************************** Table: user_api_skills Create Table: CREATE TABLE `user_api_skills` ( `characterID` int(11) NOT NULL, …
ModulusJoe
  • 1,416
  • 10
  • 17
3
votes
1 answer

SQL - Fill one table from fields of another table

I have an empty SQL table with the following Design: table1 MsgName_ID bigint MsgName_Type nvarchar(10) MsgName_CurID nvarchar(100) MsgName_Name nvarchar(50) MsgName_Meaning nvarchar(1000) MsgName_Note …
HelpASisterOut
  • 3,085
  • 16
  • 45
  • 89
3
votes
2 answers

inserting values to new table in mysql_query

Okay guys, I will try to share my guestion understandable. So I have 2 tables like below: ALL Id from TABLES are Autoincrement. Number id number 10 100 11 102 12 105 13 106 subnumber id number_id subnumber 52 10 10 53 …
user2767715
3
votes
4 answers

What is the fastest way to insert a large amount of records into a SQL Server DB?

I need to insert millions of records being read from disk into SQL server. I am parsing these from a file on one machine, in what is a single-threaded process. Ideally I would want it to perform well if the SQL server is local or remote. It has to…
esac
  • 24,099
  • 38
  • 122
  • 179
3
votes
1 answer

Entity Framework and Identity Insert

I am writing an application that exports data and serializes it to file for archiving old data. There may be occasions where for some reason select data needs to be re-imported. This has been causing me a problem because of an identity column. To…
PaulMcCaffery
  • 145
  • 1
  • 9
3
votes
2 answers

How to insert POINT type value using PreparedStatement from a java app into Postgresql DB

The following query works in pgAdmin's sql console: insert into sometable values (DEFAULT,9, 'test content', '(-194.0, 53.0)', '(+144.345345, -453.043534)', '2012-08-24 14:00:00 +02:00', '2012-08-24 14:00:00 +02:00'); Following are the values sent…
Bilal Ahmed
  • 91
  • 3
  • 5
3
votes
1 answer

boost::flyweight as value in std::map

I am wondering why std::map does not replace value after using insert. example: using std::string; using boost::flyweight; using std::map; int main() { map> testMap; flyweight str("1"); …
Aleksander Fular
  • 803
  • 9
  • 18
3
votes
2 answers

PostgreSQL multi-column unique constraint causes errors

I am new to postgresql and have a question about multiple column unique constraint. I got this error when tried to add rows to the table: ERROR: duplicate key value violates unique constraint "i_rb_on" DETAIL: Key (a_fk, b_fk)=(296, 16) already…
lk7777
  • 303
  • 1
  • 5
  • 10
3
votes
4 answers

INSERT INTO PostgreSQL

I have got a little problem with SQL. I'm trying to insert 2 values into my table. that's my query: INSERT INTO tableinfo (table,date) VALUES ('Sell','24 August'); But it doesnt work. I've got something like that: SQL error: ERROR: syntax near…
Dominik
  • 203
  • 1
  • 3
  • 10
3
votes
5 answers

How do I handle large SQL SERVER batch inserts?

I'm looking to execute a series of queries as part of a migration project. The scripts to be generated are produced from a tool which analyses the legacy database then produces a script to map each of the old entities to an appropriate new record.…
Brian Scott
1 2 3
99
100