RE: row filtering for logical replication
От | houzj.fnst@fujitsu.com |
---|---|
Тема | RE: row filtering for logical replication |
Дата | |
Msg-id | OS0PR01MB571696CA853B3655F7DE752994E29@OS0PR01MB5716.jpnprd01.prod.outlook.com обсуждение исходный текст |
Ответ на | Re: row filtering for logical replication ("Euler Taveira" <euler@eulerto.com>) |
Список | pgsql-hackers |
Hi, I am interested in this feature and took a quick a look at the patch. Here are a few comments. (1) + appendStringInfo(&cmd, "%s", q); We'd better use appendStringInfoString(&cmd, q); (2) + whereclause = transformWhereClause(pstate, + copyObject(pri->whereClause), + EXPR_KIND_PUBLICATION_WHERE, + "PUBLICATION"); + + /* Fix up collation information */ + assign_expr_collations(pstate, whereclause); Is it better to invoke eval_const_expressions or canonicalize_qual here to simplify the expression ? (3) + appendPQExpBuffer(&buf, + ", pg_get_expr(pr.prqual, c.oid)"); + else + appendPQExpBuffer(&buf, + ", NULL"); we'd better use appendPQExpBufferStr instead of appendPQExpBuffer here. (4) nodeTag(expr) == T_FuncCall) It might looks clearer to use IsA(expr, FuncCall) here. Best regards, Houzj
В списке pgsql-hackers по дате отправления: