ml
create view publicaciones_ml as
SELECT pgi.code codigo, l.status estado
FROM mercadobusiness.listings l
INNER JOIN mercadobusiness.product_groups pg ON pg.listing_id = l.id
INNER JOIN mercadobusiness.product_group_items pgi ON pgi.product_group_id = pg.id
WHERE l.status = "active"