SQL schema and reporting queries for a sales analytics proof-of-concept. Uses a single sales table and standard SQL suitable for PostgreSQL, MySQL, or SQL Server (with minor syntax notes where needed) ...
-- Use 'orden' for the sorting path to keep the hierarchy together. -- Using 'level' here was causing the sort issue. , sys_connect_by_path(lpad(nvl(orden, 0), 5, '0 ...
Some results have been hidden because they may be inaccessible to you
Show inaccessible results