1
0
mirror of https://github.com/postgres/postgres.git synced 2025-10-18 04:29:09 +03:00

Add COLLATION FOR expression

reviewed by Jaime Casanova
This commit is contained in:
Peter Eisentraut
2012-03-02 21:12:16 +02:00
parent d41f510c80
commit 6688d2878e
9 changed files with 103 additions and 3 deletions

View File

@@ -10701,6 +10701,19 @@ func_expr: func_name '(' ')' over_clause
n->location = @1;
$$ = (Node *)n;
}
| COLLATION FOR '(' a_expr ')'
{
FuncCall *n = makeNode(FuncCall);
n->funcname = SystemFuncName("pg_collation_for");
n->args = list_make1($4);
n->agg_order = NIL;
n->agg_star = FALSE;
n->agg_distinct = FALSE;
n->func_variadic = FALSE;
n->over = NULL;
n->location = @1;
$$ = (Node *)n;
}
| CURRENT_DATE
{
/*
@@ -12152,7 +12165,6 @@ unreserved_keyword:
| CLASS
| CLOSE
| CLUSTER
| COLLATION
| COMMENT
| COMMENTS
| COMMIT
@@ -12491,6 +12503,7 @@ reserved_keyword:
| CAST
| CHECK
| COLLATE
| COLLATION
| COLUMN
| CONSTRAINT
| CREATE