I have 2 tables.
The first returns the order number and the two-state times
Pedido TiempoPreparar TiempoAsignar
-------------------------------------------
P001 10 9
P002 20 5
P003...
I have a table Peticiones whose design is:
NPeticion - nvarchar
FechaApertura - date
TipoPeticion - nvarchar
FechaResolucion - nvarchar
...
(más campos, irrelevantes para este asunto)
The question is that I try to make a q...
How about I have a table students with a column called " id_schools "
in Mysql
I want it is to make a "select" that throw me the results ordered as follows:
nombre_a id_escuelas
--------- -------------
Juan...
I have the following query :
SELECT S.IdCliente
,S.NOMBRE
,S.JLI_SDESLINEA
,S.JCA_SDESCATEGORIA
,SUM(S.MONTO) AS MONTO
,COUNT(*) AS QTY
,S.DIA
,T.IDTERRITORIO
,T.VENDEDOR
,T.SUPERVISOR
,V.IDCLIENTE
FROM...
$username=$_POST["username"];
$email=$_POST["email"];
$sex=$_POST["sex"];
$description=$_POST["description"];
$infoVisivility=$_POST["infoVisivility"];
The thing is that I collect the above data from a form for the user to...
I have the following table where I sort by prioridad and id_agenda , the order should be as follows Priority ASC and id_agenda DESC (In case a data does not have priority so it must go below the if it has priority).
sql...
Hello, I am making a request to searchRand.php, in the php I make a query to obtain data. And I save it in the $ to_return variable. But when returning the value of $ to_return does not return anything. Being in the php command print the variabl...
I need to search in a database like this, where "id" is the variable with autoincrement:
id device
6 1
5 1
4 2
3 2
2 1
1 1
I need to sort by "device" but it gave me when "id" is minimal, I need to group w...
I am building a query that tells me the number of fields that are null and the number of fields that contain some content.
Data . This is my table:
CREATE TABLE opciones ( ID int(11) NOT NULL,
id_pregunta int(50) D...
I have the following MySQL query:
select * from venta as v, pago_venta as pv
where pv.pv_fecha in (SELECT MAX(pv_fecha) FROM pago_venta as p GROUP BY ven_id ) AND v.ven_id = pv.ven_id AND v.ven_cliente= 'Amaia Valentina Cardenas Gonzales'
T...