How does pg parse 'select '(1,2)''

2023-08-05 Thread jacktby jacktby
I’m trying to add new grammar for my application. So I’m do research on gram.y. I think it will make the '(1,2)' as " '(' a_expr ')' "; but I can’t find out something like " a_expr ',' a_expr “, can you give me the details?

Failed to parse new syntax

2023-08-05 Thread jacktby jacktby
/* * similarity_search_expr is used for our multi-mode * similarity_search, and we just use this for multi * cols search. */ similarity_search_expr: sub_search_expr '<' AexprConst { $$ = (Node *) makeSimpleA_Expr(AEXPR_OP, "<", $1, $3, @2); }

Re: Failed to parse new syntax

2023-08-05 Thread Jan Wieck
Are you aware that PostgreSQL has a built in '~' operator for regular expressions? Regards, Jan On 8/5/23 11:56, jacktby jacktby wrote: /* * similarity_search_expr is used for our multi-mode * similarity_search, and we just use this for multi * cols search. */ similarity_search