From c9b6b9a5ca082fe7c1b6f58d7713f785a9eb6a5c Mon Sep 17 00:00:00 2001 From: Martial Simon Date: Mon, 15 Sep 2025 01:08:27 +0200 Subject: add: graphs et rushs --- graphs/sql/socially_unfit/req01.sql | 2 ++ graphs/sql/socially_unfit/req02.sql | 2 ++ graphs/sql/socially_unfit/req03.sql | 3 +++ graphs/sql/socially_unfit/req04.sql | 6 ++++++ graphs/sql/socially_unfit/req05.sql | 5 +++++ 5 files changed, 18 insertions(+) create mode 100644 graphs/sql/socially_unfit/req01.sql create mode 100644 graphs/sql/socially_unfit/req02.sql create mode 100644 graphs/sql/socially_unfit/req03.sql create mode 100644 graphs/sql/socially_unfit/req04.sql create mode 100644 graphs/sql/socially_unfit/req05.sql (limited to 'graphs/sql/socially_unfit') diff --git a/graphs/sql/socially_unfit/req01.sql b/graphs/sql/socially_unfit/req01.sql new file mode 100644 index 0000000..cd0c60b --- /dev/null +++ b/graphs/sql/socially_unfit/req01.sql @@ -0,0 +1,2 @@ +SELECT * FROM public.people +LIMIT 100 diff --git a/graphs/sql/socially_unfit/req02.sql b/graphs/sql/socially_unfit/req02.sql new file mode 100644 index 0000000..2178826 --- /dev/null +++ b/graphs/sql/socially_unfit/req02.sql @@ -0,0 +1,2 @@ +SELECT id,first_name,last_name FROM public.people +LIMIT 100 OFFSET 42 diff --git a/graphs/sql/socially_unfit/req03.sql b/graphs/sql/socially_unfit/req03.sql new file mode 100644 index 0000000..4f1d62d --- /dev/null +++ b/graphs/sql/socially_unfit/req03.sql @@ -0,0 +1,3 @@ +SELECT DISTINCT first_name,last_name,death_date,social_credit_balance FROM public.people +WHERE death_date IS NOT NULL +ORDER BY death_date DESC,social_credit_balance DESC LIMIT 100 diff --git a/graphs/sql/socially_unfit/req04.sql b/graphs/sql/socially_unfit/req04.sql new file mode 100644 index 0000000..a11948a --- /dev/null +++ b/graphs/sql/socially_unfit/req04.sql @@ -0,0 +1,6 @@ +SELECT first_name,last_name,birth_date,job_id,social_credit_balance +FROM public.people +WHERE job_id IS NOT NULL +AND social_credit_balance > 0 +AND death_date IS NULL +ORDER BY social_credit_balance DESC,birth_date,job_id LIMIT 100 OFFSET 200 diff --git a/graphs/sql/socially_unfit/req05.sql b/graphs/sql/socially_unfit/req05.sql new file mode 100644 index 0000000..45029d8 --- /dev/null +++ b/graphs/sql/socially_unfit/req05.sql @@ -0,0 +1,5 @@ +SELECT id,person_id,credits_change,action_description +FROM public.social_credit_history +WHERE date >= '2059-12-03 17:00' AND date <= '2059-12-03 22:00' +ORDER BY credits_change,id +LIMIT 10 -- cgit v1.2.3