Fix function names and argument order in catalog guide

This commit is contained in:
Ryan Malloy 2026-02-18 10:28:26 -07:00
parent 89ea0246b6
commit eadbb45a3b

View File

@ -180,22 +180,29 @@ Once loaded, the full pg_orrery function set is available:
```sql ```sql
-- Where is every LEO satellite right now? -- 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 FROM satellites
WHERE tle_mean_motion(tle) > 11.25; WHERE tle_mean_motion(tle) > 11.25;
-- Which satellites are overhead right now? -- 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 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; ORDER BY el DESC;
-- Predict ISS passes for the next 24 hours -- 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, FROM satellites,
predict_passes(tle, '40.0N 105.3W 1655m'::observer, predict_passes(tle, '40.0N 105.3W 1655m'::observer,
now(), now() + interval '24 hours', 10.0) p now(), now() + interval '24 hours', 10.0) p
WHERE norad_id = 25544; WHERE tle_norad_id(tle) = 25544;
``` ```
## NORAD ID encoding ## NORAD ID encoding