Formatting only change

master
Sandro Santilli 10 years ago
parent f5ad0d0434
commit ac53d6b000

@ -100,9 +100,9 @@ BEGIN
AND a.attname = 'cartodb_id' AND a.attname = 'cartodb_id'
INTO STRICT rec; INTO STRICT rec;
-- 20=int2, 21=int4, 23=int8 -- 20=int2, 21=int4, 23=int8
IF rec.oid NOT IN (20,21,23) THEN IF rec.oid NOT IN (20,21,23) THEN -- {
RAISE NOTICE 'Existing cartodb_id field is of invalid type % (need int2, int4 or int8), renaming', rec.typname; RAISE NOTICE 'Existing cartodb_id field is of invalid type % (need int2, int4 or int8), renaming', rec.typname;
ELSIF rec.seq IS NULL THEN ELSIF rec.seq IS NULL THEN -- }{
RAISE NOTICE 'Existing cartodb_id field does not have an associated sequence, renaming'; RAISE NOTICE 'Existing cartodb_id field does not have an associated sequence, renaming';
ELSE -- }{ ELSE -- }{
sql := 'ALTER TABLE ' || reloid::text || ' ALTER COLUMN cartodb_id SET NOT NULL'; sql := 'ALTER TABLE ' || reloid::text || ' ALTER COLUMN cartodb_id SET NOT NULL';
@ -191,7 +191,8 @@ BEGIN
END IF; END IF;
-- We need created_at and updated_at -- We need created_at and updated_at
FOR rec IN SELECT * FROM ( VALUES ('created_at'), ('updated_at') ) t(cname) LOOP --{ FOR rec IN SELECT * FROM ( VALUES ('created_at'), ('updated_at') ) t(cname)
LOOP --{
new_name := null; new_name := null;
<< column_setup >> << column_setup >>
LOOP --{ LOOP --{

Loading…
Cancel
Save