Examples of Schema.ini Files

This section shows two examples of Schema.ini files. The first example is the schema information file for a comma-delimited text file, and the second example is for a fixed-length file.

The first example is the Schema.ini file for the text table Sample1.txt in the JetBook\Samples\Text\CommaDelimited directory. This file does not contain header information in the first row and is in comma-delimited format. The character set is ANSI and there are five columns. Each of the columns is designated by name, along with the corresponding data type, but only three columns include a width designator. (Width designators are optional for character-delimited files.)

[SAMPLE1.TXT]
ColNameHeader=False
Format=CSVDelimited
CharacterSet=ANSI
Col1=ProductID Short
Col2=ProductName Char Width 30
Col3=QuantityPerUnit Char Width 30
Col4=UnitPrice Currency
Col5=Discontinued Bit

The second example is the Schema.ini file for the text table Sample2.txt in the JetBook\Samples\Text\FixedLength directory. This file does not contain header information in the first row and is in fixed-length format. The character set is ANSI and there are five columns. Each of the columns is designated by name, along with the corresponding data type, and each includes a width designator, as required.

[SAMPLE2.TXT]
ColNameHeader=False
Format=FixedLength
CharacterSet=ANSI
Col1=CategoryID long width 11
Col2=CategoryName text width 15
Col3=Description memo width 513