Questions tagged as 'sql-server'

1
answer

SQL Server CHAR and VARCHAR

I understood the difference between CHAR and VARCHAR . If I want to insert the word 'house' into a field VARCHAR(10) , this word in the database will occupy 4 bytes. If I want to insert the word 'home' in a field CHAR...
asked by 04.05.2015 / 16:19
1
answer

group_concat () from MySql on SqlServer

I created a table for example: I have the following content: select * from table_t; Youneedtogetthefollowingresult: In MySql I use the following query: select group_concat(concat_ws(' - ',id,descri)) id_descri, tipo from table_t grou...
asked by 27.04.2015 / 13:57
1
answer

Recursive Query

I need to set up a recursive query to solve a simple problem, but I'm having a bit of trouble. I have a table named TABELA1 with the following fields (ID, IDPAI, NAME) I'll put some examples of records here and what I need. Recor...
asked by 24.02.2015 / 14:31
1
answer

SQL Server performance loss with insert in sequence

I have a .Net C # application that takes data via Web Service and saves it to a SQL Server 2012 database. The initial performance is 20 records per second. After having a 10000 records in the table, the performance begins to fall, gradually, rea...
asked by 09.09.2014 / 21:59
1
answer

Connection Provider is not working in VBScript

I have the following connection string: conn = "Provider=SQLNCLI; Server=" & conn_server &"; Database="& conn_database &"; UID="& conn_uid &"; PWD="& conn_pwd And the code to open and run SP: set conexao = serv...
asked by 16.06.2014 / 21:33
1
answer

Bind by position in SQL Server using Node JS (MSSQL)

I would like to know if you can bind the parameters by position instead of the name using mssql in NodeJS. Ex: //Por nome return pool.request() .input('input_parameter1', sql.Int, 10) .input('input_parameter2', sql.Int, 20) .query('select *...
asked by 01.11.2017 / 13:55
1
answer

Bring only one product per branch on the sql server [duplicate]

Good morning I need to bring only one product per branch, however in my table I have several times the same product just changing the date, I would like to get the product from the last date. What I have: SELECT ID, CODFIL, DT, COLUNAVARI...
asked by 06.06.2018 / 15:15
1
answer

Date manipulation

I wonder if it is possible, after converting the date and bringing only the time, manipulate this result to return the closed time. The example below details it best. CONVERT(VARCHAR(19), DATEADD(second, cr.open_date ,'1969-12-31 21:00:00'), 1...
asked by 27.04.2018 / 20:32
1
answer

Sequential Dynamic T-SQL Pivot

Breaking the head here to create a proc using pivot for this transformation: Is there a possibility? * Using sql server 2008R2 EDIT: CREATE TABLE #Teste5 (name VARCHAR(50),message VARCHAR(50),dtStart VARCHAR(50)) GO...
asked by 06.04.2018 / 22:12
1
answer

Disable IIS Caching

I'm having problems with IIS cache (I believe the problem is it) , whenever I make any changes to the database, the changes do not happen on the site, / p> Changes only appear when I turn off and turn on IIS. Attempts I added this comma...
asked by 11.01.2017 / 14:49