Questions tagged as 'sql'

1
answer

Error uploading file to the xampp website folder from localhost

The problem is that I upload a file to xampp. but I send it to the folder xampp / tmp / and not to the folder that I require as / htdocs / website / files but the first file you sent if you upload it correctly. the others only makes me regist...
asked by 09.07.2018 / 04:08
0
answers

Get fields changed in a trigger

I am doing an audit system and what I have done is a trigger in which the inserted is obtained and saved as JSON in a column, as well as the deleted, but I also want to save the changed fields between inserted and deleted, in postgres I did it u...
asked by 06.07.2018 / 12:01
1
answer

Purchase XML in SQL SERVER

I have two xml and I want to see which fields were modified, however the result is not formatting them as they were entered: DECLARE @xml1 xml ='<id>41</id><codigo>00054</codigo>'; DECLARE @xml2 xml ='<id>41</i...
asked by 06.07.2018 / 05:51
0
answers

How to do a procedure stored in mysql that inserts the id from one table to another?

How to do a procedure stored in mysql that allows to validate if a repeated data is found and if so to be able to register in two related tables otherwise insert only the id in a table? I have the following SQL script works if cc is not found...
asked by 06.07.2018 / 03:58
0
answers

code does not work outside the IDE

I have a JAVA application with no graphical environment that writes to a database in SQL, this application inside the NETBEANS IDE works perfectly, but outside the IDE, when I try to run the .jar it shows me an error and tells me that it does no...
asked by 03.07.2018 / 17:22
1
answer

Calculate the best-selling product by category

Having these 4 tables: TB_CAT_PRODUCTO (id_cat,nom_cat) TB_PRODUCTO (id_pro,nom_pro,id_cant) TB_PEDIDO (id_ped,fecha_ped DETALLE_PEDIDO (id_ped,id_pro,cantidad,importe) How would you find the best-selling product by category in a time inter...
asked by 04.07.2018 / 07:21
1
answer

How to insert in a related table

<?php ## Título ## if ($_POST) { $nombre = $_POST['nombre']; $apellido = $_POST['apellido']; $identidad = $_POST['identidad']; $edad = $_POST['edad']; $sexo = $_POST['sexo']; $hijos = $_POST['hijos']; $telefono = $_...
asked by 06.07.2018 / 19:49
2
answers

How can I empty several tables with a single sequence?

Hello, I have a button by which it says "delete everything", and I would like that when I clicked empty several tables, I was informed that this: $sql = "truncate tabla1,tabla2,tabla3,etc"; is not possible, so I saw an answer that I did n...
asked by 06.07.2018 / 18:35
0
answers

How can I send data from a datagrid that is linked to an access database to another data grid?

I want to send that data grid data to a sql table but it sends me an error when doing direct because that grid is already linked to access. if you could help me sending that data to another grid or if you can tell me how I can do it directly fro...
asked by 06.07.2018 / 18:33
0
answers

PHP does not work when fetching data from a database

<?php require_once('bdd.php'); $sql = "SELECT * FROM events "; $req = $bdd->prepare($sql); $req->execute(); $events = $req->fetchAll(); ?> After making the connection with my database I use this code to return the values in...
asked by 01.07.2018 / 20:17