ALTER TABLE partner_cimtar
   ALTER COLUMN cim TYPE character varying(200);
ALTER TABLE partner
   ALTER COLUMN cim TYPE character varying(200);
ALTER TABLE partner_emailtar
   ALTER COLUMN email TYPE character varying(200);
   
ALTER TABLE tulajdonos ADD COLUMN jovedeki_engedely character varying(100);
ALTER TABLE partner ADD COLUMN jovedeki_engedely character varying(100);

ALTER TABLE tetel
   ADD CONSTRAINT tetel_ch1 CHECK (tetel_tipus = 0 OR tetel_tipus = 1 OR tetel_tipus = 2 OR tetel_tipus = 3 OR tetel_tipus = 4 OR tetel_tipus = 5 OR tetel_tipus = 6 OR tetel_tipus = 7 OR tetel_tipus = 8 OR tetel_tipus = 9 OR tetel_tipus = 10 OR tetel_tipus = 11 OR tetel_tipus = 12 OR tetel_tipus = 13);

INSERT INTO _scriptlog (script, statusz) 
  (SELECT 'update_7.77#3.sql' as script, 0 as statusz  WHERE 
     ((SELECT count(*) FROM _scriptlog WHERE (script = 'update_7.77#3.sql' )) = 0));