Questions tagged as 'mysql'

0
answers

Button to delete rows in a table made in mysql / php

I would like to create a button that deletes rows from a table, the html part and css are ready, but javascript does not work. Here I leave my codes. <?php //Archivo de conexion include_once("connection.php"); $sql = "SELECT * FROM 'res...
asked by 30.10.2018 / 13:56
1
answer

Add all the fields of several records corresponding to a MySQL column

How can I add all the fields that correspond to a column in a table? Example: | ID | Cantidad | ------------------ | 1 | 200 | | 2 | 150 | | 3 | 60 | How can I add up all the "Quantity" fields? That is, (200 + 150...
asked by 31.10.2018 / 17:19
0
answers

Read CSV files and create their respective tables in mysql

This is the function of my button when loading multiple CSV files, I would like to know how to implement the function so that those files can be generated in tables in MYSQL in a database that I already have . private void examinarAct...
asked by 15.11.2018 / 20:15
0
answers

Error Code: 1290. The MySQL server is running with the - secure-file-priv option so it can not execute this statement

I am trying to enter data into a MySQL bd from a .csv file and when executing this command line: load data infile 'C:\respaldo\respaldo.csv' into table productos fields terminated by ',' lines terminated by '\n' ignore 1 lines; I get this e...
asked by 16.11.2018 / 03:03
1
answer

How to store a list in Hibernate

Here is the Container class with the PlazasBlock List that I want to store in hibernate @Entity @Table(name = "CONTENEDOR", uniqueConstraints = { @UniqueConstraint(columnNames = "IdContenedor")}) public class Contenedor implements Serializable...
asked by 09.10.2018 / 07:43
0
answers

Save special characters in phpMyAdmin database

I am trying to save the following in the database by means of an input of a form C: \ Users \ jcifuentes \ Document's \ ESTUDIOS, but it does not let me save and if I remove the quote it has that is C: \ Users \ jcifuentes \ Documents \ ESTUDIOS...
asked by 10.10.2018 / 18:56
0
answers

Remote access to MySQL MAC

I hope you can help me. I am developing an application for raspberry. For this application I need to connect to a database that is mounted on XAMPP for mac, but I have not found a way to remotely access the database. I need to make queries to...
asked by 18.10.2018 / 03:18
0
answers

Compare a column of an Array with 1 row in another table using Laravel 5.7

I hope I can explain in the best way I am developing a project in Laravel 5.7 and I have a problem which I describe below: I have the statusprestamos table id | idprestamo | totalprestamo | status 1 1 500 pendien...
asked by 20.10.2018 / 20:51
0
answers

Generate Json in PHP with mysql data

I need to create a json with the following structure (photo1), example 1115 are the union of the IDS region, province and city. Ahem: $idRegion = 1; $idProvincia = 1; $idCiudad = 1; $ids = $idRegion.''.$idProvincia.''.idCiudad; and...
asked by 19.10.2018 / 19:13
0
answers

Update a field by going through each record

I want to update records based on a variable $aux = 110 , for example. In the image the first row has an amount of 80. Therefore it must be zero and move to the next record with what about 110-80 = 30 . Then, the next record should b...
asked by 21.10.2018 / 17:14