Tab-delimited tables are imported intelligently when dragged or pasted into Tinderbox. For example, selecting a table in a spreadsheet and pasting it into Tinderbox will create a useful set of notes:
- The first row is treated as a set of headings, which map to attributes. New user attributes will be created for attributes that do not already exist.
- A new container will be created to hold the table's rows.
- Each row of the table becomes a note. The table's fields are key attributes, and these attributes are populated from the table.
- Empty cells (i.e. content-tab-tab-content) and line breaks in cell content are allowed from v5.0.0.
- For date-based date - see here.
Empty values in numeric fields are imported as "0". The first column always maps to $Name, so you may want to duplicate column 1 at source or add a 'name' column there so that the otherwise first column of the original data gets handled as a user attribute.
The feature works beyond formal spreadsheets - any tab-delimited text sample should import. This allows other material such as vcf address card data to be dragged into Tinderbox.
Tinderbox will attempt auto-detection of dates, non-ASCII characters and to handle clipboard data from Numbers '09.
From v5.5.0, if 'Text' is used as a column header $Text is mapped but $Text is no longer used as a key attribute. Also, Tinderbox is more efficient at dealing with characters in column headers that are not normally supported in attribute names. For instance, an underscore is often used as a substitute character in field names. Whilst a user can't make an attribute named "Some_Field", because it contains an underscore, data import may do so to retain fidelity with source.
Existing notes vs New notes. The tab-delimited import method only creates new notes. It cannot be used to set attribute values in pre-existing notes. Thus a new note with a title ($Name) duplicating an existing note may get created on import, rather than changing attributes of the existing note. However, this does offer scope for updating existing notes. Action code can search in a given location, for notes whose $Name matches a note elsewhere. Having identified the link, further action code could then copy across the necessary attribute values to the older pre-existing note. The newly imported imported note could then be moved to a new container outside the scope of the original query (i.e. so the update action only occurs once).