@@ -49,8 +49,6 @@ WHERE p1.typtype != 'c' AND
4949p1 .typreceive = 0 OR p1 .typsend = 0 );
5050
5151-- Check for bogus typinput routines
52- -- The first OR subclause detects bogus non-array cases,
53- -- the second one detects bogus array cases.
5452-- FIXME: ought to check prorettype, but there are special cases that make it
5553-- hard: prorettype might be binary-compatible with the type but not the same,
5654-- and for array types array_in's result has nothing to do with anything.
@@ -59,7 +57,7 @@ SELECT p1.oid, p1.typname, p2.oid, p2.proname
5957FROM pg_typeAS p1, pg_procAS p2
6058WHERE p1 .typinput = p2 .oid AND p1 .typtype = ' b' AND
6159 (p2 .pronargs != 1 OR p2 .proretset )AND
62- (p2 .pronargs != 3 OR p2 .proretset OR p1 . typelem = 0 );
60+ (p2 .pronargs != 3 OR p2 .proretset OR p2 . proargtypes [ 2 ] != 23 );
6361
6462-- Check for bogus typoutput routines
6563-- The first OR subclause detects bogus non-array cases,
@@ -73,8 +71,6 @@ WHERE p1.typoutput = p2.oid AND p1.typtype = 'b' AND
7371 (p2 .pronargs != 2 OR p2 .proretset OR p1 .typelem = 0 );
7472
7573-- Check for bogus typreceive routines
76- -- The first OR subclause detects bogus non-array cases,
77- -- the second one detects bogus array cases.
7874-- FIXME: ought to check prorettype, but there are special cases that make it
7975-- hard: prorettype might be binary-compatible with the type but not the same,
8076-- and for array types array_in's result has nothing to do with anything.
@@ -83,7 +79,7 @@ SELECT p1.oid, p1.typname, p2.oid, p2.proname
8379FROM pg_typeAS p1, pg_procAS p2
8480WHERE p1 .typreceive = p2 .oid AND p1 .typtype = ' b' AND
8581 (p2 .pronargs != 1 OR p2 .proretset )AND
86- (p2 .pronargs != 3 OR p2 .proretset OR p1 . typelem = 0 );
82+ (p2 .pronargs != 3 OR p2 .proretset OR p2 . proargtypes [ 2 ] != 23 );
8783
8884-- Check for bogus typsend routines
8985-- The first OR subclause detects bogus non-array cases,
@@ -102,7 +98,8 @@ WHERE p1.typsend = p2.oid AND p1.typtype = 'b' AND
10298
10399SELECT p1 .oid ,p1 .relname
104100FROM pg_classas p1
105- WHERE (p1 .relkind != ' r' AND p1 .relkind != ' i' AND p1 .relkind != ' s' );
101+ WHERE (p1 .relkind != ' r' AND p1 .relkind != ' i' AND
102+ p1 .relkind != ' s' AND p1 .relkind != ' S' );
106103
107104-- Indexes should have an access method, others not.
108105