Add `pipekit export` / `pipekit apply` (pipekit/config_io.py) to serialise the DB's config — drivers, connections, modules (+ columns, watermarks, hooks), groups, schedules — to a git-trackable text tree under config/, and rehydrate it. SQLite stays runtime state; definitions become diffable/reviewable/ revertible. - config only: run_log/group_run/settings and per-run state columns excluded - name-keyed refs (portable across databases); source_query in .sql sidecars; columns as real JSON arrays for line-by-line diffs - newline-normalised so CRLF-vs-LF is never a spurious change - apply is create/update by name; child collections fully synced; top-level deletes gated behind --prune; --dry-run prints the plan - round-trip is identity (export -> apply --dry-run == nothing to do) Commits the current config/ as the first baseline, capturing the freshly populated columns_json for rm00101/rm00301/iv00101. Documented in SPEC.md. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
38 lines
1.2 KiB
Transact-SQL
38 lines
1.2 KiB
Transact-SQL
SELECT
|
|
RTRIM([Doctype]) AS [doctype],
|
|
RTRIM([Doc Num]) AS [doc_num],
|
|
RTRIM([Original Doc]) AS [original_doc],
|
|
[Doc Date] AS [doc_date],
|
|
[Order Date] AS [order_date],
|
|
[Req Date] AS [req_date],
|
|
[Prom Date] AS [prom_date],
|
|
RTRIM([Cust Num]) AS [cust_num],
|
|
RTRIM([Cust Name]) AS [cust_name],
|
|
RTRIM([Rep ID]) AS [rep_id],
|
|
RTRIM([Rep Name]) AS [rep_name],
|
|
RTRIM([Cust PO]) AS [cust_po],
|
|
RTRIM([_HD_Grower]) AS [hd_grower],
|
|
RTRIM([Origin]) AS [origin],
|
|
RTRIM([Address Code]) AS [address_code],
|
|
RTRIM([State]) AS [state],
|
|
RTRIM([City]) AS [city],
|
|
RTRIM([Cust Channel]) AS [cust_channel],
|
|
RTRIM([Mold ID]) AS [mold_id],
|
|
RTRIM([Item Num]) AS [item_num],
|
|
RTRIM([Item Description]) AS [item_description],
|
|
[Quantity] AS [quantity],
|
|
RTRIM([Collection]) AS [collection],
|
|
RTRIM([Segment]) AS [segment],
|
|
[Unit Price] AS [unit_price],
|
|
[Ext. Price] AS [ext_price],
|
|
[Unit Cost] AS [unit_cost],
|
|
[Ext. Cost] AS [ext_cost],
|
|
[Margin Dollar] AS [margin_dollar],
|
|
[Ext. Margin Dollar] AS [ext_margin_dollar],
|
|
RTRIM([Margin %]) AS [margin_pct],
|
|
RTRIM([Job Number]) AS [job_number],
|
|
RTRIM([Program]) AS [program],
|
|
RTRIM([Container]) AS [container],
|
|
RTRIM([AOP Rep]) AS [aop_rep]
|
|
FROM [GPSERVER].[CHG].[dbo].[_custom_sales_line_connector]
|