name VARCHAR(255) NOT NULL,
namespace TExt NOT NULL REFERENCES wiki_namespaces(namespace) DEFAULT '',
textsearch tsvector NOT NULL DEFAULT to_tsvector(''),
+ time TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(),
UNIQUE(namespace,name)
);
WHERE NEW.wprev = wpr.wprev;
NEW.textsearch := rec.ts
|| setweight(to_tsvector(NEW.namespace || ':' || NEW.name), 'A');
+ NEW.time = NOW();
return NEW;
END;
$$ LANGUAGE plpgsql;