Most voted "ssms" questions
SQL Server Management Studio is Microsoft’s standard graphical client tool for managing SQL Server. Use this tag in questions about using this tool.
Learn more…27 questions
Sort by count of
-
4
votes3
answers1491
viewsAdd field at position I want in sql server
Every time I make one ALTER TABLE and add a column, this field goes to the end. In design mode, using the Sql Management graphical tool, there is the Insert Column option at any position, but it…
-
4
votes5
answers12287
viewsHow to perform SQL concatenation
I need to concatenate year and month. How could I do that? select cast(year(orderdate) as int) + ' ' + cast(month(OrderDate)as int) as Year_Month From sales.SalesOrderHeader…
-
3
votes3
answers6518
viewsHow to access the code behind a Stored Procedure?
How can I access the code behind a stored procedure? I’m using Microsoft SQL Server Management Studio.
-
3
votes1
answer45
viewsInsert line number in SQL Manager
Hello! I’m trying to see the number of rows on the side of my SQL Manager query, but I can’t find where to put, could anyone help me? I’m getting an error in my query and it informs the line, but…
-
2
votes2
answers2254
viewsIs it possible to know where an sql execution originated in SQL SERVER?
There is a situation that I believe will be of great importance to me, which is to know the origin of an sql command in SQL SERVER. Suppose that accidentally a user has executed any command. Then I…
-
2
votes1
answer185
viewsCan Sql Server Management Studio handle any database?
I am asking this question because I find this DBMS simply fantastic, so I would like to use it with another database (not because I want to, but because most of the databases I have are in Mysql).…
-
2
votes2
answers87
viewsI have this query and I’m not able to group by month
DECLARE @Year INT = 2005, @Month INT = 7 SELECT --SequenceNo = ROW_NUMBER() OVER(ORDER BY OrderDate), Year = Year(convert(int,OrderDate,111)), case Month(convert(int,OrderDate,111)) when 1 then…
-
2
votes1
answer168
viewsWhat is a static table in SQL Server?
What is a static table in SQL Server? I can’t understand this concept by internet searches.
-
1
votes1
answer362
viewsShortcut/Autocomplete in SQL Server Management Studio (SSMS)
I’m using the SQL Server Management Studio (SSMS) in version 17.5 of 2017 and would like to create some shortcuts/autocomplete to make the search process a little faster, without deploying it in any…
-
1
votes1
answer428
viewsDelete all records from a database except a user
I have a database that I need to delete all records that exist in it, except one user that is in the table User linked to another table (Aspnetusers). I’ve made a few attempts to SSMS, but always…
-
1
votes0
answers140
viewsDBCC CHECKDB Cannot continue the Execution because the Session is in the Kill state
In our current database scenario, we have two databases A main database: BANCO01 And a BANCO01 dependency database used for testing: BANCO02 After running the database integrity check script. DBCC…
-
0
votes1
answer69
viewsSQL Server Code for Question
After 1 hour back of this question I cannot solve the code for it. Can anyone help me? Question: "Indicate the number of drivers per brand of car" The SQL Server tables created were the following:…
-
0
votes3
answers193
viewsSelect only first place in the first half - SQL Server Code
I made this code for SQL Server to select how many times the driver "Asdovolante" came first in the first half of 2017. But it doesn’t work. What may be wrong? SELECT P.Data, Nm.Nome,…
-
0
votes1
answer810
viewsCheck the triggers linked to a given table
I use the database Sql Server 2012 And the tool SQL Server Management Studio 2012 How can I check the triggers which are linked to certain tables without having to go by the object explorer? there…
-
0
votes0
answers338
viewsRestoring sql server management studio database
I’m creating a developmental environment. I went into production environment I opened sql server management studio right click on tasks database > backup I’m back in the development environment I…
-
0
votes1
answer98
viewsQuestion for SQL Server - Code
What are the names of the pilots who did less than '1:12' in the 1st round of the 2nd race? How can I make the times of every turn? I’ll have to make a new table? The SQL Server tables created were…
-
0
votes1
answer1231
viewsHow to increase the Grid View Result font in SQL Server Management Studio 17.9.1?
I want to increase the source of Grid View Result because it gets too small in a full hd notebook of 15.6. I’ve been to the Fonts and Colors options but I can’t find the option:…
-
0
votes3
answers69
viewsI have this cursor and the Where 'between' gives error. I wanted to select the years 2005 to 2008
DECLARE @Year int DECLARE db_cursor CURSOR FOR Select distinct Year(OrderDate) as Year From Sales.SalesOrderHeader Order by Year(OrderDate) OPEN db_cursor FETCH NEXT FROM…
-
0
votes0
answers68
viewsSQL Management Studio only connects remotely without the instance
While trying to make a connection with a first remote SQL, I realized that my Management Studio could not connect using the instance, as follows: After that attempt, I removed the instance, and…
-
0
votes1
answer69
viewsProblems in select using Having MAX non-boolean expression
I need to make a select to pick up all the patients who have been consulted over a period of time in a specific sector, and see when their last comeback was, and if they are more than a year old not…
-
0
votes0
answers29
viewsImport Simple File by SQL Server Magement Studio giving Expired Run Time Out error
Hello. I am using the "Import Simple File" wizard from SQL Server Magement Studio to import a 2GB TXT file into a SQL Server Express database. I follow the entire process of the wizard, it…
-
0
votes0
answers21
viewsWhat reference is missing for my Form fields to be filled with Datagridview information?
I created a separate project to find out why information from any row in my table is not sent to the fields in my frmVisualizar_Cadastro. I discovered the error and now when I click on any row of my…
-
-1
votes2
answers207
viewsHow to create a database in SQL Server?
I installed SQL Server, and comes Magnament Studio, how do I create my bank? I tried going there, and I had authenticated by Windows but it is error. How I create my bank?
-
-1
votes0
answers8
views0x800B010C error on SQL Server Mananger Studio installation
I downloaded the SSMS on https://docs.microsoft.com/pt-br/sql/ssms/download-sql-server-management-studio-ssms?view=sql-server-ver15 when I ran it returned me the message "INSTALLATION FAILURE…
-
-1
votes0
answers19
viewsHow to Select Field from a Table in Microsoft SQL Server Management Studio (SSMS) through C#?
I am making a login system, and for the login to be valid, I must read the value entered in txtNome (where the user will have entered the name he registered), save the text in a variable and perform…
-
-2
votes1
answer23
viewsUpdate a given table field - SSMS V18
I’m filling a table with data that I pick up in a JSON, as shown in the image: When the markettype is 'place', does not have the correct information of 'Category' and 'Distance'. When the markettype…
-
-4
votes1
answer159
viewsSql query formatting in one line only
In some cases, when we save a query. sql, even if it is indented correctly in the SSMS when we open in the Notepad (windows) all the text is in one line, joining END with GO (ENDGO) at the end of a…