updating table rows in postgres using subquery

前端 未结 6 1199
北荒
北荒 2020-11-27 08:42

Using postgres 8.4, My goal is to update existing table:

CREATE TABLE public.dummy
(
  address_id SERIAL,
  addr1 character(40),
  addr2 character(40),
  ci         


        
6条回答
  •  无人及你
    2020-11-27 09:45

    update json_source_tabcol as d
    set isnullable = a.is_Nullable
    from information_schema.columns as a 
    where a.table_name =d.table_name 
    and a.table_schema = d.table_schema 
    and a.column_name = d.column_name;
    

提交回复
热议问题