Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What are NDF Files?

Tags:

sql

sql-server

SQL Server uses MDF for data files and LDF for log files, but what are NDF files?

Whats the benefits of these files?

like image 822
Nasser Hadjloo Avatar asked Apr 25 '10 06:04

Nasser Hadjloo


People also ask

Can I delete NDF files?

NDF files are just like MDF files, they contain data. LDF files are for log data. Do NOT delete NDF files!

What opens an NDF file?

You need a suitable software like SQL Server to open an NDF file.

What is mdf and NDF?

A Microsoft SQL database consists a primary data file (mdf) a secondary data file (ndf) and a transaction log file (ldf).

What does NDF stand for in SQL Server?

ndf to represent “Not Master Data File,” and the idea was accepted.


1 Answers

From Files and Filegroups Architecture

Secondary data files

Secondary data files make up all the data files, other than the primary data file. Some databases may not have any secondary data files, while others have several secondary data files. The recommended file name extension for secondary data files is .ndf.

Also from file extension NDF - Microsoft SQL Server secondary data file

See Understanding Files and Filegroups

Secondary data files are optional, are user-defined, and store user data. Secondary files can be used to spread data across multiple disks by putting each file on a different disk drive. Additionally, if a database exceeds the maximum size for a single Windows file, you can use secondary data files so the database can continue to grow.

The recommended file name extension for secondary data files is .ndf.

/

For example, three files, Data1.ndf, Data2.ndf, and Data3.ndf, can be created on three disk drives, respectively, and assigned to the filegroup fgroup1. A table can then be created specifically on the filegroup fgroup1. Queries for data from the table will be spread across the three disks; this will improve performance. The same performance improvement can be accomplished by using a single file created on a RAID (redundant array of independent disks) stripe set. However, files and filegroups let you easily add new files to new disks.

like image 188
Adriaan Stander Avatar answered Sep 25 '22 08:09

Adriaan Stander