write-script-mysql

Write and test MySQL scripts for Windmill with parameterized queries and S3 integration.

1|Updated Aug 3, 2026
One-click install
npx skills add https://github.com/vpzed-dev/smithy --skill write-script-mysql-vpzed-dev
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: write-script-mysql
Source: https://github.com/vpzed-dev/smithy/tree/main/windmill/local-dev/.agents/skills/write-script-mysql
Command: npx skills add https://github.com/vpzed-dev/smithy --skill write-script-mysql-vpzed-dev

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Writing MySQL scripts for the Windmill platform requires knowing its specific conventions for parameters, testing, and metadata synchronization. This Skill guides the AI to produce correctly formatted MySQL scripts and use the right wmill CLI commands for previewing, running, and deploying them without accidentally overwriting deployed versions. ## Core Features & Use Cases - Parameterized MySQL queries: Declares script arguments with ? placeholders and typed comment annotations (e.g. -- ? name (text)), including S3Object inputs consumed via JSON_TABLE. - Correct CLI workflow: Distinguishes wmill script preview (test local edits) from wmill script run (deployed version) and wmill sync push (deploy only on explicit request), preventing accidental deploys. - Metadata synchronization: Runs wmill generate-metadata after edits to keep .lock files, .script.yaml input schemas, and wmill-lock.yaml content hashes in sync. - S3 result streaming: Streams large query result sets directly to S3 in JSON, Parquet, or CSV format using the -- s3 directive. - Use Case: You need a Windmill script that queries a users table with filters. The Skill produces the annotated SQL, previews it locally with sample arguments, and regenerates metadata so the script is ready to deploy. ## Quick Start Write a Windmill MySQL script that selects users by name and minimum age, then preview it locally with sample arguments.

Frequently Asked Questions about write-script-mysql

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write a parameterized MySQL script in Windmill?▼

Declare parameters with ? placeholders in the SQL and name them using comment annotations before the statement, such as `-- ? name (text)` or `-- ? age (int) = 0`. Windmill uses these comments to build the script's input schema and arguments UI.

What is the difference between wmill script preview and script run?▼

`wmill script preview` executes your local script file without deploying, making it the default for iterating on edits. `wmill script run` executes the version already deployed in the workspace, so use it only when you explicitly want to test the deployed version.

How do I pass an S3 file as a parameter to a Windmill MySQL script?▼

Declare the argument with type `(s3object)` in the comment annotation. Windmill renders an S3 file picker, downloads the file, and binds it as JSON text, which you consume in the query using MySQL's JSON_TABLE function.

How do I stream large MySQL query results to S3 in Windmill?▼

Add a `-- s3` directive at the top of the script with optional keys for prefix, storage, and format (json, parquet, or csv). Windmill streams the result set directly to S3 and returns an S3Object instead of buffering rows as the script result.

Why does wmill-lock.yaml show diffs after editing a script?▼

Editing a script's content, imports, or main arguments invalidates its content hash, leaving the lock file and input schema stale. Run `wmill generate-metadata` to regenerate locks and refresh hashes, or use `generate-metadata rehash` if only hash entries need updating.