Questions tagged as 'query'

1
answer

Catch element selector created at runtime

I have a system that clears the fields and attributes of a table via javascript and ajax so far, but the elements created and listed at the precise execution time manipulate them through a selector like I do to pick up that selector like id?...
asked by 25.02.2017 / 20:38
1
answer

Arrange column Period in SQL in ascending or descending order

Personal I have the following question / problem I'm doing a select on some accounts and organized by filename, but I need to organize for the period but I'm not getting it because it's not a single date. I can not use the creation date. M...
asked by 08.03.2017 / 18:58
0
answers

Code is not sending data to the database

This first code to register is not working, it is the same as another one that is working that registers the users, it is giving the error in $ insertenome and shows the message Could not insert registration: , I searched but did not find the...
asked by 02.02.2017 / 21:51
1
answer

How to optimize a select within an update?

I created a stored-procedure that updates the balances of the Handle table. At first I tried to use From Movimentacao within the update of the move, only that returned error. I fixed this problem by doing FROM (SELECT * FROM M...
asked by 31.01.2017 / 21:54
0
answers

How to debug a MySQL query?

Is there any way to know what's wrong with this QUERY? When you perform a query, it displays it on the screen but nothing appears, var_dump returns NULL , what steps does a professional perform to find out what is wrong with a qu...
asked by 10.02.2017 / 16:12
1
answer

Grouping of lines Group By

I have the following query: SELECT distinct CAPA.COD_HOLDING, CAPA.COD_MATRIZ, CAPA.COD_FILIAL, CAPA.ID_NF_ENTRADA, CAPA.NUM_NF, CAPA.DT_ENTRADA, CAPA.DT_EMISSAO, CAPA.COD_CLIFOR, CAPA.COD_UF, CAPA.CGC_CPF,...
asked by 04.01.2017 / 18:48
1
answer

How do I do this query with subselect in laravel?

I've tried it anyway, but it does not fit me SubSelect . I used the toSql() method to confirm and it really does not mount. SQL SELECT p.descr,p.dt_hr, (SELECT u1.name FROM users u1 WHERE u1.id = f.id_friend) AS name FROM fr...
asked by 29.12.2016 / 21:41
1
answer

Chunk in Laravel 4.2 using lots of memory

I am using an application in a query to get data from a table and then generate a xlsx file. The problem is that it returns a lot of information, about 1.5 GB . As a workaround, I am using the chunk() method of Query Builder in...
asked by 09.12.2016 / 16:44
0
answers

MYSQL query error

I have the following query select DISTINCT(p.id),g.id, p.slug, p.nome from game g join game_plataforma gp on g.id=gp.id_game join plataformas p on gp.id_plataforma=p.id group by g.id,p.id,p.slug, p.nome order by g.id DESC limit 5; She retur...
asked by 19.11.2016 / 23:09
0
answers

assign rows from one column to different variables

Good afternoon, I'm a beginner in php and wanted help with a code. I made a query that selects a column and limits 6 rows in descending order, the query worked out fine, however I am having difficulty to proceed. I need now to get the value of E...
asked by 11.10.2016 / 23:36