BrickTracker/bricktracker/sql/minifigure/list/last.sql

18 lines
499 B
MySQL
Raw Normal View History

2025-01-27 18:39:35 +01:00
{% extends 'minifigure/base/base.sql' %}
2025-01-17 11:03:00 +01:00
{% block total_missing %}
SUM(IFNULL("missing"."quantity", 0)) AS "total_missing",
2025-01-17 11:03:00 +01:00
{% endblock %}
{% block join %}
LEFT JOIN "missing"
2025-01-27 18:39:35 +01:00
ON "rebrickable_minifigures"."figure" IS NOT DISTINCT FROM "missing"."set_num"
AND "bricktracker_minifigures"."bricktracker_set_id" IS NOT DISTINCT FROM "missing"."u_id"
2025-01-17 11:03:00 +01:00
{% endblock %}
{% block group %}
GROUP BY
2025-01-27 18:39:35 +01:00
"rebrickable_minifigures"."figure",
"bricktracker_minifigures"."bricktracker_set_id"
2025-01-17 11:03:00 +01:00
{% endblock %}