compile
and run
commands can take targets in multiple formats:
sdf compile catalog.schema.table_name
using fully qualified namesdf compile table_name
using table name and inferred fully qualified name from the default catalog and schemasdf compile /path/to/table_name.sql
using file pathsdf compile catalog.*.*
using glob pattern to compile multiple targetssdf compile [No params]
using no params compiles the whole workspacesdf compile /path/to/workspace
enables compiling a workspace from outside the workspace directorysdf run -q "SELECT * FROM table_name"
using a query stringworkspace.sdf.yml
file, is best practice as error messages and logs will use the relative path from the workspace root in their output.--show (all | progress | result | none)
- Print desired amount of information, i.e., produced tables.
all
prints progress, results, and any warnings and errorsprogress
prints the progress of files as they are compiledresult
prints the tables parsed and the schema assocaitednone
prints nothing. This will also prevent the Finished in [n] seconds
message from displaying at the end of stdout.--format (table | csv | tsv | json | nd-json | yml)
- Specifies the table representation
on stdout.
table
(default) is the normal ascii table representation.csv
is a CSV representationtsv
is a TSV representationjson
is a JSON representationnd-json
is an ndJSON representationyml
, is YML representation--limit <number>
- Limits the number of shown rows. Run with --limit 0
to show all rows.
Install and setup your workspace
Created lineage/checks/check_sink_phone_is_pii.sql
Created lineage/models/knis.sql
Created lineage/models/middle.sql
Created lineage/models/sink.sql
Created lineage/models/source.sql
Created lineage/workspace.sdf.yml
Welcome to your new SDF Workspace! To help you on your journey:
💡 Join the SDF Community Slack -> https://sdf.com/join
📚 Read the Docs to Get Started -> https://docs.sdf.com/
Finished new in 0.314 secs
Change Directory
Compile lineage Workspace with --show command
Working set 4 model files, 1 .sdf file
Compiling lineage.pub.source (./models/source.sql)
Compiling lineage.pub.middle (./models/middle.sql)
Compiling lineage.pub.knis (./models/knis.sql)
Compiling lineage.pub.sink (./models/sink.sql)
Finished 4 models [4 succeeded] in 1.651 secs
--show all
command to display all information after compilelineage.pub.middle
table.Display for Individual Tables
compile
command.compile
command can take targets in multiple formats.sdf compile catalog.schema.table_name
using fully qualified namesdf compile table_name
using table name and inferred fully qualified namesdf compile /path/to/table_name.sql
using file pathsdf compile catalog.*.*
using glob pattern to compile multiple targetssdf compile [No params]
using no params compiles the whole workspaceschema
of an external table must be given explicitly, following the ANSI standard SQL syntax or