Questions tagged as 'query'

1
answer

Relate sub query table with main query

SGDB: MySql. PROBLEM: I need to somehow relate the subquery (being table and field highlighted in Functional.codZone1) to the table "Zone", which is in the main query. Is there any way? "ZONE" table: Contains all Zones of the city. Tab...
asked by 15.04.2014 / 17:01
1
answer

Query returns value of another user

I'm not able to compare the code (from the logged in professional) with the contracted codigoprofessional (which must be the same as the logged in professional) in the sql query and this causes the query to return a value from another profession...
asked by 10.11.2018 / 22:05
1
answer

error in wordpress query

Good morning everyone! I have the following query: <?php $footerlocal = array( 'numberposts' => 2, 'post_type' => 'page', 'meta_query' => array( 'relation' => 'OR', array( 'key' => 'zona'...
asked by 23.11.2018 / 11:27
3
answers

How to consult a record that does not contain certain code?

I need to make an appointment where the calls that were not validated are listed. It works like this: A call is a support request, in which several actions occur, and all are recorded in an auxiliary table. I need to filter out all the cal...
asked by 28.09.2018 / 00:16
1
answer

How to control the filters of a persistent query in mongodb

I have this query in my api: @Query("{$and: [" + "{'online': ?5}, " + "{'locations.appointmentTimeRanges.weekday': ?6}, " + "{'specialties.name': ?7}, " + "{'healthInsurances.name' : ?8}"...
asked by 22.08.2018 / 14:40
1
answer

Rankin in MySQL

I'm trying to generate a ranking of faults for HR. Fault logging is done in a separate table in the Employee registry. I need to bring the list of active employees and the amount of absences he has had in the company, but I want to order from...
asked by 31.08.2018 / 16:14
0
answers

Receive data from another page

Talk, I'm creating a store with a friend, one of the security measures is to check if the CPF really exists. thinking about this we found a site: link that asks for a CPF, how can I send the user's CPF to this page and display the result in my...
asked by 05.08.2018 / 00:42
2
answers

Bring records from one table according to another's where

I am a newbie in the database area and I came across a situation that I do not know how to solve. Even looking (at least it seems, rs) simple. There is the table called dbo.FISICA and another call dbo.MATRICULA , in the dbo.FI...
asked by 07.06.2018 / 01:04
1
answer

How to perform shifted SQL query from 1 position?

I am trying to perform a query where in one of the columns ( COTA_DIA_ANTERIOR ) returns me the value of the previous day. But it's bringing the value of the day. SELECT ET.DT_REFERENCIA ,ET.VL_PU ,(SELECT TOP (1) [DT_REFEREN...
asked by 09.07.2018 / 22:58
1
answer

Subquery returns more than one value

When performing an update within a procedure, the message appears saying that the comparison subquery brings more than one result. The subquery has been tested and only returns one result since it searches for the Exam id and this is unique for...
asked by 13.05.2018 / 16:37