@@ -514,29 +514,6 @@ is_tsql_binary_family_datatype(Oid oid)
514514 return false;
515515}
516516
517- // /* Returns true if the oid belongs to sql_variant datatype */
518- // static bool
519- // is_sql_variant_type(Oid oid)
520- // {
521- // HeapTuple tuple;
522- // bool result = false;
523-
524- // tuple = SearchSysCache1(TYPEOID, ObjectIdGetDatum(oid));
525- // if (HeapTupleIsValid(tuple))
526- // {
527- // Form_pg_type typtup = (Form_pg_type) GETSTRUCT(tuple);
528- // Oid type_nsoid = typtup->typnamespace;
529- // char *type_name = NameStr(typtup->typname);
530- // char *type_nsname = get_namespace_name(type_nsoid);
531-
532- // if (strcmp(type_nsname, "sys") == 0 && strcmp(type_name, "sql_variant") == 0)
533- // result = true;
534-
535- // ReleaseSysCache(tuple);
536- // }
537-
538- // return result;
539- // }
540517
541518static CoercionPathType
542519tsql_find_coercion_pathway (Oid sourceTypeId , Oid targetTypeId , CoercionContext ccontext , Oid * funcid )
@@ -3205,8 +3182,8 @@ select_common_type_setop(ParseState *pstate, List *exprs, Node **which_expr, con
32053182 * non-char types, and the other branch (e.g. bit) would cause an early
32063183 * return of InvalidOid before sql_variant is ever seen.
32073184 */
3208- if (is_case_expr )
3209- {
3185+ // if (is_case_expr)
3186+ // {
32103187 foreach (lc , exprs )
32113188 {
32123189 Node * expr = (Node * ) lfirst (lc );
@@ -3219,7 +3196,7 @@ select_common_type_setop(ParseState *pstate, List *exprs, Node **which_expr, con
32193196 return type ;
32203197 }
32213198 }
3222- }
3199+ // }
32233200
32243201 /* Find a common type based on precedence. NULLs are ignored, and make
32253202 * string literals varchars. If a type besides CHAR, NCHAR, VARCHAR,
0 commit comments