Questions tagged as 'mysql'

2
answers

Insert in the table only the filled line

Table code: $j = 0; while($rows_cursos1 = mysqli_fetch_array($resultado_cursos1)) { $tabela2 .= '<tr>'; $tabela2 .= '<td> <input type="text" readonly="true" size="20" name= "Carro[]" id= "Carro" value="'.$rows_cursos1['Descric...
asked by 29.11.2018 / 14:54
0
answers

Loop while showing only the first record of the database

Hello, my system has a problem, I have 2 tables: alunos id | nome frequencia id | id_aluno But in the while loop where I connect the two tables by id and id_aluno , it only displays the first record of the database, and there...
asked by 30.11.2018 / 11:43
0
answers

Trigger for a goal

I want to create a trigger to determine a goal for my hospital system (college project). Every time the doctor performed 10 appointments, his salary would double. However, it does not work. I think I'm not doing it right, so I'd like help struct...
asked by 30.11.2018 / 01:38
0
answers

Error saving double in MySQL 5.7 [duplicate]

Good morning guys! I have the following situation: I have 3 fields in my table: nota1, nota2, and final_note (average of the two). All three fields are of type double . There is a problem saving some averages. For example: nota1 =...
asked by 30.11.2018 / 14:41
0
answers

Is it possible to change the Index of a database table by the following?

I have a mysql table ( tbl_test ) that has a unique ID, string and an int order. ID | Nome | Ordem 1 | name1 | 1 2 | name2 | 4 3 | name3 | 3 4 | name4 | 5 5 | name5 | 2 I would like to know if it is possible to inser...
asked by 26.11.2018 / 15:47
1
answer

Join show later dates only

I have a table that records steps of a move. For example: Data - Movimentacao - Produto 2018-01-10 - produzido - id1 2018-01-11 - embalado - id1 2018-01-12 - despachado - id1 2018-01-10 - produzido - id2 2018-01-10 -...
asked by 26.11.2018 / 14:30
0
answers

MySQL is not accepting FK null

Good night, I have a request table, which has a FK client_id, this client-id, may possibly be null, but when marking that fk can be null, myslq does not accept, it marks as in null and I define a default value . What can it be?     ALTER T...
asked by 25.11.2018 / 05:38
0
answers

MySWL Error 2005 (HY000): No such host is known

When trying to connect the MySQL database through Netbeans, mysql presented error 2005 (HY000) where it says that the host is not known. The problem is that the class is configured with everything necessary to establish the connection, I tried t...
asked by 23.11.2018 / 14:47
1
answer

Do not re-enter a user with an existing login

I have a problem with JPA with Java. I made a login system, using a self-generated ID, but every time I run the program it creates another user in the database, with a different id but same credentials. How do I, if this user login already...
asked by 23.11.2018 / 03:00
0
answers

Use INNER JOIN with WHERE clauses

I'm reassembling a system before in ASP now in PHP already with database loaded and mounted, however I need to do some filters where I need to fetch data from at least 3 different tables and maybe more later (But I'll review this database becaus...
asked by 23.11.2018 / 15:12