View: core.item_group_scrud_view
Schema | core |
Materialized View Name | item_group_scrud_view |
Owner | postgres |
Tablespace | DEFAULT |
Description | |
CREATE OR REPLACE VIEW core.item_group_scrud_view
AS
SELECT item_groups.item_group_id,
item_groups.item_group_code,
item_groups.item_group_name,
item_groups.exclude_from_purchase,
item_groups.exclude_from_sales,
((sales_taxes.sales_tax_code::text || ' ('::text) || sales_taxes.sales_tax_name::text) || ')'::text AS sales_tax,
((parent_item_group.item_group_code::text || ' ('::text) || parent_item_group.item_group_name::text) || ')'::text AS parent
FROM core.item_groups
JOIN core.sales_taxes ON item_groups.sales_tax_id = sales_taxes.sales_tax_id
LEFT JOIN core.item_groups parent_item_group ON item_groups.parent_item_group_id = parent_item_group.item_group_id;