Difference between revisions of "VbzCart/queries/qryStkItms for sale"
Jump to navigation
Jump to search
(New page: ==Details== * '''Requires''': {{vbzcart/query|qryStk_lines_remaining_forSale}} * '''Used by''': {{vbzcart/query|qryStkItms_for_sale_wItem_data}} * '''History''': ** '''2008-11-17''' Create...) |
(obsolete) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
==Details== | ==Details== | ||
+ | * '''Obsolete''': use '''VCT_StkLines::SQL_forItems_inStock_forSale()''' instead | ||
* '''Requires''': {{vbzcart/query|qryStk_lines_remaining_forSale}} | * '''Requires''': {{vbzcart/query|qryStk_lines_remaining_forSale}} | ||
− | * '''Used by''': {{vbzcart/query|qryStkItms_for_sale_wItem_data}} | + | * '''Used by''': {{vbzcart/query|qryStkItms_for_sale_wItem_data}}, {{vbzcart/query|qryItems_needed_forStock}} |
* '''History''': | * '''History''': | ||
** '''2008-11-17''' Created for revised restocking process | ** '''2008-11-17''' Created for revised restocking process | ||
==SQL== | ==SQL== | ||
− | + | <mysql>CREATE OR REPLACE VIEW qryStkItms_for_sale AS | |
SELECT | SELECT | ||
ID_Item, | ID_Item, | ||
Line 13: | Line 14: | ||
FROM qryStk_lines_remaining_forSale AS qsl | FROM qryStk_lines_remaining_forSale AS qsl | ||
GROUP BY ID_Item;</mysql> | GROUP BY ID_Item;</mysql> | ||
− |
Latest revision as of 02:07, 31 December 2015
Details
- Obsolete: use VCT_StkLines::SQL_forItems_inStock_forSale() instead
- Requires:
- REDIRECT Template:l/vc/query
- Used by: qryStkItms_for_sale_wItem_data, qryItems_needed_forStock
- History:
- 2008-11-17 Created for revised restocking process
SQL
<mysql>CREATE OR REPLACE VIEW qryStkItms_for_sale AS SELECT
ID_Item, SUM(qsl.QtyForSale) AS QtyForSale, SUM(qsl.QtyForShip) AS QtyForShip, SUM(qsl.QtyExisting) AS QtyExisting
FROM qryStk_lines_remaining_forSale AS qsl GROUP BY ID_Item;</mysql>