Using Name/Value Pairs Text Files |
In a name/value pairs text file, data is contained in a structure that identifies one or more data values and a name that is used to identify the values, such as the following.
Name="Ruth"
Occupation="Writer"
Location="Minneapolis, Minnesota"
Name="Ernst"
Location="Seattle, Washington"
Name="Tracy"
Location="Encino, California"
Occupation="Project Manager"
Name="Richard"
Occupation="Musician"
Sometimes, a name/value pairs file places the data for each record on a single line, such as the following.
Name="Ruth",Occupation="Writer",Location="Minneapolis, Minnesota"
Name="Ernst",Location="Seattle, Washington"
Name="Tracy",Location="Encino, California",Occupation="Project Manager"
Name="Richard",Occupation="Musician"
The name/value pairs can be delimited in several ways, such as by using commas (as in this example), and the value fields need not be specified in the same order for each record. Records can be separated in several ways, such as by using line breaks or custom strings.
When you use the Database Setup wizard to connect to a name/value pairs text file, BarTender analyzes the data in the file, determines which type of format it uses, and automatically configures the options in the wizard to match the detected format, although you can manually configure the settings as needed.
|
To start the Database Setup wizard to connect to a database for the first time, click Database Connection Setup on the File menu. Alternatively, click on the main toolbar. To start the wizard for an existing connection, click Configure Connection in the Database Setup dialog. |
When Name/Value Pairs is selected as the Format option on the File Format page of the wizard, the following options are available:
Pair Separation: Specifies the delimiter that is used to separate a field name from its value. Available options include Equals (meaning the equal sign [=]), Colon, Space, Tab, and Custom. When you select Custom, the Delimiter field appears. Enter the delimiter that you want, or click to insert a symbol or special character.
Field Separation: Specifies the delimiter that is used to separate one field from another. Available options include Line Break, Comma, Semicolon, and Custom. When you select Custom, the Delimiter field appears. Enter the delimiter that you want, or click to insert a symbol or special character.
Record Separation: Specifies the delimiter that is used to separate one record from another. Available options include Line Break and Custom. When you select Custom, the Delimiter field appears. Enter the delimiter that you want, or click to insert a symbol or special character.
Specify advanced filtering options: Specifies that the Line Filtering and Data Filtering pages of the wizard appear when you click Next. For more information about these options, refer to Filtering Options for Text File Databases.
Related Topics