-- 1. CTE BÁSICA — Ventas por región WITH ventas_por_region AS ( SELECT region, COUNT(*) as total_ventas, SUM(monto) as total_monto, AVG(monto) as promedio_monto FROM ventas GROUP BY region ) SELECT * ...
This repo is used to share all the scripts which is very helpful for interview - cupadhyaya/ms-sql-server-scripts ...