Skip to content
  • There are no suggestions because the search field is empty.

File Extension (Model Object)

Applies to
Platform: Microsoft SQL Server
Architecture: Stage

File Extension (FileExtension) is the extension of the source files that the raw data loader looks for in the source folder. Together with the source object name and File Group Pattern, it decides which files the loader reads.

The property exists only in the Microsoft SQL Server Stage File generator. There, the raw data loader is the procedure that reads the files of a Stage into its raw data table.

Where to set it

Set File Extension when you edit a model object of type Source. It is a text field.

Values

  • An extension with or without the leading dot: csv and .csv give the same result, because the generator adds a missing dot.
  • Empty: the file name pattern ends with File Group Pattern, so with the default * files with any extension match.

Default value

Empty. A source object that you create from a Discovery gets the extension that the Discovery found, for example .csv.

Effect on the raw data loader

The loader lists the files with the Windows dir command and the pattern <source object name><File Group Pattern><File Extension>. Here <source object name> is the name of the Source. For the Source ITEM with File Group Pattern * and File Extension .csv, the generated command is:

SET @CmdStatement = N'DIR "' + @SourceDirectory
    + N'ITEM*.csv" /b /o:n /a:-d';

The line break is added here for readability.

Example

The source folder holds ITEM.csv, ITEM_2024.csv and ITEM.txt. The Source ITEM has File Group Pattern *.

  • File Extension .csv or csv: the loader reads ITEM.csv and ITEM_2024.csv.
  • File Extension empty: the loader also reads ITEM.txt.

Related articles