I'm trying to get the data that is not related through a query between three tables, but I have not achieved the feat.
In my case I have three tables
Marcas Categorias Asignacion (It is the intercept table between Br...
SELECT
libro.titulo AS "Titulo Libro",
sum(ventas.cantidad) AS "Cantidad_Comprada"
FROM libro
left JOIN ventas ON
libro.id = ventas.id_libro
GROUP BY libro.titulo
I just want to show those elements that have a quantity of sum (sales.quant...
I want to insert in a table column T_tiphab but I can not tell me:
ERROR 1452 (23000): Can not add or update a child row: a foreign key constraint fails ( reservas . T_tiphab , CONSTRAINT T_tiphab_ibfk_1 FOREIGN K...
I want to return the following values as shown below:
fechaActual Clave Usuario Depto entrada salida sumaHoras
201712 307 USER1 TTT 06:00:04 14:04:12 8
The query must take the current d...
I'm doing an sql query to get averages of accesses for which I first make a query to extract all the accesses of a table and divide them for another field of a different table.
The first table is called TrackEvent and from it I extract a colu...
This is my code:
select ROW_NUMBER() OVER (ORDER BY p.CodPersona) AS Numero,
ccc.Descripcion AS Curso,
p.CodPersona AS Codigo,
p.NombreCompleto AS NombreAlumno,
cc.Detalle AS Detalle,...
Greetings, I would like to know what value returns me executenonquery in case I do not affect any field, example
string respuesta = "";
SqlConnection SqlConexion = new SqlConnection();
try
{
SqlConex...
I want to put the results of an sql query in a two-dimensional array.
The table would be something like id - > 1 name - > pepe last- > Garcia and other fields ...
and I want you to put it in a two-dimensional array array [index] ['same...
I have the following script that does what it does: it takes out the contents of a word, and puts it in a blob. But when I run it, I get these errors.
-ORA22275 - > LOB locator not valid -ORA06512 - > Line 29
(DBMS_LOB.fileopen (l...
Good afternoon ... I have this temporary table with the following structure:
create table ##PAC_ID_TEMP ( Id INT PRIMARY KEY IDENTITY(1,1),NHC varchar(30), Id_Ficha_IOS int) CREATE NONCLUSTERED INDEX Idx1 ON ##PAC_ID_TEMP(NHC);
Which I use...