共用方式為


FileName Element for LogFile (ICF)

Specifies the path and file name of the database log file.

語法

<Database>
    ...
    <LogFile>
        ...
        <FileName>

Element Characteristics

Characteristic Description

Data type

string, between 1 and 260 characters in length.

Default value

None.

Occurrence

Required once per LogFile element.

Updates

Cannot be added, deleted, or modified when updating the instance.

Element Relationships

Relationship Elements

Parent element

LogFile Element (ICF)

Child elements

None.

備註

The path portion of the file name must specify a folder accessible by the instance of SQL Server and cannot specify a folder in a compressed file system.

If you need to alter the database after creating the instance, use the SQL Server tools, such as SQL Server Management Studio.

For more information about log file names, see the os_file_name parameter in the CREATE DATABASE (Transact-SQL) topic.

範例

This example shows how to create the database log file in a folder specified by the %BaseDirectoryPath% parameter and has the name Stock.ldf.

<FileName>%BaseDirectoryPath%\Stock.ldf</FileName>

請參閱

參考

Application Definition File Reference

概念

Instance Configuration File Reference

其他資源

更新執行個體及應用程式

說明及資訊

取得 SQL Server 2005 協助