# `viw_purpurchaseapply` (view)


- **Updatable:** NO

## Columns

| # | Name | Type | Null |
|---|---|---|---|
| 1 | `sId` | `varchar(100)` | NO |
| 2 | `sBrandsId` | `varchar(100)` | NO |
| 3 | `sSubsidiaryId` | `varchar(100)` | NO |
| 4 | `tCreateDate` | `datetime` | NO |
| 5 | `sMakePerson` | `varchar(255)` | NO |
| 6 | `iOrder` | `int` | NO |
| 7 | `sFormId` | `varchar(100)` | NO |
| 8 | `sBillNo` | `varchar(255)` | NO |
| 9 | `sEmployeeId` | `varchar(100)` | NO |
| 10 | `tApplyDate` | `datetime` | YES |
| 11 | `sManualNo` | `varchar(255)` | YES |
| 12 | `sMemo` | `text` | YES |
| 13 | `bCheck` | `bit(1)` | NO |
| 14 | `tCheckDate` | `datetime` | YES |
| 15 | `sCheckPerson` | `varchar(255)` | YES |
| 16 | `bPrint` | `bit(1)` | NO |
| 17 | `bCopyLimit` | `bit(1)` | NO |
| 18 | `dAdvanceMoney` | `decimal(18,6)` | YES |
| 19 | `tAdvanceDate` | `datetime` | YES |
| 20 | `dRealAdvanceMoney` | `decimal(18,6)` | YES |
| 21 | `sCurrency` | `varchar(255)` | YES |
| 22 | `dCurrencyRate` | `decimal(18,6)` | YES |
| 23 | `sStatus` | `varchar(255)` | YES |
| 24 | `bInvalid` | `bit(1)` | NO |
| 25 | `sMReserve1` | `varchar(255)` | YES |
| 26 | `sMReserve2` | `varchar(255)` | YES |
| 27 | `sMReserve3` | `varchar(255)` | YES |
| 28 | `sMReserve4` | `varchar(255)` | YES |
| 29 | `sMReserve5` | `varchar(255)` | YES |
| 30 | `sMReserve6` | `varchar(255)` | YES |
| 31 | `dMReserve1` | `decimal(18,6)` | YES |
| 32 | `dMReserve2` | `decimal(18,6)` | YES |
| 33 | `dMReserve3` | `decimal(18,6)` | YES |
| 34 | `iMReserve1` | `int` | YES |
| 35 | `iMReserve2` | `int` | YES |
| 36 | `iMReserve3` | `int` | YES |
| 37 | `tMReserve1` | `datetime` | YES |
| 38 | `tMReserve2` | `datetime` | YES |
| 39 | `sSlaveId` | `varchar(100)` | NO |
| 40 | `iSlaveOrder` | `int` | NO |
| 41 | `sMaterialsId` | `varchar(100)` | NO |
| 42 | `sMaterialsStyle` | `varchar(255)` | NO |
| 43 | `dAuxiliaryQty` | `decimal(18,6)` | NO |
| 44 | `sAuxiliaryUnit` | `varchar(255)` | NO |
| 45 | `dMaterialsQty` | `decimal(18,6)` | NO |
| 46 | `dConversionQty` | `decimal(18,6)` | NO |
| 47 | `dMaterialsPrice` | `decimal(18,6)` | NO |
| 48 | `dMaterialsMoney` | `decimal(18,6)` | NO |
| 49 | `sSrcSlaveId` | `varchar(100)` | NO |
| 50 | `sSrcId` | `varchar(100)` | NO |
| 51 | `sSrcNo` | `varchar(255)` | NO |
| 52 | `dSrcQty` | `decimal(18,6)` | YES |
| 53 | `sSlaveMemo` | `text` | YES |
| 54 | `dMaterialsNoTaxPrice` | `decimal(18,6)` | YES |
| 55 | `dMaterialsNoTaxMoney` | `decimal(18,6)` | YES |
| 56 | `dMaterialsTaxMoney` | `decimal(18,6)` | YES |
| 57 | `dMaterialsTaxForeignMoney` | `decimal(18,6)` | YES |
| 58 | `dMaterialsForeignMoney` | `decimal(18,6)` | YES |
| 59 | `dOrderAuxiliaryQty` | `decimal(18,6)` | NO |
| 60 | `dOrderQty` | `decimal(18,6)` | NO |
| 61 | `sOrderId` | `varchar(100)` | NO |
| 62 | `sOrderNo` | `varchar(255)` | NO |
| 63 | `sWorkOrderId` | `varchar(100)` | NO |
| 64 | `sWorkOrderNo` | `varchar(255)` | NO |
| 65 | `sWorkOrderControlId` | `varchar(100)` | NO |
| 66 | `sBarcode` | `varchar(255)` | YES |
| 67 | `sSReserve1` | `varchar(255)` | YES |
| 68 | `sSReserve2` | `varchar(255)` | YES |
| 69 | `sSReserve3` | `varchar(255)` | YES |
| 70 | `sSReserve4` | `varchar(255)` | YES |
| 71 | `sSReserve5` | `varchar(255)` | YES |
| 72 | `sSReserve6` | `varchar(255)` | YES |
| 73 | `dSReserve1` | `decimal(18,6)` | YES |
| 74 | `dSReserve2` | `decimal(18,6)` | YES |
| 75 | `dSReserve3` | `decimal(18,6)` | YES |
| 76 | `iSReserve1` | `int` | YES |
| 77 | `iSReserve2` | `int` | YES |
| 78 | `iSReserve3` | `int` | YES |
| 79 | `tSReserve1` | `datetime` | YES |
| 80 | `tSReserve2` | `datetime` | YES |
| 81 | `bOrderComplete` | `bit(1)` | NO |
| 82 | `iIncrement` | `int` | NO |
| 83 | `sSupplyId` | `varchar(50)` | YES |
| 84 | `sMaterialsType` | `varchar(50)` | YES |
| 85 | `sSupplyName` | `varchar(255)` | YES |
| 86 | `sCity` | `varchar(255)` | YES |
| 87 | `sArea` | `varchar(255)` | YES |
| 88 | `sCompanyAddress` | `varchar(255)` | YES |
| 89 | `sContacts` | `varchar(255)` | YES |
| 90 | `sMobile` | `varchar(255)` | YES |
| 91 | `sTaxId` | `varchar(100)` | YES |
| 92 | `sGetPayId` | `varchar(100)` | YES |
| 93 | `sPhone1` | `varchar(255)` | YES |
| 94 | `sPhone2` | `varchar(255)` | YES |
| 95 | `sEmail` | `varchar(255)` | YES |
| 96 | `sPurchaseManId` | `varchar(100)` | YES |
| 97 | `sRemainderType` | `varchar(255)` | YES |
| 98 | `dKGQty` | `decimal(18,6)` | YES |
| 99 | `bQly` | `bit(1)` | YES |
| 100 | `dQlyQty` | `int` | YES |
| 101 | `dMaterialsTestAuxiliaryQty` | `decimal(18,6)` | NO |
| 102 | `dMaterialsTestQty` | `decimal(18,6)` | NO |
| 103 | `bMaterialsTestComplete` | `bit(1)` | YES |
| 104 | `iTestResult` | `bit(1)` | YES |
| 105 | `bInStoreComplete` | `bit(1)` | YES |
| 106 | `bFast` | `bit(1)` | YES |
| 107 | `tFastDate` | `datetime` | YES |
| 108 | `sFastPerson` | `varchar(255)` | YES |
| 109 | `sCustomerId` | `varchar(255)` | YES |
| 110 | `iApplySort` | `int` | YES |
| 111 | `sApplySort` | `varchar(1)` | NO |

## Definition

```sql
select `purpurchaseapplymaster`.`sId` AS `sId`,`purpurchaseapplymaster`.`sBrandsId` AS `sBrandsId`,`purpurchaseapplymaster`.`sSubsidiaryId` AS `sSubsidiaryId`,`purpurchaseapplymaster`.`tCreateDate` AS `tCreateDate`,`purpurchaseapplymaster`.`sMakePerson` AS `sMakePerson`,`purpurchaseapplymaster`.`iOrder` AS `iOrder`,`purpurchaseapplymaster`.`sFormId` AS `sFormId`,`purpurchaseapplymaster`.`sBillNo` AS `sBillNo`,`purpurchaseapplymaster`.`sEmployeeId` AS `sEmployeeId`,`purpurchaseapplymaster`.`tApplyDate` AS `tApplyDate`,`purpurchaseapplymaster`.`sManualNo` AS `sManualNo`,`purpurchaseapplymaster`.`sMemo` AS `sMemo`,`purpurchaseapplymaster`.`bCheck` AS `bCheck`,`purpurchaseapplymaster`.`tCheckDate` AS `tCheckDate`,`purpurchaseapplymaster`.`sCheckPerson` AS `sCheckPerson`,`purpurchaseapplymaster`.`bPrint` AS `bPrint`,`purpurchaseapplymaster`.`bCopyLimit` AS `bCopyLimit`,`purpurchaseapplymaster`.`dAdvanceMoney` AS `dAdvanceMoney`,`purpurchaseapplymaster`.`tAdvanceDate` AS `tAdvanceDate`,`purpurchaseapplymaster`.`dRealAdvanceMoney` AS `dRealAdvanceMoney`,`purpurchaseapplymaster`.`sCurrency` AS `sCurrency`,`purpurchaseapplymaster`.`dCurrencyRate` AS `dCurrencyRate`,`purpurchaseapplymaster`.`sStatus` AS `sStatus`,`purpurchaseapplymaster`.`bInvalid` AS `bInvalid`,`purpurchaseapplymaster`.`sMReserve1` AS `sMReserve1`,`purpurchaseapplymaster`.`sMReserve2` AS `sMReserve2`,`purpurchaseapplymaster`.`sMReserve3` AS `sMReserve3`,`purpurchaseapplymaster`.`sMReserve4` AS `sMReserve4`,`purpurchaseapplymaster`.`sMReserve5` AS `sMReserve5`,`purpurchaseapplymaster`.`sMReserve6` AS `sMReserve6`,`purpurchaseapplymaster`.`dMReserve1` AS `dMReserve1`,`purpurchaseapplymaster`.`dMReserve2` AS `dMReserve2`,`purpurchaseapplymaster`.`dMReserve3` AS `dMReserve3`,`purpurchaseapplymaster`.`iMReserve1` AS `iMReserve1`,`purpurchaseapplymaster`.`iMReserve2` AS `iMReserve2`,`purpurchaseapplymaster`.`iMReserve3` AS `iMReserve3`,`purpurchaseapplymaster`.`tMReserve1` AS `tMReserve1`,`purpurchaseapplymaster`.`tMReserve2` AS `tMReserve2`,`purpurchaseapplyslave`.`sId` AS `sSlaveId`,`purpurchaseapplyslave`.`iOrder` AS `iSlaveOrder`,`purpurchaseapplyslave`.`sMaterialsId` AS `sMaterialsId`,`purpurchaseapplyslave`.`sMaterialsStyle` AS `sMaterialsStyle`,`purpurchaseapplyslave`.`dAuxiliaryQty` AS `dAuxiliaryQty`,`purpurchaseapplyslave`.`sAuxiliaryUnit` AS `sAuxiliaryUnit`,`purpurchaseapplyslave`.`dMaterialsQty` AS `dMaterialsQty`,`purpurchaseapplyslave`.`dConversionQty` AS `dConversionQty`,`purpurchaseapplyslave`.`dMaterialsPrice` AS `dMaterialsPrice`,`purpurchaseapplyslave`.`dMaterialsMoney` AS `dMaterialsMoney`,`purpurchaseapplyslave`.`sSrcSlaveId` AS `sSrcSlaveId`,`purpurchaseapplyslave`.`sSrcId` AS `sSrcId`,`purpurchaseapplyslave`.`sSrcNo` AS `sSrcNo`,`purpurchaseapplyslave`.`dSrcQty` AS `dSrcQty`,`purpurchaseapplyslave`.`sSlaveMemo` AS `sSlaveMemo`,`purpurchaseapplyslave`.`dMaterialsNoTaxPrice` AS `dMaterialsNoTaxPrice`,`purpurchaseapplyslave`.`dMaterialsNoTaxMoney` AS `dMaterialsNoTaxMoney`,`purpurchaseapplyslave`.`dMaterialsTaxMoney` AS `dMaterialsTaxMoney`,`purpurchaseapplyslave`.`dMaterialsTaxForeignMoney` AS `dMaterialsTaxForeignMoney`,`purpurchaseapplyslave`.`dMaterialsForeignMoney` AS `dMaterialsForeignMoney`,`purpurchaseapplyslave`.`dOrderAuxiliaryQty` AS `dOrderAuxiliaryQty`,`purpurchaseapplyslave`.`dOrderQty` AS `dOrderQty`,`purpurchaseapplyslave`.`sOrderId` AS `sOrderId`,`purpurchaseapplyslave`.`sOrderNo` AS `sOrderNo`,`purpurchaseapplyslave`.`sWorkOrderId` AS `sWorkOrderId`,`purpurchaseapplyslave`.`sWorkOrderNo` AS `sWorkOrderNo`,`purpurchaseapplyslave`.`sWorkOrderControlId` AS `sWorkOrderControlId`,`purpurchaseapplyslave`.`sBarcode` AS `sBarcode`,`purpurchaseapplyslave`.`sSReserve1` AS `sSReserve1`,`purpurchaseapplyslave`.`sSReserve2` AS `sSReserve2`,`purpurchaseapplyslave`.`sSReserve3` AS `sSReserve3`,`purpurchaseapplyslave`.`sSReserve4` AS `sSReserve4`,`purpurchaseapplyslave`.`sSReserve5` AS `sSReserve5`,`purpurchaseapplyslave`.`sSReserve6` AS `sSReserve6`,`purpurchaseapplyslave`.`dSReserve1` AS `dSReserve1`,`purpurchaseapplyslave`.`dSReserve2` AS `dSReserve2`,`purpurchaseapplyslave`.`dSReserve3` AS `dSReserve3`,`purpurchaseapplyslave`.`iSReserve1` AS `iSReserve1`,`purpurchaseapplyslave`.`iSReserve2` AS `iSReserve2`,`purpurchaseapplyslave`.`iSReserve3` AS `iSReserve3`,`purpurchaseapplyslave`.`tSReserve1` AS `tSReserve1`,`purpurchaseapplyslave`.`tSReserve2` AS `tSReserve2`,`purpurchaseapplyslave`.`bOrderComplete` AS `bOrderComplete`,`purpurchaseapplyslave`.`iIncrement` AS `iIncrement`,`elematerials`.`sSupplyId` AS `sSupplyId`,`elematerials`.`sMaterialsType` AS `sMaterialsType`,`elesupply`.`sSupplyName` AS `sSupplyName`,`elesupply`.`sCity` AS `sCity`,`elesupply`.`sArea` AS `sArea`,`elesupply`.`sCompanyAddress` AS `sCompanyAddress`,`elesupply`.`sContacts` AS `sContacts`,`elesupply`.`sMobile` AS `sMobile`,`elesupply`.`sTaxId` AS `sTaxId`,`elesupply`.`sGetPayId` AS `sGetPayId`,`elesupply`.`sPhone1` AS `sPhone1`,`elesupply`.`sPhone2` AS `sPhone2`,`elesupply`.`sEmail` AS `sEmail`,`elesupply`.`sPurchaseManId` AS `sPurchaseManId`,`purpurchaseapplyslave`.`sRemainderType` AS `sRemainderType`,`purpurchaseapplyslave`.`dKGQty` AS `dKGQty`,`purpurchaseapplyslave`.`bQly` AS `bQly`,`purpurchaseapplyslave`.`dQlyQty` AS `dQlyQty`,`purpurchaseapplyslave`.`dMaterialsTestAuxiliaryQty` AS `dMaterialsTestAuxiliaryQty`,`purpurchaseapplyslave`.`dMaterialsTestQty` AS `dMaterialsTestQty`,`purpurchaseapplyslave`.`bMaterialsTestComplete` AS `bMaterialsTestComplete`,`purpurchaseapplyslave`.`iTestResult` AS `iTestResult`,`purpurchaseapplyslave`.`bInStoreComplete` AS `bInStoreComplete`,`purpurchaseapplyslave`.`bFast` AS `bFast`,`purpurchaseapplyslave`.`tFastDate` AS `tFastDate`,`purpurchaseapplyslave`.`sFastPerson` AS `sFastPerson`,`purpurchaseapplyslave`.`sCustomerId` AS `sCustomerId`,`purpurchaseapplymaster`.`iApplySort` AS `iApplySort`,(case `purpurchaseapplymaster`.`iApplySort` when 1 then '是' else '否' end) AS `sApplySort` from (((`purpurchaseapplymaster` join `purpurchaseapplyslave` on((`purpurchaseapplyslave`.`sParentId` = `purpurchaseapplymaster`.`sId`))) left join `elematerials` on((`purpurchaseapplyslave`.`sMaterialsId` = `elematerials`.`sId`))) left join `elesupply` on((`elematerials`.`sSupplyId` = `elesupply`.`sId`)))
```

## Narrative

_No human-written narrative yet._
