Questions tagged as 'mysqli'

1
answer

consult and add DB result

I have a table ( dia ) that receives the data over the course of days: (id, dia, cliente, func, servicos, valor, produtos, valorp, fdp) (1, 2018-11-01, cliente1, func1, servicos1, 0++, produto1, 0++, D ou C) I need to make a query for...
asked by 07.11.2018 / 05:51
1
answer

How to list rows table values

How can I list column values in a " <table> "? Iwanttolistallrowsvaluesin<tr>asshownintheimage Tablecode:<tableid="datatable" class="table table-striped table-bordered" cellspacing="0" width="100%">...
asked by 22.08.2018 / 23:59
1
answer

Save more than one data in this form with PHP and MySQLi

Hello, I have a problem with this code. I am making a form that I need to save, but unfortunately in the database it only saves once the rest always gives error ... I would like to solve this problem, since I thank you for having read it. Below...
asked by 13.06.2018 / 06:21
2
answers

How to put a php variable in a mysql query?

For example: $query = "INSERT INTO tabela (data, assunto, destino, elaborado) VALUES('{$data}', '{$assunto}', '{$destino}', '{$elaborado}')"; Where is tabela , I want to put a variable in place, because depending on what the user choo...
asked by 21.06.2018 / 00:16
3
answers

Mysql query error

Hello! Why is the status coming different from the table? follow my query: SELECT DISTINCT max(idEmbreagem) as idEmbreagem, b.prefixo as idVeiculo, max(datamontagem) as datamontagem, max(kmmontagem) as kmmontagem, max(horime...
asked by 24.06.2018 / 05:52
3
answers

Convert an array of numbers into a single string in php

How do I transform an array of numbers into a single string in php? In the code below the variable $ result is the array of numbers, and I tried to convert it to a single string with the implode () function. But it does not seem to work becau...
asked by 27.05.2018 / 22:47
2
answers

Mysql Help to Return the Unavailable Days to Schedule Time

I have 2 mysql tables that represent the unavailable days for scheduling: holidays table: id, day (date), name Special_days table : id, day (date), will_work (boolean) At the end I need to select the unavailable days which are the hol...
asked by 15.05.2018 / 14:15
1
answer

Mysql Left outer join show only the first result

I need to make this join of the sales table with the Nfe table, but the NFE table can have more than one result which causes a change in total sales, how can I change this join to get only the last note? p> select sum(total_venda) as total_ven...
asked by 03.07.2018 / 14:43
1
answer

ORDER BY RAND () in 2 columns

Well earlier I posted a problem about deleting 1 select that was solved but now I had another problem. My idea is to create a playlist that prioritizes status 1. Whenever a user posts the video it is inserted with status 1. After the vi...
asked by 04.04.2018 / 02:24
1
answer

Inner Join is returning repeated results

I have three tables! One of them being a relationship table! They are: Person: Treatment: RelationshipbetweenPersonandTreatmenttable: I would like to pass the ID of the person, the query would return the NAMES of the selected treatme...
asked by 16.04.2018 / 03:24