Skip to main content

Posts

Showing posts with the label SQL Server Connection String

SQL Server, Connection String creation

Whenever we need to create a connection string for a new database or in the same database then we need to follow simple few steps listed below: Create the login in the master database using the query given in the above mentioned reference file name or see as given CREATE LOGIN [XYZ] WITH PASSWORD=N'XYZ', DEFAULT_DATABASE=[Master], DEFAULT_LANGUAGE=[us_english], CHECK_EXPIRATION=OFF, CHECK_POLICY=OFF GO NOTE- if you are using the sql server GUI to create a new login then please make sure to un check the enforce password policy otherwise there would be problem with the connection string in the near future Create the User in the concerned Database and attach the user with the particular login any failure in doing so will result an error while using the connection string. Set the default schema name with it too (default schema name is useful as all the procedures under that default schema can be accessed by the application using the procedure name only if any other schema proc...