tailieunhanh - Wrox’s ASP.NET 2.0 Visual Web Develope 2005 Express Edition Starter Kit phần 2

Sau khi xác định các loại nguồn dữ liệu, bạn có thể sử dụng danh sách thả xuống tên máy chủ để xem tất cả các cơ sở dữ liệu của các loại mà bạn đã chọn quảng cáo hiện diện của họ và có sẵn. Bạn cũng có thể gõ một tên dụ trực tiếp. Trong Chương 4, bạn thấy làm thế nào SqlDataControl được sử dụng để lấy dữ liệu từ một cơ sở dữ liệu | Getting Started Figure 1-18 Adding a connection to a database server other than SQL Server After specifying the data source type you can use the drop-down Server name list to see all the databases of the type you selected that advertise their presence and are available. You can also type an instance name directly. For the default instance you just need to enter the machine name or you can access a named instance such as a remote Microsoft Data Engine MSDE or SQL Server Express instance by appending the instance name to the machine name separated by a backslash. Figure 1-19 shows a connection to the default instance of SQL Server running on a remote machine named DELBOY and to the Northwind database on that machine. 17 Chapter 1 Figure 1-19 Connecting to the Northwind database on a remote machine named DELBOY Figure 1-19 you must specify details of a suitable account within SQL Server. If for any reason you cannot install SQL Server Express or want to experiment with a different database you can use the process just described to connect to a suitable database. You can confirm that the connection to the target database is working by clicking the Test Connection button before you close the Add Connection dialog. 18 Getting Started Figure 1-19 is the option to connect to a SQL Server MDF database file. In this case you specify the file location using the Browse button near the bottom of the Add Connection dialog. As before you must specify the database server name to which the file will be attached and the authentication type you want to use. Another feature is the ability to specify the fine details of the connection. Click the Advanced button near the bottom of the Add Connection dialog to open the Advanced Properties dialog. For example you can turn on or off features such as Multiple Active Results Sets and Asynchronous Processing which saves resources and increases efficiency if you do not require these features. Figure 1-20 shows a connection to a database file .

TỪ KHÓA LIÊN QUAN