Problem
Currently there are no examples showing how to use XML input files in:
- The usage text (
main.zig --help)
- The man page (
docs/sql-pipe.1.scd)
- The README.md
Users may not discover that sql-pipe supports XML input via -I xml or --input-format xml, especially for nested structures like RSS feeds that require --xml-root and --xml-row.
Proposed Solution
Add XML usage examples to all three documentation locations:
- main.zig --help text — Add example showing basic XML input and the --xml-root/--xml-row flags
- docs/sql-pipe.1.scd — Add an EXAMPLES section with XML examples, including RSS feed navigation
- README.md — Add XML section in the "Input formats" area with a practical example
Example for main.zig (usage)
Add to the Examples section:
cat data.xml | sql-pipe -I xml --xml-root channel --xml-row item "SELECT title FROM t"
Example for README.md
Add to "Input file formats":
### XML
sql-pipe supports row-based XML input. For nested XML (like RSS feeds), use --xml-root to navigate to the row container and --xml-row to filter specific elements:
curl -s "https://feeds.feedburner.com/TheHackersNews" | sql-pipe -I xml --xml-root channel --xml-row item "SELECT title FROM t LIMIT 5"
Problem
Currently there are no examples showing how to use XML input files in:
main.zig --help)docs/sql-pipe.1.scd)Users may not discover that sql-pipe supports XML input via
-I xmlor--input-format xml, especially for nested structures like RSS feeds that require--xml-rootand--xml-row.Proposed Solution
Add XML usage examples to all three documentation locations:
Example for main.zig (usage)
Add to the Examples section:
Example for README.md
Add to "Input file formats":