]> git.openstreetmap.org Git - rails.git/commitdiff
Ooops, forgot to commit changes to db/structure.sql
authorMatt Amos <zerebubuth@gmail.com>
Mon, 21 Oct 2019 14:05:16 +0000 (15:05 +0100)
committerMatt Amos <zerebubuth@gmail.com>
Mon, 21 Oct 2019 14:05:16 +0000 (15:05 +0100)
db/structure.sql

index 03950502c52702b8ce005f0071c648dfaa5ee14c..6370eb95a0904a8b63b978b7d9abb1f5972822e6 100644 (file)
@@ -184,6 +184,30 @@ END;
 $$;
 
 
 $$;
 
 
+--
+-- Name: xid_to_int4(xid); Type: FUNCTION; Schema: public; Owner: -
+--
+
+CREATE FUNCTION public.xid_to_int4(t xid) RETURNS integer
+    LANGUAGE plpgsql STRICT
+    AS $$
+DECLARE
+  tl bigint;
+  ti int;
+BEGIN
+  tl := t;
+
+  IF tl >= 2147483648 THEN
+    tl := tl - 4294967296;
+  END IF;
+
+  ti := tl;
+
+  RETURN ti;
+END;
+$$;
+
+
 SET default_tablespace = '';
 
 SET default_with_oids = false;
 SET default_tablespace = '';
 
 SET default_with_oids = false;