You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CREATE TABLE l3vpn_rib (
.....
isPrePolicy boolean NOT NULL DEFAULT true,
isAdjRibIn boolean NOT NULL DEFAULT true,
);
Dependent table (correct)
CREATE TABLE l3vpn_rib_log (
.....
isPrePolicy boolean NOT NULL DEFAULT true,
isAdjRibIn boolean NOT NULL DEFAULT true,
) TABLESPACE timeseries;
PostgreSQL function for the insertion into l3vpn_rib_log misses new.isPrePolicy and new.isAdjRibIn values!
CREATE OR REPLACE FUNCTION t_l3vpn_rib_update()
RETURNS trigger AS $$
BEGIN
IF (new.isWithdrawn) THEN
INSERT INTO l3vpn_rib_log (isWithdrawn,prefix,prefix_len,base_attr_hash_id,peer_hash_id,origin_as,timestamp,
rd,ext_community_list)
VALUES (true,new.prefix,new.prefix_len,old.base_attr_hash_id,new.peer_hash_id,
old.origin_as,new.timestamp,old.rd,old.ext_community_list);
ELSE
INSERT INTO l3vpn_rib_log (isWithdrawn,prefix,prefix_len,base_attr_hash_id,peer_hash_id,origin_as,timestamp,
rd,ext_community_list)
VALUES (false,new.prefix,new.prefix_len,new.base_attr_hash_id,new.peer_hash_id,
new.origin_as,new.timestamp,new.rd,new.ext_community_list);
END IF;
RETURN NEW;
END;
$$ LANGUAGE plpgsql;
The text was updated successfully, but these errors were encountered:
Base table in the file "10_l3vpn.sql"
Dependent table (correct)
PostgreSQL function for the insertion into l3vpn_rib_log misses new.isPrePolicy and new.isAdjRibIn values!
The text was updated successfully, but these errors were encountered: