How to make a OpExpr check compatible among different versions

Поиск
Список
Период
Сортировка
От Andy Fan
Тема How to make a OpExpr check compatible among different versions
Дата
Msg-id CAKU4AWqrv8AZQFi7x2O2cME2ifDw18ZDRzuQnMgWwiXyJo_RfQ@mail.gmail.com
обсуждение исходный текст
Ответы Re: How to make a OpExpr check compatible among different versions
Список pgsql-hackers
During one of my works for logical rewrite,  I want to check if the expr is a given Expr. 

so the simplest way is:
if (expr->opno == 418 && nodeTag(linitial(expr->args)) == T_xxx  && nodeTag(lsecond(expr->args)) == T_yyyy )   
{
 .. 
}

if we write code like above,  we may have issues if the oid changed in the future version. 
so what would be your suggestion? 

Thanks

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Antonin Houska
Дата:
Сообщение: Comment fix in session.h
Следующее
От: Konstantin Knizhnik
Дата:
Сообщение: Re: [Proposal] Global temporary tables