# `Sp_beforeSave_sCio` (procedure)

> 客户审核反写数量


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

## Parameters

| # | Mode | Name | Type |
|---|---|---|---|
| 1 | IN | `sGuid` | `varchar(2000)` |
| 2 | IN | `sBrId` | `varchar(100)` |
| 3 | IN | `sSuId` | `varchar(100)` |
| 4 | OUT | `sCode` | `int` |
| 5 | OUT | `sReturn` | `varchar(4000)` |

## Body

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

## Narrative

**Business context:** 客户审核反写数量 — before-save dispatcher intended for the customer-audit (客户审核) document family. Wraps `sGuid` and delegates to `Sp_saveReturn_sCio` to backwrite related counters before the master save commits.

**What it does:** Normalises `sGuid` to a quoted-CSV form, then `CALL Sp_saveReturn_sCio(sGuid, sBrId, sSuId, 1, @sCode, @sReturn)`. The downstream proc holds the actual writeback logic.

**Invocation:** Status: appears orphaned. No `gdsmodule` row references this proc as `sSaveProNameBefore`/`sSaveProName`/`sDeleteProName`/`sProcName`; the `客户信息` and `客户报备信息单据` modules hook `Sp_Calc_sCio` instead. No form-master sSqlStr, no other-routine caller, no xly-src reference — candidate for maintainer audit (likely superseded by the `Sp_Calc_sCio` path or never wired in).
