
Extract columns with their source tables from a TWB
Source:R/fields.R
extract_columns_with_table_source.Rd
Scans top-level <datasource>
nodes (excluding view-specific references) and
returns fields with raw names/captions, cleaned table/field names, and basic
metadata.
Value
A tibble with columns:
- datasource
Datasource name.
- name
Raw column name (may include brackets/qualifiers).
- caption
Column caption if present.
- datatype
Tableau datatype.
- role
Tableau role.
- semantic_role
Semantic role if present.
- table
Raw table reference.
- table_clean
Cleaned table name (no brackets/suffix).
- field_clean
Cleaned field name.
Examples
if (FALSE) { # \dontrun{
xml <- xml2::read_xml("inst/extdata/sample.twb")
fields <- extract_columns_with_table_source(xml)
} # }