I looked at How can I determine installed SQL Server instances and their versions? already but CMD returns nothing:
C:\Windows\system32>sqlcmd -L
C:\Windows\system32>
But when using Visual Studio (v2019), I go to View > SQL Server Object Explorer, I see two SQL Server instances with system databases inside. One is called (LocalDB)\MSSQLLocalDB and the other (LocalDB)\ProjectsV13.
Both are using SQL Server 2016 (v13.0.4001). Using that I was able to connect through SSMS 2018 as well.
My question is: why aren't these instances showing up in the command line? And can I delete one of the server instance? Why are there two?
Using SSMS, in the connection manager typing the following in the server name box does it:
.
open cmd and type hostname, and use that
(LocalDB)\MSSQLLocalDB
(LocalDB)\ProjectsV13 I think this depends on the installation
Related
I'm doing the SSRS setup in my DEV environment. I've been using (LocalDb)\MSSQLLocalDB for some of my databases. Now that I want to start using SSRS, can I use (LocalDb)\MSSQLLocalDB as a data source for SSRS? I already tried, but I'm not able to connect it. However, if I use the server name (name of my computer) it works.
Do I have to use the actual server name? Is local database (LocalDb)\MSSQLLocalDB a wrong way of doing it? I'm assuming that the actual server name will be the best practice.
If I have to use the server name, that means that I will need to migrate my databases from (LocalDb)\MSSQLLocalDB to the instance of the server name.
What do you recommend?
LocalDb instances run in your desktop session, and are meant for desktop applications (particularly Visual Studio). So no. You should migrate your databases to a service-based SQL Server instance for SSRS (which runs as a Windows Service) to access them.
I have installed the SQL Server Management Studio (v. 17.9.1) but I am not able to create an instance.
In fact no server appears in the box when I browse:
How can I proceed, step by step, to create a local instance?
You can create a local Database by using the command prompt. As open cmd with Admin privilege, > sqllocaldb create "database name" -s(start with it) . There is lot of option with sqllocaldb read there.
Go to windows services (services.msc) and check if SQL Server and SQL Server Browser are running. If not, start them and you should be able to login and create the DB.
type in sql server download in your browser and go to microsoft's website. You have downloaded SSMS but you do not have a server installed. Download SQL express or SQL developer edition and install. Once you have done this you will have a default instance (or named if you customized the install). I must have hit this posting 4 times trying to figure this out but now I'm off and running. If you want a test database to play with you can then download adventureworks (again just use your browser (sql adventureworks) and download the backup file. You can restore it by clicking on the databases folder once you have connected to your sql instance in SSMS.
I am very new to SQL Anywhere. I have been working MSSQL for a long time.
So in MSSQL, if we need to see the list of database under server, we can see that under Server Explorer.
How can I do same in SQL Anywhere?
I have just installed SQL Anywhere 16 and have no idea how to find Server name etc.
There should be a program called "SQL Central" (scjview.exe) that was installed with SQLAnywhere server. Run that and you should be able to see the servers.
I have a very fundamental and basic SQL question. Using Microsoft SQL Server Management Studio Express, how do I create my first Server? For that matter, how would I create it using any other required software tool?
I took a look at Sql Server Configuration Manager and I saw SQLEPRESS running as a SQL Server. But when I added that in to the start up widow for MSSM Studio Express, as the server name, it threw an error saying it cannot be found or does not exist. It seems that this is not the right kind of server.
To connect to the local instance of SQLEXPRESS, you will need localhost as the server name.
This is a fairly comprehensive guide on how to create a database once you have connected. All the steps won't apply to using SQL Express, but the gist of it is there.
In Object Explorer, connect to an instance of the SQL Server Database
Engine and then expand that instance.
Right-click Databases, and then
click New Database. In New Database, enter a database name.
To create
the database by accepting all default values, click OK; otherwise,
continue with the following optional steps.
Based on this comment:
Trying .\SQLEXPRESS in SQL Server Management Studio Express throws an error that says that "This version of Microsoft SQL Server Management Studio Express can only be used to connect to SQL Server 2005 servers". So this is the problem, I think.
.\SQLEXPRESS is the correct server name, but you have the wrong version of client tools (SQL Server Management Studio). To find out the version of SQL you are connecting to, there are a number of suggestions here: https://www.mssqltips.com/sqlservertip/1140/how-to-tell-what-sql-server-version-you-are-running/
But since you can't connect yet the easiest thing to do is go searching for sqlserver.exe, right click, properties, version. If you have multiple version you need take note of the folder that it's in and check the SQLExpress one. You can also check in services.
Once you've worked out the version, download and install just the management tools for that version.
I am just learn C# from Java and now struggling with sql server
i usually use mysql with phpmyadmin
i use windows 7
i already install Visual Studio 2013 Community Edition, in control panel program and feature there is some name with sql server
i try to search the answer in google for 3 days & download many youtube tutorial. but still confuse what to do.
My goal :
i try to create ms sql database like i do in phpmyadmin
i dont want to create local database, i try to create database in server (the server sit in localhost)
heres what i do :
in visual studio 2013 - server explorer tab, i right click in data
connections
then select Create New Sql Server Database
dialog show up and my question :
What value i must put in Server Name
If i select radio button Use SQL Server Authentication. what value i
must put in username and password. (when installing visual
studio, it don't tell me anything)
thank, forgive my english
EDIT :
i already install management studio from here. At installing, it dont tell me any configuration.
Using SSMS i still can't create database, i already try :
via Windows Authentication with servername : 127.0.0.1 or localhost
via SQL Server Authentication with username : sa, password :
[empty], or Password123, or [myComputerPassword]
i already try uninstall & install Visual Studio 2013 Community Edition & SQL Server 2014 Management Studio multiple time in different PC. But it dont tell me any configuration when installing.
based on my newbie feeling : (maybe) it look like installation don't create instance server
here's my control panel look like :
Unless SQL Server was installed with non-default settings, the following connection parameters should allow you to connect to your (locally installed) SQL Server instance:
Password: chances are that SQL Server was installed with SQL Server authentication disabled. Try to log in with the option Integrated Authentication or Integrated Security enabled, then you won't even have the option to enter a username and password.
Server: try these in the following order:
.\SQLEXPRESS (which stands for "instance named SQLEXPRESS on the local host, .")
. (which stands for "(instance with default name on the) local host")
(localdb)
Basically, the server name consists of up to three parts: First, the network host on which the desired SQL Server service is running (the local host or . in your case), the name of the SQL Server service after a \ (often MSSQLSERVER or SQLSERVER, the first of which you can omit because it's the default name), and a network port on which the SQL Server service is listening (you can often omit that, too).
You can find out your SQL Server's service name from Administrative Tools → Services. Locate the entry for the SQL Server service and note down the name in the parentheses; that's what will go after the .\ in the server name:
You usually get a local or express version of Sql Server installed when you install Visual Studio.
You can however..go a little further.
Sql Server Express 2014 (You may already have this installed based on what you chose during the install)
https://msdn.microsoft.com/en-us/evalcenter/dn434042.aspx
Sql Server 2012 Express
http://www.microsoft.com/en-us/download/details.aspx?id=29062
Under the 2012, you'll also note that one of the downloads is
SQLManagementStudio_x64_ENU.exe
This is "Sql Server Management Studio". This is a front-end to the Sql Server RDBMS. You could do most things through Visual Studio, but I usually install SSMS as well. SSMS is kinda the same thing as MySql Workbench.
You can also write scripts and execute them in SSMS.
You security mode is probably "Trusted" which means you connect to Sql Server using your windows credentials. This was auto-voodoo'ed mapped for you when you did the install.
Sql Authentication (the alternative to Trusted) is the username/password model. This takes extra setup and configuration (usually through SSMS), so your easiest bet is to rely on "Trusted" unless you find a need for something else.
I hope that helps.