Databases Reference
In-Depth Information
You can also manage permissions through explicit assignments to individual users,
but this is discouraged because of the added management overhead involved in
handling permissions at that level. Permission management is discussed in more
detail later in this chapter.
11.2.3 Understanding the Connection Process
Now that you have an understanding of the security objects involved, we can take
a closer look at the connection process from the context of SQL Server. The process
for most other high-level DBMS products is similar. We'll start with the connec-
tion dialog box, only this time we'll look at advanced connection properties.
In Figure 11-10, you're logging in to the database engine, the database server,
using Windows authentication. This is also referred to as connecting with inte-
grated security, referring to SQL Server security integrated with Windows secu-
rity, or a trusted connection, meaning that the user is trusted to connect to SQL
Server. If you choose SQL Server authentication, you must provide a valid SQL
Server login name and password.
The Connection Properties tab in the Connect to Server dialog box is shown
in Figure 11-11. Here, you can specify the database for the connection, over-
riding the login's default database. You can specify network communication
parameters, in this case the network protocol to use for communication and the
network packet size. The packet size controls how much data is sent at a time.
Additional connection properties let you set the connection and command exe-
cution time-outs, with a value of 0 used for no time-out, meaning that the client
will wait indefinitely for the server's response.
When you connect, the login criteria are either passed to Windows for
authentication or authenticated by SQL Server. The connection to the server is
established and a process ID value assigned for the connection. The login's
default database is set as the connection's current database, unless a different
database is specified.
When connecting with a connection that opens a command-line prompt, like
the Sqlcmd command, connection parameters are passed as command options.
For example, the following command line connects to a server named Datadev
using the login sa, a password of P*ssword, and sets GeneralHardware as the
current database:
sqlcmd -sDatadev -Usa -PP*ssword -dGeneralHardware
Command options are case-sensitive, so you have to be careful when typing
the command. For example, the capital -U option is used to specify the login,
but the lower case -u option specifies the command to output Unicode charac-
ters instead of ASCII characters.
If you wanted to connect as a trusted connection, you would use the following:
sqlcmd -sDatadev -E -dGeneralHardware
Search WWH ::




Custom Search