mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-12-21 08:29:39 +08:00
Fix LLONG_MAX define used by new int64 FETCH/MOVE patch.
This commit is contained in:
parent
b0e5468448
commit
754c7d53a4
@ -8,7 +8,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $PostgreSQL: pgsql/src/backend/tcop/pquery.c,v 1.108 2006/09/02 18:17:17 momjian Exp $
|
* $PostgreSQL: pgsql/src/backend/tcop/pquery.c,v 1.109 2006/09/03 01:15:40 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -1347,7 +1347,7 @@ DoPortalRunFetch(Portal portal,
|
|||||||
* we are. In any case, we arrange to fetch the target row
|
* we are. In any case, we arrange to fetch the target row
|
||||||
* going forwards.
|
* going forwards.
|
||||||
*/
|
*/
|
||||||
if (portal->posOverflow || portal->portalPos == LLONG_MAX ||
|
if (portal->posOverflow || portal->portalPos == FETCH_ALL ||
|
||||||
count - 1 <= portal->portalPos / 2)
|
count - 1 <= portal->portalPos / 2)
|
||||||
{
|
{
|
||||||
DoPortalRewind(portal);
|
DoPortalRewind(portal);
|
||||||
|
@ -7,13 +7,15 @@
|
|||||||
* Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group
|
* Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group
|
||||||
* Portions Copyright (c) 1994, Regents of the University of California
|
* Portions Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $PostgreSQL: pgsql/src/include/nodes/parsenodes.h,v 1.327 2006/09/02 18:17:17 momjian Exp $
|
* $PostgreSQL: pgsql/src/include/nodes/parsenodes.h,v 1.328 2006/09/03 01:15:40 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
#ifndef PARSENODES_H
|
#ifndef PARSENODES_H
|
||||||
#define PARSENODES_H
|
#define PARSENODES_H
|
||||||
|
|
||||||
|
#include "limits.h"
|
||||||
|
|
||||||
#include "nodes/primnodes.h"
|
#include "nodes/primnodes.h"
|
||||||
#include "nodes/value.h"
|
#include "nodes/value.h"
|
||||||
|
|
||||||
@ -1439,7 +1441,12 @@ typedef enum FetchDirection
|
|||||||
FETCH_RELATIVE
|
FETCH_RELATIVE
|
||||||
} FetchDirection;
|
} FetchDirection;
|
||||||
|
|
||||||
|
#ifdef HAVE_INT64
|
||||||
#define FETCH_ALL LLONG_MAX
|
#define FETCH_ALL LLONG_MAX
|
||||||
|
#else
|
||||||
|
#define FETCH_ALL LONG_MAX
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
typedef struct FetchStmt
|
typedef struct FetchStmt
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user