
CREATE FUNCTION RA_in( cstring )
   RETURNS RA
   AS '/usr/local/pgsql/types/RA'
   LANGUAGE C;

CREATE FUNCTION RA_out( RA )
   RETURNS cstring
   AS '/usr/local/pgsql/types/RA'
   LANGUAGE C;

CREATE TYPE RA
   (
   INTERNALLENGTH = 8,
   INPUT = RA_in,
   OUTPUT = RA_out
   );

CREATE FUNCTION RA_add( RA, RA )
   RETURNS RA
   AS '/usr/local/pgsql/types/RA'
   LANGUAGE C;

CREATE OPERATOR +
   (
   LEFTARG = RA,
   RIGHTARG = RA,
   PROCEDURE = RA_add,
   COMMUTATOR = +
   );
