I am working on a system with 15 concurrent processes that perform several operations against a SQL SERVER database, the versions can go from 2005 to 2014.
Each process has its particular data in several tables, no process queries / deletes / up...
I have a question about how I can make queries in SQL Server with hours fields.
I have a column called hora_inicio_prestamo and another hora_fin_prestamo , both of type time(0) , I also have a column called Estado_presta...
In SQL Server, it is possible to make a INSERT INTO to a table using a SELECT :
INSERT INTO tabla (col, col2, col3)
SELECT col, col2, col3 FROM otra_tabla WHERE sql = 'ok'
Is this also possible for a UPDATE ? I have a...
Good afternoon, I would like you to support me with this. I have a query
select ...
FROM
DBSosst..SRG_SUMMARY_NAVIGATION,
SALDOS_prueba1 a
WHERE
GROUP_ID = 4 and
STRUCTURE_ID = 1118 and
SUMTO...
I have the following schema in SQL Server 2012:
Tabla 1
Id INT PRIMARY KEY
Descripcion NVARCHAR(20)
Tipo INT
Tabla 2
Id INT PRIMARY KEY
Nombre NVARCHAR(80)
IdTabla1 INT --Llave foranea a la primera tabla
Tabla 3
Id INT PRIMARY KEY
Nombre NV...
To know the last access of a Login to a database in SQL Server;
Perform the following query to obtain dates however the LOGINPROPERTY function does not contain the last login date of Login.
SELECT
dbp.name AS [nombreUsuarioBD],...
I have a table with several fields and my goal is to bring only the id that appear only once and whose fields 3 and 4 are not null (any of them)
The query you make is the following
SELECT id
FROM tabla
WHERE campo3 IS N...
I need this table:
Be this: (edit it as an image using paint to show as an example)
The data will always have the same 'serverName', DATE and TIME in common
How to change the database with the name of the base stored in variable ?; Do the following code, however, do not change the database.
DECLARE @inicio VARCHAR (100)
DECLARE @bdname VARCHAR (100)
DECLARE @usedb VARCHAR (100)
SET @inicio =...