# `viw_mftworkorderremainder` (view)


- **Updatable:** YES

## Columns

| # | Name | Type | Null |
|---|---|---|---|
| 1 | `sId` | `varchar(100)` | NO |
| 2 | `bCheck` | `bit(1)` | NO |
| 3 | `sStatus` | `varchar(255)` | YES |
| 4 | `iOrder` | `int` | NO |
| 5 | `sBrandsId` | `varchar(100)` | NO |
| 6 | `sSubsidiaryId` | `varchar(100)` | NO |
| 7 | `sSlaveId` | `varchar(100)` | NO |
| 8 | `sBillNo` | `varchar(255)` | NO |
| 9 | `sMakePerson` | `varchar(255)` | NO |
| 10 | `sCustomerId` | `varchar(100)` | NO |
| 11 | `sProductId` | `varchar(100)` | NO |
| 12 | `sPartsName` | `varchar(255)` | NO |
| 13 | `dSumMachineQty` | `decimal(18,6)` | NO |
| 14 | `dProductQty` | `decimal(18,6)` | NO |
| 15 | `dProductInStoreQty` | `decimal(18,6)` | NO |
| 16 | `tCreateDate` | `datetime` | NO |
| 17 | `tCheckDate` | `datetime` | YES |
| 18 | `dRemainderQty` | `decimal(19,6)` | NO |
| 19 | `sMemo` | `char(0)` | NO |
| 20 | `bBillComplete` | `bit(1)` | NO |

## Definition

```sql
select `mftworkordermaster`.`sId` AS `sId`,`mftworkordermaster`.`bCheck` AS `bCheck`,`mftworkordermaster`.`sStatus` AS `sStatus`,`mftworkordermaster`.`iOrder` AS `iOrder`,`mftworkordermaster`.`sBrandsId` AS `sBrandsId`,`mftworkordermaster`.`sSubsidiaryId` AS `sSubsidiaryId`,`mftworkordercontrol`.`sId` AS `sSlaveId`,`mftworkordermaster`.`sBillNo` AS `sBillNo`,`mftworkordermaster`.`sMakePerson` AS `sMakePerson`,`mftworkorderslave`.`sCustomerId` AS `sCustomerId`,`mftworkorderslave`.`sProductId` AS `sProductId`,`mftworkordercontrol`.`sPartsName` AS `sPartsName`,`mftworkordercontrol`.`dSumMachineQty` AS `dSumMachineQty`,`mftworkorderslave`.`dProductQty` AS `dProductQty`,`mftworkorderslave`.`dProductInStoreQty` AS `dProductInStoreQty`,`mftworkordermaster`.`tCreateDate` AS `tCreateDate`,`mftworkordermaster`.`tCheckDate` AS `tCheckDate`,(`mftworkorderslave`.`dProductInStoreQty` - `mftworkorderslave`.`dProductQty`) AS `dRemainderQty`,'' AS `sMemo`,`mftworkordermaster`.`bBillComplete` AS `bBillComplete` from (((`mftworkordermaster` join `mftworkorderslave` on((`mftworkordermaster`.`sId` = `mftworkorderslave`.`sParentId`))) join `mftworkordercontrolcombine` on((`mftworkorderslave`.`sId` = `mftworkordercontrolcombine`.`sSlaveId`))) join `mftworkordercontrol` on((`mftworkordercontrolcombine`.`sControlId` = `mftworkordercontrol`.`sId`))) where ((`mftworkordermaster`.`bCheck` = 1) and (`mftworkordermaster`.`bBillComplete` = 1) and (`mftworkordermaster`.`bBillOutside` = 0) and (`mftworkordermaster`.`sFormId` = '101251240115016002469445380'))
```

## Narrative

_No human-written narrative yet._
