From eadbb45a3b57a6e769f077b85c4b8eef9e4b0d7e Mon Sep 17 00:00:00 2001 From: Ryan Malloy Date: Wed, 18 Feb 2026 10:28:26 -0700 Subject: [PATCH] Fix function names and argument order in catalog guide --- .../content/docs/guides/catalog-management.mdx | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/docs/src/content/docs/guides/catalog-management.mdx b/docs/src/content/docs/guides/catalog-management.mdx index 9968948..230a083 100644 --- a/docs/src/content/docs/guides/catalog-management.mdx +++ b/docs/src/content/docs/guides/catalog-management.mdx @@ -180,22 +180,29 @@ Once loaded, the full pg_orrery function set is available: ```sql -- Where is every LEO satellite right now? -SELECT name, observe('40.0N 105.3W 1655m'::observer, tle, now()) AS topo +SELECT name, observe(tle, '40.0N 105.3W 1655m'::observer, now()) AS topo FROM satellites WHERE tle_mean_motion(tle) > 11.25; -- Which satellites are overhead right now? -SELECT name, topo_elevation(observe('40.0N 105.3W 1655m'::observer, tle, now())) AS el +SELECT name, + round(topo_elevation( + observe_safe(tle, '40.0N 105.3W 1655m'::observer, now()) + )::numeric, 1) AS el FROM satellites -WHERE topo_elevation(observe('40.0N 105.3W 1655m'::observer, tle, now())) > 10 +WHERE topo_elevation( + observe_safe(tle, '40.0N 105.3W 1655m'::observer, now()) + ) > 10 ORDER BY el DESC; -- Predict ISS passes for the next 24 hours -SELECT pass_aos(p), pass_max_el(p), pass_los(p) +SELECT pass_aos_time(p)::timestamp(0) AS rise, + round(pass_max_elevation(p)::numeric, 1) AS max_el, + pass_los_time(p)::timestamp(0) AS set FROM satellites, predict_passes(tle, '40.0N 105.3W 1655m'::observer, now(), now() + interval '24 hours', 10.0) p -WHERE norad_id = 25544; +WHERE tle_norad_id(tle) = 25544; ``` ## NORAD ID encoding