Questions tagged as 'mysql'

1
answer

how to fix this java.util.Date can not be cast to java.sql.Date

hi I'm uploading an excel file to jsp to save it in MySQL the excel file has two fields type date, at the time of reading the respective file I get this error java.util.Date can not be cast to java .sql.Date when executing it and I could not s...
asked by 19.01.2017 / 22:04
4
answers

Consultation with Inner Join

A few days ago I asked a question to get data from a database linking several tables with **INNER JOIN** . Now I'm trying to mix the INNER and the COUNT but I do not know how to express it. I have these tables. Table...
asked by 03.05.2017 / 11:22
1
answer

Declare variable in MySQL stored procedure

I have a question about how to perform the following procedure: DELIMITER $$ create procedure insertaEmpleado (nombre varchar(50), apPat varchar(50), apMat varchar(50), apodo varchar(50), calle varchar(50), colonia varchar(50), numero varchar(...
asked by 18.12.2016 / 05:31
1
answer

Query whose result includes a field that is the result of another query in mysql

I have a table of people that has the following fields, among others: +----------------------------+ |persona_id | persona_nombre | +-----------+----------------+ | 1 | persona 1 | | 2 | persona 2 | +-----------+-----...
asked by 04.01.2017 / 18:32
2
answers

How to show duplicate MySQL and PHP records?

How can I get duplicate records of a product? I'm developing a site to sell video games online, I have a search bar to show the titles by entering their SKU, but I want to show them the games that have their duplicate. For example: ===========...
asked by 16.01.2017 / 05:21
1
answer

Work with all the fields returned by a PHP, JQUERY, MYSQL table

Good, I have a problem that is that I need to manipulate all the records that exist in a table, that is, I am creating an inbox, with inbox and the tables and the backend part are fine, it returns all the messages that they wrote to me, since al...
asked by 20.02.2017 / 21:45
2
answers

query prepared in php does not work (no error)

I'm trying to execute this query but it does not give me any errors but it does not work for me, it simply does not order anything: $sql = 'SELECT * FROM productos ORDER BY :orden'; $stmt = $this->BD->prepare($sql); $params = array(':ord...
asked by 15.11.2016 / 15:17
3
answers

Send notifications when you insert to MySQL from Asterisk

I would like to know how to send a notification after having made an insert in MySQL. We have a system that uses Asterisk to register phone calls from our Call Center. The issue is that using Nodejs and Socketio we want to notify of the insert...
asked by 26.10.2016 / 17:12
2
answers

Solution to PHP Notice: Undefined variable: db

This is the code: function getCategoryTree($level = 0, $prefix = '') { //$sqll = "SELECT * FROM expense_categories WHERE master_category = ".$level." GROUP BY category_id ORDER BY category ASC"; echo $db."<br/><br/>\n"; $...
asked by 30.03.2017 / 21:09
1
answer

Doubt to create mysql table with monthly and quarterly values

I need to create a table called "evaluation" in which once a month must enter values of a simple formula a / b, that is, a field for a, another for b and a third for the result. First, the table would look like this: idEvaluacion,idProducto,f...
asked by 30.03.2017 / 20:08