Questions tagged as 'sql-insert'

0
answers

Insert image into database

I am trying to insert an image into the database and it is not working. Can you help? Image Insertion Page Code: <form action="registo_produtos.php" method="post" enctype="multipart/form-data"> <label>Nome Produto : <...
asked by 18.06.2018 / 12:42
0
answers

Problem with mysqli_insert_id - Class

I have a problem getting the last id inserted in a table, because it is returning empty. I searched the stack but could not find a solution. Script to include information in DB: if ( isset( $_GET['create'] ) ) { if ( isset( $_POST['de...
asked by 06.04.2018 / 15:43
3
answers

Inserting registry and retrieving ID generated by SQL Server 2012

I want to insert a record into a table, retrieve the ID that was generated by AUTO_INCREMENT and insert records into other tables, using that ID. But, I want to do this all using BeginTransaction . How could I do this? I'm doi...
asked by 23.11.2015 / 12:49
1
answer

Insert using parameters in the C # application for the Oracle database error: ORA-01036: invalid variable name / number [closed]

I noticed that you have a lot of questions about this error but none solved my case the connection works normally, there is the method Insert (): public bool Insert(ArrayList arrAlunos) { vsql = "insert into ALUNOS_("...
asked by 31.01.2018 / 17:46
0
answers

INSERT IF NOT SQL (PROCEDURE)

I need to create a SQL procedure that does what's down here! -- procura cadastro SELECT id_cadastro FROM c1datasource.tb_cadastro where cpf_cnpj = '12344'; -- se não achou, insere INSERT INTO 'c1datasource'.'tb_cadastro' ('nome', 'cep', 'cpf_...
asked by 01.02.2018 / 15:26
1
answer

Synchronize MySQL database with XLS

The situation is as follows. I have a MYSQL database and an XLS file on an FTP server The code below downloads XLS to read and UPDATE from the database from the XLS data. The problem is that it only updates the existing data, I need to check...
asked by 06.01.2018 / 00:01
1
answer

Get insert ID after pg_query ()

I'm using php and postgres in a web system, I have a form that I'm saving by doing the insert using pg_query, however, I'd like to get the id of the new record after inserting, but I'm not getting it, or it returns null or false . What I've alre...
asked by 19.12.2017 / 02:47
1
answer

Problems with insertion into two MySQL PHP tables

I'm trying to do an INSERT on two tables, first I need to enter the vehicle information on the 'vehicle_table' table and I need to insert the images into the 'image_table' table. You are entering the ELSE of the first INSERT, I wanted to know wh...
asked by 06.07.2017 / 07:57
1
answer

Hibernate gives insert but does not insert data into table

I have a visitor record in which I fill in the data (title and date), and hibernate executes when requesting "save" on the form. Here is the log when I ask to save in bank (MySql). 12:37:27.752 DEBUG org.hibernate.validator.internal.metadat...
asked by 15.06.2017 / 17:42
1
answer

How to insert data into a MySQL B.D with PHP

This is the form for entering data <html> <head> <title></title> <meta charset="utf-8"> <link rel="stylesheet" href="style.css"> </head> <body> <form action="cadastrando.php"...
asked by 08.06.2017 / 01:10