Questions tagged as 'mysql'

0
answers

Call another page with the action of a form

I have this code to open multiple forms on the same page: <select id="mudar_produto"> <option value="#produto_1">Novo Produto Higiene</option> <option value="#produto_2">Entrada de Produtos Higiene</option&...
asked by 21.05.2018 / 11:31
1
answer

How to reproduce query with MySQL subqueries in hibernate?

I'm using JPA 2.0 and trying to reproduce this query in hibernate, but I can not figure out how to do it. I did in the language of Mysql SELECT totalassociado, totalcriticado, items.item_codigo_item, items.item_data_...
asked by 19.03.2014 / 15:00
1
answer

Return string search in table

Data and database queries have a very special place in the universe of computers. The popularization of the internet was due to the agility of searches implemented by the Enginner Search Web mechanisms. Simply searching for a string using sql...
asked by 05.04.2018 / 19:23
1
answer

How to remove duplicate records in MySQL with WHERE condition

My address book table has many duplicate addresses for each client. Note in the screenshot below that I have many duplicate zip codes for the same client with ID 12. Ineedtoremoveduplicateaddresseswherepostcodeandparent_idaregreaterthan1andk...
asked by 24.09.2018 / 14:40
3
answers

Perform insertion into a foreign key table

include_once 'acesso_bd/conexao_bd.php'; class PropriedadeDAO { function inserirPropriedadeBD($propriedade) { $nome = $propriedade->getNome(); $endereco = $propriedade->getEndereco(); $telefone = $proprieda...
asked by 22.06.2017 / 19:49
1
answer

I accidentally delete all MySQL users phpMyAdmin [duplicate]

I was following some tutorials on the internet to change the password of my mysql user in phpMyAdmin and in the end I ended up deleting this user. I did not have access to phpMyAdmin and I do not know how to solve this problem, I'm using Wamp...
asked by 25.08.2017 / 03:39
1
answer

How to make the student's registration number of the logged in account stay in the publication table made?

I'm doing a rating project for a "college", I have the publishing class and in it the method: public String NovaPublicacao(Connection conn){ String sqlInserir = "INSERT INTO Publicacao (Assunto, Conteudo, RA) VALUES (?, ?, (SELECT RA fr...
asked by 17.11.2016 / 01:21
1
answer

ERR_CONNECTION_TIMED_OUT ERR_CONNECTION_REFUSED [closed]

I'm developing a system that uses HTML, JS, PHP and MySQL. Pages have multiple AJAX calls to the bank. I have approximately 350 users today. Lately I've been getting a lot of errors from: ERR_CONNECTION_TIMED_OUT ERR_CONNECTIO...
asked by 09.11.2016 / 15:05
9
answers

How to prevent SQL injection in my PHP code?

I developed a page in PHP for internal use of the company I work with and only very few people use it. You can use this page to do some queries, insertions, changes and deletions of a table in a MySQL database, however I believe that my PHP code...
asked by 03.02.2014 / 13:37
1
answer

Problem inserting unique MySQL record

I have a table that has a unique field, a record of this table has been deleted and now I want to insert it again, however MySQL generates the error: "Error Code: 1062. Duplicate entry '' for key ' '". How can I solve this? CREATE TABLE:...
asked by 07.07.2016 / 15:17