mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-16 11:26:59 +08:00
This adds the SQL standard feature that adds the SEARCH and CYCLE clauses to recursive queries to be able to do produce breadth- or depth-first search orders and detect cycles. These clauses can be rewritten into queries using existing syntax, and that is what this patch does in the rewriter. Reviewed-by: Vik Fearing <vik@postgresfriends.org> Reviewed-by: Pavel Stehule <pavel.stehule@gmail.com> Discussion: https://www.postgresql.org/message-id/flat/db80ceee-6f97-9b4a-8ee8-3ba0c58e5be2@2ndquadrant.com
22 lines
636 B
C
22 lines
636 B
C
/*-------------------------------------------------------------------------
|
|
*
|
|
* rewriteSearchCycle.h
|
|
* Support for rewriting SEARCH and CYCLE clauses.
|
|
*
|
|
*
|
|
* Portions Copyright (c) 1996-2020, PostgreSQL Global Development Group
|
|
* Portions Copyright (c) 1994, Regents of the University of California
|
|
*
|
|
* src/include/rewrite/rewriteSearchCycle.h
|
|
*
|
|
*-------------------------------------------------------------------------
|
|
*/
|
|
#ifndef REWRITESEARCHCYCLE_H
|
|
#define REWRITESEARCHCYCLE_H
|
|
|
|
#include "nodes/parsenodes.h"
|
|
|
|
extern CommonTableExpr *rewriteSearchAndCycle(CommonTableExpr *cte);
|
|
|
|
#endif /* REWRITESEARCHCYCLE_H */
|