# `Sp_bd_TmYield2` (procedure)

> 班组产量对比分析


- **Type:** PROCEDURE
- **Deterministic:** NO
- **SQL data access:** CONTAINS SQL

## Parameters

| # | Mode | Name | Type |
|---|---|---|---|
| 1 | IN | `sLoginId` | `varchar(100)` |
| 2 | IN | `sBrId` | `varchar(100)` |
| 3 | IN | `sSuId` | `varchar(100)` |
| 4 | IN | `bFilter` | `varchar(5000)` |
| 5 | OUT | `sCode` | `int` |
| 6 | OUT | `sReturn` | `longtext` |

## Body

_Body is not pre-cached. To inspect: `mysql --defaults-file=~/.my.cnf -e 'SHOW CREATE PROCEDURE `Sp_bd_TmYield2`'`._

## Narrative

**Business context:** 看板管理 / 班组产量对比分析 — second-group variant of [`Sp_bd_TmYield`](Sp_bd_TmYield.md) for `elemachine.iPlcNo` 15-26. Identical output aggregation, identical four-shift buckets, identical JSON output.

**What it does:** Same body as `Sp_bd_TmYield` with PLC filter `iPlcNo > 14 AND iPlcNo < 27`. Outputs each machine's raw output across 昨日白班 / 昨日晚班 / 今日白班 / 今日晚班.

**Invocation:** Installed by `xly-src/script/标版/30100101/Sp_bd_TmYield2.sql`. No form-master sSqlStr, no `gdsmodule` hook, no other-routine caller, no Java caller — reachable only via an external dashboard HTTP endpoint.
