VbzCart/docs/queries/qryCtg Items active: Difference between revisions
Jump to navigation
Jump to search
imported>Woozle (moved from single-page listing) |
m (Woozle moved page VbzCart/VbzCart/queries/qryCtg Items active to VbzCart/docs/queries/qryCtg Items active without leaving a redirect: part 2) |
||
(One intermediate revision by one other user not shown) | |||
Line 2: | Line 2: | ||
* '''Purpose''': Brings up ''only'' [[../../tables/ctg_items|ctg_items]] records which are active, simplifying the final massive JOIN query a bit and hopefully avoiding any errors similar to the one mentioned above. | * '''Purpose''': Brings up ''only'' [[../../tables/ctg_items|ctg_items]] records which are active, simplifying the final massive JOIN query a bit and hopefully avoiding any errors similar to the one mentioned above. | ||
* '''Requires''': [[../../tables/ctg_items|ctg_items]] | * '''Requires''': [[../../tables/ctg_items|ctg_items]] | ||
* '''Used by''': | * '''Used by''': {{vbzcart/query|qryCtg_src_sub}} | ||
==SQL== | ==SQL== | ||
<section begin=sql /><mysql>CREATE OR REPLACE VIEW qryCtg_Items_active AS | <section begin=sql /><mysql>CREATE OR REPLACE VIEW qryCtg_Items_active AS |
Latest revision as of 01:55, 25 February 2024
Details
- Purpose: Brings up only ctg_items records which are active, simplifying the final massive JOIN query a bit and hopefully avoiding any errors similar to the one mentioned above.
- Requires: ctg_items
- Used by: Template:Vbzcart/query
SQL
<section begin=sql /><mysql>CREATE OR REPLACE VIEW qryCtg_Items_active AS
SELECT * FROM ctg_items AS tgi WHERE tgi.isActive AND (tgi.PriceSell IS NOT NULL) AND (tgi.ID_ShipCost IS NOT NULL);</mysql>
<section end=sql />