Sql to XML export with XSL template formatting
Needs changesWhat this workflow does
This workflow has 11 nodes and runs when an HTTP GET request hits its webhook URL (plus 1 other trigger). Along the way it connects MySQL. It also calls gist.githubusercontent.com over HTTP.
How it runs
Trigger: When an HTTP GET request hits its webhook URL (plus 1 other trigger).
- Show 16 random products (MySQL): run a query
- Get XSLT (HTTP Request): calls gist.githubusercontent.com
- Define file structure (Edit Fields (Set)): sets or maps fields
- Respond to Webhook: sends the response back to the webhook caller
- Concatenate Items (Item Lists): reshapes item lists (legacy Item Lists node)
- Convert to XML (XML): converts between XML and JSON
- Create HTML (HTML): parses or builds HTML
- Move Binary Data (Convert to/from binary data): uses Convert to/from binary data
- Respond to Webhook: sends the response back to the webhook caller
Services it uses
HTTP calls to: gist.githubusercontent.com
Before you upgrade to n8n 3.0
2 things in this workflow are removed in n8n 3.0. Fix them before you upgrade:
- Item Lists (legacy) in Concatenate Items: replace with Split Out, Aggregate, Sort, Limit, Remove Duplicates or Summarize (match the operation used).
- Convert to/from binary data in Move Binary Data: replace with Convert to File or Extract from File.
Rather not rewrite it? Many of these flows can be rebuilt in Make (free plan).
| Removed in 3.0 | Replace with |
|---|---|
| Item Lists (legacy) Concatenate Items | Split Out, Aggregate, Sort, Limit, Remove Duplicates or Summarize (match the operation used) |
| Convert to/from binary data Move Binary Data | Convert to File or Extract from File |
Nodes used (9)
- Webhook
n8n-nodes-base.webhook - MySQL
n8n-nodes-base.mySql - Edit Fields (Set)
n8n-nodes-base.set - Item Lists
n8n-nodes-base.itemLists - XML
n8n-nodes-base.xml - HTML
n8n-nodes-base.html - Convert to/from binary data
n8n-nodes-base.moveBinaryData - Respond to Webhook
n8n-nodes-base.respondToWebhook - HTTP Request
n8n-nodes-base.httpRequest
From the author
This workflow demonstrates how to export SQL to XML and present the data nicely formatted using an XSL Template. The upper part of the workflow starts with a webhook. Then it gets several random records from the SQL table and converts them into an XML string.…