DriveWorks Solo 16: TableReplaceHeaders [send feedback...]

TableReplaceHeaders

Replaces the headers in the given table, the result is returned as an array.

Syntax

TableReplaceHeaders(Table, Replacement Headers List, Replace Blank Headers)

Where:

Table is the Table in which to replace the headers.

Replacement Headers List is a pipe delimited list of headers to replace the existing headers in the table.

Replace Blank Headers is True to replace the existing header with the blank value. False to leave the existing header if a blank value is supplied in the list. By default this is false.

Examples

RuleMeaning
TableReplaceHeaders(DwLookupCustomers,"Name|Area||",False)Will replace the header row of the Customers table with the values Name and Area. The last column header will not be replaced

Example Data

Customers Table

CustomerNameCityCountry
Amazon WarriorsParisFrance
Bolton BurnersConcordUnited States
Boston BullsHanoverGermany
Cambridge CatsToulouseFrance

Example Outcome

Customers Table

NameAreaCountry
Amazon WarriorsParisFrance
Bolton BurnersConcordUnited States
Boston BullsHanoverGermany
Cambridge CatsToulouseFrance

DriveWorks will return the table above as an array, which will look like:

Table returned as an Array
{"Name","Area","Country";"Amazon Warriors","Paris","France";"Bolton Burners","Concord","United States";"Boston Bulls","Hanover","Germany";"Cambridge Cats","Toulouse","France"}


Table of Contents