Tag: ssms

SQL Server query designer on C# application

I have been given the tasking of providing a desktop solution which allows a user to simply and safely create bespoke reporting queries where their knowledge of the database is limited. Immediately what came to mind is the SQL server query designer in SSMS. I have searched the internet with no success of whether this […]

SQL Server Management Studio: prompt for user input

Is it possible in SQL Server Management Studio to ask the user for input and based on that input proceed? I have a stored procedure which inserts some data into tables. When ever a user executes the stored procedure, I want a message to come up asking if he is sure he wants the stored […]

How to correct a SQL Server Syntax Error setting FK contrainsts?

Trying to run this query in SSMS 2012: SET FOREIGN_KEY_CHECKS = 0; TRUNCATE TABLE dbo.mydb; SET FOREIGN_KEY_CHECKS = 1; Results in this error on the Foreign Key check Msg 102, Level 15, State 1, Line 3 Incorrect syntax near ‘=’. So both SET commands are failing for this reason. How can I fix the syntax […]

Identity column skipping some values when adding a new row

I have a table with 56 rows. Adding new rows starts from ID 59. What can I do to continue with ID 57?

How to migrate only TOP 1000 rows from Oracle to SQL Server?

I’m trying to migrate only a limited number of rows from several tables in Oracle to SQL Server. I have SQL Server Management Studio and SSMA for Oracle installed, but I’m not sure how to selectively import data into a new SQL Server database. Any help will be appreciated, thanks!

Pick a physical location for a single database in Management Studio

I have the following issue: I am working on a Macbook Retina with 250gb harddisk space, and 10gb left. Now, I just got a new customer, who runs their SQL Server database locally (./SQLEXPRESS). Problem is their database is 110gb. That means I am forced to work on an external harddrive on some databases, but […]

How can I automate / script an update that modifies 100+ triggers at once (or in a loop)?

Summary I am trying to figure out a way I can automatically alter 100+ triggers at once or in a loop. The triggers are all identical except for the respective table that they are associated with. Details: I have a SQL server database and I have 300+tables and over 100+ of those tables have a […]

SQL Server (running/stopped) Status in SSMS

In the attached image below, I show my SQL Server as seen from SSMS on my PC (left) compared to the same as seen from the server (right) … could someone advise why the view from my PC does not show the status indicator (running/stopped) for the server and for the SQL Server Agent items? […]

How can I copy-and-paste Data into MySQL Workbench table?

I’ve used MySQL Workbench and MS SQL Server Management Studio off & on over the years. The one thing I enjoy with SSMS is the ability to copy information from an Excel document and paste it into the results pane of SSMS. Is there a similar means of importing information into tables for MySQL Workbench? […]

Trying to manually run SSIS package on MSDB but getting error

I am trying to run my SSIS packages on MSDB with a console application, but I keep getting an error. Application app = new Application(); Package package = app.LoadFromSqlServer(“\\File\\Path\\” + paramName, “.”, “MSDBUser”, “password”, null); DTSExecResult result = package.Execute(); Console.WriteLine(“Package Execution Results: {0}”, result.ToString()); I keep getting the error: “The Execute method on the task […]

MS SQL Server is a Microsoft SQL Database product, include sql server standard, sql server management studio, sql server express and so on.