dbatools is a PowerShell toolkit for automating SQL Server administration and moving SQL Server instances between environments. It is for database administrators who manage SQL Server systems and migrations.
Borrowing it
Nothing to install: this file belongs to dataplat/dbatools. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/dataplat/dbatools/development/.github/prompts/pipeline-output.mdgit clone --depth 1 https://github.com/dataplat/dbatoolsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/dataplat/dbatools/pipeline-output)<a href="https://agentmods.dev/commands/dataplat/dbatools/pipeline-output"><img src="https://agentmods.dev/badge/commands/dataplat/dbatools/pipeline-output/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/dataplat/dbatools/pipeline-output"><img src="https://agentmods.dev/badge/commands/dataplat/dbatools/pipeline-output.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.00818 |
| Opus 5.5 | $0.00000 | $0.00327 |
| Sonnet 5.5 | $0.00000 | $0.00164 |
| Haiku 4.5 | $0.00000 | $0.00082 |
Grade A, and why
pipeline-output scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 127 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Pipeline Output Patterns
CRITICAL RULE: NEVER collect objects in an ArrayList or array and output them at the end. Output objects to the pipeline immediately as they are created.
Why Immediate Output
- Memory Efficiency: Objects are released to the pipeline immediately, not held in memory
- User Experience: Users see results streaming in real-time, not waiting until the end
- Pipeline Compatibility: Enables proper pipeline chaining and early termination (Ctrl+C)
- Error Resilience: Partial results are available even if the command fails partway through
Correct Pattern - Output Immediately
foreach ($instance in $SqlInstance) {
$server = Connect-DbaInstance -SqlInstance $instance -SqlCredential $SqlCredential
foreach ($db in $server.Databases) {
# Output each object immediately to the pipeline
[PSCustomObject]@{
ComputerName = $server.ComputerName
InstanceName = $server.ServiceName
SqlInstance = $server.DomainInstanceName
Database = $db.Name
Size = $db.Size
}
}
}
Wrong Patterns - DO NOT USE
ArrayList Collection (OLD PATTERN)
# WRONG - This is an outdated anti-pattern
$results = New-Object System.Collections.ArrayList
foreach ($instance in $SqlInstance) {
$server = Connect-DbaInstance -SqlInstance $instance -SqlCredential $SqlCredential
foreach ($db in $server.Databases) {
$null = $results.Add([PSCustomObject]@{
ComputerName = $server.ComputerName
Database = $db.Name
})
}
}
# WRONG - Holding everything until the end
$results
Array Concatenation (Worst Performance)
# WRONG - Array concatenation is extremely slow
$results = @()
foreach ($db in $databases) {
$results += [PSCustomObject]@{
Name = $db.Name
}
}
$results
No -Detailed or -Simple Parameters
Do NOT create -Detailed or -Simple switch parameters that change the output object structure. This is an outdated pattern that creates confusion and breaks pipeline expectations.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 127 lines · 0 tokens per session scan A 2445d0785e84
pipeline-output is a command published in the GitHub repository dataplat/dbatools (2,858 stars, last pushed 4d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 818 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-10.
pipeline-output compared with commands from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| pipeline-outputdataplat/dbatools | Command | 2.9k | 4d ago | MIT | A | 0 | GitHub Copilot |
| rust-developerhmohamed01/claude-code-plugins | Command | 7 | 1mo ago | none | A | 22 | Claude Code |
| generate-typesHKTITAN/cursor-best-practices | Command | 7 | 8mo ago | MIT | A | 0 | Claude Code |
| auditofershap/go-best-practices | Command | 2 | 8mo ago | MIT | A | 12 | Claude Code |
| auditofershap/python-best-practices | Command | 1 | 8mo ago | MIT | A | 12 | Claude Code |
| triagejuan294/cc-rpi | Command | 5 | 3d ago | MIT | A | 0 | Claude Code |
| azure-graph-dotnet:deploy-azureTheLobbi/Claude-m | Command | 18 | 1mo ago | none | A | 57 | Claude Code |