]> granicus.if.org Git - postgresql/commitdiff
Reduce json <=> jsonb casts from explicit-only to assignment level.
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 3 Mar 2015 16:26:04 +0000 (11:26 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 3 Mar 2015 16:26:04 +0000 (11:26 -0500)
There's no reason to make users write an explicit cast to store a
json value in a jsonb column or vice versa.

We could probably even make these implicit, but that might open us up
to problems with ambiguous function calls, so for now just do this.

src/include/catalog/catversion.h
src/include/catalog/pg_cast.h

index 508741fd443524cbeb6bc34b32c765a509d57a42..f416094380ca304aff6d3afb8eb62754761680ec 100644 (file)
@@ -53,6 +53,6 @@
  */
 
 /*                                                     yyyymmddN */
-#define CATALOG_VERSION_NO     201503011
+#define CATALOG_VERSION_NO     201503031
 
 #endif
index b3143694ab39fb1bef8a0ce4c2616989c0384f9d..c49fe263bbfe6c644994d9cf46d27302a7767961 100644 (file)
@@ -360,7 +360,7 @@ DATA(insert ( 1562 1562 1687 i f ));
 DATA(insert ( 1700 1700 1703 i f ));
 
 /* json to/from jsonb */
-DATA(insert ( 114 3802 0 e i ));
-DATA(insert ( 3802 114 0 e i ));
+DATA(insert (  114 3802    0 a i ));
+DATA(insert ( 3802  114    0 a i ));
 
 #endif   /* PG_CAST_H */