Questions tagged as 'mysql'

1
answer

cascade delete with entity framework

I have the following situation: my database is MySql, when I try to delete a direct record in the bank, from this message: Cannot delete or update a parent row: a foreign key constraint fails ('lifeproject'.'t0041_usuario', CONSTRAINT 'fk_t004...
asked by 28.05.2016 / 02:30
1
answer

Refresh table field without refresh?

I have a "div" that brings the data from a table "Mysql", how do I click the "div" to make the data editable? But without going to another page. <div id="nome_mysql">João</div> By clicking on John, the "div" would bec...
asked by 17.05.2016 / 04:06
1
answer

How to edit registered data so that when selecting the register to be changed, the data of the same appear in the same form that was created?

Given the following form: <form action="action_page.php"> <fieldset> <legend>Personal information:</legend> First name:<br> <input type="text" name="firstname" value="Mickey"><br&g...
asked by 16.05.2016 / 22:31
1
answer

Problem with ("select username, points from date order by points desc limit 10");

I'm trying to make a ranking system, where the user name and punctuation appears. I'm doing the following: $select = $mysqli->query("select username, pontos from data order by pontos desc limit 10"); $row = $select->num_rows; $get =...
asked by 08.06.2016 / 06:32
2
answers

Problem inserting data into the database

I'm trying to insert a mass of data into the Mysql database using Hibernate. However I have the following error: 18:15:30,221 ERROR [org.hibernate.tool.hbm2ddl.SchemaExport] (ServerService Thread Pool -- 59) HHH000388: Unsuccessful: INSERT INT...
asked by 27.04.2016 / 23:23
1
answer

Bringing added records from another table in a new query

I have a table "tbA" where the primary column "a1" needs to be referenced by the "tbB" table by the "fk_a1" column tbA id | nome | ---+------+-- 1, 'aaaa' 2, 'bbbbb' 3, 'cccc' 4, 'ddddd' tbB id | fk_a1 | valor_1 | valor_2 |...
asked by 27.04.2016 / 22:43
1
answer

Select field to fill according to code entered in another field

Based on the image below, I would like that when the person passes the card of her, was made a select in mysql and where it is written the store appeared the store in which the person is registered.   How could I process? The biggest dou...
asked by 29.04.2016 / 00:43
1
answer

I need an if that changes the mask of an input

Hello, I have a php mysql code, and I need help, the code is ready, I just have the option to edit the data, that's what I need help with, I'll explain what's happening, I have my code has three inputs, the first asks what will be edited the seco...
asked by 28.04.2016 / 16:09
2
answers

Replace number by string in the results

I have the following query: SELECT sum(pedidos_lentes.quantidade) AS value, pedidos_lentes.solar AS label FROM pedidos JOIN pedidos_lentes ON pedidos_lentes.id_pedido = pedidos.id_pedido WHERE id_loja = 2 group by pedidos_lentes.solar T...
asked by 04.05.2016 / 20:15
1
answer

Insert date and currency data of a maskedTextBox in MySQL

When trying to insert the data entered from a maskedTextBox object, one of type data and another of type currency, in MySQL database, where I have a table named test, created according to the command below: CREATE TABLE 'teste' ( 't...
asked by 01.05.2016 / 23:16