Related differences

Ques 6. How to get a list all databases on the SQL server?

If you don't remember database names you have created, you can get a list of all databases on the server by query the "sys.databases" view as shown in this tutorial example:

CREATE DATABASE withoutbookdb
GO

SELECT name, database_id, create_date FROM sys.databases
GO
[name] [database_id] [create_date]
master 1 2003-04-08 09:13:36.390
tempdb 2 2007-05-19 13:42:42.200
model 3 2003-04-08 09:13:36.390
msdb 4 2005-10-14 01:54:05.240
withoutbookdb 5 2007-05-19 20:04:39.310

As you can see, the newly created database is listed at the end of query result.

Is it helpful? Add Comment View Comments
 

Ques 7. How to download Microsoft SQL Server 2005 Express Edition?

Microsoft SQL Server 2005 Express Edition is the free version of the Microsoft SQL Server 2005. If you are interested to try SQL Server 2005, you should follow this tutorial to download Microsoft SQL Server 2005 Express Edition:

1. Go to the Microsoft SQL Server 2005 Express Edition download page.

2. Go to the Files in This Download section, and click Download button next to the "SQLEXPR.EXE - 53.5 MB" file. The File Download box shows up.

3. Save the download file to C:temp directory. When the download is done, you should get the following file:

Name: SQLEXPR.EXE
Description: Microsoft SQL 2005 Server Express Edition
Location: C:temp
Size: 56,105,688 bytes
Version: 9.0.1399.6

Is it helpful? Add Comment View Comments
 

Ques 8. Where is my database stored on the hard disk in MS SQL Server?

If a database is created with simple CREATE DATABASE statement, the server will create two database files on the hard disk to store data and configuration information about that data bases:

* database_name.mdf - SQL Server Database Primary Data File
* database_name_log.ldf - SQL Server Database Transaction Log File

To find out the location of database files, you can query the "sys.database_files" view as shown in this tutorial example:

USE withoutbookdb
GO

SELECT type_desc, physical_name, size
FROM sys.database_files
GO
type_desc physical_name size

ROWS c:Program FilesMicrosoft SQL Server
MSSQL.1MSSQLDATAwithoutbookdb.mdf 152

LOG c:Program FilesMicrosoft SQL Server
MSSQL.1MSSQLDATAwithoutbookdb_log.LDF 63

Go verify these two files with Windows Explorer.

Is it helpful? Add Comment View Comments
 

Ques 9. System Requirements for SQL Server 2005 Express Edition?

The following system requirements cover the SQL Server 2005 Express Edition:

Processor
32-bit Processor of 600-megahertz (MHz) or faster

Operating System
Windows XP with Service Pack 2 or later
Windows 2000 Professional with SP4
Windows 2000 Server with Service Pack 4 or later
Windows Server 2003 Standard, or Enterprise SP1
Windows Server 2003 Web Edition SP1
Windows Small Business Server 2003 with SP1
Vista Home Basic and above

Framework
.NET Framework 2.0

Memory
512 megabytes (MB) or more recommended

Hard Disk
Approximately 425 MB of available hard-disk space

Is it helpful? Add Comment View Comments
 

Ques 10. How to create database with physical files specified in MS SQL Server?

If you don't like the default behavior of the CREATE DATABASE statement, you can specify the physical database files with a longer statement:

CREATE DATABASE database_name
ON (NAME = logical_data_name,
FILENAME = physical_data_name,
SIZE = x, MAXSIZE = y, FILEGROWTH = z)
LOG ON (NAME = logical_log_name,
FILENAME = physical_log_name,
SIZE = x, MAXSIZE = y, FILEGROWTH = z)

For example, the following statement will create a database with database files located in the C:temp directory:

USE master
GO

DROP DATABASE withoutbookdb
GO

CREATE DATABASE withoutbookdb
ON (NAME = withoutbookdb,
FILENAME = 'C:tempwithoutbookdb.mdf',
SIZE = 10MB, MAXSIZE = 50MB, FILEGROWTH = 5MB)
LOG ON (NAME = GlobalGuidelineLog,
FILENAME = 'C:tempwithoutbookdb.ldf',
SIZE = 1MB, MAXSIZE = 5MB, FILEGROWTH = 1MB)
GO

SELECT type_desc, name, physical_name, size
FROM sys.database_files
GO
type_desc name physical_name size
ROWS withoutbookdb C:tempwithoutbookdb.mdf 1280
LOG GlobalGuidelineLog C:tempwithoutbookdb.ldf 128

Is it helpful? Add Comment View Comments
 

Most helpful rated by users: