Getting type from a CTE - Drizzle Team