Questions tagged as 'mysql'

1
answer

Display a record by quantity and the most repeated value of a column

Hello, I have the following problem: I need to display the locations, the number of submissions for each one (that is, how many times the name of the locality appears in the column) and the most common disease in each locality , the name of the d...
asked by 24.05.2018 / 16:18
2
answers

Select data from three SQL tables

I'm trying to merge data from three tables using this sql: SELECT cod_nota, cupom, valor_contrato, valor_cadastro, data_emissao FROM cupons_nota, vendas, notas_fiscais WHERE cupons_nota.cupom = vendas.numero_nf AND notas_fiscais.cod_cliente='0...
asked by 24.05.2018 / 15:20
0
answers

Push notification Android PHP

How to make a website (PHP Application, JS) send a push notification to an android app , this android app has only one component : a WebView that opens this site , notification must be sent when a user performs an action that is stored...
asked by 29.05.2018 / 20:53
0
answers

Insertion and removal using PDO in OneToMany and ManyToMany relationships

I beginner questions about insertion and removal using PDO in relationships of type OneToMany and ManyToMany . Example: class Livro{ private $id; private $titulo; private $generos; //Livro tem mais de um genero } class Genero{...
asked by 29.05.2018 / 21:28
0
answers

How to do automatic push notifications in android webview application with php mysql? (With Thunkable)

I'm developing an android application with a WebView that opens a website (which is the actual application) and I need to make that site or its server send automatic push notifications to the mobile phone that has the application (even without b...
asked by 23.05.2018 / 18:14
0
answers

Trigger creates duplicate records

The "update" trigger in Mysql creates 8 records with each update. The first record is the old record, the next 7 are copies of the change. How do I leave only the old and the edited? I tried to put a UNIQUE key in the datetime of the "histo...
asked by 23.05.2018 / 09:00
0
answers

Calculate subtotal of selected items with trigger

I have a table item with the following fields: ( id_item - id_pedido- id_produto - qtde - subtotal - valor _unitario ) and the following requested table with the following fields: ( id_pedido - data - id_cliente - valor_total - descon...
asked by 22.05.2018 / 15:57
2
answers

fill combobox with bank data

I'm following a php video lesson with mysql and I'm able to list the data of a table in a list (list), just so that they know that the connection problem with the bank is already over. I tried to use the same code to list the same table in a com...
asked by 06.06.2018 / 17:06
2
answers

How do I not insert repeated records?

I am doing a login system in which each user creates a URL that sends to the bank, but I need to make it not repeat information, if there is already information in the database, it returns (URL indisponível) result. p> INPUT COD...
asked by 01.07.2014 / 01:55
0
answers

Put the ID in the foreign key table

Because I can not put ID in my table foreign key last_insert_id() returning "0" <html> <head> <meta http-equiv="content-Type" content="text/html"; charset="utf-8" /> <title>cadastrando</title> </he...
asked by 22.05.2018 / 13:36