質問

Hi I'm developing simple audit trigger in postgres server. At the moment, I'm getting old value from name column such as below line.

v_old_data := ROW (OLD.name);

It works fine, but it store the value with parentheses. Such as '(john)'. Is there any way to storing/getting value from the table without parentheses?

役に立ちましたか?

解決

Simply:

v_old_data := OLD.name;

You want the value, don't wrap it into a row and convert the whole row to text - including the parentheses that belong to the text representation of a row.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top