Questions tagged as 'sql-server'

3
answers

Change column for indentity using T-SQL in SQL Server

I need to change an existing column in a table so that it has the identity property using T-SQL and then insert data into this table. The column already contains data and after this insertion, I must again change this column by disabling...
asked by 15.12.2015 / 15:35
2
answers

When is it worth to pay for SQLServer or Oracle?

Open-source databases such as MySQL and Postgres are so advanced that they can handle a wide variety of applications without problems, perhaps most. (There's SQLite too, but this is more for when portability is essential.) But for business ap...
asked by 18.06.2014 / 13:32
2
answers

Remove an item from a List

Well, I have a method that I query on my bank and compare with a List<Carros> . My intention is, for each item that contains both in my query, and in my List<Carros> , I remove the item from my List<Carros> ....
asked by 08.05.2015 / 16:33
2
answers

How to remove formatting from the GETDATE () command

I'm developing an application that will be used by multiple clients simultaneously, I'd like to use Day, Month, Year, Hour, Minute, Second and Millisecond as id and / that the : function returns?     
asked by 28.05.2015 / 14:32
1
answer

Maximum size for database tables

What can be the maximum size that a table can have? To be clearer: a table in MySQL, what is the maximum size it supports? And in SQL Server, Oracle, PostgreSQL?     
asked by 07.07.2016 / 20:17
2
answers

How to get the size of each table in the database?

By query , how can I get the disk space that the tables (in a database) are occupying? I can list all tables using sys.tables , but what about size? SELECT NAME AS NomeTabela FROM sys.tables     
asked by 13.04.2017 / 02:27
5
answers

How do I list all the tables with their respective banks?

I would like to list all the tables in my database that end with a specific name and also all my databases that match those tables. I tried to do but it does not return anything to me. Query SELECT da.name AS BANCOS,ta.name as TABELAS FROM...
asked by 05.06.2017 / 14:51
3
answers

Calculate difference between Dates in SQL Server, with Years, Months, and Days output

What would be the SQL (SQLSERVER) that could extract the difference between two dates (the largest being the current system date) with Years, Months, and Days output?     
asked by 29.06.2014 / 18:08
2
answers

SQL SERVER - Convert String in Days

How can I convert this string into days? Example: return "2 days and 2 hours"? SELECT '50:00:00'     
asked by 20.07.2018 / 20:53
2
answers

Clause similar to MySQL's LIMIT in MSSQL

I need to run the query below in PHP with SQL Server, however I can not use the LIMIT clause missing in Microsoft queries . $SqlTabelaAtual="SELECT * FROM BusinessCadTabPreco RIGHT JOIN BusinessCadTabPrecoItem ON B...
asked by 15.01.2016 / 15:17