# `viw_logisticsorderdetailsno` (view)


- **Updatable:** NO

## Columns

| # | Name | Type | Null |
|---|---|---|---|
| 1 | `iIncrement` | `int` | NO |
| 2 | `sId` | `varchar(100)` | NO |
| 3 | `sBrandsId` | `varchar(100)` | NO |
| 4 | `sSubsidiaryId` | `varchar(100)` | NO |
| 5 | `tCreateDate` | `datetime` | NO |
| 6 | `sMakePerson` | `varchar(255)` | NO |
| 7 | `iOrder` | `int` | NO |
| 8 | `sFormId` | `varchar(100)` | NO |
| 9 | `sBillNo` | `varchar(255)` | NO |
| 10 | `bCheck` | `bit(1)` | NO |
| 11 | `tCheckDate` | `datetime` | YES |
| 12 | `sMemo` | `mediumtext` | YES |
| 13 | `sCheckPerson` | `varchar(255)` | YES |
| 14 | `bPrint` | `bit(1)` | NO |
| 15 | `sStatus` | `varchar(255)` | YES |
| 16 | `bInvalid` | `bit(1)` | NO |
| 17 | `sSlaveId` | `varchar(100)` | NO |
| 18 | `sParentId` | `varchar(100)` | NO |
| 19 | `sSupplyId` | `varchar(100)` | NO |
| 20 | `sLogType` | `varchar(100)` | YES |
| 21 | `sSrcSlaveId` | `varchar(100)` | NO |
| 22 | `sSrcId` | `varchar(100)` | NO |
| 23 | `sSrcNo` | `varchar(255)` | NO |
| 24 | `sTaxId` | `varchar(100)` | YES |
| 25 | `dProductQty` | `decimal(18,6)` | YES |
| 26 | `dProductPrice` | `decimal(23,6)` | YES |
| 27 | `dProductMoney` | `decimal(23,6)` | YES |
| 28 | `dProductNoTaxPrice` | `decimal(30,2)` | YES |
| 29 | `dProductNoTaxMoney` | `decimal(30,2)` | YES |
| 30 | `dProductTaxMoney` | `decimal(42,2)` | YES |
| 31 | `dProductForeignMoney` | `decimal(23,6)` | YES |
| 32 | `dProductTaxForeignMoney` | `decimal(30,2)` | YES |
| 33 | `dNProductPrice` | `decimal(30,2)` | YES |
| 34 | `dNProductMoney` | `decimal(23,6)` | YES |
| 35 | `dProductForeignPrice` | `decimal(23,6)` | YES |
| 36 | `bCheckingComplete` | `bit(1)` | YES |
| 37 | `dCheckingProductMoney` | `decimal(22,6)` | YES |
| 38 | `sGetPayId` | `varchar(100)` | YES |
| 39 | `tGetPayDate` | `datetime` | YES |
| 40 | `sSlaveMemo` | `mediumtext` | YES |
| 41 | `dSrcProductMoney` | `decimal(18,6)` | YES |
| 42 | `sCarNo` | `varchar(255)` | YES |
| 43 | `sTon` | `varchar(255)` | YES |
| 44 | `sCity` | `varchar(255)` | YES |
| 45 | `iLogType` | `bigint` | YES |
| 46 | `tDispatchDate` | `datetime` | YES |

## Definition

```sql
select `logisticsordermaster`.`iIncrement` AS `iIncrement`,`logisticsordermaster`.`sId` AS `sId`,`logisticsordermaster`.`sBrandsId` AS `sBrandsId`,`logisticsordermaster`.`sSubsidiaryId` AS `sSubsidiaryId`,`logisticsordermaster`.`tCreateDate` AS `tCreateDate`,`logisticsordermaster`.`sMakePerson` AS `sMakePerson`,`logisticsordermaster`.`iOrder` AS `iOrder`,`logisticsordermaster`.`sFormId` AS `sFormId`,`logisticsordermaster`.`sBillNo` AS `sBillNo`,`logisticsordermaster`.`bCheck` AS `bCheck`,`logisticsordermaster`.`tCheckDate` AS `tCheckDate`,`logisticsordermaster`.`sMemo` AS `sMemo`,`logisticsordermaster`.`sCheckPerson` AS `sCheckPerson`,`logisticsordermaster`.`bPrint` AS `bPrint`,`logisticsordermaster`.`sStatus` AS `sStatus`,`logisticsordermaster`.`bInvalid` AS `bInvalid`,`logisticsorderdetails`.`sId` AS `sSlaveId`,`logisticsorderdetails`.`sParentId` AS `sParentId`,`logisticsorderdetails`.`sSupplyId` AS `sSupplyId`,`logisticsorderdetails`.`sLogType` AS `sLogType`,`logisticsorderdetails`.`sSrcSlaveId` AS `sSrcSlaveId`,`logisticsorderdetails`.`sSrcId` AS `sSrcId`,`logisticsorderdetails`.`sSrcNo` AS `sSrcNo`,`logisticsorderdetails`.`sTaxId` AS `sTaxId`,`logisticsorderdetails`.`dProductQty` AS `dProductQty`,(`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) AS `dProductPrice`,(`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) AS `dProductMoney`,round(((`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))),2) AS `dProductNoTaxPrice`,round(((`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))),2) AS `dProductNoTaxMoney`,round((((`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))) * (`sistax`.`dRate` / 100)),2) AS `dProductTaxMoney`,(`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) AS `dProductForeignMoney`,round(((`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))),2) AS `dProductTaxForeignMoney`,round(((`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))),2) AS `dNProductPrice`,(`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) AS `dNProductMoney`,(`logisticsorderdetails`.`dProductMoney` - `logisticsorderdetails`.`dCheckingProductMoney`) AS `dProductForeignPrice`,`logisticsorderdetails`.`bCheckingComplete` AS `bCheckingComplete`,`logisticsorderdetails`.`dCheckingProductMoney` AS `dCheckingProductMoney`,`logisticsorderdetails`.`sGetPayId` AS `sGetPayId`,`logisticsorderdetails`.`tGetPayDate` AS `tGetPayDate`,`logisticsorderdetails`.`sSlaveMemo` AS `sSlaveMemo`,`logisticsorderdetails`.`dProductMoney` AS `dSrcProductMoney`,`logisticsorderdetails`.`sCarNo` AS `sCarNo`,`logisticsorderdetails`.`sTon` AS `sTon`,`logisticsorderdetails`.`sCity` AS `sCity`,`logisticsordermaster`.`iLogType` AS `iLogType`,`logisticsordermaster`.`tDispatchDate` AS `tDispatchDate` from (((`logisticsordermaster` join `logisticsorderdetails` on((`logisticsordermaster`.`sId` = `logisticsorderdetails`.`sParentId`))) join `elesupply` on((`elesupply`.`sId` = `logisticsorderdetails`.`sSupplyId`))) join `sistax` on((`sistax`.`sId` = `logisticsorderdetails`.`sTaxId`))) where (`logisticsorderdetails`.`dProductMoney` > 0) union select `opsoutsideinstorededmaster`.`iIncrement` AS `iIncrement`,`opsoutsideinstorededmaster`.`sId` AS `sId`,`opsoutsideinstorededmaster`.`sBrandsId` AS `sBrandsId`,`opsoutsideinstorededmaster`.`sSubsidiaryId` AS `sSubsidiaryId`,`opsoutsideinstorededmaster`.`tCreateDate` AS `tCreateDate`,`opsoutsideinstorededmaster`.`sMakePerson` AS `sMakePerson`,`opsoutsideinstorededmaster`.`iOrder` AS `iOrder`,`opsoutsideinstorededmaster`.`sFormId` AS `sFormId`,`opsoutsideinstorededmaster`.`sBillNo` AS `sBillNo`,`opsoutsideinstorededmaster`.`bCheck` AS `bCheck`,`opsoutsideinstorededmaster`.`tCheckDate` AS `tCheckDate`,`opsoutsideinstorededmaster`.`sMemo` AS `sMemo`,`opsoutsideinstorededmaster`.`sCheckPerson` AS `sCheckPerson`,`opsoutsideinstorededmaster`.`bPrint` AS `bPrint`,`opsoutsideinstorededmaster`.`sStatus` AS `sStatus`,`opsoutsideinstorededmaster`.`bInvalid` AS `bInvalid`,`opsoutsideinstorededslave`.`sId` AS `sSlaveId`,`opsoutsideinstorededslave`.`sParentId` AS `sParentId`,`opsoutsideinstorededmaster`.`sSupplyId` AS `sSupplyId`,2 AS `sLogType`,`opsoutsideinstorededslave`.`sSrcSlaveId` AS `sSrcSlaveId`,`opsoutsideinstorededslave`.`sSrcId` AS `sSrcId`,`opsoutsideinstorededslave`.`sSrcNo` AS `sSrcNo`,`opsoutsideinstorededslave`.`sTaxId` AS `sTaxId`,`opsoutsideinstorededslave`.`dAuxiliaryQty` AS `dProductQty`,(`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) AS `dProductPrice`,(`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) AS `dProductMoney`,round(((`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))),2) AS `dProductNoTaxPrice`,round(((`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))),2) AS `dProductNoTaxMoney`,round((((`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))) * (`sistax`.`dRate` / 100)),2) AS `dProductTaxMoney`,(`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) AS `dProductForeignMoney`,round(((`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))),2) AS `dProductTaxForeignMoney`,round(((`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) / (1 + (`sistax`.`dRate` / 100))),2) AS `dNProductPrice`,(`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) AS `dNProductMoney`,(`opsoutsideinstorededslave`.`dMaterialsMoney` - `opsoutsideinstorededslave`.`dCheckingProductMoney`) AS `dProductForeignPrice`,`opsoutsideinstorededslave`.`bCheckingComplete` AS `bCheckingComplete`,`opsoutsideinstorededslave`.`dCheckingProductMoney` AS `dCheckingProductMoney`,`opsoutsideinstorededmaster`.`sGetPayId` AS `sGetPayId`,(now() + interval `sispayment`.`iAfterDeliverDay` day) AS `tGetPayDate`,`opsoutsideinstorededslave`.`sSlaveMemo` AS `sSlaveMemo`,`opsoutsideinstorededslave`.`dMaterialsMoney` AS `dSrcProductMoney`,'' AS `sCarNo`,'' AS `sTon`,'' AS `sCity`,2 AS `iLogType`,NULL AS `tDispatchDate` from ((((`opsoutsideinstorededmaster` join `opsoutsideinstorededslave` on((`opsoutsideinstorededslave`.`sParentId` = `opsoutsideinstorededmaster`.`sId`))) join `elesupply` on((`elesupply`.`sId` = `opsoutsideinstorededmaster`.`sSupplyId`))) join `sistax` on((`sistax`.`sId` = `opsoutsideinstorededslave`.`sTaxId`))) join `sispayment` on((`opsoutsideinstorededmaster`.`sGetPayId` = `sispayment`.`sId`))) where (`elesupply`.`sSupplyType` = 'WLS')
```

## Narrative

_No human-written narrative yet._
