/* Sanity checks */
if (array == (ArrayType *) NULL)
{
- /* elog(NOTICE, "array_iterator: array is null"); */
+ /* elog(WARNING, "array_iterator: array is null"); */
return (0);
}
dim = ARR_DIMS(array);
nitems = ArrayGetNItems(ndim, dim);
if (nitems == 0)
- {
- /* elog(NOTICE, "array_iterator: nitems = 0"); */
return (0);
- }
/* Lookup element type information */
get_typlenbyval(elemtype, &typlen, &typbyval);
/*
* Integer array aggregator / enumerator
*
- * Mark L. Woodward
+ * Mark L. Woodward
* DMN Digital Music Network.
* www.dmn.com
*
PG_FUNCTION_INFO_V1(int_agg_final_array);
PG_FUNCTION_INFO_V1(int_enum);
-/*
- * Manage the aggregation state of the array
- * You need to specify the correct memory context, or it will vanish!
+/*
+ * Manage the aggregation state of the array
+ * You need to specify the correct memory context, or it will vanish!
*/
static PGARRAY * GetPGArray(int4 state, int fAdd)
{
return p;
}
-/* Shrinks the array to its actual size and moves it into the standard
+/* Shrinks the array to its actual size and moves it into the standard
* memory allocation context, frees working memory */
static PGARRAY *ShrinkPGArray(PGARRAY *p)
{
elog(ERROR, "Integer aggregator, can't allocate memory");
}
pfree(p);
- }
+ }
return pnew;
}
if(!p)
{
- elog(NOTICE, "No data sent\n");
+ elog(WARNING, "No data sent\n");
return 0;
}
if(!rsi)
{
elog(ERROR, "No ReturnSetInfo sent! function must be declared returning a 'setof' integer");
PG_RETURN_NULL();
-
+
}
if(!fcinfo->context)
{
/* dimension of array */
#define NDIM 1
-/*
- * flags for gist__int_ops, use ArrayType->flags
+/*
+ * flags for gist__int_ops, use ArrayType->flags
* which is unused (see array.h)
*/
#define LEAFKEY (1<<31)
sprintf(cur, "%d ", d[l]);
cur = strchr(cur, '\0');
}
- elog(NOTICE, "\t\t%s", bbb);
+ elog(DEBUG3, "\t\t%s", bbb);
}
static void
printbitvec(BITVEC bv)
str[SIGLENBIT] = '\0';
LOOPBIT(str[i] = (GETBIT(bv, i)) ? '1' : '0');
- elog(NOTICE, "BV: %s", str);
+ elog(DEBUG3, "BV: %s", str);
}
#endif
/*****************************************************************************
- * Boolean Search
+ * Boolean Search
*****************************************************************************/
#define BooleanSearchStrategy 20
PG_FUNCTION_INFO_V1(bqarr_in);
PG_FUNCTION_INFO_V1(bqarr_out);
-Datum bqarr_in(PG_FUNCTION_ARGS);
+Datum bqarr_in(PG_FUNCTION_ARGS);
Datum bqarr_out(PG_FUNCTION_ARGS);
-
+
PG_FUNCTION_INFO_V1(boolop);
-Datum boolop(PG_FUNCTION_ARGS);
+Datum boolop(PG_FUNCTION_ARGS);
PG_FUNCTION_INFO_V1(rboolop);
-Datum rboolop(PG_FUNCTION_ARGS);
+Datum rboolop(PG_FUNCTION_ARGS);
PG_FUNCTION_INFO_V1(querytree);
-Datum querytree(PG_FUNCTION_ARGS);
+Datum querytree(PG_FUNCTION_ARGS);
static bool signconsistent( QUERYTYPE *query, BITVEC sign, bool leaf );
static bool execconsistent( QUERYTYPE *query, ArrayType *array, bool leaf );
bool retval;
if ( strategy == BooleanSearchStrategy )
- PG_RETURN_BOOL(execconsistent( (QUERYTYPE*)query,
+ PG_RETURN_BOOL(execconsistent( (QUERYTYPE*)query,
(ArrayType *) DatumGetPointer(entry->key),
ISLEAFKEY( (ArrayType *) DatumGetPointer(entry->key) ) ) );
-
+
/* XXX are we sure it's safe to scribble on the query object here? */
/* XXX what about toasted input? */
/* sort query for fast search, key is already sorted */
query);
break;
case RTContainedByStrategyNumber:
- if ( GIST_LEAF(entry) )
+ if ( GIST_LEAF(entry) )
retval = inner_int_contains(query,
(ArrayType *) DatumGetPointer(entry->key) );
- else
+ else
retval = inner_int_overlap((ArrayType *) DatumGetPointer(entry->key),
query);
break;
g_int_union(PG_FUNCTION_ARGS)
{
PG_RETURN_POINTER( _int_common_union(
- (bytea *) PG_GETARG_POINTER(0),
- (int *) PG_GETARG_POINTER(1),
- inner_int_union
+ (bytea *) PG_GETARG_POINTER(0),
+ (int *) PG_GETARG_POINTER(1),
+ inner_int_union
) );
}
if ( r != (ArrayType*)DatumGetPointer(entry->key) )
pfree(r);
PG_RETURN_POINTER(entry);
- }
+ }
if ( (len=ARRNELEMS(r)) >= 2 * MAXNUMRANGE) { /* compress */
- if ( r == (ArrayType*)DatumGetPointer( entry->key) )
+ if ( r == (ArrayType*)DatumGetPointer( entry->key) )
r = (ArrayType *) PG_DETOAST_DATUM_COPY(entry->key);
r = resize_intArrayType(r, 2 * (len));
if (lenin < 2 * MAXNUMRANGE || ISLEAFKEY( in ) ) { /* not comressed value */
if ( in != (ArrayType *) DatumGetPointer(entry->key)) {
retval = palloc(sizeof(GISTENTRY));
- gistentryinit(*retval, PointerGetDatum(in),
+ gistentryinit(*retval, PointerGetDatum(in),
entry->rel, entry->page, entry->offset, VARSIZE(in), FALSE);
PG_RETURN_POINTER(retval);
- }
+ }
PG_RETURN_POINTER(entry);
}
if (in != (ArrayType *) DatumGetPointer(entry->key))
pfree(in);
retval = palloc(sizeof(GISTENTRY));
- gistentryinit(*retval, PointerGetDatum(r),
+ gistentryinit(*retval, PointerGetDatum(r),
entry->rel, entry->page, entry->offset, VARSIZE(r), FALSE);
PG_RETURN_POINTER(retval);
Datum
g_int_penalty(PG_FUNCTION_ARGS)
{
- PG_RETURN_POINTER( _int_common_penalty(
- (GISTENTRY *)PG_GETARG_POINTER(0),
- (GISTENTRY *)PG_GETARG_POINTER(1),
- (float *) PG_GETARG_POINTER(2),
+ PG_RETURN_POINTER( _int_common_penalty(
+ (GISTENTRY *)PG_GETARG_POINTER(0),
+ (GISTENTRY *)PG_GETARG_POINTER(1),
+ (float *) PG_GETARG_POINTER(2),
inner_int_union, rt__int_size
) );
}
g_int_picksplit(PG_FUNCTION_ARGS)
{
PG_RETURN_POINTER( _int_common_picksplit(
- (bytea *)PG_GETARG_POINTER(0),
+ (bytea *)PG_GETARG_POINTER(0),
(GIST_SPLITVEC *)PG_GETARG_POINTER(1),
inner_int_union,
inner_int_inter,
rt__int_size,
- 0.01
+ 0.01
) );
}
PG_RETURN_POINTER(result);
}
-Datum
+Datum
_int_contained(PG_FUNCTION_ARGS)
{
- PG_RETURN_BOOL( DatumGetBool(
- DirectFunctionCall2(
- _int_contains,
- PointerGetDatum(PG_GETARG_POINTER(1)),
- PointerGetDatum(PG_GETARG_POINTER(0))
+ PG_RETURN_BOOL( DatumGetBool(
+ DirectFunctionCall2(
+ _int_contains,
+ PointerGetDatum(PG_GETARG_POINTER(1)),
+ PointerGetDatum(PG_GETARG_POINTER(0))
)
));
}
db = ARRPTR(b);
#ifdef GIST_DEBUG
- elog(NOTICE, "contains %d %d", na, nb);
+ elog(DEBUG3, "contains %d %d", na, nb);
#endif
i = j = n = 0;
* Operator class for R-tree indexing
*****************************************************************************/
-Datum
+Datum
_int_different(PG_FUNCTION_ARGS)
{
- PG_RETURN_BOOL( ! DatumGetBool(
- DirectFunctionCall2(
- _int_same,
- PointerGetDatum(PG_GETARG_POINTER(0)),
- PointerGetDatum(PG_GETARG_POINTER(1))
+ PG_RETURN_BOOL( ! DatumGetBool(
+ DirectFunctionCall2(
+ _int_same,
+ PointerGetDatum(PG_GETARG_POINTER(0)),
+ PointerGetDatum(PG_GETARG_POINTER(1))
)
));
}
db = ARRPTR(b);
#ifdef GIST_DEBUG
- elog(NOTICE, "g_int_overlap");
+ elog(DEBUG3, "g_int_overlap");
#endif
i = j = 0;
GETBITBYTE(bv,7) ;
bv = (BITVECP) ( ((char*)bv) + 1 );
);
-
+
*sz = (float) len;
return;
}
in = NULL;
if (!entry->leafkey) {
- LOOPBYTE(
+ LOOPBYTE(
if ( ( ((char*)ARRPTR(in))[i] & 0xff ) != 0xff ) {
maycompress = false;
break;
}
- );
+ );
if ( maycompress ) {
retval = palloc(sizeof(GISTENTRY));
r = new_intArrayType(1);
- gistentryinit(*retval, PointerGetDatum(r),
+ gistentryinit(*retval, PointerGetDatum(r),
entry->rel, entry->page, entry->offset, VARSIZE(r), FALSE);
PG_RETURN_POINTER( retval );
- }
+ }
PG_RETURN_POINTER( entry );
}
ARRPTR(in),
ARRNELEMS(in));
- LOOPBYTE(
+ LOOPBYTE(
if( ( ((char*)ARRPTR(in))[i] & 0xff ) != 0xff ) {
maycompress = false;
break;
}
- );
+ );
if ( maycompress ) {
pfree(r);
r = new_intArrayType(1);
- }
+ }
gistentryinit(*retval, PointerGetDatum(r), entry->rel, entry->page, entry->offset, VARSIZE(r), FALSE);
retval = palloc(sizeof(GISTENTRY));
- gistentryinit(*retval, PointerGetDatum(key),
+ gistentryinit(*retval, PointerGetDatum(key),
entry->rel, entry->page, entry->offset, (key) ? VARSIZE(key) : 0, FALSE);
PG_RETURN_POINTER( retval );
}
retval = palloc(sizeof(GISTENTRY));
newkey = new_intArrayType(SIGLENINT);
- MemSet( (void*)ARRPTR(newkey), 0xff, SIGLEN );
+ MemSet( (void*)ARRPTR(newkey), 0xff, SIGLEN );
- gistentryinit(*retval, PointerGetDatum(newkey),
+ gistentryinit(*retval, PointerGetDatum(newkey),
entry->rel, entry->page, entry->offset, VARSIZE(newkey), FALSE);
PG_RETURN_POINTER( retval );
}
g_intbig_picksplit(PG_FUNCTION_ARGS)
{
PG_RETURN_POINTER( _int_common_picksplit(
- (bytea *)PG_GETARG_POINTER(0),
+ (bytea *)PG_GETARG_POINTER(0),
(GIST_SPLITVEC *)PG_GETARG_POINTER(1),
_intbig_union,
_intbig_inter,
Datum
g_intbig_union(PG_FUNCTION_ARGS)
{
- PG_RETURN_POINTER( _int_common_union(
- (bytea *) PG_GETARG_POINTER(0),
- (int *) PG_GETARG_POINTER(1),
- _intbig_union
- ) );
+ PG_RETURN_POINTER( _int_common_union(
+ (bytea *) PG_GETARG_POINTER(0),
+ (int *) PG_GETARG_POINTER(1),
+ _intbig_union
+ ) );
}
Datum
g_intbig_penalty(PG_FUNCTION_ARGS)
{
- PG_RETURN_POINTER( _int_common_penalty(
- (GISTENTRY *)PG_GETARG_POINTER(0),
- (GISTENTRY *)PG_GETARG_POINTER(1),
- (float *) PG_GETARG_POINTER(2),
+ PG_RETURN_POINTER( _int_common_penalty(
+ (GISTENTRY *)PG_GETARG_POINTER(0),
+ (GISTENTRY *)PG_GETARG_POINTER(1),
+ (float *) PG_GETARG_POINTER(2),
_intbig_union, rt__intbig_size
) );
}
Datum
g_intbig_consistent(PG_FUNCTION_ARGS) {
- GISTENTRY *entry = (GISTENTRY *)PG_GETARG_POINTER(0);
- ArrayType *query = ( ArrayType * )PG_GETARG_POINTER(1);
- StrategyNumber strategy = (StrategyNumber) PG_GETARG_UINT16(2);
+ GISTENTRY *entry = (GISTENTRY *)PG_GETARG_POINTER(0);
+ ArrayType *query = ( ArrayType * )PG_GETARG_POINTER(1);
+ StrategyNumber strategy = (StrategyNumber) PG_GETARG_UINT16(2);
bool retval;
ArrayType *q;
if ( strategy == BooleanSearchStrategy )
- PG_RETURN_BOOL(signconsistent( (QUERYTYPE*)query,
+ PG_RETURN_BOOL(signconsistent( (QUERYTYPE*)query,
SIGPTR((ArrayType *) DatumGetPointer(entry->key)),
false ) );
-
+
/* XXX what about toasted input? */
if (ARRISVOID(query))
return FALSE;
ArrayType *tmp;
#ifdef GIST_DEBUG
- elog(NOTICE, "_int_common_union in");
+ elog(DEBUG3, "_int_common_union in");
#endif
numranges = (VARSIZE(entryvec) - VARHDRSZ) / sizeof(GISTENTRY);
{
pfree(out);
#ifdef GIST_DEBUG
- elog(NOTICE, "_int_common_union out1");
+ elog(DEBUG3, "_int_common_union out1");
#endif
return NULL;
}
#ifdef GIST_DEBUG
- elog(NOTICE, "_int_common_union out");
+ elog(DEBUG3, "_int_common_union out");
#endif
return (out);
tmp2;
#ifdef GIST_DEBUG
- elog(NOTICE, "penalty");
+ elog(DEBUG3, "penalty");
#endif
ud = (*unionf) ((ArrayType *) DatumGetPointer(origentry->key),
(ArrayType *) DatumGetPointer(newentry->key));
pfree(ud);
#ifdef GIST_DEBUG
- elog(NOTICE, "--penalty\t%g", *result);
+ elog(DEBUG3, "--penalty\t%g", *result);
#endif
return (result);
float cost;
} SPLITCOST;
-static int
+static int
comparecost( const void *a, const void *b ) {
if ( ((SPLITCOST*)a)->cost == ((SPLITCOST*)b)->cost )
return 0;
SPLITCOST *costvector;
#ifdef GIST_DEBUG
- elog(NOTICE, "--------picksplit %d", (VARSIZE(entryvec) - VARHDRSZ) / sizeof(GISTENTRY));
+ elog(DEBUG3, "--------picksplit %d", (VARSIZE(entryvec) - VARHDRSZ) / sizeof(GISTENTRY));
#endif
maxoff = ((VARSIZE(entryvec) - VARHDRSZ) / sizeof(GISTENTRY)) - 2;
maxoff = OffsetNumberNext(maxoff);
/*
- * sort entries
+ * sort entries
*/
costvector=(SPLITCOST*)palloc( sizeof(SPLITCOST)*maxoff );
for (i = FirstOffsetNumber; i <= maxoff; i = OffsetNumberNext(i)) {
costvector[i-1].cost = abs( (size_alpha - size_l) - (size_beta - size_r) );
}
qsort( (void*)costvector, maxoff, sizeof(SPLITCOST), comparecost );
-
+
/*
* Now split up the regions between the two seeds. An important
* property of this split algorithm is that the split vector v has the
* tuples and i == maxoff + 1.
*/
-
+
for (j = 0; j < maxoff; j++) {
i = costvector[j].pos;
v->spl_rdatum = PointerGetDatum(datum_r);
#ifdef GIST_DEBUG
- elog(NOTICE, "--------ENDpicksplit %d %d", v->spl_nleft, v->spl_nright);
+ elog(DEBUG3, "--------ENDpicksplit %d %d", v->spl_nleft, v->spl_nright);
#endif
return v;
}
/*****************************************************************************
- * BoolSearch
+ * BoolSearch
*****************************************************************************/
/*
* get token from query string
*/
-static int4
+static int4
gettoken( WORKSTATE* state, int4* val ) {
char nnn[16], *curnnn;
switch(state->state) {
case WAITOPERAND:
curnnn=nnn;
- if ( (*(state->buf)>='0' && *(state->buf)<='9') ||
+ if ( (*(state->buf)>='0' && *(state->buf)<='9') ||
*(state->buf)=='-' ) {
state->state = WAITENDOPERAND;
*curnnn = *(state->buf);
state->count++;
(state->buf)++;
return OPEN;
- } else if ( *(state->buf) != ' ' )
+ } else if ( *(state->buf) != ' ' )
return ERR;
break;
case WAITENDOPERAND:
*curnnn = '\0';
*val=(int4)atoi( nnn );
state->state = WAITOPERATOR;
- return ( state->count && *(state->buf) == '\0' )
+ return ( state->count && *(state->buf) == '\0' )
? ERR : VAL;
}
break;
if ( *(state->buf) == '&' || *(state->buf) == '|' ) {
state->state = WAITOPERAND;
*val = (int4) *(state->buf);
- (state->buf)++;
+ (state->buf)++;
return OPR;
} else if ( *(state->buf) == ')' ) {
(state->buf)++;
} else if ( *(state->buf) != ' ' )
return ERR;
break;
- default:
+ default:
return ERR;
break;
- }
- (state->buf)++;
+ }
+ (state->buf)++;
}
return END;
}
/*
* make polish notaion of query
*/
-static int4
+static int4
makepol(WORKSTATE *state) {
int4 val,type;
int4 stack[STACKDEPTH];
switch(type) {
case VAL:
pushquery(state, type, val);
- while ( lenstack && (stack[ lenstack-1 ] == (int4)'&' ||
+ while ( lenstack && (stack[ lenstack-1 ] == (int4)'&' ||
stack[ lenstack-1 ] == (int4)'!') ) {
lenstack--;
pushquery(state, OPR, stack[ lenstack ]);
case OPR:
if ( lenstack && val == (int4) '|' ) {
pushquery(state, OPR, val);
- } else {
+ } else {
if ( lenstack == STACKDEPTH )
elog(ERROR,"Stack too short");
stack[ lenstack ] = val;
break;
case OPEN:
if ( makepol( state ) == ERR ) return ERR;
- if ( lenstack && (stack[ lenstack-1 ] == (int4)'&' ||
+ if ( lenstack && (stack[ lenstack-1 ] == (int4)'&' ||
stack[ lenstack-1 ] == (int4)'!') ) {
lenstack--;
pushquery(state, OPR, stack[ lenstack ]);
default:
elog(ERROR,"Syntax error");
return ERR;
-
+
}
}
static bool
checkcondition_bit( void *checkval, int4 val ) {
- return GETBIT( checkval, HASHVAL( val ) );
+ return GETBIT( checkval, HASHVAL( val ) );
}
/*
if ( curitem->type == VAL ) {
return (*chkcond)( checkval, curitem->val );
} else if ( curitem->val == (int4)'!' ) {
- return ( calcnot ) ?
- ( ( execute(curitem - 1, checkval, calcnot, chkcond) ) ? false : true )
+ return ( calcnot ) ?
+ ( ( execute(curitem - 1, checkval, calcnot, chkcond) ) ? false : true )
: true;
} else if ( curitem->val == (int4)'&' ) {
if ( execute(curitem + curitem->left, checkval, calcnot, chkcond) )
return execute(curitem - 1, checkval, calcnot, chkcond);
}
return false;
-}
+}
/*
* signconsistent & execconsistent called by *_consistent
*/
-static bool
+static bool
signconsistent( QUERYTYPE *query, BITVEC sign, bool calcnot ) {
- return execute(
- GETQUERY(query) + query->size-1 ,
- (void*)sign, calcnot,
- checkcondition_bit
- );
+ return execute(
+ GETQUERY(query) + query->size-1 ,
+ (void*)sign, calcnot,
+ checkcondition_bit
+ );
}
-static bool
+static bool
execconsistent( QUERYTYPE *query, ArrayType *array, bool calcnot ) {
CHKVAL chkval;
chkval.arrb = ARRPTR(array);
chkval.arre = chkval.arrb + ARRNELEMS(array);
- return execute(
- GETQUERY(query) + query->size-1 ,
- (void*)&chkval, calcnot,
- checkcondition_arr
+ return execute(
+ GETQUERY(query) + query->size-1 ,
+ (void*)&chkval, calcnot,
+ checkcondition_arr
);
}
/*
- * boolean operations
+ * boolean operations
*/
Datum
rboolop(PG_FUNCTION_ARGS) {
QUERYTYPE *query = ( QUERYTYPE * )PG_DETOAST_DATUM(PG_GETARG_POINTER(1));
CHKVAL chkval;
bool result;
-
+
if ( ARRISVOID( val ) ) {
pfree(val);
PG_FREE_IF_COPY(query,1);
PREPAREARR(val);
chkval.arrb = ARRPTR(val);
chkval.arre = chkval.arrb + ARRNELEMS(val);
- result = execute(
- GETQUERY(query) + query->size-1 ,
- &chkval, true,
- checkcondition_arr
+ result = execute(
+ GETQUERY(query) + query->size-1 ,
+ &chkval, true,
+ checkcondition_arr
);
pfree(val);
static void
findoprnd( ITEM *ptr, int4 *pos ) {
#ifdef BS_DEBUG
- elog(NOTICE, ( ptr[*pos].type == OPR ) ?
+ elog(DEBUG3, ( ptr[*pos].type == OPR ) ?
"%d %c" : "%d %d ", *pos, ptr[*pos].val );
#endif
if ( ptr[*pos].type == VAL ) {
findoprnd( ptr, pos );
} else {
ITEM *curitem = &ptr[*pos];
- int4 tmp = *pos;
+ int4 tmp = *pos;
(*pos)--;
findoprnd(ptr,pos);
curitem->left = *pos - tmp;
/* make polish notation (postfix, but in reverse order) */
makepol( &state );
- if (!state.num)
+ if (!state.num)
elog( ERROR,"Empty query");
commonlen = COMPUTESIZE(state.num);
ptr = GETQUERY(query);
for(i=state.num-1; i>=0; i-- ) {
- ptr[i].type = state.str->type;
+ ptr[i].type = state.str->type;
ptr[i].val = state.str->val;
tmp = state.str->next;
pfree( state.str );
state.str = tmp;
}
-
+
pos = query->size-1;
findoprnd( ptr, &pos );
#ifdef BS_DEBUG
cur = pbuf;
*cur = '\0';
for( i=0;i<query->size;i++ ) {
- if ( ptr[i].type == OPR )
+ if ( ptr[i].type == OPR )
sprintf(cur, "%c(%d) ", ptr[i].val, ptr[i].left);
- else
+ else
sprintf(cur, "%d ", ptr[i].val );
- cur = strchr(cur,'\0');
+ cur = strchr(cur,'\0');
}
- elog(NOTICE,"POR: %s", pbuf);
+ elog(DEBUG3,"POR: %s", pbuf);
#endif
PG_RETURN_POINTER( query );
RESIZEBUF(in, 2);
sprintf(in->cur, "( ");
in->cur = strchr( in->cur, '\0' );
- }
+ }
infix( in, isopr );
if ( isopr ) {
RESIZEBUF(in, 2);
sprintf(in->cur, " )");
in->cur = strchr( in->cur, '\0' );
- }
+ }
} else {
int4 op = in->curpol->val;
INFIX nrm;
-
+
in->curpol--;
if ( op == (int4)'|' && ! first) {
RESIZEBUF(in, 2);
nrm.curpol = in->curpol;
nrm.buflen = 16;
nrm.cur = nrm.buf = (char*)palloc( sizeof(char) * nrm.buflen );
-
+
/* get right operand */
infix( &nrm, false );
-
+
/* get & print left operand */
in->curpol = nrm.curpol;
infix( in, false );
INFIX nrm;
if ( query->size == 0 )
- elog(ERROR,"Empty");
+ elog(ERROR,"Empty");
nrm.curpol = GETQUERY(query) + query->size - 1;
nrm.buflen = 32;
nrm.cur = nrm.buf = (char*)palloc( sizeof(char) * nrm.buflen );
*(nrm.cur) = '\0';
infix( &nrm, true );
-
+
PG_FREE_IF_COPY(query,0);
PG_RETURN_POINTER( nrm.buf );
}
} else if ( q[pos].val == (int4)'!' ) {
return 1+countdroptree(q, pos-1);
} else {
- return 1 + countdroptree(q, pos-1) + countdroptree(q, pos + q[pos].left);
- }
+ return 1 + countdroptree(q, pos-1) + countdroptree(q, pos + q[pos].left);
+ }
}
/*
* common algorithm:
- * result of all '!' will be = 'true', so
+ * result of all '!' will be = 'true', so
* we can modify query tree for clearing
*/
-static int4
+static int4
shorterquery( ITEM *q, int4 len ) {
int4 index,posnot,poscor;
bool notisleft = false;
if ( poscor == posnot+1 ) {
notisleft = false;
break;
- } else if ( q[poscor].left + poscor == posnot ) {
+ } else if ( q[poscor].left + poscor == posnot ) {
notisleft = true;
break;
}
q[poscor-1].type=VAL;
for(i=poscor+1;i<len;i++)
if ( q[i].type == OPR && q[i].left + i <= poscor )
- q[i].left += drop - 2;
- memcpy( (void*)&q[poscor-drop+1],
- (void*)&q[poscor-1],
+ q[i].left += drop - 2;
+ memcpy( (void*)&q[poscor-drop+1],
+ (void*)&q[poscor-1],
sizeof(ITEM) * ( len - (poscor-1) ));
len -= drop - 2;
} else if ( q[poscor].val == (int4)'|' ) {
q[poscor].left=-1;
for(i=poscor+1;i<len;i++)
if ( q[i].type == OPR && q[i].left + i < poscor )
- q[i].left += drop - 2;
- memcpy( (void*)&q[poscor-drop+1],
- (void*)&q[poscor-1],
+ q[i].left += drop - 2;
+ memcpy( (void*)&q[poscor-drop+1],
+ (void*)&q[poscor-1],
sizeof(ITEM) * ( len - (poscor-1) ));
len -= drop - 2;
} else { /* &-operator */
- if (
- (notisleft && q[poscor-1].type == OPR &&
+ if (
+ (notisleft && q[poscor-1].type == OPR &&
q[poscor-1].val == (int4)'!' ) ||
- (!notisleft && q[poscor+q[poscor].left].type == OPR &&
+ (!notisleft && q[poscor+q[poscor].left].type == OPR &&
q[poscor+q[poscor].left].val == (int4)'!' )
) { /* drop subtree */
drop = countdroptree(q, poscor);
q[poscor].left=-1;
for(i=poscor+1;i<len;i++)
if ( q[i].type == OPR && q[i].left + i < poscor )
- q[i].left += drop - 2;
- memcpy( (void*)&q[poscor-drop+1],
- (void*)&q[poscor-1],
+ q[i].left += drop - 2;
+ memcpy( (void*)&q[poscor-drop+1],
+ (void*)&q[poscor-1],
sizeof(ITEM) * ( len - (poscor-1) ));
len -= drop - 2;
} else { /* drop only operator */
- int4 subtreepos = ( notisleft ) ?
+ int4 subtreepos = ( notisleft ) ?
poscor-1 : poscor+q[poscor].left;
int4 subtreelen = countdroptree( q, subtreepos );
drop = countdroptree(q, poscor);
for(i=poscor+1;i<len;i++)
if ( q[i].type == OPR && q[i].left + i < poscor )
- q[i].left += drop - subtreelen;
- memcpy( (void*)&q[ subtreepos+1 ],
- (void*)&q[poscor+1],
- sizeof(ITEM)*( len - (poscor-1) ) );
- memcpy( (void*)&q[ poscor-drop+1 ],
- (void*)&q[subtreepos-subtreelen+1],
+ q[i].left += drop - subtreelen;
+ memcpy( (void*)&q[ subtreepos+1 ],
+ (void*)&q[poscor+1],
+ sizeof(ITEM)*( len - (poscor-1) ) );
+ memcpy( (void*)&q[ poscor-drop+1 ],
+ (void*)&q[subtreepos-subtreelen+1],
sizeof(ITEM)*( len - (drop-subtreelen) ) );
- len -= drop - subtreelen;
+ len -= drop - subtreelen;
}
}
} while( index );
d = heap_getattr(lTuple, Anum_pg_listener_pid, tdesc, &isnull);
pid = DatumGetInt32(d);
if ((pid == ourpid) || (kill(pid, SIGTSTP) == 0))
- {
- /* elog(NOTICE, "%d ok", pid); */
count++;
- }
}
heap_endscan(sRel);
if (!isnull)
{
- elog(NOTICE, "%s: update not allowed", args[i]);
+ elog(WARNING, "%s: update not allowed", args[i]);
SPI_finish();
return PointerGetDatum(NULL);
}
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: px.c,v 1.6 2001/11/20 18:54:07 momjian Exp $
+ * $Id: px.c,v 1.7 2002/03/06 06:09:10 momjian Exp $
*/
#include <postgres.h>
/* error reporting should be done in pgcrypto.c */
block_error:
- elog(NOTICE, "Data not a multiple of block size");
+ elog(WARNING, "Data not a multiple of block size");
return -1;
}
/*
- * $Header: /cvsroot/pgsql/contrib/pgstattuple/pgstattuple.c,v 1.3 2001/12/19 20:28:41 tgl Exp $
+ * $Header: /cvsroot/pgsql/contrib/pgstattuple/pgstattuple.c,v 1.4 2002/03/06 06:09:10 momjian Exp $
*
* Copyright (c) 2001 Tatsuo Ishii
*
free_percent = (double) free_space *100.0 / table_len;
}
- elog(NOTICE, "physical length: %.2fMB live tuples: %.0f (%.2fMB, %.2f%%) dead tuples: %.0f (%.2fMB, %.2f%%) free/reusable space: %.2fMB (%.2f%%) overhead: %.2f%%",
+ elog(DEBUG3, "physical length: %.2fMB live tuples: %.0f (%.2fMB, %.2f%%) dead tuples: %.0f (%.2fMB, %.2f%%) free/reusable space: %.2fMB (%.2f%%) overhead: %.2f%%",
table_len / (1024 * 1024), /* physical length in MB */
GetCurrentTransactionId(), deleted, rel->rd_id, okey);
if (debug)
- elog(NOTICE, sql);
+ elog(DEBUG3, sql);
ret = SPI_exec(sql, 0);
deleted, okey);
if (debug)
- elog(NOTICE, sql);
+ elog(DEBUG3, sql);
ret = SPI_exec(sql, 0);
rel->rd_id, GetCurrentTransactionId(), okey);
if (debug)
- elog(NOTICE, sql);
+ elog(DEBUG3, sql);
ret = SPI_exec(sql, 0);
int i;
#ifdef DEBUG_QUERY
- elog(NOTICE, "Check_primary_key Enter Function");
+ elog(DEBUG3, "Check_primary_key Enter Function");
#endif
/*
r;
#ifdef DEBUG_QUERY
- elog(NOTICE, "Check_foreign_key Enter Function");
+ elog(DEBUG3, "Check_foreign_key Enter Function");
#endif
/*
strcmp(type, "date") && strcmp(type, "datetime")) == 0)
is_char_type = 1;
#ifdef DEBUG_QUERY
- elog(NOTICE, "Check_foreign_key Debug value %s type %s %d",
+ elog(DEBUG3, "Check_foreign_key Debug value %s type %s %d",
nv, type, is_char_type);
#endif
}
plan->nplans = nrefs;
#ifdef DEBUG_QUERY
- elog(NOTICE, "Check_foreign_key Debug Query is : %s ", sql);
+ elog(DEBUG3, "Check_foreign_key Debug Query is : %s ", sql);
#endif
}
}
#ifdef REFINT_VERBOSE
else
- elog(NOTICE, "%s: %d tuple(s) of %s are %s",
+ elog(DEBUG3, "%s: %d tuple(s) of %s are %s",
trigger->tgname, SPI_processed, relname,
(action == 'c') ? "deleted" : "setted to null");
#endif
findoprnd(ITEM * ptr, int4 *pos)
{
#ifdef BS_DEBUG
- elog(NOTICE, (ptr[*pos].type == OPR) ?
+ elog(DEBUG3, (ptr[*pos].type == OPR) ?
"%d %c" : "%d %d ", *pos, ptr[*pos].val);
#endif
if (ptr[*pos].type == VAL || ptr[*pos].type == VALTRUE)
sprintf(cur, "%d(%s) ", ptr[i].val, GETOPERAND(query) + ptr[i].distance);
cur = strchr(cur, '\0');
}
- elog(NOTICE, "POR: %s", pbuf);
+ elog(DEBUG3, "POR: %s", pbuf);
#endif
return query;
sprintf(cur, "%d(%s) ", ptr[i].val, GETOPERAND(query) + ptr[i].distance);
cur = strchr(cur, '\0');
}
- elog(NOTICE, "POR: %s", pbuf);
+ elog(DEBUG3, "POR: %s", pbuf);
#endif
pfree(res);
PG_RETURN_POINTER(query);
oidtype = SPI_gettypeid(rel->rd_att, numattr);
if (numattr < 0 || (!(oidtype == TEXTOID || oidtype == VARCHAROID)))
{
- elog(NOTICE, "TSearch: can not find field '%s'", trigger->tgargs[i]);
+ elog(WARNING, "TSearch: can not find field '%s'", trigger->tgargs[i]);
continue;
}
txt_toasted = (text *) DatumGetPointer(SPI_getbinval(rettuple, rel->rd_att, numattr, &isnull));
if (!XML_Parse(p, (char *) VARDATA(t), docsize, 1))
{
/*
- * elog(NOTICE, "Parse error at line %d:%s",
+ * elog(WARNING, "Parse error at line %d:%s",
* XML_GetCurrentLineNumber(p),
* XML_ErrorString(XML_GetErrorCode(p)));
*/
if (!XML_Parse(p, (char *) VARDATA(doc), docsize, 1))
{
/*
- * elog(NOTICE, "Parse error at line %d:%s",
+ * elog(WARNING, "Parse error at line %d:%s",
* XML_GetCurrentLineNumber(p),
* XML_ErrorString(XML_GetErrorCode(p)));
*/
char sepstr[] = "/";
if ((strlen(name) + strlen(UD->currentpath)) > MAXPATHLENGTH - 2)
- elog(NOTICE, "Path too long");
+ elog(WARNING, "Path too long");
else
{
strncat(UD->currentpath, sepstr, 1);
}
if (strcmp(name, sepptr + 1) != 0)
{
- elog(NOTICE, "Wanted [%s], got [%s]", sepptr, name);
+ elog(WARNING, "Wanted [%s], got [%s]", sepptr, name);
/* unmatched entry, so do nothing */
}
else
comppath = xmlXPathCompile(xpath);
if (comppath == NULL)
{
- elog(NOTICE, "XPath syntax error");
+ elog(WARNING, "XPath syntax error");
xmlFreeDoc(doctree);
pfree((void *) xpath);
PG_RETURN_NULL();
xpresstr = xmlStrdup(res->stringval);
break;
default:
- elog(NOTICE, "Unsupported XQuery result: %d", res->type);
+ elog(WARNING, "Unsupported XQuery result: %d", res->type);
xpresstr = xmlStrdup("<unsupported/>");
}
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/gist/gist.c,v 1.90 2002/03/05 05:30:31 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/gist/gist.c,v 1.91 2002/03/06 06:09:15 momjian Exp $
*
*-------------------------------------------------------------------------
*/
maxoff = PageGetMaxOffsetNumber(page);
- elog(NOTICE, "%sPage: %d %s blk: %d maxoff: %d free: %d", pred,
+ elog(DEBUG3, "%sPage: %d %s blk: %d maxoff: %d free: %d", pred,
coff, (opaque->flags & F_LEAF) ? "LEAF" : "INTE", (int) blk,
(int) maxoff, PageGetFreeSpace(page));
which = (IndexTuple) PageGetItem(page, iid);
cblk = ItemPointerGetBlockNumber(&(which->t_tid));
#ifdef PRINTTUPLE
- elog(NOTICE, "%s Tuple. blk: %d size: %d", pred, (int) cblk,
+ elog(DEBUG3, "%s Tuple. blk: %d size: %d", pred, (int) cblk,
IndexTupleSize(which));
#endif
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.89 2002/03/02 21:39:18 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.90 2002/03/06 06:09:17 momjian Exp $
*
*-------------------------------------------------------------------------
*/
elog(ERROR, "bt_insertonpg[%s]: no root page found", RelationGetRelationName(rel));
_bt_wrtbuf(rel, rbuf);
_bt_wrtnorelbuf(rel, buf);
- elog(NOTICE, "bt_insertonpg[%s]: root page unfound - fixing upper levels", RelationGetRelationName(rel));
+ elog(WARNING, "bt_insertonpg[%s]: root page unfound - fixing upper levels", RelationGetRelationName(rel));
_bt_fixup(rel, buf);
goto formres;
}
elog(ERROR, "_bt_getstackbuf: my bits moved right off the end of the world!"
"\n\tRecreate index %s.", RelationGetRelationName(rel));
pfree(new_item);
- elog(NOTICE, "bt_insertonpg[%s]: parent page unfound - fixing branch", RelationGetRelationName(rel));
+ elog(WARNING, "bt_insertonpg[%s]: parent page unfound - fixing branch", RelationGetRelationName(rel));
_bt_fixbranch(rel, bknum, rbknum, stack);
goto formres;
}
/* Call _bt_fixroot() if there is no upper level */
if (BTreeInvalidParent(opaque))
{
- elog(NOTICE, "bt_fixtree[%s]: fixing root page", RelationGetRelationName(rel));
+ elog(WARNING, "bt_fixtree[%s]: fixing root page", RelationGetRelationName(rel));
buf = _bt_fixroot(rel, buf, true);
_bt_relbuf(rel, buf);
return;
break;
}
- elog(NOTICE, "bt_fixbranch[%s]: fixing upper levels", RelationGetRelationName(rel));
+ elog(WARNING, "bt_fixbranch[%s]: fixing upper levels", RelationGetRelationName(rel));
_bt_fixup(rel, buf);
return;
{
blkno = opaque->btpo_parent;
_bt_relbuf(rel, buf);
- elog(NOTICE, "bt_fixup[%s]: checking/fixing upper levels", RelationGetRelationName(rel));
+ elog(WARNING, "bt_fixup[%s]: checking/fixing upper levels", RelationGetRelationName(rel));
_bt_fixtree(rel, blkno);
return;
}
* Ok, we are on the leftmost page, it's write locked by us and its
* btpo_parent points to meta page - time for _bt_fixroot().
*/
- elog(NOTICE, "bt_fixup[%s]: fixing root page", RelationGetRelationName(rel));
+ elog(WARNING, "bt_fixup[%s]: fixing root page", RelationGetRelationName(rel));
buf = _bt_fixroot(rel, buf, true);
_bt_relbuf(rel, buf);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtpage.c,v 1.55 2002/01/15 22:14:17 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtpage.c,v 1.56 2002/03/06 06:09:18 momjian Exp $
*
* NOTES
* Postgres btree pages look like ordinary relation pages. The opaque
/* handle concurrent fix of root page */
if (BTreeInvalidParent(rootopaque)) /* unupdated! */
{
- elog(NOTICE, "bt_getroot[%s]: fixing root page", RelationGetRelationName(rel));
+ elog(WARNING, "bt_getroot[%s]: fixing root page", RelationGetRelationName(rel));
newrootbuf = _bt_fixroot(rel, rootbuf, true);
LockBuffer(newrootbuf, BUFFER_LOCK_UNLOCK);
LockBuffer(newrootbuf, BT_READ);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.116 2002/03/02 21:39:19 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.117 2002/03/06 06:09:21 momjian Exp $
*
* NOTES
* Transaction aborts can now occur two ways:
* check the current transaction state
*/
if (s->state != TRANS_INPROGRESS)
- elog(NOTICE, "CommitTransaction and not in in-progress state");
+ elog(WARNING, "CommitTransaction and not in in-progress state");
/*
* Tell the trigger manager that this transaction is about to be
* check the current transaction state
*/
if (s->state != TRANS_INPROGRESS)
- elog(NOTICE, "AbortTransaction and not in in-progress state");
+ elog(WARNING, "AbortTransaction and not in in-progress state");
/*
* set the current transaction state information appropriately during
* warning and change to the in-progress state.
*/
case TBLOCK_BEGIN:
- elog(NOTICE, "StartTransactionCommand: unexpected TBLOCK_BEGIN");
+ elog(WARNING, "StartTransactionCommand: unexpected TBLOCK_BEGIN");
s->blockState = TBLOCK_INPROGRESS;
break;
* and change to the default state.
*/
case TBLOCK_END:
- elog(NOTICE, "StartTransactionCommand: unexpected TBLOCK_END");
+ elog(WARNING, "StartTransactionCommand: unexpected TBLOCK_END");
s->blockState = TBLOCK_DEFAULT;
CommitTransaction();
StartTransaction();
* default.
*/
case TBLOCK_ENDABORT:
- elog(NOTICE, "StartTransactionCommand: unexpected TBLOCK_ENDABORT");
+ elog(WARNING, "StartTransactionCommand: unexpected TBLOCK_ENDABORT");
break;
}
* check the current transaction state
*/
if (s->blockState != TBLOCK_DEFAULT)
- elog(NOTICE, "BEGIN: already a transaction in progress");
+ elog(WARNING, "BEGIN: already a transaction in progress");
/*
* set the current transaction block state information appropriately
/*
* here, the user issued COMMIT when not inside a transaction. Issue a
- * notice and go to abort state. The upcoming call to
+ * WARNING and go to abort state. The upcoming call to
* CommitTransactionCommand() will then put us back into the default
* state.
*/
- elog(NOTICE, "COMMIT: no transaction in progress");
+ elog(WARNING, "COMMIT: no transaction in progress");
AbortTransaction();
s->blockState = TBLOCK_ENDABORT;
}
/*
* here, the user issued ABORT when not inside a transaction. Issue a
- * notice and go to abort state. The upcoming call to
+ * WARNING and go to abort state. The upcoming call to
* CommitTransactionCommand() will then put us back into the default
* state.
*/
- elog(NOTICE, "ROLLBACK: no transaction in progress");
+ elog(WARNING, "ROLLBACK: no transaction in progress");
AbortTransaction();
s->blockState = TBLOCK_ENDABORT;
}
/*
* here, the user issued ABORT when not inside a transaction. Issue a
- * notice and go to abort state. The upcoming call to
+ * WARNING and go to abort state. The upcoming call to
* CommitTransactionCommand() will then put us back into the default
* state.
*/
- elog(NOTICE, "ROLLBACK: no transaction in progress");
+ elog(WARNING, "ROLLBACK: no transaction in progress");
AbortTransaction();
s->blockState = TBLOCK_ENDABORT;
}
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Header: /cvsroot/pgsql/src/backend/access/transam/xlog.c,v 1.88 2002/03/02 21:39:20 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/transam/xlog.c,v 1.89 2002/03/06 06:09:22 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* CreateCheckpoint will try to flush it at the end of recovery.)
*
* The current approach is to ERROR under normal conditions, but only
- * NOTICE during recovery, so that the system can be brought up even if
+ * WARNING during recovery, so that the system can be brought up even if
* there's a corrupt LSN. Note that for calls from xact.c, the ERROR
* will be promoted to PANIC since xact.c calls this routine inside a
* critical section. However, calls from bufmgr.c are not within
* on a data page.
*/
if (XLByteLT(LogwrtResult.Flush, record))
- elog(InRecovery ? NOTICE : ERROR,
+ elog(InRecovery ? WARNING : ERROR,
"XLogFlush: request %X/%X is not satisfied --- flushed only to %X/%X",
record.xlogid, record.xrecoff,
LogwrtResult.Flush.xlogid, LogwrtResult.Flush.xrecoff);
{
elog(LOG, "archiving transaction log file %s",
xlde->d_name);
- elog(NOTICE, "archiving log files is not implemented!");
+ elog(WARNING, "archiving log files is not implemented!");
}
else
{
StrNCpy(ControlFile->lc_ctype, localeptr, LOCALE_NAME_BUFLEN);
/*
- * Issue warning notice if initdb'ing in a locale that will not permit
+ * Issue warning WARNING if initdb'ing in a locale that will not permit
* LIKE index optimization. This is not a clean place to do it, but I
* don't see a better place either...
*/
if (!locale_is_like_safe())
- elog(NOTICE, "Initializing database with %s collation order."
+ elog(WARNING, "Initializing database with %s collation order."
"\n\tThis locale setting will prevent use of index optimization for"
"\n\tLIKE and regexp searches. If you are concerned about speed of"
"\n\tsuch queries, you may wish to set LC_COLLATE to \"C\" and"
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/aclchk.c,v 1.55 2002/03/02 21:39:22 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/aclchk.c,v 1.56 2002/03/06 06:09:24 momjian Exp $
*
* NOTES
* See acl.h.
ReleaseSysCache(tuple);
}
else
- elog(NOTICE, "in_group: group %u not found", gid);
+ elog(WARNING, "in_group: group %u not found", gid);
return result;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/heap.c,v 1.183 2002/03/03 17:47:54 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/heap.c,v 1.184 2002/03/06 06:09:25 momjian Exp $
*
*
* INTERFACE ROUTINES
elog(ERROR, "name of column \"%s\" conflicts with an existing system column",
NameStr(tupdesc->attrs[i]->attname));
if (tupdesc->attrs[i]->atttypid == UNKNOWNOID)
- elog(NOTICE, "Attribute '%s' has an unknown type"
+ elog(WARNING, "Attribute '%s' has an unknown type"
"\n\tProceeding with relation creation anyway",
NameStr(tupdesc->attrs[i]->attname));
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/pg_proc.c,v 1.64 2002/02/18 23:11:08 petere Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/pg_proc.c,v 1.65 2002/03/06 06:09:26 momjian Exp $
*
*-------------------------------------------------------------------------
*/
elog(ERROR, "argument type %s does not exist",
typnam);
if (!defined)
- elog(NOTICE, "argument type %s is only a shell",
+ elog(WARNING, "argument type %s is only a shell",
typnam);
}
if (!OidIsValid(typeObjectId))
{
- elog(NOTICE, "ProcedureCreate: type %s is not yet defined",
+ elog(WARNING, "ProcedureCreate: type %s is not yet defined",
returnTypeName);
typeObjectId = TypeShellMake(returnTypeName);
if (!OidIsValid(typeObjectId))
returnTypeName);
}
else if (!defined)
- elog(NOTICE, "return type %s is only a shell",
+ elog(WARNING, "return type %s is only a shell",
returnTypeName);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/_deadcode/Attic/recipe.c,v 1.15 2001/11/05 17:46:25 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/_deadcode/Attic/recipe.c,v 1.16 2002/03/06 06:09:40 momjian Exp $
*
*-------------------------------------------------------------------------
*/
void
beginRecipe(RecipeStmt *stmt)
{
- elog(NOTICE, "You must compile with TIOGA defined in order to use recipes\n");
+ elog(WARNING, "You must compile with TIOGA defined in order to use recipes\n");
}
#else
e = r->eyes->val[i];
if (e->inNodes->num > 1)
{
- elog(NOTICE,
+ elog(WARNING,
"beginRecipe: Currently eyes cannot have more than one input");
}
if (e->inNodes->num == 0)
}
#ifdef DEBUG_RECIPE
- elog(NOTICE, "beginRecipe: eyes[%d] = %s\n", i, e->nodeName);
+ elog(WARNING, "beginRecipe: eyes[%d] = %s\n", i, e->nodeName);
#endif /* DEBUG_RECIPE */
qList = tg_parseSubQuery(r, e->inNodes->val[0], teeInfo);
tplan = planner(teeInfo->val[t].tpi_parsetree);
/* now add a tee node to the root of the plan */
- elog(NOTICE, "adding tee plan node to the root of the %s\n",
+ elog(WARNING, "adding tee plan node to the root of the %s\n",
teeInfo->val[t].tpi_relName);
newplan = (Tee *) makeNode(Tee);
newplan->plan.targetlist = tplan->targetlist;
plan,
attinfo,
whereToSendOutput);
- elog(NOTICE, "beginRecipe: cursor named %s is now available", portalName);
+ elog(WARNING, "beginRecipe: cursor named %s is now available", portalName);
}
}
}
}
else
- elog(NOTICE, "tg_replaceNumberedParam: unexpected paramkind value of %d", p->paramkind);
+ elog(WARNING, "tg_replaceNumberedParam: unexpected paramkind value of %d", p->paramkind);
}
break;
case T_Expr:
}
}
else
- elog(NOTICE, "tg_rewriteParamsInExpr: unexpected paramkind value of %d", p->paramkind);
+ elog(WARNING, "tg_rewriteParamsInExpr: unexpected paramkind value of %d", p->paramkind);
}
break;
case T_Expr:
if (!OidIsValid(toid))
elog(ERROR, "getParamTypes: arg type '%s' is not defined", t);
if (!defined)
- elog(NOTICE, "getParamTypes: arg type '%s' is only a shell", t);
+ elog(WARNING, "getParamTypes: arg type '%s' is only a shell", t);
}
typev[parameterCount++] = toid;
}
*/
#ifdef DEBUG_RECIPE
- elog(NOTICE, "calling parser with %s", elem->src);
+ elog(WARNING, "calling parser with %s", elem->src);
#endif /* DEBUG_RECIPE */
parameterCount = getParamTypes(elem, typev);
if (qList->len > 1)
{
- elog(NOTICE,
+ elog(WARNING,
"tg_parseSubQuery: parser produced > 1 query tree");
}
}
snprintf(newquery, 1000, "select %s()", funcName);
#ifdef DEBUG_RECIPE
- elog(NOTICE, "calling parser with %s", newquery);
+ elog(WARNING, "calling parser with %s", newquery);
#endif /* DEBUG_RECIPE */
qList = parser(newquery, typev, parameterCount);
if (qList->len > 1)
{
- elog(NOTICE,
+ elog(WARNING,
"tg_parseSubQuery: parser produced > 1 query tree");
}
}
break;
case TG_RECIPE_GRAPH:
- elog(NOTICE, "tg_parseSubQuery: can't parse recipe graph ingredients yet!");
+ elog(WARNING, "tg_parseSubQuery: can't parse recipe graph ingredients yet!");
break;
case TG_COMPILED:
- elog(NOTICE, "tg_parseSubQuery: can't parse compiled ingredients yet!");
+ elog(WARNING, "tg_parseSubQuery: can't parse compiled ingredients yet!");
break;
default:
- elog(NOTICE, "tg_parseSubQuery: unknown srcLang: %d", elem->srcLang);
+ elog(WARNING, "tg_parseSubQuery: unknown srcLang: %d", elem->srcLang);
}
/* parse each of the subrecipes that are input to this node */
* if we hit an eye, we need to stop and make what we have into a
* subrecipe query block
*/
- elog(NOTICE, "tg_parseSubQuery: can't handle eye nodes yet");
+ elog(WARNING, "tg_parseSubQuery: can't handle eye nodes yet");
}
else if (n->nodeType == TG_TEE_NODE)
{
"result",
InvalidOid,
-1, 0, false))
- elog(NOTICE, "tg_parseSubQuery: unexpected result from TupleDescInitEntry");
+ elog(WARNING, "tg_parseSubQuery: unexpected result from TupleDescInitEntry");
else
{
relid = heap_create_with_catalog(
}
}
else if (n->nodeType == TG_RECIPE_NODE)
- elog(NOTICE, "tg_parseSubQuery: can't handle embedded recipes yet!");
+ elog(WARNING, "tg_parseSubQuery: can't handle embedded recipes yet!");
else
- elog(NOTICE, "unknown nodeType: %d", n->nodeType);
+ elog(WARNING, "unknown nodeType: %d", n->nodeType);
return qList;
}
return;
}
}
- elog(NOTICE, "appendTeeQuery: teeNodeName '%s' not found in teeInfo");
+ elog(WARNING, "appendTeeQuery: teeNodeName '%s' not found in teeInfo");
}
tplan = teeInfo->val[i].tpi_plan;
}
if (tplan == NULL)
- elog(NOTICE, "replaceTeeScans didn't find the corresponding tee plan");
+ elog(WARNING, "replaceTeeScans didn't find the corresponding tee plan");
/*
* replace the sequential scan node with that var number with
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/analyze.c,v 1.27 2002/03/02 21:39:22 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/analyze.c,v 1.28 2002/03/06 06:09:28 momjian Exp $
*
*-------------------------------------------------------------------------
*/
elevel = INFO;
else
elevel = DEBUG1;
-
+
/*
* Begin a transaction for analyzing this relation.
*
/*
* Check for user-requested abort. Note we want this to be inside a
- * transaction, so xact.c doesn't issue useless NOTICE.
+ * transaction, so xact.c doesn't issue useless WARNING.
*/
CHECK_FOR_INTERRUPTS();
RELNAME) ||
(is_dbadmin(MyDatabaseId) && !onerel->rd_rel->relisshared)))
{
- /* No need for a notice if we already complained during VACUUM */
+ /* No need for a WARNING if we already complained during VACUUM */
if (!vacstmt->vacuum)
- elog(NOTICE, "Skipping \"%s\" --- only table or database owner can ANALYZE it",
+ elog(WARNING, "Skipping \"%s\" --- only table or database owner can ANALYZE it",
RelationGetRelationName(onerel));
heap_close(onerel, NoLock);
CommitTransactionCommand();
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/async.c,v 1.82 2002/03/02 21:39:22 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/async.c,v 1.83 2002/03/06 06:09:29 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (alreadyListener)
{
heap_close(lRel, AccessExclusiveLock);
- elog(NOTICE, "Async_Listen: We are already listening on %s", relname);
+ elog(WARNING, "Async_Listen: We are already listening on %s", relname);
return;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/command.c,v 1.158 2002/03/05 05:33:08 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/command.c,v 1.159 2002/03/06 06:09:29 momjian Exp $
*
* NOTES
* The PerformAddAttribute() code, like most of the relation
*/
if (name == NULL)
{
- elog(NOTICE, "PerformPortalFetch: missing portal name");
+ elog(WARNING, "PerformPortalFetch: missing portal name");
return;
}
portal = GetPortalByName(name);
if (!PortalIsValid(portal))
{
- elog(NOTICE, "PerformPortalFetch: portal \"%s\" not found",
+ elog(WARNING, "PerformPortalFetch: portal \"%s\" not found",
name);
return;
}
*/
if (name == NULL)
{
- elog(NOTICE, "PerformPortalClose: missing portal name");
+ elog(WARNING, "PerformPortalClose: missing portal name");
return;
}
portal = GetPortalByName(name);
if (!PortalIsValid(portal))
{
- elog(NOTICE, "PerformPortalClose: portal \"%s\" not found",
+ elog(WARNING, "PerformPortalClose: portal \"%s\" not found",
name);
return;
}
myrelid = RelationGetRelid(rel);
heap_close(rel, NoLock); /* close rel, but keep lock! */
-
+
/*
* Check the supplied parameters before anything else
*/
{
Assert(IsA(flagValue, Integer));
newtarget = intVal(flagValue);
-
+
/*
* Limit target to sane range (should we raise an error instead?)
*/
*/
{
Assert(IsA(flagValue, Value));
-
+
storagemode = strVal(flagValue);
if (strcasecmp(storagemode, "plain") == 0)
newstorage = 'p';
constrName);
/* Otherwise if more than one constraint deleted, notify */
else if (deleted > 1)
- elog(INFO, "Multiple constraints dropped");
+ elog(NOTICE, "Multiple constraints dropped");
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.149 2002/02/27 01:34:41 ishii Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.150 2002/03/06 06:09:30 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
if (!*newline)
{
- elog(NOTICE, "CopyReadNewline: extra fields ignored");
+ elog(WARNING, "CopyReadNewline: extra fields ignored");
while (!CopyGetEof(fp) && (CopyGetChar(fp) != '\n'));
}
*newline = 0;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/creatinh.c,v 1.82 2002/03/02 21:39:22 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/creatinh.c,v 1.83 2002/03/06 06:09:31 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* Yes, try to merge the two column definitions. They must
* have the same type and typmod.
*/
- elog(INFO, "CREATE TABLE: merging multiple inherited definitions of attribute \"%s\"",
+ elog(NOTICE, "CREATE TABLE: merging multiple inherited definitions of attribute \"%s\"",
attributeName);
def = (ColumnDef *) nth(exist_attno - 1, inhSchema);
if (strcmp(def->typename->name, attributeType) != 0 ||
* Yes, try to merge the two column definitions. They must
* have the same type and typmod.
*/
- elog(INFO, "CREATE TABLE: merging attribute \"%s\" with inherited definition",
+ elog(NOTICE, "CREATE TABLE: merging attribute \"%s\" with inherited definition",
attributeName);
def = (ColumnDef *) nth(exist_attno - 1, inhSchema);
if (strcmp(def->typename->name, attributeType) != 0 ||
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.84 2002/03/01 22:45:08 petere Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.85 2002/03/06 06:09:32 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/* remove symlink */
if (unlink(nominal_loc) != 0)
{
- elog(NOTICE, "could not remove '%s': %m", nominal_loc);
+ elog(WARNING, "could not remove '%s': %m", nominal_loc);
success = false;
}
}
if (system(buf) != 0)
{
- elog(NOTICE, "database directory '%s' could not be removed",
+ elog(WARNING, "database directory '%s' could not be removed",
target_dir);
success = false;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/define.c,v 1.66 2002/03/02 21:39:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/define.c,v 1.67 2002/03/06 06:09:32 momjian Exp $
*
* DESCRIPTION
* The "DefineFoo" routines take the parse tree and pick out the
else if (strcasecmp(param->defname, "outin_ratio") == 0)
*outin_ratio_p = (int) defGetNumeric(param);
else
- elog(NOTICE, "Unrecognized function attribute '%s' ignored",
+ elog(WARNING, "Unrecognized function attribute '%s' ignored",
param->defname);
}
}
else if (strcasecmp(defel->defname, "precedence") == 0)
{
/* NOT IMPLEMENTED (never worked in v4.2) */
- elog(INFO, "CREATE OPERATOR: precedence not implemented");
+ elog(NOTICE, "CREATE OPERATOR: precedence not implemented");
}
else if (strcasecmp(defel->defname, "associativity") == 0)
{
/* NOT IMPLEMENTED (never worked in v4.2) */
- elog(INFO, "CREATE OPERATOR: associativity not implemented");
+ elog(NOTICE, "CREATE OPERATOR: associativity not implemented");
}
else if (strcasecmp(defel->defname, "commutator") == 0)
commutatorName = defGetString(defel);
sortName2 = defGetString(defel);
else
{
- elog(NOTICE, "DefineOperator: attribute \"%s\" not recognized",
+ elog(WARNING, "DefineOperator: attribute \"%s\" not recognized",
defel->defname);
}
}
else if (strcasecmp(defel->defname, "initcond1") == 0)
initval = defGetString(defel);
else
- elog(NOTICE, "DefineAggregate: attribute \"%s\" not recognized",
+ elog(WARNING, "DefineAggregate: attribute \"%s\" not recognized",
defel->defname);
}
}
else
{
- elog(NOTICE, "DefineType: attribute \"%s\" not recognized",
+ elog(WARNING, "DefineType: attribute \"%s\" not recognized",
defel->defname);
}
}
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994-5, Regents of the University of California
*
- * $Header: /cvsroot/pgsql/src/backend/commands/explain.c,v 1.69 2002/03/02 21:39:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/explain.c,v 1.70 2002/03/06 06:09:33 momjian Exp $
*
*/
/* rewriter and planner may not work in aborted state? */
if (IsAbortedTransactionBlockState())
{
- elog(NOTICE, "(transaction aborted): %s",
+ elog(WARNING, "(transaction aborted): %s",
"queries ignored until END");
return;
}
/* rewriter will not cope with utility statements */
if (query->commandType == CMD_UTILITY)
{
- elog(INFO, "Utility statements have no plan structure");
+ elog(NOTICE, "Utility statements have no plan structure");
return;
}
/* In the case of an INSTEAD NOTHING, tell at least that */
if (rewritten == NIL)
{
- elog(INFO, "Query rewrites to nothing");
+ elog(NOTICE, "Query rewrites to nothing");
return;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/indexcmds.c,v 1.62 2002/01/03 23:19:36 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/indexcmds.c,v 1.63 2002/03/06 06:09:33 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (IsIgnoringSystemIndexes())
overwrite = true;
if (!reindex_index(tuple->t_data->t_oid, force, overwrite))
- elog(NOTICE, "index \"%s\" wasn't reindexed", name);
+ elog(WARNING, "index \"%s\" wasn't reindexed", name);
ReleaseSysCache(tuple);
}
name, ((Form_pg_class) GETSTRUCT(tuple))->relkind);
if (!reindex_relation(tuple->t_data->t_oid, force))
- elog(NOTICE, "table \"%s\" wasn't reindexed", name);
+ elog(WARNING, "table \"%s\" wasn't reindexed", name);
ReleaseSysCache(tuple);
}
{
StartTransactionCommand();
if (reindex_relation(relids[i], force))
- elog(NOTICE, "relation %u was reindexed", relids[i]);
+ elog(WARNING, "relation %u was reindexed", relids[i]);
CommitTransactionCommand();
}
StartTransactionCommand();
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/remove.c,v 1.65 2001/11/05 17:46:24 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/remove.c,v 1.66 2002/03/06 06:09:35 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (((Form_pg_proc) GETSTRUCT(tup))->prolang == INTERNALlanguageId)
{
- /* "Helpful" notice when removing a builtin function ... */
- elog(NOTICE, "Removing built-in function \"%s\"", functionName);
+ /* "Helpful" WARNING when removing a builtin function ... */
+ elog(WARNING, "Removing built-in function \"%s\"", functionName);
}
/* Delete any comments associated with this function */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/sequence.c,v 1.69 2002/03/02 21:39:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/sequence.c,v 1.70 2002/03/06 06:09:35 momjian Exp $
*
*-------------------------------------------------------------------------
*/
elm->rel = seqrel;
if (RelationGetRelid(seqrel) != elm->relid)
{
- elog(NOTICE, "%s.%s: sequence was re-created",
+ elog(WARNING, "%s.%s: sequence was re-created",
name, caller);
elm->relid = RelationGetRelid(seqrel);
elm->cached = elm->last = elm->increment = 0;
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/trigger.c,v 1.103 2002/03/02 21:39:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/trigger.c,v 1.104 2002/03/06 06:09:36 momjian Exp $
*
*-------------------------------------------------------------------------
*/
elog(ERROR, "DropTrigger: there is no trigger %s on relation %s",
stmt->trigname, stmt->relname);
if (tgfound > 1)
- elog(INFO, "DropTrigger: found (and deleted) %d triggers %s on relation %s",
+ elog(NOTICE, "DropTrigger: found (and deleted) %d triggers %s on relation %s",
tgfound, stmt->trigname, stmt->relname);
/*
stmt.relname = pstrdup(RelationGetRelationName(refrel));
heap_close(refrel, NoLock);
- elog(INFO, "DROP TABLE implicitly drops referential integrity trigger from table \"%s\"", stmt.relname);
+ elog(NOTICE, "DROP TABLE implicitly drops referential integrity trigger from table \"%s\"", stmt.relname);
DropTrigger(&stmt);
* deferred-to-end-of-transaction triggers, it could get annoying
* to rescan all the deferred triggers at each command end.
* To speed this up, we could remember the actual end of the queue at
- * EndQuery and examine only events that are newer. On state changes
- * we simply reset the saved position to the beginning of the queue
+ * EndQuery and examine only events that are newer. On state changes
+ * we simply reset the saved position to the beginning of the queue
* and process all events once with the new states.
*/
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Header: /cvsroot/pgsql/src/backend/commands/user.c,v 1.92 2002/03/02 21:39:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/user.c,v 1.93 2002/03/06 06:09:37 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/* changes to the flat password file cannot be rolled back */
if (IsTransactionBlock() && password)
- elog(INFO, "ALTER USER: password changes cannot be rolled back");
+ elog(NOTICE, "ALTER USER: password changes cannot be rolled back");
/*
* Scan the pg_shadow relation to be certain the user exists. Note we
elog(ERROR, "DROP USER: permission denied");
if (IsTransactionBlock())
- elog(INFO, "DROP USER cannot be rolled back completely");
+ elog(NOTICE, "DROP USER cannot be rolled back completely");
/*
* Scan the pg_shadow relation to find the usesysid of the user to be
if (!member(v, newlist))
newlist = lappend(newlist, v);
else
-
/*
* we silently assume here that this error will only come
* up in a ALTER GROUP statement
*/
- elog(NOTICE, "%s: user \"%s\" is already in group \"%s\"",
+ elog(WARNING, "%s: user \"%s\" is already in group \"%s\"",
tag, strVal(lfirst(item)), stmt->name);
}
if (null)
{
if (!is_dropuser)
- elog(NOTICE, "ALTER GROUP: group \"%s\" does not have any members", stmt->name);
+ elog(WARNING, "ALTER GROUP: group \"%s\" does not have any members", stmt->name);
}
else
{
if (member(v, newlist))
newlist = LispRemove(v, newlist);
else if (!is_dropuser)
- elog(NOTICE, "ALTER GROUP: user \"%s\" is not in group \"%s\"", strVal(lfirst(item)), stmt->name);
+ elog(WARNING, "ALTER GROUP: user \"%s\" is not in group \"%s\"", strVal(lfirst(item)), stmt->name);
}
newarray = palloc(ARR_OVERHEAD(1) + length(newlist) * sizeof(int32));
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.216 2002/03/03 17:47:54 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.217 2002/03/06 06:09:38 momjian Exp $
*
*-------------------------------------------------------------------------
*/
elevel = INFO;
else
elevel = DEBUG1;
-
+
/*
* Create special memory context for cross-transaction storage.
*
if (rkind != RELKIND_RELATION)
{
- elog(NOTICE, "%s: can not process indexes, views or special system tables",
+ elog(WARNING, "%s: can not process indexes, views or special system tables",
stmttype);
continue;
}
heap_close(rel, AccessShareLock);
if (vrl == NULL)
- elog(NOTICE, "%s: table not found", stmttype);
+ elog(WARNING, "%s: table not found", stmttype);
return vrl;
}
*/
if (TransactionIdFollows(limit, *oldestXmin))
{
- elog(NOTICE, "oldest Xmin is far in the past --- close open transactions soon to avoid wraparound problems");
+ elog(WARNING, "oldest Xmin is far in the past --- close open transactions soon to avoid wraparound problems");
limit = *oldestXmin;
}
/* Give warning about impending wraparound problems */
age = (int32) (GetCurrentTransactionId() - frozenXID);
if (age > (int32) ((MaxTransactionId >> 3) * 3))
- elog(NOTICE, "Some databases have not been vacuumed in %d transactions."
+ elog(WARNING, "Some databases have not been vacuumed in %d transactions."
"\n\tBetter vacuum them within %d transactions,"
"\n\tor you may have a wraparound failure.",
age, (int32) (MaxTransactionId >> 1) - age);
/*
* Check for user-requested abort. Note we want this to be inside a
- * transaction, so xact.c doesn't issue useless NOTICE.
+ * transaction, so xact.c doesn't issue useless WARNING.
*/
CHECK_FOR_INTERRUPTS();
* owner, or the database owner (but in the latter case, only if it's
* not a shared relation). pg_ownercheck includes the superuser case.
*
- * Note we choose to treat permissions failure as a NOTICE and keep
+ * Note we choose to treat permissions failure as a WARNING and keep
* trying to vacuum the rest of the DB --- is this appropriate?
*/
onerel = heap_open(relid, lmode);
RELNAME) ||
(is_dbadmin(MyDatabaseId) && !onerel->rd_rel->relisshared)))
{
- elog(NOTICE, "Skipping \"%s\" --- only table or database owner can VACUUM it",
+ elog(WARNING, "Skipping \"%s\" --- only table or database owner can VACUUM it",
RelationGetRelationName(onerel));
heap_close(onerel, lmode);
CommitTransactionCommand();
if (PageIsNew(page))
{
- elog(NOTICE, "Rel %s: Uninitialized page %u - fixing",
+ elog(WARNING, "Rel %s: Uninitialized page %u - fixing",
relname, blkno);
PageInit(page, BufferGetPageSize(buf), 0);
vacpage->free = ((PageHeader) page)->pd_upper - ((PageHeader) page)->pd_lower;
* This should not happen, since we hold exclusive
* lock on the relation; shouldn't we raise an error?
*/
- elog(NOTICE, "Rel %s: TID %u/%u: InsertTransactionInProgress %u - can't shrink relation",
+ elog(WARNING, "Rel %s: TID %u/%u: InsertTransactionInProgress %u - can't shrink relation",
relname, blkno, offnum, tuple.t_data->t_xmin);
do_shrinking = false;
break;
* This should not happen, since we hold exclusive
* lock on the relation; shouldn't we raise an error?
*/
- elog(NOTICE, "Rel %s: TID %u/%u: DeleteTransactionInProgress %u - can't shrink relation",
+ elog(WARNING, "Rel %s: TID %u/%u: DeleteTransactionInProgress %u - can't shrink relation",
relname, blkno, offnum, tuple.t_data->t_xmax);
do_shrinking = false;
break;
*/
if (!OidIsValid(tuple.t_data->t_oid) &&
onerel->rd_rel->relhasoids)
- elog(NOTICE, "Rel %s: TID %u/%u: OID IS INVALID. TUPGONE %d.",
+ elog(WARNING, "Rel %s: TID %u/%u: OID IS INVALID. TUPGONE %d.",
relname, blkno, offnum, (int) tupgone);
if (tupgone)
ReleaseBuffer(Cbuf);
pfree(vtmove);
vtmove = NULL;
- elog(NOTICE, "Child itemid in update-chain marked as unused - can't continue repair_frag");
+ elog(WARNING, "Child itemid in update-chain marked as unused - can't continue repair_frag");
break;
}
tp.t_datamcxt = NULL;
(vtmove[i].vacpage->offsets_used)--;
}
num_vtmove = 0;
- elog(NOTICE, "Too old parent tuple found - can't continue repair_frag");
+ elog(WARNING, "Too old parent tuple found - can't continue repair_frag");
break;
}
#ifdef NOT_USED /* I'm not sure that this will wotk
* status bits. This is not really necessary, but will save time for
* future transactions examining these tuples.
*
- * XXX Notice that this code fails to clear HEAP_MOVED_OFF tuples from
+ * XXX WARNING that this code fails to clear HEAP_MOVED_OFF tuples from
* pages that were move source pages but not move dest pages. One
* also wonders whether it wouldn't be better to skip this step and
* let the tuple status updates happen someplace that's not holding an
{
if (stats->num_index_tuples > num_tuples ||
!vac_is_partial_index(indrel))
- elog(NOTICE, "Index %s: NUMBER OF INDEX' TUPLES (%.0f) IS NOT THE SAME AS HEAP' (%.0f).\
+ elog(WARNING, "Index %s: NUMBER OF INDEX' TUPLES (%.0f) IS NOT THE SAME AS HEAP' (%.0f).\
\n\tRecreate the index.",
RelationGetRelationName(indrel),
stats->num_index_tuples, num_tuples);
{
if (stats->num_index_tuples > num_tuples + keep_tuples ||
!vac_is_partial_index(indrel))
- elog(NOTICE, "Index %s: NUMBER OF INDEX' TUPLES (%.0f) IS NOT THE SAME AS HEAP' (%.0f).\
+ elog(WARNING, "Index %s: NUMBER OF INDEX' TUPLES (%.0f) IS NOT THE SAME AS HEAP' (%.0f).\
\n\tRecreate the index.",
RelationGetRelationName(indrel),
stats->num_index_tuples, num_tuples);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/vacuumlazy.c,v 1.12 2002/03/02 21:39:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/vacuumlazy.c,v 1.13 2002/03/06 06:09:38 momjian Exp $
*
*-------------------------------------------------------------------------
*/
elevel = INFO;
else
elevel = DEBUG1;
-
+
vacuum_set_xid_limits(vacstmt, onerel->rd_rel->relisshared,
&OldestXmin, &FreezeLimit);
LockBuffer(buf, BUFFER_LOCK_EXCLUSIVE);
if (PageIsNew(page))
{
- elog(NOTICE, "Rel %s: Uninitialized page %u - fixing",
+ elog(WARNING, "Rel %s: Uninitialized page %u - fixing",
relname, blkno);
PageInit(page, BufferGetPageSize(buf), 0);
lazy_record_free_space(vacrelstats, blkno,
*/
if (!OidIsValid(tuple.t_data->t_oid) &&
onerel->rd_rel->relhasoids)
- elog(NOTICE, "Rel %s: TID %u/%u: OID IS INVALID. TUPGONE %d.",
+ elog(WARNING, "Rel %s: TID %u/%u: OID IS INVALID. TUPGONE %d.",
relname, blkno, offnum, (int) tupgone);
if (tupgone)
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/variable.c,v 1.59 2002/03/02 21:39:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/variable.c,v 1.60 2002/03/06 06:09:39 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
if (dcnt > 1 || ecnt > 1)
- elog(NOTICE, "Conflicting settings for date");
+ elog(WARNING, "Conflicting settings for date");
return TRUE;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/execMain.c,v 1.151 2002/03/02 21:39:25 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/execMain.c,v 1.152 2002/03/06 06:09:42 momjian Exp $
*
*-------------------------------------------------------------------------
*/
*/
if (IsBootstrapProcessingMode())
{
- elog(NOTICE, "ExecReplace: replace can't run without transactions");
+ elog(WARNING, "ExecReplace: replace can't run without transactions");
return;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/nodeMergejoin.c,v 1.48 2002/03/01 04:09:22 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/nodeMergejoin.c,v 1.49 2002/03/06 06:09:43 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* just end the join prematurely.
*/
default:
- elog(NOTICE, "ExecMergeJoin: invalid join state %d, aborting",
+ elog(WARNING, "ExecMergeJoin: invalid join state %d, aborting",
mergestate->mj_JoinState);
return NULL;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/libpq/be-fsstubs.c,v 1.59 2001/06/13 21:44:41 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/libpq/be-fsstubs.c,v 1.60 2002/03/06 06:09:46 momjian Exp $
*
* NOTES
* This should be moved to a more appropriate place. It is here
MemoryContext currentContext;
#if FSDB
- elog(NOTICE, "lo_open(%u,%d)", lobjId, mode);
+ elog(DEBUG3, "lo_open(%u,%d)", lobjId, mode);
#endif
if (fscxt == NULL)
{ /* lookup failed */
MemoryContextSwitchTo(currentContext);
#if FSDB
- elog(NOTICE, "cannot open large object %u", lobjId);
+ elog(DEBUG3, "cannot open large object %u", lobjId);
#endif
PG_RETURN_INT32(-1);
}
PG_RETURN_INT32(-1);
}
#if FSDB
- elog(NOTICE, "lo_close(%d)", fd);
+ elog(DEBUG3, "lo_close(%d)", fd);
#endif
Assert(fscxt != NULL);
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Id: pqcomm.c,v 1.128 2002/03/04 01:46:03 tgl Exp $
+ * $Id: pqcomm.c,v 1.129 2002/03/06 06:09:47 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* If msgtype is '\0', then the buffer already includes the type code.
*
* All normal messages are suppressed while COPY OUT is in progress.
- * (In practice only NOTICE messages might get emitted then; dropping
+ * (In practice only a few messages might get emitted then; dropping
* them is annoying, but at least they will still appear in the
* postmaster log.)
*
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.112 2002/03/01 22:45:12 petere Exp $
+ * $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.113 2002/03/06 06:09:49 momjian Exp $
*
*-------------------------------------------------------------------------
*/
break;
default:
- elog(NOTICE, "equal: don't know whether nodes of type %d are equal",
+ elog(WARNING, "equal: don't know whether nodes of type %d are equal",
nodeTag(a));
break;
}
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Header: /cvsroot/pgsql/src/backend/nodes/outfuncs.c,v 1.147 2001/10/25 14:08:11 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/nodes/outfuncs.c,v 1.148 2002/03/06 06:09:49 momjian Exp $
*
* NOTES
* Every (plan) node in POSTGRES has an associated "out" routine which
appendStringInfo(str, " %s ", value->val.str);
break;
default:
- elog(NOTICE, "_outValue: don't know how to print type %d ",
+ elog(WARNING, "_outValue: don't know how to print type %d ",
value->type);
break;
}
break;
default:
- elog(NOTICE, "_outNode: don't know how to print type %d ",
+ elog(WARNING, "_outNode: don't know how to print type %d ",
nodeTag(obj));
break;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/path/clausesel.c,v 1.48 2001/11/05 17:46:25 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/path/clausesel.c,v 1.49 2002/03/06 06:09:50 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
#ifdef SELECTIVITY_DEBUG
- elog(NOTICE, "clause_selectivity: s1 %f", s1);
+ elog(DEBUG3, "clause_selectivity: s1 %f", s1);
#endif /* SELECTIVITY_DEBUG */
return s1;
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.216 2002/03/02 21:39:27 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.217 2002/03/06 06:09:51 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/*
* Note: we are not expecting that extras_before and extras_after
* are going to be used by the transformation of the SELECT statement.
- */
+ */
selectQuery = transformStmt(sub_pstate, stmt->selectStmt,
extras_before, extras_after);
sequence->istemp = cxt->istemp;
sequence->options = NIL;
- elog(INFO, "%s will create implicit sequence '%s' for SERIAL column '%s.%s'",
+ elog(NOTICE, "%s will create implicit sequence '%s' for SERIAL column '%s.%s'",
cxt->stmtType, sequence->seqname, cxt->relname, column->colname);
cxt->blist = lappend(cxt->blist, sequence);
* later. That would likely be cleaner, but
* too much work to contemplate right now.
* Instead, raise an error if the inherited
- * column won't be NOT NULL. (Would a NOTICE
+ * column won't be NOT NULL. (Would a WARNING
* be more reasonable?)
*/
if (constraint->contype == CONSTR_PRIMARY &&
/*
* Finally, select unique names for all not-previously-named indices,
- * and display notice messages.
+ * and display WARNING messages.
*
* XXX in ALTER TABLE case, we fail to consider name collisions against
* pre-existing indexes.
elog(ERROR, "%s: failed to make implicit index name",
cxt->stmtType);
- elog(INFO, "%s / %s%s will create implicit index '%s' for table '%s'",
+ elog(NOTICE, "%s / %s%s will create implicit index '%s' for table '%s'",
cxt->stmtType,
(strcmp(cxt->stmtType, "ALTER TABLE") == 0) ? "ADD " : "",
(index->primary ? "PRIMARY KEY" : "UNIQUE"),
if (cxt->fkconstraints == NIL)
return;
- elog(INFO, "%s will create implicit trigger(s) for FOREIGN KEY check(s)",
+ elog(NOTICE, "%s will create implicit trigger(s) for FOREIGN KEY check(s)",
cxt->stmtType);
foreach(fkclist, cxt->fkconstraints)
elog(ERROR, "unsupported expression in %%TYPE");
v = (Var *) n;
tyn = typeidTypeName(v->vartype);
- elog(INFO, "%s.%s%%TYPE converted to %s", tn->name, tn->attrname, tyn);
+ elog(NOTICE, "%s.%s%%TYPE converted to %s", tn->name, tn->attrname, tyn);
tn->name = tyn;
tn->typmod = v->vartypmod;
tn->attrname = NULL;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 2.284 2002/03/05 05:33:14 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 2.285 2002/03/06 06:09:53 momjian Exp $
*
* HISTORY
* AUTHOR DATE MAJOR EVENT
n->constraints = $3;
if ($4 != NULL)
- elog(INFO,"CREATE TABLE / COLLATE %s not yet implemented"
+ elog(NOTICE,"CREATE TABLE / COLLATE %s not yet implemented"
"; clause ignored", $4);
$$ = (Node *)n;
| RELATIVE { $$ = RELATIVE; }
| ABSOLUTE
{
- elog(INFO,"FETCH / ABSOLUTE not supported, using RELATIVE");
+ elog(NOTICE,"FETCH / ABSOLUTE not supported, using RELATIVE");
$$ = RELATIVE;
}
;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_node.c,v 1.57 2001/10/28 06:25:47 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_node.c,v 1.58 2002/03/06 06:09:54 momjian Exp $
*
*-------------------------------------------------------------------------
*/
break;
default:
- elog(NOTICE, "make_const: unknown type %d", nodeTag(value));
+ elog(WARNING, "make_const: unknown type %d", nodeTag(value));
/* FALLTHROUGH */
case T_Null:
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_relation.c,v 1.61 2002/03/02 21:39:28 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_relation.c,v 1.62 2002/03/06 06:09:55 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
}
if (foundInFromCl)
- elog(INFO, "Adding missing FROM-clause entry%s for table \"%s\"",
+ elog(NOTICE, "Adding missing FROM-clause entry%s for table \"%s\"",
pstate->parentParseState != NULL ? " in subquery" : "",
refname);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.90 2001/09/07 23:17:14 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.91 2002/03/06 06:09:56 momjian Exp $
*
*-------------------------------------------------------------------------
*/
#ifdef MULTIBYTE
int len;
len = pg_mbcliplen(literalbuf,strlen(literalbuf),NAMEDATALEN-1);
- elog(NOTICE, "identifier \"%s\" will be truncated to \"%.*s\"",
+ elog(WARNING, "identifier \"%s\" will be truncated to \"%.*s\"",
literalbuf, len, literalbuf);
literalbuf[len] = '\0';
#else
- elog(NOTICE, "identifier \"%s\" will be truncated to \"%.*s\"",
+ elog(WARNING, "identifier \"%s\" will be truncated to \"%.*s\"",
literalbuf, NAMEDATALEN-1, literalbuf);
literalbuf[NAMEDATALEN-1] = '\0';
#endif
#ifdef MULTIBYTE
int len;
len = pg_mbcliplen(yytext,i,NAMEDATALEN-1);
- elog(NOTICE, "identifier \"%s\" will be truncated to \"%.*s\"",
+ elog(WARNING, "identifier \"%s\" will be truncated to \"%.*s\"",
yytext, len, yytext);
yytext[len] = '\0';
#else
- elog(NOTICE, "identifier \"%s\" will be truncated to \"%.*s\"",
+ elog(WARNING, "identifier \"%s\" will be truncated to \"%.*s\"",
yytext, NAMEDATALEN-1, yytext);
yytext[NAMEDATALEN-1] = '\0';
#endif
if ((beos_dl_port_in <= 0) || (beos_dl_port_out <= 0))
{
- elog(NOTICE, "Error loading BeOS support server : can't create communication ports");
+ elog(WARNING, "Error loading BeOS support server : can't create communication ports");
return B_ERROR;
}
else
/* Checking integrity */
if (im < 0)
{
- elog(NOTICE, "Can't load this add-on ");
+ elog(WARNING, "Can't load this add-on ");
return B_ERROR;
}
else
/* Remap */
resu = clone_area(datas, &add, B_EXACT_ADDRESS, B_READ_AREA | B_WRITE_AREA, area);
if (resu < 0)
- elog(NOTICE, "Can't load this add-on : map text error");
+ elog(WARNING, "Can't load this add-on : map text error");
}
/* read text segment id and address */
/* Remap */
resu = clone_area(datas, &add, B_EXACT_ADDRESS, B_READ_AREA | B_WRITE_AREA, area);
if (resu < 0)
- elog(NOTICE, "Can't load this add-on : map data error");
+ elog(WARNING, "Can't load this add-on : map data error");
}
return im;
read_port(beos_dl_port_out, (int32 *) (fptr), NULL, 0);
if (fptr == NULL)
- elog(NOTICE, "loading symbol '%s' failed ", symname);
+ elog(WARNING, "loading symbol '%s' failed ", symname);
}
status_t
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/port/dynloader/Attic/beos.c,v 1.9 2001/10/25 05:49:40 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/port/dynloader/Attic/beos.c,v 1.10 2002/03/06 06:09:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
beos_dl_sym(*((int *) (handle)), funcname, (void **) &fpt);
return fpt;
}
- elog(NOTICE, "add-on not loaded correctly");
+ elog(WARNING, "add-on not loaded correctly");
return NULL;
}
if ((handle) && ((*(int *) (handle)) >= 0))
{
if (beos_dl_close(*(image_id *) handle) != B_OK)
- elog(NOTICE, "error while unloading add-on");
+ elog(WARNING, "error while unloading add-on");
free(handle);
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/port/dynloader/bsdi.c,v 1.18 2001/11/05 17:46:27 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/port/dynloader/bsdi.c,v 1.19 2002/03/06 06:09:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
if (dld_link("/usr/lib/libc.a"))
{
- elog(NOTICE, "dld: Cannot link C library!");
+ elog(WARNING, "dld: Cannot link C library!");
return NULL;
}
if (dld_undefined_sym_count > 0)
{
if (dld_link("/usr/lib/libm.a"))
{
- elog(NOTICE, "dld: Cannot link math library!");
+ elog(WARNING, "dld: Cannot link math library!");
return NULL;
}
if (dld_undefined_sym_count > 0)
char **list = dld_list_undefined_sym();
/* list the undefined symbols, if any */
- elog(NOTICE, "dld: Undefined:");
+ elog(WARNING, "dld: Undefined:");
do
{
- elog(NOTICE, " %s", *list);
+ elog(WARNING, " %s", *list);
list++;
count--;
} while (count > 0);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/port/dynloader/linux.c,v 1.20 2001/10/28 06:25:47 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/port/dynloader/linux.c,v 1.21 2002/03/06 06:09:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
if (dld_link("/usr/lib/libc.a"))
{
- elog(NOTICE, "dld: Cannot link C library!");
+ elog(WARNING, "dld: Cannot link C library!");
return NULL;
}
if (dld_undefined_sym_count > 0)
{
if (dld_link("/usr/lib/libm.a"))
{
- elog(NOTICE, "dld: Cannot link math library!");
+ elog(WARNING, "dld: Cannot link math library!");
return NULL;
}
if (dld_undefined_sym_count > 0)
char **list = dld_list_undefined_sym();
/* list the undefined symbols, if any */
- elog(NOTICE, "dld: Undefined:");
+ elog(WARNING, "dld: Undefined:");
do
{
- elog(NOTICE, " %s", *list);
+ elog(WARNING, " %s", *list);
list++;
count--;
} while (count > 0);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/port/dynloader/ultrix4.c,v 1.13 2001/02/10 02:31:26 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/port/dynloader/ultrix4.c,v 1.14 2002/03/06 06:09:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/* list the undefined symbols, if any */
if (count)
{
- elog(NOTICE, "dl: Undefined:");
+ elog(WARNING, "dl: Undefined:");
while (*list)
{
- elog(NOTICE, " %s", *list);
+ elog(WARNING, " %s", *list);
list++;
}
}
*
* Copyright (c) 2001, PostgreSQL Global Development Group
*
- * $Header: /cvsroot/pgsql/src/backend/postmaster/pgstat.c,v 1.17 2002/02/07 22:20:26 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/postmaster/pgstat.c,v 1.18 2002/03/06 06:10:00 momjian Exp $
* ----------
*/
#include "postgres.h"
}
else
{
- elog(NOTICE,
+ elog(WARNING,
"PGSTAT: corrupted pgstat.stat file");
fclose(fpin);
return;
}
else
{
- elog(NOTICE,
+ elog(WARNING,
"PGSTAT: corrupted pgstat.stat file");
fclose(fpin);
return;
}
else
{
- elog(NOTICE,
+ elog(WARNING,
"PGSTAT: corrupted pgstat.stat file");
fclose(fpin);
return;
}
else
{
- elog(NOTICE,
+ elog(WARNING,
"PGSTAT: corrupted pgstat.stat file");
fclose(fpin);
return;
}
else
{
- elog(NOTICE,
+ elog(WARNING,
"PGSTAT: corrupted pgstat.stat file");
fclose(fpin);
return;
}
else
{
- elog(NOTICE,
+ elog(WARNING,
"PGSTAT: corrupted pgstat.stat file");
fclose(fpin);
return;
}
else
{
- elog(NOTICE, "PGSTAT: corrupted pgstat.stat file");
+ elog(WARNING, "PGSTAT: corrupted pgstat.stat file");
fclose(fpin);
return;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/buffer/bufmgr.c,v 1.121 2002/03/02 21:39:28 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/buffer/bufmgr.c,v 1.122 2002/03/06 06:10:02 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (smok == FALSE)
{
- elog(NOTICE, "BufferAlloc: cannot write block %u for %u/%u",
+ elog(WARNING, "BufferAlloc: cannot write block %u for %u/%u",
buf->tag.blockNum,
buf->tag.rnode.tblNode, buf->tag.rnode.relNode);
inProgress = FALSE;
{
BufferDesc *buf = &(BufferDescriptors[i]);
- elog(NOTICE,
+ elog(WARNING,
"Buffer Leak: [%03d] (freeNext=%d, freePrev=%d, \
rel=%u/%u, blockNum=%u, flags=0x%x, refcount=%d %ld)",
i, buf->freeNext, buf->freePrev,
for (i = 0; i < NBuffers; ++i, ++buf)
{
if (PrivateRefCount[i] > 0)
- elog(NOTICE, "[%02d] (freeNext=%d, freePrev=%d, rel=%u/%u, \
+ elog(WARNING, "[%02d] (freeNext=%d, freePrev=%d, rel=%u/%u, \
blockNum=%u, flags=0x%x, refcount=%d %ld)",
i, buf->freeNext, buf->freePrev,
buf->tag.rnode.tblNode, buf->tag.rnode.relNode,
(char *) MAKE_PTR(bufHdr->data));
if (status == SM_FAIL)
{
- elog(NOTICE, "FlushRelationBuffers(%s (local), %u): block %u is dirty, could not flush it",
+ elog(WARNING, "FlushRelationBuffers(%s (local), %u): block %u is dirty, could not flush it",
RelationGetRelationName(rel), firstDelBlock,
bufHdr->tag.blockNum);
return (-1);
}
if (LocalRefCount[i] > 0)
{
- elog(NOTICE, "FlushRelationBuffers(%s (local), %u): block %u is referenced (%ld)",
+ elog(WARNING, "FlushRelationBuffers(%s (local), %u): block %u is referenced (%ld)",
RelationGetRelationName(rel), firstDelBlock,
bufHdr->tag.blockNum, LocalRefCount[i]);
return (-2);
if (!(bufHdr->flags & BM_FREE))
{
LWLockRelease(BufMgrLock);
- elog(NOTICE, "FlushRelationBuffers(%s, %u): block %u is referenced (private %ld, global %d)",
+ elog(WARNING, "FlushRelationBuffers(%s, %u): block %u is referenced (private %ld, global %d)",
RelationGetRelationName(rel), firstDelBlock,
bufHdr->tag.blockNum,
PrivateRefCount[i], bufHdr->refcount);
/* Issue notice if this is not the first failure... */
if (buf->flags & BM_IO_ERROR)
{
- elog(NOTICE, "write error may be permanent: cannot write block %u for %u/%u",
+ elog(WARNING, "write error may be permanent: cannot write block %u for %u/%u",
buf->tag.blockNum,
buf->tag.rnode.tblNode, buf->tag.rnode.relNode);
}
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/file/fd.c,v 1.89 2002/03/02 21:39:29 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/file/fd.c,v 1.90 2002/03/06 06:10:03 momjian Exp $
*
* NOTES:
*
}
}
if (i < 0)
- elog(NOTICE, "FreeFile: file was not obtained from AllocateFile");
+ elog(WARNING, "FreeFile: file was not obtained from AllocateFile");
fclose(file);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipc.c,v 1.76 2002/03/02 21:39:29 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipc.c,v 1.77 2002/03/06 06:10:05 momjian Exp $
*
* NOTES
*
semId, strerror(errno));
/*
- * We used to report a failure via elog(NOTICE), but that's pretty
+ * We used to report a failure via elog(WARNING), but that's pretty
* pointless considering any client has long since disconnected ...
*/
}
DatumGetPointer(shmaddr), strerror(errno));
/*
- * We used to report a failure via elog(NOTICE), but that's pretty
+ * We used to report a failure via elog(WARNING), but that's pretty
* pointless considering any client has long since disconnected ...
*/
}
DatumGetInt32(shmId), IPC_RMID, strerror(errno));
/*
- * We used to report a failure via elog(NOTICE), but that's pretty
+ * We used to report a failure via elog(WARNING), but that's pretty
* pointless considering any client has long since disconnected ...
*/
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmem.c,v 1.63 2001/12/28 18:16:43 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmem.c,v 1.64 2002/03/06 06:10:05 momjian Exp $
*
*-------------------------------------------------------------------------
*/
SpinLockRelease(ShmemLock);
if (!newSpace)
- elog(NOTICE, "ShmemAlloc: out of memory");
+ elog(WARNING, "ShmemAlloc: out of memory");
return newSpace;
}
{
LWLockRelease(ShmemIndexLock);
- elog(NOTICE, "ShmemInitStruct: ShmemIndex entry size is wrong");
+ elog(WARNING, "ShmemInitStruct: ShmemIndex entry size is wrong");
/* let caller print its message too */
return NULL;
}
hash_search(ShmemIndex, (void *) &item, HASH_REMOVE, NULL);
LWLockRelease(ShmemIndexLock);
- elog(NOTICE, "ShmemInitStruct: cannot allocate '%s'",
+ elog(WARNING, "ShmemInitStruct: cannot allocate '%s'",
name);
*foundPtr = FALSE;
return NULL;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmqueue.c,v 1.19 2001/11/05 17:46:28 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmqueue.c,v 1.20 2002/03/06 06:10:06 momjian Exp $
*
* NOTES
*
/*#define SHMQUEUE_DEBUG*/
#ifdef SHMQUEUE_DEBUG
-#define SHMQUEUE_DEBUG_ELOG NOTICE
+#define SHMQUEUE_DEBUG_ELOG WARNING
static void dumpQ(SHM_QUEUE *q, char *s);
#endif
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.105 2002/03/02 21:39:29 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.106 2002/03/06 06:10:06 momjian Exp $
*
* NOTES
* Outside modules can create a lock table and acquire/release
if (numModes >= MAX_LOCKMODES)
{
- elog(NOTICE, "LockMethodTableInit: too many lock types %d greater than %d",
+ elog(WARNING, "LockMethodTableInit: too many lock types %d greater than %d",
numModes, MAX_LOCKMODES);
return INVALID_LOCKMETHOD;
}
lockMethodTable = LockMethodTable[lockmethod];
if (!lockMethodTable)
{
- elog(NOTICE, "LockAcquire: bad lock table %d", lockmethod);
+ elog(WARNING, "LockAcquire: bad lock table %d", lockmethod);
return FALSE;
}
(void *) holder,
HASH_REMOVE, NULL);
if (!holder)
- elog(NOTICE, "LockAcquire: remove holder, table corrupted");
+ elog(WARNING, "LockAcquire: remove holder, table corrupted");
}
else
HOLDER_PRINT("LockAcquire: NHOLDING", holder);
lockMethodTable = LockMethodTable[lockmethod];
if (!lockMethodTable)
{
- elog(NOTICE, "lockMethodTable is null in LockRelease");
+ elog(WARNING, "lockMethodTable is null in LockRelease");
return FALSE;
}
if (!lock)
{
LWLockRelease(masterLock);
- elog(NOTICE, "LockRelease: no such lock");
+ elog(WARNING, "LockRelease: no such lock");
return FALSE;
}
LOCK_PRINT("LockRelease: found", lock, lockmode);
LWLockRelease(masterLock);
#ifdef USER_LOCKS
if (lockmethod == USER_LOCKMETHOD)
- elog(NOTICE, "LockRelease: no lock with this tag");
+ elog(WARNING, "LockRelease: no lock with this tag");
else
#endif
- elog(NOTICE, "LockRelease: holder table corrupted");
+ elog(WARNING, "LockRelease: holder table corrupted");
return FALSE;
}
HOLDER_PRINT("LockRelease: found", holder);
HOLDER_PRINT("LockRelease: WRONGTYPE", holder);
Assert(holder->holding[lockmode] >= 0);
LWLockRelease(masterLock);
- elog(NOTICE, "LockRelease: you don't own a lock of type %s",
+ elog(WARNING, "LockRelease: you don't own a lock of type %s",
lock_mode_names[lockmode]);
return FALSE;
}
if (!lock)
{
LWLockRelease(masterLock);
- elog(NOTICE, "LockRelease: remove lock, table corrupted");
+ elog(WARNING, "LockRelease: remove lock, table corrupted");
return FALSE;
}
wakeupNeeded = false; /* should be false, but make sure */
if (!holder)
{
LWLockRelease(masterLock);
- elog(NOTICE, "LockRelease: remove holder, table corrupted");
+ elog(WARNING, "LockRelease: remove holder, table corrupted");
return FALSE;
}
}
lockMethodTable = LockMethodTable[lockmethod];
if (!lockMethodTable)
{
- elog(NOTICE, "LockReleaseAll: bad lockmethod %d", lockmethod);
+ elog(WARNING, "LockReleaseAll: bad lockmethod %d", lockmethod);
return FALSE;
}
if (!holder)
{
LWLockRelease(masterLock);
- elog(NOTICE, "LockReleaseAll: holder table corrupted");
+ elog(WARNING, "LockReleaseAll: holder table corrupted");
return FALSE;
}
if (!lock)
{
LWLockRelease(masterLock);
- elog(NOTICE, "LockReleaseAll: cannot remove lock from HTAB");
+ elog(WARNING, "LockReleaseAll: cannot remove lock from HTAB");
return FALSE;
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/page/bufpage.c,v 1.43 2002/01/30 19:34:55 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/page/bufpage.c,v 1.44 2002/03/06 06:10:07 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
if (offsetNumber > limit)
{
- elog(NOTICE, "PageAddItem: tried overwrite after maxoff");
+ elog(WARNING, "PageAddItem: tried overwrite after maxoff");
return InvalidOffsetNumber;
}
if (offsetNumber < limit)
if (((*itemId).lp_flags & LP_USED) ||
((*itemId).lp_len != 0))
{
- elog(NOTICE, "PageAddItem: tried overwrite of used ItemId");
+ elog(WARNING, "PageAddItem: tried overwrite of used ItemId");
return InvalidOffsetNumber;
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/smgr/smgr.c,v 1.55 2002/03/02 21:39:30 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/smgr/smgr.c,v 1.56 2002/03/06 06:10:08 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/*
* And delete the physical files.
*
- * Note: we treat deletion failure as a NOTICE, not an error,
+ * Note: we treat deletion failure as a WARNING, not an error,
* because we've already decided to commit or abort the
* current xact.
*/
if ((*(smgrsw[pending->which].smgr_unlink)) (pending->relnode) == SM_FAIL)
- elog(NOTICE, "cannot unlink %u/%u: %m",
+ elog(WARNING, "cannot unlink %u/%u: %m",
pending->relnode.tblNode, pending->relnode.relNode);
}
pfree(pending);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.253 2002/03/04 01:46:03 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.254 2002/03/06 06:10:09 momjian Exp $
*
* NOTES
* this is the "main" module of the postgres backend and
new_list = (List *) copyObject(querytree_list);
/* This checks both copyObject() and the equal() routines... */
if (!equal(new_list, querytree_list))
- elog(NOTICE, "pg_analyze_and_rewrite: copyObject failed on parse tree");
+ elog(WARNING, "pg_analyze_and_rewrite: copyObject failed on parse tree");
else
querytree_list = new_list;
#endif
#ifdef NOT_USED
/* This checks both copyObject() and the equal() routines... */
if (!equal(new_plan, plan))
- elog(NOTICE, "pg_plan_query: copyObject failed on plan tree");
+ elog(WARNING, "pg_plan_query: copyObject failed on plan tree");
else
#endif
plan = new_plan;
if (!allowit)
{
- elog(NOTICE, "current transaction is aborted, "
+ elog(WARNING, "current transaction is aborted, "
"queries ignored until end of transaction block");
/*
quickdie(SIGNAL_ARGS)
{
PG_SETMASK(&BlockSig);
- elog(NOTICE, "Message from PostgreSQL backend:"
+ elog(WARNING, "Message from PostgreSQL backend:"
"\n\tThe Postmaster has informed me that some other backend"
"\n\tdied abnormally and possibly corrupted shared memory."
"\n\tI have rolled back the current transaction and am"
#ifdef USE_ASSERT_CHECKING
SetConfigOption("debug_assertions", optarg, ctx, gucsource);
#else
- elog(NOTICE, "Assert checking is not compiled in");
+ elog(WARNING, "Assert checking is not compiled in");
#endif
break;
*/
if (XfuncMode != 0)
{
- elog(NOTICE, "only one -x flag is allowed");
+ elog(WARNING, "only one -x flag is allowed");
errs++;
break;
}
XfuncMode = XFUNC_WAIT;
else
{
- elog(NOTICE, "use -x {off,nor,nopull,nopm,pullall,wait}");
+ elog(WARNING, "use -x {off,nor,nopull,nopm,pullall,wait}");
errs++;
}
#endif
if (Show_query_stats &&
(Show_parser_stats || Show_planner_stats || Show_executor_stats))
{
- elog(NOTICE, "Query statistics are disabled because parser, planner, or executor statistics are on.");
+ elog(WARNING, "Query statistics are disabled because parser, planner, or executor statistics are on.");
SetConfigOption("show_query_stats", "false", ctx, gucsource);
}
/* noninteractive case: nothing should be left after switches */
if (errs || argc != optind || DBName == NULL)
{
- elog(NOTICE, "%s: invalid command line arguments\nTry -? for help.",
+ elog(WARNING, "%s: invalid command line arguments\nTry -? for help.",
argv[0]);
proc_exit(0); /* not 1, that causes system-wide
* restart... */
/* interactive case: database name can be last arg on command line */
if (errs || argc - optind > 1)
{
- elog(NOTICE, "%s: invalid command line arguments\nTry -? for help.",
+ elog(WARNING, "%s: invalid command line arguments\nTry -? for help.",
argv[0]);
proc_exit(1);
}
DBName = argv[optind];
else if ((DBName = username) == NULL)
{
- elog(NOTICE, "%s: user name undefined and no database specified",
+ elog(WARNING, "%s: user name undefined and no database specified",
argv[0]);
proc_exit(1);
}
if (!IsUnderPostmaster)
{
puts("\nPOSTGRES backend interactive interface ");
- puts("$Revision: 1.253 $ $Date: 2002/03/04 01:46:03 $\n");
+ puts("$Revision: 1.254 $ $Date: 2002/03/06 06:10:09 $\n");
}
/*
if (assert_enabled)
{
/* val != 0 should be trapped by previous Assert */
- elog(INFO, "Assert test successful (val = %d)", val);
+ elog(DEBUG3, "Assert test successful (val = %d)", val);
}
else
- elog(INFO, "Assert checking is disabled (val = %d)", val);
+ elog(DEBUG3, "Assert checking is disabled (val = %d)", val);
return val;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.49 2002/02/27 19:52:41 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.50 2002/03/06 06:10:10 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* XXX Should we raise an error rather than closing the old
* portal?
*/
- elog(NOTICE, "Closing pre-existing portal \"%s\"",
+ elog(WARNING, "Closing pre-existing portal \"%s\"",
portalName);
PortalDrop(portal);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tioga/Attic/tgRecipe.c,v 1.20 2001/10/25 05:49:43 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tioga/Attic/tgRecipe.c,v 1.21 2002/03/06 06:10:11 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (*str != ARRAY_LEFT_DELIM)
{
- elog(NOTICE, "TextArray2ArrTgString: badly formed string, must have %c as \
+ elog(WARNING, "TextArray2ArrTgString: badly formed string, must have %c as \
first character\n", ARRAY_LEFT_DELIM);
return result;
}
{
if (*str == '\0')
{
- elog(NOTICE, "TextArray2ArrTgString: text string ended prematurely\n");
+ elog(WARNING, "TextArray2ArrTgString: text string ended prematurely\n");
return result;
}
if ((beginQuote = strchr(str, ARRAY_ELEM_LEFT)) == NULL)
{
- elog(NOTICE, "textArray2ArrTgString: missing a begin quote\n");
+ elog(WARNING, "textArray2ArrTgString: missing a begin quote\n");
return result;
}
if ((endQuote = strchr(beginQuote + 1, '"')) == NULL)
{
- elog(NOTICE, "textArray2ArrTgString: missing an end quote\n");
+ elog(WARNING, "textArray2ArrTgString: missing an end quote\n");
return result;
}
nextlen = endQuote - beginQuote; /* don't subtract one here
if (strcmp(e->elemName, elemName) == 0)
return e;
}
- elog(NOTICE, "Element named %s not found in recipe named %s", elemName, r->elmValue.elemName);
+ elog(WARNING, "Element named %s not found in recipe named %s", elemName, r->elmValue.elemName);
return NULL;
}
if (strcmp(n->nodeName, nodeName) == 0)
return n;
}
- elog(NOTICE, "Node named %s not found in recipe named %s", nodeName, r->elmValue.elemName);
+ elog(WARNING, "Node named %s not found in recipe named %s", nodeName, r->elmValue.elemName);
return NULL;
}
else if (strcmp(nodeType, "Recipe") == 0)
node->nodeType = TG_RECIPE_NODE;
else
- elog(NOTICE, "fillTgNode: unknown nodeType field value : %s\n", nodeType);
+ elog(WARNING, "fillTgNode: unknown nodeType field value : %s\n", nodeType);
}
else if (strcmp(srcLang, "Compiled") == 0)
elem->srcLang = TG_COMPILED;
else
- elog(NOTICE, "fillTgElement(): unknown srcLang field value : %s\n", srcLang);
+ elog(WARNING, "fillTgElement(): unknown srcLang field value : %s\n", srcLang);
elemType = PQgetvalue(pbuf, tupno, elemType_attnum);
if (strcmp(elemType, "Ingred") == 0)
else if (strcmp(elemType, "Recipe") == 0)
elem->elemType = TG_RECIPE;
else
- elog(NOTICE, "fillTgElement(): unknown elemType field value : %s\n", elemType);
+ elog(WARNING, "fillTgElement(): unknown elemType field value : %s\n", elemType);
}
pqres = PQexec(qbuf);
if (*pqres == 'R' || *pqres == 'E')
{
- elog(NOTICE, "lookupEdges(): Error while executing query : %s\n", qbuf);
- elog(NOTICE, "result = %s, error is %s\n", pqres, PQerrormsg);
+ elog(WARNING, "lookupEdges(): Error while executing query : %s\n", qbuf);
+ elog(WARNING, "result = %s, error is %s\n", pqres, PQerrormsg);
return;
}
pbufname = ++pqres;
if (!fromPortStr || fromPortStr[0] == '\0')
{
- elog(NOTICE, "lookupEdges(): SANITY CHECK failed. Edge with invalid fromPort value!");
+ elog(WARNING, "lookupEdges(): SANITY CHECK failed. Edge with invalid fromPort value!");
return;
}
if (!toPortStr || toPortStr[0] == '\0')
{
- elog(NOTICE, "lookupEdges(): SANITY CHECK failed. Edge with invalid toPort value!!");
+ elog(WARNING, "lookupEdges(): SANITY CHECK failed. Edge with invalid toPort value!!");
return;
}
fromPort = atoi(fromPortStr);
fromNodePtr = findNodeInRecipe(r, fromNode);
if (!fromNodePtr)
{
- elog(NOTICE, "lookupEdges(): SANITY CHECK failed. Edge with bad fromNode value!");
+ elog(WARNING, "lookupEdges(): SANITY CHECK failed. Edge with bad fromNode value!");
return;
}
toNodePtr = findNodeInRecipe(r, toNode);
if (!toNodePtr)
{
- elog(NOTICE, "lookupEdges(): SANITY CHECK failed. Edge with bad toNode value!");
+ elog(WARNING, "lookupEdges(): SANITY CHECK failed. Edge with bad toNode value!");
return;
}
if (origToNode == NULL)
{
- elog(NOTICE, "Internal Error: connectTee() called with a null origToNode");
+ elog(WARNING, "Internal Error: connectTee() called with a null origToNode");
return;
}
pqres = PQexec(qbuf);
if (*pqres == 'R' || *pqres == 'E')
{
- elog(NOTICE, "fillAllNodes(): Error while executing query : %s\n", qbuf);
- elog(NOTICE, "result = %s, error is %s\n", pqres, PQerrormsg);
+ elog(WARNING, "fillAllNodes(): Error while executing query : %s\n", qbuf);
+ elog(WARNING, "result = %s, error is %s\n", pqres, PQerrormsg);
return;
}
pbufname = ++pqres;
pqres = PQexec(qbuf);
if (*pqres == 'R' || *pqres == 'E')
{
- elog(NOTICE, "fillAllNodes(): Error while executing query : %s\n", qbuf);
- elog(NOTICE, "result = %s, error is %s\n", pqres, PQerrormsg);
+ elog(WARNING, "fillAllNodes(): Error while executing query : %s\n", qbuf);
+ elog(WARNING, "result = %s, error is %s\n", pqres, PQerrormsg);
return;
}
pbufname = ++pqres;
pqres = PQexec(qbuf);
if (*pqres == 'R' || *pqres == 'E')
{
- elog(NOTICE, "fillAllElements(): Error while executing query : %s\n", qbuf);
- elog(NOTICE, "result = %s, error is %s\n", pqres, PQerrormsg);
+ elog(WARNING, "fillAllElements(): Error while executing query : %s\n", qbuf);
+ elog(WARNING, "result = %s, error is %s\n", pqres, PQerrormsg);
return;
}
pbufname = ++pqres;
pqres = PQexec(qbuf);
if (*pqres == 'R' || *pqres == 'E')
{
- elog(NOTICE, "retrieveRecipe: Error while executing query : %s\n", qbuf);
- elog(NOTICE, "result = %s, error is %s\n", pqres, PQerrormsg);
+ elog(WARNING, "retrieveRecipe: Error while executing query : %s\n", qbuf);
+ elog(WARNING, "result = %s, error is %s\n", pqres, PQerrormsg);
return NULL;
}
pbufname = ++pqres;
ntups = PQntuplesGroup(pbuf, 0);
if (ntups == 0)
{
- elog(NOTICE, "retrieveRecipe(): No recipe named %s exists\n", name);
+ elog(WARNING, "retrieveRecipe(): No recipe named %s exists\n", name);
return NULL;
}
if (ntups != 1)
{
- elog(NOTICE, "retrieveRecipe(): Multiple (%d) recipes named %s exists\n", ntups, name);
+ elog(WARNING, "retrieveRecipe(): Multiple (%d) recipes named %s exists\n", ntups, name);
return NULL;
}
/* -----------------------------------------------------------------------
* formatting.c
*
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/formatting.c,v 1.50 2002/02/18 14:24:35 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/formatting.c,v 1.51 2002/03/06 06:10:12 momjian Exp $
*
*
* Portions Copyright (c) 1999-2000, PostgreSQL Global Development Group
*/
/***
#define DEBUG_TO_FROM_CHAR
-#define DEBUG_elog_output NOTICE
+#define DEBUG_elog_output DEBUG3
***/
#include "postgres.h"
x == 2 ? 10 : 1;
/*
- * elog(NOTICE, "X: %d, MS: %d, LEN: %d", x, tmfc->ms,
+ * elog(DEBUG3, "X: %d, MS: %d, LEN: %d", x, tmfc->ms,
* len);
*/
return len - 1 + SKIP_THth(suf);
x == 5 ? 10 : 1;
/*
- * elog(NOTICE, "X: %d, US: %d, LEN: %d", x, tmfc->us,
+ * elog(DEBUG3, "X: %d, US: %d, LEN: %d", x, tmfc->us,
* len);
*/
return len - 1 + SKIP_THth(suf);
else if (flag == FROM_CHAR)
{
sscanf(inout, "%03d", &tmfc->year);
-
+
/*
* 3-digit year:
* '100' ... '999' = 1100 ... 1999
* 2-digit year:
* '00' ... '69' = 2000 ... 2069
* '70' ... '99' = 1970 ... 1999
- */
+ */
if (tmfc->year < 70)
tmfc->year += 2000;
else
else if (flag == FROM_CHAR)
{
sscanf(inout, "%1d", &tmfc->year);
-
+
/*
* 1-digit year: always +2000
*/
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/nabstime.c,v 1.91 2001/10/25 05:49:44 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/nabstime.c,v 1.92 2002/03/06 06:10:13 momjian Exp $
*
* NOTES
*
*/
StrNCpy(*tzn, tm->tm_zone, MAXTZLEN + 1);
if (strlen(tm->tm_zone) > MAXTZLEN)
- elog(NOTICE, "Invalid timezone \'%s\'", tm->tm_zone);
+ elog(WARNING, "Invalid timezone \'%s\'", tm->tm_zone);
}
}
}
*/
StrNCpy(*tzn, tzname[tm->tm_isdst], MAXTZLEN + 1);
if (strlen(tzname[tm->tm_isdst]) > MAXTZLEN)
- elog(NOTICE, "Invalid timezone \'%s\'", tzname[tm->tm_isdst]);
+ elog(WARNING, "Invalid timezone \'%s\'", tzname[tm->tm_isdst]);
}
}
}
* The PostgreSQL locale utils.
*
*
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/pg_locale.c,v 1.14 2002/03/02 21:39:32 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/pg_locale.c,v 1.15 2002/03/06 06:10:14 momjian Exp $
*
* Portions Copyright (c) 1999-2000, PostgreSQL Global Development Group
*
PGLC_setlocale(PG_LocaleCategories *lc)
{
if (!setlocale(LC_COLLATE, lc->lc_collate))
- elog(NOTICE, "pg_setlocale(): 'LC_COLLATE=%s' cannot be honored.",
+ elog(WARNING, "pg_setlocale(): 'LC_COLLATE=%s' cannot be honored.",
lc->lc_collate);
if (!setlocale(LC_CTYPE, lc->lc_ctype))
- elog(NOTICE, "pg_setlocale(): 'LC_CTYPE=%s' cannot be honored.",
+ elog(WARNING, "pg_setlocale(): 'LC_CTYPE=%s' cannot be honored.",
lc->lc_ctype);
if (!setlocale(LC_NUMERIC, lc->lc_numeric))
- elog(NOTICE, "pg_setlocale(): 'LC_NUMERIC=%s' cannot be honored.",
+ elog(WARNING, "pg_setlocale(): 'LC_NUMERIC=%s' cannot be honored.",
lc->lc_numeric);
if (!setlocale(LC_TIME, lc->lc_time))
- elog(NOTICE, "pg_setlocale(): 'LC_TIME=%s' cannot be honored.",
+ elog(WARNING, "pg_setlocale(): 'LC_TIME=%s' cannot be honored.",
lc->lc_time);
if (!setlocale(LC_MONETARY, lc->lc_monetary))
- elog(NOTICE, "pg_setlocale(): 'LC_MONETARY=%s' cannot be honored.",
+ elog(WARNING, "pg_setlocale(): 'LC_MONETARY=%s' cannot be honored.",
lc->lc_monetary);
#ifdef LC_MESSAGES
if (!setlocale(LC_MESSAGES, lc->lc_messages))
- elog(NOTICE, "pg_setlocale(): 'LC_MESSAGES=%s' cannot be honored.",
+ elog(WARNING, "pg_setlocale(): 'LC_MESSAGES=%s' cannot be honored.",
lc->lc_messages);
#endif
}
* Portions Copyright (c) 2000-2001, PostgreSQL Global Development Group
* Copyright 1999 Jan Wieck
*
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/ri_triggers.c,v 1.31 2001/11/12 06:09:09 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/ri_triggers.c,v 1.32 2002/03/06 06:10:14 momjian Exp $
*
* ----------
*/
* Execute the plan
*/
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_check()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_check()");
SetUserId(RelationGetForm(pk_rel)->relowner);
/* pk_rel is no longer neede OK ? */
tgargs[RI_PK_RELNAME_ARGNO]);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_check()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_check()");
return PointerGetDatum(NULL);
* to see it).
*/
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_check()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_check()");
/*
* Fetch or prepare a saved plan for the real check
tgargs[RI_PK_RELNAME_ARGNO]);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_check()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_check()");
return PointerGetDatum(NULL);
heap_close(fk_rel, NoLock);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_noaction_del()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_noaction_del()");
/*
* Fetch or prepare a saved plan for the restrict delete
tgargs[RI_FK_RELNAME_ARGNO]);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_noaction_del()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_noaction_del()");
return PointerGetDatum(NULL);
return PointerGetDatum(NULL);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_noaction_upd()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_noaction_upd()");
/*
* Fetch or prepare a saved plan for the noaction update
tgargs[RI_FK_RELNAME_ARGNO]);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_noaction_upd()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_noaction_upd()");
return PointerGetDatum(NULL);
heap_close(fk_rel, NoLock);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_cascade_del()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_cascade_del()");
/*
* Fetch or prepare a saved plan for the cascaded delete
SetUserId(save_uid);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_cascade_del()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_cascade_del()");
return PointerGetDatum(NULL);
return PointerGetDatum(NULL);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_cascade_upd()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_cascade_upd()");
/*
* Fetch or prepare a saved plan for the cascaded update of
SetUserId(save_uid);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_cascade_upd()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_cascade_upd()");
return PointerGetDatum(NULL);
heap_close(fk_rel, NoLock);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_restrict_del()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_restrict_del()");
/*
* Fetch or prepare a saved plan for the restrict delete
tgargs[RI_FK_RELNAME_ARGNO]);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_restrict_del()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_restrict_del()");
return PointerGetDatum(NULL);
return PointerGetDatum(NULL);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_restrict_upd()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_restrict_upd()");
/*
* Fetch or prepare a saved plan for the restrict update
tgargs[RI_FK_RELNAME_ARGNO]);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_restrict_upd()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_restrict_upd()");
return PointerGetDatum(NULL);
heap_close(fk_rel, NoLock);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_setnull_del()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_setnull_del()");
/*
* Fetch or prepare a saved plan for the set null delete
SetUserId(save_uid);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_setnull_del()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_setnull_del()");
return PointerGetDatum(NULL);
return PointerGetDatum(NULL);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_setnull_upd()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_setnull_upd()");
/*
* "MATCH <unspecified>" only changes columns corresponding to
SetUserId(save_uid);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_setnull_upd()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_setnull_upd()");
return PointerGetDatum(NULL);
}
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_setdefault_del()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_setdefault_del()");
/*
* Prepare a plan for the set defalt delete operation.
SetUserId(save_uid);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_setdefault_del()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_setdefault_del()");
return PointerGetDatum(NULL);
return PointerGetDatum(NULL);
if (SPI_connect() != SPI_OK_CONNECT)
- elog(NOTICE, "SPI_connect() failed in RI_FKey_setdefault_upd()");
+ elog(WARNING, "SPI_connect() failed in RI_FKey_setdefault_upd()");
/*
* Prepare a plan for the set defalt delete operation.
SetUserId(save_uid);
if (SPI_finish() != SPI_OK_FINISH)
- elog(NOTICE, "SPI_finish() failed in RI_FKey_setdefault_upd()");
+ elog(WARNING, "SPI_finish() failed in RI_FKey_setdefault_upd()");
return PointerGetDatum(NULL);
* back to source text
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/ruleutils.c,v 1.90 2002/02/19 20:11:16 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/ruleutils.c,v 1.91 2002/03/06 06:10:16 momjian Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
*/
if (aref->refexpr == NULL || !IsA(aref->refexpr, Var) ||
((Var *) aref->refexpr)->varattno != tle->resdom->resno)
- elog(NOTICE, "tleIsArrayAssign: I'm confused ...");
+ elog(WARNING, "tleIsArrayAssign: I'm confused ...");
return true;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/timestamp.c,v 1.63 2002/03/04 03:55:46 ishii Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/timestamp.c,v 1.64 2002/03/06 06:10:18 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
else
{
- elog(NOTICE, "Unable to decode INTERVAL; internal coding error");
+ elog(WARNING, "Unable to decode INTERVAL; internal coding error");
*result = *interval;
}
}
}
else
{
- elog(NOTICE, "Unable to decode INTERVAL"
+ elog(WARNING, "Unable to decode INTERVAL"
"\n\tinterval_part() internal coding error");
result = 0;
}
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/varbit.c,v 1.20 2001/10/25 05:49:46 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/varbit.c,v 1.21 2002/03/06 06:10:19 momjian Exp $
*
*-------------------------------------------------------------------------
*/
mask2 = end_mask << (BITS_PER_BYTE - is);
is_match = mask2 == 0;
#if 0
- elog(NOTICE, "S. %d %d em=%2x sm=%2x r=%d",
+ elog(DEBUG3, "S. %d %d em=%2x sm=%2x r=%d",
i, is, end_mask, mask2, is_match);
#endif
break;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.90 2002/03/03 17:47:55 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.91 2002/03/06 06:10:21 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (ct->refcount != 0)
{
if (isCommit)
- elog(NOTICE, "Cache reference leak: cache %s (%d), tuple %u has count %d",
+ elog(WARNING, "Cache reference leak: cache %s (%d), tuple %u has count %d",
ct->my_cache->cc_relname, ct->my_cache->id,
ct->tuple.t_data->t_oid,
ct->refcount);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.153 2002/03/03 17:47:55 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.154 2002/03/06 06:10:21 momjian Exp $
*
*-------------------------------------------------------------------------
*/
relname, \
HASH_REMOVE, NULL); \
if (namehentry == NULL) \
- elog(NOTICE, "trying to delete a reldesc that does not exist."); \
+ elog(WARNING, "trying to delete a reldesc that does not exist."); \
idhentry = (RelIdCacheEnt*)hash_search(RelationIdCache, \
(void *)&(RELATION->rd_id), \
HASH_REMOVE, NULL); \
if (idhentry == NULL) \
- elog(NOTICE, "trying to delete a reldesc that does not exist."); \
+ elog(WARNING, "trying to delete a reldesc that does not exist."); \
nodentry = (RelNodeCacheEnt*)hash_search(RelationNodeCache, \
(void *)&(RELATION->rd_node), \
HASH_REMOVE, NULL); \
if (nodentry == NULL) \
- elog(NOTICE, "trying to delete a reldesc that does not exist."); \
+ elog(WARNING, "trying to delete a reldesc that does not exist."); \
} while(0)
if (adform->adnum != attrdef[i].adnum)
continue;
if (attrdef[i].adbin != NULL)
- elog(NOTICE, "AttrDefaultFetch: second record found for attr %s in rel %s",
+ elog(WARNING, "AttrDefaultFetch: second record found for attr %s in rel %s",
NameStr(relation->rd_att->attrs[adform->adnum - 1]->attname),
RelationGetRelationName(relation));
Anum_pg_attrdef_adbin,
adrel->rd_att, &isnull);
if (isnull)
- elog(NOTICE, "AttrDefaultFetch: adbin IS NULL for attr %s in rel %s",
+ elog(WARNING, "AttrDefaultFetch: adbin IS NULL for attr %s in rel %s",
NameStr(relation->rd_att->attrs[adform->adnum - 1]->attname),
RelationGetRelationName(relation));
else
}
if (i >= ndef)
- elog(NOTICE, "AttrDefaultFetch: unexpected record found for attr %d in rel %s",
+ elog(WARNING, "AttrDefaultFetch: unexpected record found for attr %d in rel %s",
adform->adnum,
RelationGetRelationName(relation));
}
heap_close(adrel, AccessShareLock);
if (found != ndef)
- elog(NOTICE, "AttrDefaultFetch: %d record(s) not found for rel %s",
+ elog(WARNING, "AttrDefaultFetch: %d record(s) not found for rel %s",
ndef - found, RelationGetRelationName(relation));
}
* We used to consider this a fatal error, but we might as well
* continue with backend startup ...
*/
- elog(NOTICE, "Cannot create init file %s: %m\n\tContinuing anyway, but there's something wrong.", tempfilename);
+ elog(WARNING, "Cannot create init file %s: %m\n\tContinuing anyway, but there's something wrong.", tempfilename);
return;
}
*/
if (rename(tempfilename, finalfilename) < 0)
{
- elog(NOTICE, "Cannot rename init file %s to %s: %m\n\tContinuing anyway, but there's something wrong.", tempfilename, finalfilename);
+ elog(WARNING, "Cannot rename init file %s to %s: %m\n\tContinuing anyway, but there's something wrong.", tempfilename, finalfilename);
/*
* If we fail, try to clean up the useless temp file; don't bother
* to complain if this fails too.
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/error/elog.c,v 1.93 2002/03/04 01:46:03 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/error/elog.c,v 1.94 2002/03/06 06:10:24 momjian Exp $
*
*-------------------------------------------------------------------------
*/
int client_min_messages;
char *client_min_messages_str = NULL;
-const char client_min_messages_str_default[] = "info";
+const char client_min_messages_str_default[] = "notice";
#ifdef ENABLE_SYSLOG
/*
static const char *useful_strerror(int errnum);
static const char *elog_message_prefix(int lev);
-#define send_notice_to_frontend(msg) send_message_to_frontend(NOTICE, msg)
-#define send_error_to_frontend(msg) send_message_to_frontend(ERROR, msg)
-
-
static int Debugfile = -1;
if (ClientAuthInProgress)
output_to_client = (lev >= ERROR);
else
- output_to_client = (lev >= client_min_messages);
+ output_to_client = (lev >= client_min_messages || lev == INFO);
}
/* Skip formatting effort if non-error message will not be output */
syslog_level = LOG_INFO;
break;
case NOTICE:
+ case WARNING:
syslog_level = LOG_NOTICE;
break;
case ERROR:
*/
oldcxt = MemoryContextSwitchTo(ErrorContext);
- if (lev <= NOTICE)
+ if (lev <= WARNING)
/* exclude the timestamp from msg sent to frontend */
- send_notice_to_frontend(msg_buf + timestamp_size);
+ send_message_to_frontend(lev, msg_buf + timestamp_size);
else
{
/*
* protocol.
*/
pq_endcopyout(true);
- send_error_to_frontend(msg_buf + timestamp_size);
+ send_message_to_frontend(ERROR, msg_buf + timestamp_size);
}
MemoryContextSwitchTo(oldcxt);
proc_exit(2);
}
- /* We reach here if lev <= NOTICE. OK to return to caller. */
+ /* We reach here if lev <= WARNING. OK to return to caller. */
}
AssertArg(type <= ERROR);
pq_beginmessage(&buf);
- pq_sendbyte(&buf, type != ERROR ? 'N' : 'E'); /* N is INFO or NOTICE */
+ pq_sendbyte(&buf, type != ERROR ? 'N' : 'E'); /* N is INFO, NOTICE,
+ * or WARNING */
pq_sendstring(&buf, msg);
pq_endmessage(&buf);
case NOTICE:
prefix = gettext("NOTICE: ");
break;
+ case WARNING:
+ prefix = gettext("WARNING: ");
+ break;
case ERROR:
prefix = gettext("ERROR: ");
break;
strcasecmp(lev, "log") == 0 ||
strcasecmp(lev, "info") == 0 ||
strcasecmp(lev, "notice") == 0 ||
+ strcasecmp(lev, "warning") == 0 ||
strcasecmp(lev, "error") == 0 ||
strcasecmp(lev, "fatal") == 0 ||
strcasecmp(lev, "panic") == 0)
server_min_messages = INFO;
else if (strcasecmp(lev, "notice") == 0)
server_min_messages = NOTICE;
+ else if (strcasecmp(lev, "warning") == 0)
+ server_min_messages = WARNING;
else if (strcasecmp(lev, "error") == 0)
server_min_messages = ERROR;
else if (strcasecmp(lev, "fatal") == 0)
strcasecmp(lev, "debug4") == 0 ||
strcasecmp(lev, "debug5") == 0 ||
strcasecmp(lev, "log") == 0 ||
- strcasecmp(lev, "info") == 0 ||
strcasecmp(lev, "notice") == 0 ||
+ strcasecmp(lev, "warning") == 0 ||
strcasecmp(lev, "error") == 0)
return true;
return false;
client_min_messages = DEBUG5;
else if (strcasecmp(lev, "log") == 0)
client_min_messages = LOG;
- else if (strcasecmp(lev, "info") == 0)
- client_min_messages = INFO;
else if (strcasecmp(lev, "notice") == 0)
client_min_messages = NOTICE;
+ else if (strcasecmp(lev, "warning") == 0)
+ client_min_messages = WARNING;
else if (strcasecmp(lev, "error") == 0)
client_min_messages = ERROR;
else
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/init/postinit.c,v 1.99 2002/03/01 22:45:15 petere Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/init/postinit.c,v 1.100 2002/03/06 06:10:25 momjian Exp $
*
*
*-------------------------------------------------------------------------
InitializeSessionUserIdStandalone();
if (!ThereIsAtLeastOneUser())
{
- elog(NOTICE, "There are currently no users defined in this database system.");
- elog(NOTICE, "You should immediately run 'CREATE USER \"%s\" WITH SYSID %d CREATEUSER;'.",
+ elog(WARNING, "There are currently no users defined in this database system.");
+ elog(WARNING, "You should immediately run 'CREATE USER \"%s\" WITH SYSID %d CREATEUSER;'.",
username, BOOTSTRAP_USESYSID);
}
}
* WIN1250 client encoding support contributed by Pavel Behal
* SJIS UDC (NEC selection IBM kanji) support contributed by Eiji Tokuya
*
- * $Id: conv.c,v 1.36 2002/03/05 05:52:43 momjian Exp $
+ * $Id: conv.c,v 1.37 2002/03/06 06:10:26 momjian Exp $
*
*
*/
sizeof(pg_utf_to_local), compare1);
if (p == NULL)
{
- elog(NOTICE, "utf_to_local: could not convert UTF-8 (0x%04x). Ignored", iutf);
+ elog(WARNING, "utf_to_local: could not convert UTF-8 (0x%04x). Ignored", iutf);
continue;
}
if (p->code & 0xff000000)
sizeof(pg_local_to_utf), compare2);
if (p == NULL)
{
- elog(NOTICE, "local_to_utf: could not convert (0x%04x) %s to UTF-8. Ignored",
+ elog(WARNING, "local_to_utf: could not convert (0x%04x) %s to UTF-8. Ignored",
iiso, (&pg_enc2name_tbl[encoding])->name);
continue;
}
utf_to_win1250(unsigned char *utf, unsigned char *euc, int len)
{
- utf_to_local(utf, euc, ULmapWIN1250,
- sizeof(ULmapWIN1250) / sizeof(pg_utf_to_local), len);
+ utf_to_local(utf, euc, ULmapWIN1250,
+ sizeof(ULmapWIN1250) / sizeof(pg_utf_to_local), len);
}
/*
static void
win1250_to_utf(unsigned char *euc, unsigned char *utf, int len)
{
- local_to_utf(euc, utf, LUmapWIN1250,
- sizeof(LUmapWIN1250) / sizeof(pg_local_to_utf), PG_WIN1250, len);
+ local_to_utf(euc, utf, LUmapWIN1250,
+ sizeof(LUmapWIN1250) / sizeof(pg_local_to_utf), PG_WIN1250, len);
}
/*
utf_to_win1256(unsigned char *utf, unsigned char *euc, int len)
{
- utf_to_local(utf, euc, ULmapWIN1256,
- sizeof(ULmapWIN1256) / sizeof(pg_utf_to_local), len);
+ utf_to_local(utf, euc, ULmapWIN1256,
+ sizeof(ULmapWIN1256) / sizeof(pg_utf_to_local), len);
}
/*
* Support for grand unified configuration scheme, including SET
* command, configuration file, and command line options.
*
- * $Header: /cvsroot/pgsql/src/backend/utils/misc/guc.c,v 1.61 2002/03/02 21:39:34 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/misc/guc.c,v 1.62 2002/03/06 06:10:27 momjian Exp $
*
* Copyright 2000 by PostgreSQL Global Development Group
* Written by Peter Eisentraut <peter_e@gmx.net>.
if (context == PGC_SIGHUP)
elevel = DEBUG1;
else if (guc_session_init)
- elevel = NOTICE;
+ elevel = INFO;
else
elevel = ERROR;
default:
val = "???";
}
- elog(NOTICE, "%s is %s", record->name, val);
+ elog(INFO, "%s is %s", record->name, val);
}
void
ParseLongOption(s, &name, &value);
if (!value)
{
- elog(NOTICE, "cannot to parse setting \"%s\"", name);
- continue;
+ elog(WARNING, "cannot to parse setting \"%s\"", name);
+ continue;
}
/* prevent errors from incorrect options */
guc_session_init = true;
-
+
SetConfigOption(name, value, PGC_SUSET, source);
guc_session_init = false;
newval = palloc(strlen(name) + 1 + strlen(value) + 1);
sprintf(newval, "%s=%s", name, value);
datum = DirectFunctionCall1(textin, CStringGetDatum(newval));
-
+
if (array)
{
int index;
#server_min_messages = notice # Values, in order of decreasing detail:
# debug5, debug4, debug3, debug2, debug1,
- # info, notice, error, log, fatal, panic
-#client_min_messages = info # Values, in order of decreasing detail:
+ # info, notice, warning, error, log, fatal,
+ # panic
+#client_min_messages = notice # Values, in order of decreasing detail:
# debug5, debug4, debug3, debug2, debug1,
- # log, info, notice, error
+ # log, notice, warning, error
#silent_mode = false
#log_connections = false
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/mmgr/aset.c,v 1.44 2001/11/05 17:46:30 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/mmgr/aset.c,v 1.45 2002/03/06 06:10:29 momjian Exp $
*
* NOTE:
* This is a new (Feb. 05, 1999) implementation of the allocation set
/* Test for someone scribbling on unused space in chunk */
if (chunk->requested_size < chunk->size)
if (((char *) pointer)[chunk->requested_size] != 0x7E)
- elog(NOTICE, "AllocSetFree: detected write past chunk end in %s %p",
+ elog(WARNING, "AllocSetFree: detected write past chunk end in %s %p",
set->header.name, chunk);
#endif
/* Test for someone scribbling on unused space in chunk */
if (chunk->requested_size < oldsize)
if (((char *) pointer)[chunk->requested_size] != 0x7E)
- elog(NOTICE, "AllocSetRealloc: detected write past chunk end in %s %p",
+ elog(WARNING, "AllocSetRealloc: detected write past chunk end in %s %p",
set->header.name, chunk);
#endif
* AllocSetCheck
* Walk through chunks and check consistency of memory.
*
- * NOTE: report errors as NOTICE, *not* ERROR or FATAL. Otherwise you'll
+ * NOTE: report errors as WARNING, *not* ERROR or FATAL. Otherwise you'll
* find yourself in an infinite loop when trouble occurs, because this
* routine will be entered again when elog cleanup tries to release memory!
*/
if (!blk_used)
{
if (set->keeper != block)
- elog(NOTICE, "AllocSetCheck: %s: empty block %p",
+ elog(WARNING, "AllocSetCheck: %s: empty block %p",
name, block);
}
* Check chunk size
*/
if (dsize > chsize)
- elog(NOTICE, "AllocSetCheck: %s: req size > alloc size for chunk %p in block %p",
+ elog(WARNING, "AllocSetCheck: %s: req size > alloc size for chunk %p in block %p",
name, chunk, block);
if (chsize < (1 << ALLOC_MINBITS))
- elog(NOTICE, "AllocSetCheck: %s: bad size %lu for chunk %p in block %p",
+ elog(WARNING, "AllocSetCheck: %s: bad size %lu for chunk %p in block %p",
name, (unsigned long) chsize, chunk, block);
/* single-chunk block? */
if (chsize > ALLOC_CHUNK_LIMIT &&
chsize + ALLOC_CHUNKHDRSZ != blk_used)
- elog(NOTICE, "AllocSetCheck: %s: bad single-chunk %p in block %p",
+ elog(WARNING, "AllocSetCheck: %s: bad single-chunk %p in block %p",
name, chunk, block);
/*
* check as easily...)
*/
if (dsize > 0 && chunk->aset != (void *) set)
- elog(NOTICE, "AllocSetCheck: %s: bogus aset link in block %p, chunk %p",
+ elog(WARNING, "AllocSetCheck: %s: bogus aset link in block %p, chunk %p",
name, block, chunk);
/*
* Check for overwrite of "unallocated" space in chunk
*/
if (dsize > 0 && dsize < chsize && *chdata_end != 0x7E)
- elog(NOTICE, "AllocSetCheck: %s: detected write past chunk end in block %p, chunk %p",
+ elog(WARNING, "AllocSetCheck: %s: detected write past chunk end in block %p, chunk %p",
name, block, chunk);
blk_data += chsize;
}
if ((blk_data + (nchunks * ALLOC_CHUNKHDRSZ)) != blk_used)
- elog(NOTICE, "AllocSetCheck: %s: found inconsistent memory block %p",
+ elog(WARNING, "AllocSetCheck: %s: found inconsistent memory block %p",
name, block);
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/mmgr/portalmem.c,v 1.46 2002/02/27 19:35:35 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/mmgr/portalmem.c,v 1.47 2002/03/06 06:10:29 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (hentry == NULL) \
elog(ERROR, "out of memory in PortalHashTable"); \
if (found) \
- elog(NOTICE, "trying to insert a portal name that exists."); \
+ elog(WARNING, "trying to insert a portal name that exists."); \
hentry->portal = PORTAL; \
} while(0)
hentry = (PortalHashEnt*)hash_search(PortalHashTable, \
key, HASH_REMOVE, NULL); \
if (hentry == NULL) \
- elog(NOTICE, "trying to delete portal name that does not exist."); \
+ elog(WARNING, "trying to delete portal name that does not exist."); \
} while(0)
static MemoryContext PortalMemory = NULL;
* Exceptions:
* BadState if called when disabled.
* BadArg if portal name is invalid.
- * "NOTICE" if portal name is in use (existing portal is returned!)
+ * "WARNING" if portal name is in use (existing portal is returned!)
*/
Portal
CreatePortal(char *name)
portal = GetPortalByName(name);
if (PortalIsValid(portal))
{
- elog(NOTICE, "CreatePortal: portal \"%s\" already exists", name);
+ elog(WARNING, "CreatePortal: portal \"%s\" already exists", name);
return portal;
}
*
* Copyright 2000 by PostgreSQL Global Development Group
*
- * $Header: /cvsroot/pgsql/src/bin/psql/common.c,v 1.39 2002/03/05 00:01:00 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/bin/psql/common.c,v 1.40 2002/03/06 06:10:31 momjian Exp $
*/
#include "postgres_fe.h"
/*
- * for backend NOTICES
+ * for backend INFO, WARNING, ERROR
*/
void
NoticeProcessor(void *arg, const char *message)
if (results)
PQclear(results);
- }
+ }
/* Possible microtiming output */
-
if (pset.timing && success)
- {
- ! printf(gettext("Total time: %.3fs\n"), ((after.tv_sec-before.tv_sec)*1000000 + after.tv_usec - before.tv_usec) / 1000000.0);
- }
+ printf(gettext("Total time: %.3fs\n"), ((after.tv_sec-before.tv_sec)*1000000 + after.tv_usec - before.tv_usec) / 1000000.0);
return success;
}
*
* Copyright 2000 by PostgreSQL Global Development Group
*
- * $Header: /cvsroot/pgsql/src/bin/psql/large_obj.c,v 1.18 2001/10/25 05:49:54 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/bin/psql/large_obj.c,v 1.19 2002/03/06 06:10:31 momjian Exp $
*/
#include "postgres_fe.h"
#include "large_obj.h"
if (notice[0])
{
- if ((!commit && strcmp(notice, "NOTICE: ROLLBACK: no transaction in progress\n") != 0) ||
- (commit && strcmp(notice, "NOTICE: COMMIT: no transaction in progress\n") != 0))
+ if ((!commit && strcmp(notice, "WARNING: ROLLBACK: no transaction in progress\n") != 0) ||
+ (commit && strcmp(notice, "WARNING: COMMIT: no transaction in progress\n") != 0))
fputs(notice, stderr);
}
else if (!QUIET())
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Id: elog.h,v 1.33 2002/03/04 23:59:14 momjian Exp $
+ * $Id: elog.h,v 1.34 2002/03/06 06:10:33 momjian Exp $
*
*-------------------------------------------------------------------------
*/
#define COMMERROR 16 /* Client communication problems; same as
* LOG for server reporting, but never ever
* try to send to client. */
-#define INFO 17 /* Informative messages that are part of
- * normal query operation; sent only to
- * client by default. */
-#define INFOALWAYS 18 /* Like INFO, but always prints to client */
-#define NOTICE 19 /* Important messages, for unusual cases that
- * should be reported but are not serious
+#define INFO 17 /* Informative messages that always sent to the
+ * clent; is not affected by client_min_messages */
+#define NOTICE 18 /* Important messages, for unusual cases that
+ * should be reported but are not serious
* enough to abort the query. Sent to client
* and server log by default. */
+#define WARNING 19 /* Important warnings */
#define ERROR 20 /* user error - return to known state */
#define FATAL 21 /* fatal error - abort process */
#define PANIC 22 /* take down the other backends with me */
#define ECPG_TRANS -401
#define ECPG_CONNECT -402
-/* backend notices, starting at 600 */
-#define ECPG_NOTICE_UNRECOGNIZED -600
- /* NOTICE: (transaction aborted): queries ignored until END */
+/* backend WARNINGs, starting at 600 */
+#define ECPG_WARNING_UNRECOGNIZED -600
+ /* WARNING: (transaction aborted): queries ignored until END */
/*
- * NOTICE: current transaction is aborted, queries ignored until end of
+ * WARNING: current transaction is aborted, queries ignored until end of
* transaction block
*/
-#define ECPG_NOTICE_QUERY_IGNORED -601
- /* NOTICE: PerformPortalClose: portal "*" not found */
-#define ECPG_NOTICE_UNKNOWN_PORTAL -602
- /* NOTICE: BEGIN: already a transaction in progress */
-#define ECPG_NOTICE_IN_TRANSACTION -603
- /* NOTICE: AbortTransaction and not in in-progress state */
- /* NOTICE: COMMIT: no transaction in progress */
-#define ECPG_NOTICE_NO_TRANSACTION -604
- /* NOTICE: BlankPortalAssignName: portal * already exists */
-#define ECPG_NOTICE_PORTAL_EXISTS -605
+#define ECPG_WARNING_QUERY_IGNORED -601
+ /* WARNING: PerformPortalClose: portal "*" not found */
+#define ECPG_WARNING_UNKNOWN_PORTAL -602
+ /* WARNING: BEGIN: already a transaction in progress */
+#define ECPG_WARNING_IN_TRANSACTION -603
+ /* WARNING: AbortTransaction and not in in-progress state */
+ /* WARNING: COMMIT: no transaction in progress */
+#define ECPG_WARNING_NO_TRANSACTION -604
+ /* WARNING: BlankPortalAssignName: portal * already exists */
+#define ECPG_WARNING_PORTAL_EXISTS -605
#endif /* !_ECPG_ERROR_H */
-/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/lib/Attic/connect.c,v 1.17 2001/12/23 12:17:41 meskes Exp $ */
+/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/lib/Attic/connect.c,v 1.18 2002/03/06 06:10:35 momjian Exp $ */
#include "postgres_fe.h"
ECPGnoticeProcessor(void *arg, const char *message)
{
/* these notices raise an error */
- if (strncmp(message, "NOTICE: ", 8))
+ if (strncmp(message, "WARNING: ", 9))
{
- ECPGlog("ECPGnoticeProcessor: strange notice '%s'\n", message);
- ECPGnoticeProcessor_raise(ECPG_NOTICE_UNRECOGNIZED, message);
+ ECPGlog("ECPGnoticeProcessor: strange warning '%s'\n", message);
+ ECPGnoticeProcessor_raise(ECPG_WARNING_UNRECOGNIZED, message);
return;
}
message += 8;
while (*message == ' ')
message++;
- ECPGlog("NOTICE: %s", message);
+ ECPGlog("WARNING: %s", message);
- /* NOTICE: (transaction aborted): queries ignored until END */
+ /* WARNING: (transaction aborted): queries ignored until END */
/*
- * NOTICE: current transaction is aborted, queries ignored until end
+ * WARNING: current transaction is aborted, queries ignored until end
* of transaction block
*/
if (strstr(message, "queries ignored") && strstr(message, "transaction")
&& strstr(message, "aborted"))
{
- ECPGnoticeProcessor_raise(ECPG_NOTICE_QUERY_IGNORED, message);
+ ECPGnoticeProcessor_raise(ECPG_WARNING_QUERY_IGNORED, message);
return;
}
- /* NOTICE: PerformPortalClose: portal "*" not found */
+ /* WARNING: PerformPortalClose: portal "*" not found */
if ((!strncmp(message, "PerformPortalClose: portal", 26)
|| !strncmp(message, "PerformPortalFetch: portal", 26))
&& strstr(message + 26, "not found"))
{
- ECPGnoticeProcessor_raise(ECPG_NOTICE_UNKNOWN_PORTAL, message);
+ ECPGnoticeProcessor_raise(ECPG_WARNING_UNKNOWN_PORTAL, message);
return;
}
- /* NOTICE: BEGIN: already a transaction in progress */
+ /* WARNING: BEGIN: already a transaction in progress */
if (!strncmp(message, "BEGIN: already a transaction in progress", 40))
{
- ECPGnoticeProcessor_raise(ECPG_NOTICE_IN_TRANSACTION, message);
+ ECPGnoticeProcessor_raise(ECPG_WARNING_IN_TRANSACTION, message);
return;
}
- /* NOTICE: AbortTransaction and not in in-progress state */
- /* NOTICE: COMMIT: no transaction in progress */
- /* NOTICE: ROLLBACK: no transaction in progress */
+ /* WARNING: AbortTransaction and not in in-progress state */
+ /* WARNING: COMMIT: no transaction in progress */
+ /* WARNING: ROLLBACK: no transaction in progress */
if (!strncmp(message, "AbortTransaction and not in in-progress state", 45)
|| !strncmp(message, "COMMIT: no transaction in progress", 34)
|| !strncmp(message, "ROLLBACK: no transaction in progress", 36))
{
- ECPGnoticeProcessor_raise(ECPG_NOTICE_NO_TRANSACTION, message);
+ ECPGnoticeProcessor_raise(ECPG_WARNING_NO_TRANSACTION, message);
return;
}
- /* NOTICE: BlankPortalAssignName: portal * already exists */
+ /* WARNING: BlankPortalAssignName: portal * already exists */
if (!strncmp(message, "BlankPortalAssignName: portal", 29)
&& strstr(message + 29, "already exists"))
{
- ECPGnoticeProcessor_raise(ECPG_NOTICE_PORTAL_EXISTS, message);
+ ECPGnoticeProcessor_raise(ECPG_WARNING_PORTAL_EXISTS, message);
return;
}
/* these are harmless - do nothing */
/*
- * NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index '*'
+ * WARNING: CREATE TABLE / PRIMARY KEY will create implicit index '*'
* for table '*'
*/
/*
- * NOTICE: ALTER TABLE ... ADD CONSTRAINT will create implicit
+ * WARNING: ALTER TABLE ... ADD CONSTRAINT will create implicit
* trigger(s) for FOREIGN KEY check(s)
*/
/*
- * NOTICE: CREATE TABLE will create implicit sequence '*' for SERIAL
+ * WARNING: CREATE TABLE will create implicit sequence '*' for SERIAL
* column '*.*'
*/
/*
- * NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN
+ * WARNING: CREATE TABLE will create implicit trigger(s) for FOREIGN
* KEY check(s)
*/
if ((!strncmp(message, "CREATE TABLE", 12) || !strncmp(message, "ALTER TABLE", 11))
&& strstr(message + 11, "will create implicit"))
return;
- /* NOTICE: QUERY PLAN: */
+ /* WARNING: QUERY PLAN: */
if (!strncmp(message, "QUERY PLAN:", 11)) /* do we really see these? */
return;
/*
- * NOTICE: DROP TABLE implicitly drops referential integrity trigger
+ * WARNING: DROP TABLE implicitly drops referential integrity trigger
* from table "*"
*/
if (!strncmp(message, "DROP TABLE implicitly drops", 27))
return;
/*
- * NOTICE: Caution: DROP INDEX cannot be rolled back, so don't abort
+ * WARNING: Caution: DROP INDEX cannot be rolled back, so don't abort
* now
*/
if (strstr(message, "cannot be rolled back"))
return;
/* these and other unmentioned should set sqlca.sqlwarn[2] */
- /* NOTICE: The ':' operator is deprecated. Use exp(x) instead. */
- /* NOTICE: Rel *: Uninitialized page 0 - fixing */
- /* NOTICE: PortalHeapMemoryFree: * not in alloc set! */
- /* NOTICE: Too old parent tuple found - can't continue vc_repair_frag */
- /* NOTICE: identifier "*" will be truncated to "*" */
- /* NOTICE: InvalidateSharedInvalid: cache state reset */
- /* NOTICE: RegisterSharedInvalid: SI buffer overflow */
+ /* WARNING: The ':' operator is deprecated. Use exp(x) instead. */
+ /* WARNING: Rel *: Uninitialized page 0 - fixing */
+ /* WARNING: PortalHeapMemoryFree: * not in alloc set! */
+ /* WARNING: Too old parent tuple found - can't continue vc_repair_frag */
+ /* WARNING: identifier "*" will be truncated to "*" */
+ /* WARNING: InvalidateSharedInvalid: cache state reset */
+ /* WARNING: RegisterSharedInvalid: SI buffer overflow */
sqlca.sqlwarn[2] = 'W';
sqlca.sqlwarn[0] = 'W';
}
}
}
snprintf(errortext, sizeof errortext, "unknown descriptor %s", name);
- mmerror(PARSE_ERROR, ET_NOTICE, errortext);
+ mmerror(PARSE_ERROR, ET_WARNING, errortext);
}
struct descriptor
}
}
snprintf(errortext, sizeof errortext, "unknown descriptor %s", name);
- mmerror(PARSE_ERROR, ET_NOTICE, errortext);
+ mmerror(PARSE_ERROR, ET_WARNING, errortext);
return NULL;
}
else
{
snprintf(errortext, sizeof errortext, "unknown descriptor header item '%d'", results->value);
- mmerror(PARSE_ERROR, ET_NOTICE, errortext);
+ mmerror(PARSE_ERROR, ET_WARNING, errortext);
}
}
switch (results->value)
{
case ECPGd_nullable:
- mmerror(PARSE_ERROR, ET_NOTICE, "nullable is always 1");
+ mmerror(PARSE_ERROR, ET_WARNING, "nullable is always 1");
break;
case ECPGd_key_member:
- mmerror(PARSE_ERROR, ET_NOTICE, "key_member is always 0");
+ mmerror(PARSE_ERROR, ET_WARNING, "key_member is always 0");
break;
default:
break;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/pgc.l,v 1.85 2002/02/15 17:46:57 petere Exp $
+ * $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/pgc.l,v 1.86 2002/03/06 06:10:36 momjian Exp $
*
*-------------------------------------------------------------------------
*/
literalbuf, NAMEDATALEN-1, literalbuf);
literalbuf[NAMEDATALEN-1] = '\0';
#endif
- mmerror(PARSE_ERROR, ET_NOTICE, errortext);
+ mmerror(PARSE_ERROR, ET_WARNING, errortext);
}
yylval.str = mm_strdup(literalbuf);
{
switch(type)
{
- case ET_NOTICE:
+ case ET_WARNING:
fprintf(stderr, "%s:%d: WARNING: %s\n", input_filename, yylineno, error);
break;
case ET_ERROR:
| LOCAL TEMPORARY { $$ = make_str("local temporary"); }
| LOCAL TEMP { $$ = make_str("local temp"); }
| GLOBAL TEMPORARY {
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported CREATE TABLE / GLOBAL TEMPORARY will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported CREATE TABLE / GLOBAL TEMPORARY will be passed to backend");
$$ = make_str("global temporary");
}
| GLOBAL TEMP {
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported CREATE TABLE / GLOBAL TEMP will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported CREATE TABLE / GLOBAL TEMP will be passed to backend");
$$ = make_str("global temp");
}
| /*EMPTY*/ { $$ = EMPTY; }
if (strlen($4) > 0)
{
sprintf(errortext, "Currently unsupported CREATE TABLE / COLLATE %s will be passed to backend", $4);
- mmerror(PARSE_ERROR, ET_NOTICE, errortext);
+ mmerror(PARSE_ERROR, ET_WARNING, errortext);
}
$$ = cat_str(4, $1, $2, $3, $4);
}
}
| MATCH PARTIAL
{
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported FOREIGN KEY/MATCH PARTIAL will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported FOREIGN KEY/MATCH PARTIAL will be passed to backend");
$$ = make_str("match partial");
}
| /*EMPTY*/
| BACKWARD { $$ = make_str("backward"); }
| RELATIVE { $$ = make_str("relative"); }
| ABSOLUTE {
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported FETCH/ABSOLUTE will be passed to backend, backend will use RELATIVE");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported FETCH/ABSOLUTE will be passed to backend, backend will use RELATIVE");
$$ = make_str("absolute");
}
;
opt_with_grant: WITH GRANT OPTION
{
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported GRANT/WITH GRANT OPTION will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported GRANT/WITH GRANT OPTION will be passed to backend");
$$ = make_str("with grant option");
}
| /*EMPTY*/ { $$ = EMPTY; }
opt_arg: IN { $$ = make_str("in"); }
| OUT {
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported CREATE FUNCTION/OUT will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported CREATE FUNCTION/OUT will be passed to backend");
$$ = make_str("out");
}
| INOUT {
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported CREATE FUNCTION/INOUT will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported CREATE FUNCTION/INOUT will be passed to backend");
$$ = make_str("inout");
}
opt_chain: AND NO CHAIN { $$ = make_str("and no chain"); }
| AND CHAIN {
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported COMMIT/CHAIN will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported COMMIT/CHAIN will be passed to backend");
$$ = make_str("and chain");
}
}
| GLOBAL TEMPORARY opt_table relation_name
{
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported CREATE TABLE / GLOBAL TEMPORARY will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported CREATE TABLE / GLOBAL TEMPORARY will be passed to backend");
$$ = cat_str(3, make_str("global temporary"), $3, $4);
}
| GLOBAL TEMP opt_table relation_name
{
- mmerror(PARSE_ERROR, ET_NOTICE, "Currently unsupported CREATE TABLE / GLOBAL TEMP will be passed to backend");
+ mmerror(PARSE_ERROR, ET_WARNING, "Currently unsupported CREATE TABLE / GLOBAL TEMP will be passed to backend");
$$ = cat_str(3, make_str("global temp"), $3, $4);
}
| TABLE relation_name
| LIMIT select_limit_value ',' select_offset_value
{ $$ = cat_str(4, make_str("limit"), $2, make_str(","), $4); }
/* enable this in 7.3, bjm 2001-10-22
- { mmerror(PARSE_ERROR, ET_NOTICE, "No longer supported LIMIT #,# syntax passed to backend."); }
+ { mmerror(PARSE_ERROR, ET_WARNING, "No longer supported LIMIT #,# syntax passed to backend."); }
*/
;
enum errortype
{
- ET_NOTICE, ET_ERROR, ET_FATAL
+ ET_WARNING, ET_ERROR, ET_FATAL
};
struct fetch_desc
-// $Id: test_notice.pgc,v 1.2 2001/08/11 10:52:09 petere Exp $
+// $Id: test_notice.pgc,v 1.3 2002/03/06 06:10:41 momjian Exp $
exec sql include sqlca;
if (sqlca.sqlcode) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql begin work;
- if (sqlca.sqlcode!=ECPG_NOTICE_IN_TRANSACTION) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
+ if (sqlca.sqlcode!=ECPG_WARNING_IN_TRANSACTION) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql commit;
if (sqlca.sqlcode) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql commit;
- if (sqlca.sqlcode!=ECPG_NOTICE_NO_TRANSACTION) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
+ if (sqlca.sqlcode!=ECPG_WARNING_NO_TRANSACTION) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql rollback;
- if (sqlca.sqlcode!=ECPG_NOTICE_NO_TRANSACTION) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
+ if (sqlca.sqlcode!=ECPG_WARNING_NO_TRANSACTION) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
sqlca.sqlcode=0;
exec sql declare x cursor for select * from test;
if (sqlca.sqlcode) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql open x;
- if (sqlca.sqlcode!=ECPG_NOTICE_PORTAL_EXISTS) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
+ if (sqlca.sqlcode!=ECPG_WARNING_PORTAL_EXISTS) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql close x;
if (sqlca.sqlcode) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql close x;
- if (sqlca.sqlcode!=ECPG_NOTICE_UNKNOWN_PORTAL) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
+ if (sqlca.sqlcode!=ECPG_WARNING_UNKNOWN_PORTAL) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql update test set nonexistent=2;
if (sqlca.sqlcode!=ECPG_PGSQL) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql select payload into :payload from test where index=1;
- if (sqlca.sqlcode!=ECPG_NOTICE_QUERY_IGNORED) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
+ if (sqlca.sqlcode!=ECPG_WARNING_QUERY_IGNORED) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql rollback;
if (sqlca.sqlcode) printf("%d %ld:%s\n",__LINE__,sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-exec.c,v 1.116 2002/03/05 06:07:26 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-exec.c,v 1.117 2002/03/06 06:10:42 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* 6 \\
*/
unsigned char *
-PQunescapeBytea(unsigned char *strtext, size_t *retbuflen)
+PQunescapeBytea(unsigned char *strtext, size_t *retbuflen)
{
size_t buflen;
unsigned char *buffer, *sp, *bp;
unsigned int state=0;
- if(strtext == NULL)return NULL;
+ if(strtext == NULL)return NULL;
buflen = strlen(strtext); /* will shrink, also we discover if strtext */
buffer = (unsigned char *) malloc(buflen); /* isn't NULL terminated */
- if(buffer == NULL)return NULL;
+ if(buffer == NULL)return NULL;
for(bp = buffer, sp = strtext; *sp != '\0'; bp++, sp++)
{
switch(state)
* handleSendFailure: try to clean up after failure to send command.
*
* Primarily, what we want to accomplish here is to process an async
- * NOTICE message that the backend might have sent just before it died.
+ * WARNING message that the backend might have sent just before it died.
*
* NOTE: this routine should only be called in PGASYNC_IDLE state.
*/
/*
* Parse any available input messages. Since we are in PGASYNC_IDLE
- * state, only NOTICE and NOTIFY messages will be eaten.
+ * state, only WARNING and NOTIFY messages will be eaten.
*/
parseInput(conn);
}
return;
/*
- * NOTIFY and NOTICE messages can happen in any state besides COPY
+ * NOTIFY and WARNING messages can happen in any state besides COPY
* OUT; always process them right away.
*
* Most other messages should only be processed while in BUSY state.
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-misc.c,v 1.67 2002/03/05 06:07:26 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-misc.c,v 1.68 2002/03/06 06:10:42 momjian Exp $
*
*-------------------------------------------------------------------------
*/
while (nbytes)
{
size_t avail, remaining;
-
+
/* fill the output buffer */
avail = Max(conn->outBufSize - conn->outCount, 0);
remaining = Min(avail, nbytes);
/*
* We used to close the socket here, but that's a bad
* idea since there might be unread data waiting
- * (typically, a NOTICE message from the backend
+ * (typically, a WARNING message from the backend
* telling us it's committing hara-kiri...). Leave
* the socket open until pqReadData finds no more data
* can be read.
{
free(pwd1);
return 1;
- }
+ }
if (!(pwd2 = malloc(MD5_PASSWD_LEN + 1)))
{
free(pwd1);
return 1;
- }
+ }
if (!EncryptMD5(pwd1 + strlen("md5"), salt, 4, pwd2))
{
free(pwd2);
SOCK_put_n_char(sock, pwd2, strlen(pwd2) + 1);
SOCK_flush_output(sock);
free(pwd2);
- return 0;
+ return 0;
}
char
{
mylog("send_query: ok - 'C' - %s\n", cmdbuffer);
- if (res == NULL) /* allow for "show" style notices */
+ if (res == NULL) /* allow for "show" style info */
res = QR_Constructor();
mylog("send_query: setting cmdbuffer = '%s'\n", cmdbuffer);
ReadyToReturn = FALSE;
}
break;
- case 'N': /* NOTICE: */
+ case 'N': /* INFO, NOTICE, WARNING */
msg_truncated = SOCK_get_string(sock, cmdbuffer, ERROR_MSG_LENGTH);
if (!res)
res = QR_Constructor();
strcpy(PG_CCSS, cmdbuffer + 36);\r
if (strstr(cmdbuffer,"Current server encoding is"))\r
strcpy(PG_SCSS, cmdbuffer + 36);\r
- mylog("~~~ NOTICE: '%s'\n", cmdbuffer);\r
- qlog("NOTICE from backend during send_query: '%s'\n ClientEncoding = %s\n ServerEncoding = %s\n", cmdbuffer, PG_CCSS, PG_SCSS);\r
+ mylog("~~~ WARNING: '%s'\n", cmdbuffer);\r
+ qlog("WARNING from backend during send_query: '%s'\n ClientEncoding = %s\n ServerEncoding = %s\n", cmdbuffer, PG_CCSS, PG_SCSS);\r
\r
}\r
else\r
{\r
\r
- mylog("~~~ NOTICE: '%s'\n", cmdbuffer);\r
- qlog("NOTICE from backend during send_query: '%s'\n", cmdbuffer);\r
+ mylog("~~~ WARNING: '%s'\n", cmdbuffer);\r
+ qlog("WARNING from backend during send_query: '%s'\n", cmdbuffer);\r
}\r
#else\r
- mylog("~~~ NOTICE: '%s'\n", cmdbuffer);\r
- qlog("NOTICE from backend during send_query: '%s'\n", cmdbuffer);\r
+ mylog("~~~ WARNING: '%s'\n", cmdbuffer);\r
+ qlog("WARNING from backend during send_query: '%s'\n", cmdbuffer);\r
#endif
while (msg_truncated)
msg_truncated = SOCK_get_string(sock, cmdbuffer, ERROR_MSG_LENGTH);
SOCK_get_string(sock, msgbuffer, ERROR_MSG_LENGTH);
mylog("send_function(G): 'N' - %s\n", msgbuffer);
- qlog("NOTICE from backend during send_function: '%s'\n", msgbuffer);
+ qlog("WARNING from backend during send_function: '%s'\n", msgbuffer);
continue; /* dont return a result -- continue
* reading */
* procedural language
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/pl/plpgsql/src/pl_comp.c,v 1.37 2001/10/25 05:50:20 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/pl/plpgsql/src/pl_comp.c,v 1.38 2002/03/06 06:10:45 momjian Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
*/
if (plpgsql_error_funcname != NULL)
{
- elog(NOTICE, "plpgsql: ERROR during compile of %s near line %d",
+ elog(WARNING, "plpgsql: ERROR during compile of %s near line %d",
plpgsql_error_funcname, plpgsql_error_lineno);
plpgsql_error_funcname = NULL;
* procedural language
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/pl/plpgsql/src/pl_exec.c,v 1.53 2002/02/26 00:00:08 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/pl/plpgsql/src/pl_exec.c,v 1.54 2002/03/06 06:10:46 momjian Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
*/
if (error_info_func != NULL)
{
- elog(NOTICE, "Error occurred while executing PL/pgSQL function %s",
+ elog(WARNING, "Error occurred while executing PL/pgSQL function %s",
error_info_func->fn_name);
if (error_info_stmt != NULL)
- elog(NOTICE, "line %d at %s", error_info_stmt->lineno,
+ elog(WARNING, "line %d at %s", error_info_stmt->lineno,
plpgsql_stmt_typename(error_info_stmt));
else if (error_info_text != NULL)
- elog(NOTICE, "%s", error_info_text);
+ elog(WARNING, "%s", error_info_text);
else
- elog(NOTICE, "no more error information available");
+ elog(WARNING, "no more error information available");
error_info_func = NULL;
error_info_stmt = NULL;
*/
if (error_info_func != NULL)
{
- elog(NOTICE, "Error occurred while executing PL/pgSQL function %s",
+ elog(WARNING, "Error occurred while executing PL/pgSQL function %s",
error_info_func->fn_name);
if (error_info_stmt != NULL)
- elog(NOTICE, "line %d at %s", error_info_stmt->lineno,
+ elog(WARNING, "line %d at %s", error_info_stmt->lineno,
plpgsql_stmt_typename(error_info_stmt));
else if (error_info_text != NULL)
- elog(NOTICE, "%s", error_info_text);
+ elog(WARNING, "%s", error_info_text);
else
- elog(NOTICE, "no more error information available");
+ elog(WARNING, "no more error information available");
error_info_func = NULL;
error_info_stmt = NULL;
* MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/pl/plpython/plpython.c,v 1.14 2002/03/02 21:39:35 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/pl/plpython/plpython.c,v 1.15 2002/03/06 06:10:47 momjian Exp $
*
*********************************************************************
*/
}
/*
- * elog(NOTICE, "PLy_restart_in_progress is %d",
+ * elog(DEBUG3, "PLy_restart_in_progress is %d",
* PLy_restart_in_progress);
*/
(TRIGGER_FIRED_BY_UPDATE(tdata->tg_event)))
rv = PLy_modify_tuple(proc, plargs, tdata, rv);
else
- elog(NOTICE, "plpython: Ignoring modified tuple in DELETE trigger");
+ elog(WARNING, "plpython: Ignoring modified tuple in DELETE trigger");
}
else if (strcasecmp(srv, "OK"))
{
if (!PyErr_Occurred())
PyErr_SetString(PLy_exc_spi_error,
"Unknown error in PLy_spi_prepare.");
- PLy_elog(NOTICE,"in function %s:",PLy_procedure_name(PLy_last_procedure));
+ PLy_elog(WARNING,"in function %s:",PLy_procedure_name(PLy_last_procedure));
RERAISE_EXC();
}
if (!PyErr_Occurred())
PyErr_SetString(PLy_exc_error,
"Unknown error in PLy_spi_execute_plan");
- PLy_elog(NOTICE,"in function %s:",PLy_procedure_name(PLy_last_procedure));
+ PLy_elog(WARNING,"in function %s:",PLy_procedure_name(PLy_last_procedure));
RERAISE_EXC();
}
if ((!PLy_restart_in_progress) && (!PyErr_Occurred()))
PyErr_SetString(PLy_exc_spi_error,
"Unknown error in PLy_spi_execute_query.");
- PLy_elog(NOTICE,"in function %s:",PLy_procedure_name(PLy_last_procedure));
+ PLy_elog(WARNING,"in function %s:",PLy_procedure_name(PLy_last_procedure));
RERAISE_EXC();
}
enter();
if (args == NULL)
- elog(NOTICE, "plpython, args is NULL in %s", __FUNCTION__);
+ elog(WARNING, "plpython, args is NULL in %s", __FUNCTION__);
so = PyObject_Str(args);
if ((so == NULL) || ((sv = PyString_AsString(so)) == NULL))
}
/*
- * ok, this is a NOTICE, or LOG message
+ * ok, this is a WARNING, or LOG message
*
* but just in case DON'T long jump out of the interpreter!
*/
*/
if (e == NULL)
{
- *xlevel = NOTICE;
+ *xlevel = WARNING;
return NULL;
}
-/* $Header: /cvsroot/pgsql/src/pl/plpython/Attic/plpython.h,v 1.5 2001/11/05 17:46:39 momjian Exp $ */
+/* $Header: /cvsroot/pgsql/src/pl/plpython/Attic/plpython.h,v 1.6 2002/03/06 06:10:48 momjian Exp $ */
#ifndef PLPYTHON_H
#define PLPYTHON_H
#define RAISE_EXC(V) siglongjmp(Warn_restart, (V))
#else
#define RESTORE_N_EXC(N) do { \
- elog(NOTICE, "exception (%d,%d) restore at %s:%d",\
+ elog(WARNING, "exception (%d,%d) restore at %s:%d",\
PLy_call_level, exc_save_calls, __FUNCTION__, (__LINE__));\
exc_save_calls -= 1; \
memcpy(&Warn_restart, &(buf_##N), sizeof(sigjmp_buf)); } while (0)
#define SAVE_N_EXC(N) do { \
exc_save_calls += 1; \
- elog(NOTICE, "exception (%d,%d) save at %s:%d", \
+ elog(WARNING, "exception (%d,%d) save at %s:%d", \
PLy_call_level, exc_save_calls, __FUNCTION__, (__LINE__)); \
memcpy(&(buf_##N), &Warn_restart, sizeof(sigjmp_buf)); } while (0)
#define RERAISE_N_EXC(N) do { \
- elog(NOTICE, "exception (%d,%d) reraise at %s:%d", \
+ elog(WARNING, "exception (%d,%d) reraise at %s:%d", \
PLy_call_level, exc_save_calls, __FUNCTION__, (__LINE__)); \
siglongjmp(Warn_restart, rv_##N); } while (0)
#define RAISE_EXC(V) do { \
- elog(NOTICE, "exception (%d,%d) raise at %s:%d", \
+ elog(WARNING, "exception (%d,%d) raise at %s:%d", \
PLy_call_level, exc_save_calls, __FUNCTION__, (__LINE__)); \
siglongjmp(Warn_restart, (V)); } while (0)
#endif
#if DEBUG_LEVEL
#define CALL_LEVEL_INC() do { PLy_call_level += 1; \
- elog(NOTICE, "Level: %d", PLy_call_level); } while (0)
-#define CALL_LEVEL_DEC() do { elog(NOTICE, "Level: %d", PLy_call_level); \
+ elog(DEBUG3, "Level: %d", PLy_call_level); } while (0)
+#define CALL_LEVEL_DEC() do { elog(DEBUG3, "Level: %d", PLy_call_level); \
PLy_call_level -= 1; } while (0)
#else
#define CALL_LEVEL_INC() do { PLy_call_level += 1; } while (0)
/* temporary debugging macros
*/
#if DEBUG_LEVEL
-#define enter() elog(NOTICE, "Enter(%d): %s", func_enter_calls++,__FUNCTION__)
-#define leave() elog(NOTICE, "Leave(%d): %s", func_leave_calls++,__FUNCTION__)
-#define mark() elog(NOTICE, "Mark: %s:%d", __FUNCTION__, __LINE__);
-#define refc(O) elog(NOTICE, "Ref<%p>:<%d>:%s:%d", (O), (((O) == NULL) ? -1 : (O)->ob_refcnt), __FUNCTION__, __LINE__)
+#define enter() elog(DEBUG3, "Enter(%d): %s", func_enter_calls++,__FUNCTION__)
+#define leave() elog(DEBUG3, "Leave(%d): %s", func_leave_calls++,__FUNCTION__)
+#define mark() elog(DEBUG3, "Mark: %s:%d", __FUNCTION__, __LINE__);
+#define refc(O) elog(DEBUG3, "Ref<%p>:<%d>:%s:%d", (O), (((O) == NULL) ? -1 : (O)->ob_refcnt), __FUNCTION__, __LINE__)
#else
#define enter()
#define leave()
* ENHANCEMENTS, OR MODIFICATIONS.
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/pl/tcl/pltcl.c,v 1.50 2002/03/02 21:39:35 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/pl/tcl/pltcl.c,v 1.51 2002/03/06 06:10:48 momjian Exp $
*
**********************************************************************/
if (SPI_processed == 0)
{
Tcl_DStringFree(&unknown_src);
- elog(NOTICE, "pltcl: Module unknown not found in pltcl_modules");
+ elog(WARNING, "pltcl: Module unknown not found in pltcl_modules");
return;
}
if (Tcl_SplitList(interp, interp->result,
&ret_numvals, &ret_values) != TCL_OK)
{
- elog(NOTICE, "pltcl: cannot split return value from trigger");
+ elog(WARNING, "pltcl: cannot split return value from trigger");
elog(ERROR, "pltcl: %s", interp->result);
}
return TCL_ERROR;
}
- if (strcmp(argv[1], "NOTICE") == 0)
+ if (strcmp(argv[1], "INFO") == 0)
+ level = INFO;
+ else if (strcmp(argv[1], "NOTICE") == 0)
level = NOTICE;
- else if (strcmp(argv[1], "WARN") == 0)
+ else if (strcmp(argv[1], "WARNING") == 0)
level = ERROR;
else if (strcmp(argv[1], "ERROR") == 0)
level = ERROR;
-- FOREIGN KEY CONSTRAINT adding TEST
CREATE TABLE tmp2 (a int primary key);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'tmp2_pkey' for table 'tmp2'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'tmp2_pkey' for table 'tmp2'
CREATE TABLE tmp3 (a int, b int);
CREATE TABLE tmp4 (a int, b int, unique(a,b));
-INFO: CREATE TABLE / UNIQUE will create implicit index 'tmp4_a_key' for table 'tmp4'
+NOTICE: CREATE TABLE / UNIQUE will create implicit index 'tmp4_a_key' for table 'tmp4'
CREATE TABLE tmp5 (a int, b int);
-- Insert rows into tmp2 (pktable)
INSERT INTO tmp2 values (1);
INSERT INTO tmp3 values (5,50);
-- Try (and fail) to add constraint due to invalid source columns
ALTER TABLE tmp3 add constraint tmpconstr foreign key(c) references tmp2 match full;
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: ALTER TABLE: column "c" referenced in foreign key constraint does not exist
-- Try (and fail) to add constraint due to invalide destination columns explicitly given
ALTER TABLE tmp3 add constraint tmpconstr foreign key(a) references tmp2(b) match full;
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: UNIQUE constraint matching given keys for referenced table "tmp2" not found
-- Try (and fail) to add constraint due to invalid data
ALTER TABLE tmp3 add constraint tmpconstr foreign key (a) references tmp2 match full;
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: tmpconstr referential integrity violation - key referenced from tmp3 not found in tmp2
-- Delete failing row
DELETE FROM tmp3 where a=5;
-- Try (and succeed)
ALTER TABLE tmp3 add constraint tmpconstr foreign key (a) references tmp2 match full;
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Try (and fail) to create constraint from tmp5(a) to tmp4(a) - unique constraint on
-- tmp4 is a,b
ALTER TABLE tmp5 add constraint tmpconstr foreign key(a) references tmp4(a) match full;
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: UNIQUE constraint matching given keys for referenced table "tmp4" not found
DROP TABLE tmp5;
DROP TABLE tmp4;
DROP TABLE tmp3;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "tmp2"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "tmp2"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "tmp2"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "tmp2"
DROP TABLE tmp2;
-- Foreign key adding test with mixed types
-- Note: these tables are TEMP to avoid name conflicts when this test
-- is run in parallel with foreign_key.sql.
CREATE TEMP TABLE PKTABLE (ptest1 int PRIMARY KEY);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TEMP TABLE FKTABLE (ftest1 text);
-- This next should fail, because text=int does not exist
ALTER TABLE FKTABLE ADD FOREIGN KEY(ftest1) references pktable;
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
-- This should also fail for the same reason, but here we
-- give the column name
ALTER TABLE FKTABLE ADD FOREIGN KEY(ftest1) references pktable(ptest1);
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
-- This should succeed, even though they are different types
DROP TABLE FKTABLE;
CREATE TEMP TABLE FKTABLE (ftest1 varchar);
ALTER TABLE FKTABLE ADD FOREIGN KEY(ftest1) references pktable;
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- As should this
ALTER TABLE FKTABLE ADD FOREIGN KEY(ftest1) references pktable(ptest1);
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
DROP TABLE pktable;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
DROP TABLE fktable;
CREATE TEMP TABLE PKTABLE (ptest1 int, ptest2 text,
PRIMARY KEY(ptest1, ptest2));
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-- This should fail, because we just chose really odd types
CREATE TEMP TABLE FKTABLE (ftest1 cidr, ftest2 datetime);
ALTER TABLE FKTABLE ADD FOREIGN KEY(ftest1, ftest2) references pktable;
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'cidr' and 'integer'
You will have to retype this query using an explicit cast
-- Again, so should this...
CREATE TEMP TABLE FKTABLE (ftest1 cidr, ftest2 datetime);
ALTER TABLE FKTABLE ADD FOREIGN KEY(ftest1, ftest2)
references pktable(ptest1, ptest2);
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'cidr' and 'integer'
You will have to retype this query using an explicit cast
-- This fails because we mixed up the column ordering
CREATE TEMP TABLE FKTABLE (ftest1 int, ftest2 text);
ALTER TABLE FKTABLE ADD FOREIGN KEY(ftest1, ftest2)
references pktable(ptest2, ptest1);
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'integer' and 'text'
You will have to retype this query using an explicit cast
-- As does this...
ALTER TABLE FKTABLE ADD FOREIGN KEY(ftest2, ftest1)
references pktable(ptest1, ptest2);
-INFO: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: ALTER TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
-- temp tables should go away by themselves, need not drop them.
create table atacc1 ( test int );
-- add a unique constraint
alter table atacc1 add constraint atacc_test1 unique (test);
-INFO: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc_test1' for table 'atacc1'
+NOTICE: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc_test1' for table 'atacc1'
-- insert first value
insert into atacc1 (test) values (2);
-- should fail
insert into atacc1 (test) values (4);
-- try adding a unique oid constraint
alter table atacc1 add constraint atacc_oid1 unique(oid);
-INFO: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc_oid1' for table 'atacc1'
+NOTICE: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc_oid1' for table 'atacc1'
drop table atacc1;
-- let's do one where the unique constraint fails when added
create table atacc1 ( test int );
insert into atacc1 (test) values (2);
-- add a unique constraint (fails)
alter table atacc1 add constraint atacc_test1 unique (test);
-INFO: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc_test1' for table 'atacc1'
+NOTICE: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc_test1' for table 'atacc1'
ERROR: Cannot create unique index. Table contains non-unique values
insert into atacc1 (test) values (3);
drop table atacc1;
create table atacc1 ( test int, test2 int);
-- add a unique constraint
alter table atacc1 add constraint atacc_test1 unique (test, test2);
-INFO: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc_test1' for table 'atacc1'
+NOTICE: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc_test1' for table 'atacc1'
-- insert initial value
insert into atacc1 (test,test2) values (4,4);
-- should fail
drop table atacc1;
-- lets do some naming tests
create table atacc1 (test int, test2 int, unique(test));
-INFO: CREATE TABLE / UNIQUE will create implicit index 'atacc1_test_key' for table 'atacc1'
+NOTICE: CREATE TABLE / UNIQUE will create implicit index 'atacc1_test_key' for table 'atacc1'
alter table atacc1 add unique (test2);
-INFO: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc1_test2_key' for table 'atacc1'
+NOTICE: ALTER TABLE / ADD UNIQUE will create implicit index 'atacc1_test2_key' for table 'atacc1'
-- should fail for @@ second one @@
insert into atacc1 (test2, test) values (3, 3);
insert into atacc1 (test2, test) values (2, 3);
--- test creation of SERIAL column
---
CREATE TABLE serialTest (f1 text, f2 serial);
-INFO: CREATE TABLE will create implicit sequence 'serialtest_f2_seq' for SERIAL column 'serialtest.f2'
-INFO: CREATE TABLE / UNIQUE will create implicit index 'serialtest_f2_key' for table 'serialtest'
+NOTICE: CREATE TABLE will create implicit sequence 'serialtest_f2_seq' for SERIAL column 'serialtest.f2'
+NOTICE: CREATE TABLE / UNIQUE will create implicit index 'serialtest_f2_key' for table 'serialtest'
INSERT INTO serialTest VALUES ('foo');
INSERT INTO serialTest VALUES ('bar');
INSERT INTO serialTest VALUES ('force', 100);
CREATE TABLE stud_emp (
percent int4
) INHERITS (emp, student);
-INFO: CREATE TABLE: merging multiple inherited definitions of attribute "name"
-INFO: CREATE TABLE: merging multiple inherited definitions of attribute "age"
-INFO: CREATE TABLE: merging multiple inherited definitions of attribute "location"
+NOTICE: CREATE TABLE: merging multiple inherited definitions of attribute "name"
+NOTICE: CREATE TABLE: merging multiple inherited definitions of attribute "age"
+NOTICE: CREATE TABLE: merging multiple inherited definitions of attribute "location"
CREATE TABLE city (
name name,
location box,
CREATE TABLE d_star (
d float8
) INHERITS (b_star, c_star);
-INFO: CREATE TABLE: merging multiple inherited definitions of attribute "class"
-INFO: CREATE TABLE: merging multiple inherited definitions of attribute "a"
+NOTICE: CREATE TABLE: merging multiple inherited definitions of attribute "class"
+NOTICE: CREATE TABLE: merging multiple inherited definitions of attribute "a"
CREATE TABLE e_star (
e int2
) INHERITS (c_star);
-- not in a xact
abort;
-NOTICE: ROLLBACK: no transaction in progress
+WARNING: ROLLBACK: no transaction in progress
-- not in a xact
end;
-NOTICE: COMMIT: no transaction in progress
+WARNING: COMMIT: no transaction in progress
--
-- DEFINE AGGREGATE
-- sfunc/finalfunc type disagreement
-- First test, check and cascade
--
CREATE TABLE PKTABLE ( ptest1 int PRIMARY KEY, ptest2 text );
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE ( ftest1 int REFERENCES PKTABLE MATCH FULL ON DELETE CASCADE ON UPDATE CASCADE, ftest2 int );
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Insert test data into PKTABLE
INSERT INTO PKTABLE VALUES (1, 'Test1');
INSERT INTO PKTABLE VALUES (2, 'Test2');
(3 rows)
DROP TABLE PKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
DROP TABLE FKTABLE;
--
-- check set NULL and table constraint on multiple columns
--
CREATE TABLE PKTABLE ( ptest1 int, ptest2 int, ptest3 text, PRIMARY KEY(ptest1, ptest2) );
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE ( ftest1 int, ftest2 int, ftest3 int, CONSTRAINT constrname FOREIGN KEY(ftest1, ftest2)
REFERENCES PKTABLE MATCH FULL ON DELETE SET NULL ON UPDATE SET NULL);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Insert test data into PKTABLE
INSERT INTO PKTABLE VALUES (1, 2, 'Test1');
INSERT INTO PKTABLE VALUES (1, 3, 'Test1-2');
(5 rows)
DROP TABLE PKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
DROP TABLE FKTABLE;
--
-- check set default and table constraint on multiple columns
--
CREATE TABLE PKTABLE ( ptest1 int, ptest2 int, ptest3 text, PRIMARY KEY(ptest1, ptest2) );
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE ( ftest1 int DEFAULT -1, ftest2 int DEFAULT -2, ftest3 int, CONSTRAINT constrname2 FOREIGN KEY(ftest1, ftest2)
REFERENCES PKTABLE MATCH FULL ON DELETE SET DEFAULT ON UPDATE SET DEFAULT);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Insert a value in PKTABLE for default
INSERT INTO PKTABLE VALUES (-1, -2, 'The Default!');
-- Insert test data into PKTABLE
(5 rows)
DROP TABLE PKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
DROP TABLE FKTABLE;
--
-- First test, check with no on delete or on update
--
CREATE TABLE PKTABLE ( ptest1 int PRIMARY KEY, ptest2 text );
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE ( ftest1 int REFERENCES PKTABLE MATCH FULL, ftest2 int );
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Insert test data into PKTABLE
INSERT INTO PKTABLE VALUES (1, 'Test1');
INSERT INTO PKTABLE VALUES (2, 'Test2');
(4 rows)
DROP TABLE PKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "fktable"
DROP TABLE FKTABLE;
-- MATCH unspecified
-- Base test restricting update/delete
CREATE TABLE PKTABLE ( ptest1 int, ptest2 int, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2, ptest3) );
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE ( ftest1 int, ftest2 int, ftest3 int, ftest4 int, CONSTRAINT constrname3
FOREIGN KEY(ftest1, ftest2, ftest3) REFERENCES PKTABLE);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Insert Primary Key values
INSERT INTO PKTABLE VALUES (1, 2, 3, 'test1');
INSERT INTO PKTABLE VALUES (1, 3, 3, 'test2');
(5 rows)
DROP TABLE FKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
DROP TABLE PKTABLE;
-- cascade update/delete
CREATE TABLE PKTABLE ( ptest1 int, ptest2 int, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2, ptest3) );
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE ( ftest1 int, ftest2 int, ftest3 int, ftest4 int, CONSTRAINT constrname3
FOREIGN KEY(ftest1, ftest2, ftest3) REFERENCES PKTABLE
ON DELETE CASCADE ON UPDATE CASCADE);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Insert Primary Key values
INSERT INTO PKTABLE VALUES (1, 2, 3, 'test1');
INSERT INTO PKTABLE VALUES (1, 3, 3, 'test2');
(4 rows)
DROP TABLE FKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
DROP TABLE PKTABLE;
-- set null update / set default delete
CREATE TABLE PKTABLE ( ptest1 int, ptest2 int, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2, ptest3) );
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE ( ftest1 int DEFAULT 0, ftest2 int, ftest3 int, ftest4 int, CONSTRAINT constrname3
FOREIGN KEY(ftest1, ftest2, ftest3) REFERENCES PKTABLE
ON DELETE SET DEFAULT ON UPDATE SET NULL);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Insert Primary Key values
INSERT INTO PKTABLE VALUES (1, 2, 3, 'test1');
INSERT INTO PKTABLE VALUES (1, 3, 3, 'test2');
(6 rows)
DROP TABLE FKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
DROP TABLE PKTABLE;
-- set default update / set null delete
CREATE TABLE PKTABLE ( ptest1 int, ptest2 int, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2, ptest3) );
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE ( ftest1 int DEFAULT 0, ftest2 int DEFAULT -1, ftest3 int, ftest4 int, CONSTRAINT constrname3
FOREIGN KEY(ftest1, ftest2, ftest3) REFERENCES PKTABLE
ON DELETE SET NULL ON UPDATE SET DEFAULT);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- Insert Primary Key values
INSERT INTO PKTABLE VALUES (1, 2, 3, 'test1');
INSERT INTO PKTABLE VALUES (1, 3, 3, 'test2');
(7 rows)
DROP TABLE FKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
DROP TABLE PKTABLE;
CREATE TABLE PKTABLE (ptest1 int PRIMARY KEY);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
CREATE TABLE FKTABLE_FAIL1 ( ftest1 int, CONSTRAINT fkfail1 FOREIGN KEY (ftest2) REFERENCES PKTABLE);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: CREATE TABLE: column "ftest2" referenced in foreign key constraint does not exist
CREATE TABLE FKTABLE_FAIL2 ( ftest1 int, CONSTRAINT fkfail1 FOREIGN KEY (ftest1) REFERENCES PKTABLE(ptest2));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: UNIQUE constraint matching given keys for referenced table "pktable" not found
DROP TABLE FKTABLE_FAIL1;
ERROR: table "fktable_fail1" does not exist
DROP TABLE PKTABLE;
-- Test for referencing column number smaller than referenced constraint
CREATE TABLE PKTABLE (ptest1 int, ptest2 int, UNIQUE(ptest1, ptest2));
-INFO: CREATE TABLE / UNIQUE will create implicit index 'pktable_ptest1_key' for table 'pktable'
+NOTICE: CREATE TABLE / UNIQUE will create implicit index 'pktable_ptest1_key' for table 'pktable'
CREATE TABLE FKTABLE_FAIL1 (ftest1 int REFERENCES pktable(ptest1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: UNIQUE constraint matching given keys for referenced table "pktable" not found
DROP TABLE FKTABLE_FAIL1;
ERROR: table "fktable_fail1" does not exist
--
-- Basic one column, two table setup
CREATE TABLE PKTABLE (ptest1 int PRIMARY KEY);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-- This next should fail, because text=int does not exist
CREATE TABLE FKTABLE (ftest1 text REFERENCES pktable);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
-- This should also fail for the same reason, but here we
-- give the column name
CREATE TABLE FKTABLE (ftest1 text REFERENCES pktable(ptest1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
-- This should succeed, even though they are different types
-- because varchar=int does exist
CREATE TABLE FKTABLE (ftest1 varchar REFERENCES pktable);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
DROP TABLE FKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-- As should this
CREATE TABLE FKTABLE (ftest1 varchar REFERENCES pktable(ptest1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
DROP TABLE FKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
DROP TABLE PKTABLE;
-- Two columns, two tables
CREATE TABLE PKTABLE (ptest1 int, ptest2 text, PRIMARY KEY(ptest1, ptest2));
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-- This should fail, because we just chose really odd types
CREATE TABLE FKTABLE (ftest1 cidr, ftest2 datetime, FOREIGN KEY(ftest1, ftest2) REFERENCES pktable);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'cidr' and 'integer'
You will have to retype this query using an explicit cast
-- Again, so should this...
CREATE TABLE FKTABLE (ftest1 cidr, ftest2 datetime, FOREIGN KEY(ftest1, ftest2) REFERENCES pktable(ptest1, ptest2));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'cidr' and 'integer'
You will have to retype this query using an explicit cast
-- This fails because we mixed up the column ordering
CREATE TABLE FKTABLE (ftest1 int, ftest2 text, FOREIGN KEY(ftest2, ftest1) REFERENCES pktable);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
-- As does this...
CREATE TABLE FKTABLE (ftest1 int, ftest2 text, FOREIGN KEY(ftest2, ftest1) REFERENCES pktable(ptest1, ptest2));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
-- And again..
CREATE TABLE FKTABLE (ftest1 int, ftest2 text, FOREIGN KEY(ftest1, ftest2) REFERENCES pktable(ptest2, ptest1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'integer' and 'text'
You will have to retype this query using an explicit cast
-- This works...
CREATE TABLE FKTABLE (ftest1 int, ftest2 text, FOREIGN KEY(ftest2, ftest1) REFERENCES pktable(ptest2, ptest1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
DROP TABLE FKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-- As does this
CREATE TABLE FKTABLE (ftest1 int, ftest2 text, FOREIGN KEY(ftest1, ftest2) REFERENCES pktable(ptest1, ptest2));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
DROP TABLE FKTABLE;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
DROP TABLE PKTABLE;
-- Two columns, same table
-- Make sure this still works...
CREATE TABLE PKTABLE (ptest1 int, ptest2 text, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2), FOREIGN KEY(ptest3,
ptest4) REFERENCES pktable(ptest1, ptest2));
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
DROP TABLE PKTABLE;
-- And this,
CREATE TABLE PKTABLE (ptest1 int, ptest2 text, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2), FOREIGN KEY(ptest3,
ptest4) REFERENCES pktable);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
DROP TABLE PKTABLE;
-- This shouldn't (mixed up columns)
CREATE TABLE PKTABLE (ptest1 int, ptest2 text, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2), FOREIGN KEY(ptest3,
ptest4) REFERENCES pktable(ptest2, ptest1));
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'integer' and 'text'
You will have to retype this query using an explicit cast
-- Nor should this... (same reason, we have 4,3 referencing 1,2 which mismatches types
CREATE TABLE PKTABLE (ptest1 int, ptest2 text, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2), FOREIGN KEY(ptest4,
ptest3) REFERENCES pktable(ptest1, ptest2));
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
-- Not this one either... Same as the last one except we didn't defined the columns being referenced.
CREATE TABLE PKTABLE (ptest1 int, ptest2 text, ptest3 int, ptest4 text, PRIMARY KEY(ptest1, ptest2), FOREIGN KEY(ptest4,
ptest3) REFERENCES pktable);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
--
-- Basic 2 table case: 1 column of matching types.
create table pktable_base (base1 int not null);
create table pktable (ptest1 int, primary key(base1), unique(base1, ptest1)) inherits (pktable_base);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE / UNIQUE will create implicit index 'pktable_base1_key' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / UNIQUE will create implicit index 'pktable_base1_key' for table 'pktable'
create table fktable (ftest1 int references pktable(base1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- now some ins, upd, del
insert into pktable(base1) values (1);
insert into pktable(base1) values (2);
delete from pktable where base1>3;
-- cleanup
drop table fktable;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
delete from pktable;
-- Now 2 columns 2 tables, matching types
create table fktable (ftest1 int, ftest2 int, foreign key(ftest1, ftest2) references pktable(base1, ptest1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
-- now some ins, upd, del
insert into pktable(base1, ptest1) values (1, 1);
insert into pktable(base1, ptest1) values (2, 2);
delete from pktable where base1>3;
-- cleanup
drop table fktable;
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
-INFO: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
+NOTICE: DROP TABLE implicitly drops referential integrity trigger from table "pktable"
drop table pktable;
drop table pktable_base;
-- Now we'll do one all in 1 table with 2 columns of matching types
create table pktable_base(base1 int not null, base2 int);
create table pktable(ptest1 int, ptest2 int, primary key(base1, ptest1), foreign key(base2, ptest2) references
pktable(base1, ptest1)) inherits (pktable_base);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
insert into pktable (base1, ptest1, base2, ptest2) values (1, 1, 1, 1);
insert into pktable (base1, ptest1, base2, ptest2) values (2, 1, 1, 1);
insert into pktable (base1, ptest1, base2, ptest2) values (2, 2, 2, 1);
-- 2 columns (2 tables), mismatched types
create table pktable_base(base1 int not null);
create table pktable(ptest1 text, primary key(base1, ptest1)) inherits (pktable_base);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-- just generally bad types (with and without column references on the referenced table)
create table fktable(ftest1 cidr, ftest2 int[], foreign key (ftest1, ftest2) references pktable);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'cidr' and 'integer'
You will have to retype this query using an explicit cast
create table fktable(ftest1 cidr, ftest2 int[], foreign key (ftest1, ftest2) references pktable(base1, ptest1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'cidr' and 'integer'
You will have to retype this query using an explicit cast
-- let's mix up which columns reference which
create table fktable(ftest1 int, ftest2 text, foreign key(ftest2, ftest1) references pktable);
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
create table fktable(ftest1 int, ftest2 text, foreign key(ftest2, ftest1) references pktable(base1, ptest1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
create table fktable(ftest1 int, ftest2 text, foreign key(ftest1, ftest2) references pktable(ptest1, base1));
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'integer' and 'text'
You will have to retype this query using an explicit cast
drop table pktable;
create table pktable_base(base1 int not null, base2 int);
create table pktable(ptest1 text, ptest2 text[], primary key(base1, ptest1), foreign key(base2, ptest2) references
pktable(base1, ptest1)) inherits (pktable_base);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text[]' and 'text'
You will have to retype this query using an explicit cast
create table pktable(ptest1 text, ptest2 text, primary key(base1, ptest1), foreign key(base2, ptest2) references
pktable(ptest1, base1)) inherits (pktable_base);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'integer' and 'text'
You will have to retype this query using an explicit cast
create table pktable(ptest1 text, ptest2 text, primary key(base1, ptest1), foreign key(ptest2, base2) references
pktable(base1, ptest1)) inherits (pktable_base);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
create table pktable(ptest1 text, ptest2 text, primary key(base1, ptest1), foreign key(ptest2, base2) references
pktable(base1, ptest1)) inherits (pktable_base);
-INFO: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
-INFO: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
+NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'pktable_pkey' for table 'pktable'
+NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY check(s)
ERROR: Unable to identify an operator '=' for types 'text' and 'integer'
You will have to retype this query using an explicit cast
drop table pktable;
CREATE TABLE b (bb TEXT) INHERITS (a);
CREATE TABLE c (cc TEXT) INHERITS (a);
CREATE TABLE d (dd TEXT) INHERITS (b,c,a);
-INFO: CREATE TABLE: merging multiple inherited definitions of attribute "aa"
-INFO: CREATE TABLE: merging multiple inherited definitions of attribute "aa"
+NOTICE: CREATE TABLE: merging multiple inherited definitions of attribute "aa"
+NOTICE: CREATE TABLE: merging multiple inherited definitions of attribute "aa"
INSERT INTO a(aa) VALUES('aaa');
INSERT INTO a(aa) VALUES('aaaa');
INSERT INTO a(aa) VALUES('aaaaa');
CREATE GROUP regressgroup2 WITH USER regressuser1, regressuser2;
ALTER GROUP regressgroup1 ADD USER regressuser4;
ALTER GROUP regressgroup2 ADD USER regressuser2; -- duplicate
-NOTICE: ALTER GROUP: user "regressuser2" is already in group "regressgroup2"
+WARNING: ALTER GROUP: user "regressuser2" is already in group "regressgroup2"
ALTER GROUP regressgroup2 DROP USER regressuser2;
ALTER GROUP regressgroup2 ADD USER regressuser4;
-- test owner privileges
insert into fkeys values (60, '6', 4);
ERROR: check_fkeys_pkey2_exist: tuple references non-existing key in fkeys2
delete from pkeys where pkey1 = 30 and pkey2 = '3';
-NOTICE: check_pkeys_fkey_cascade: 1 tuple(s) of fkeys are deleted
ERROR: check_fkeys2_fkey_restrict: tuple referenced in fkeys
delete from pkeys where pkey1 = 40 and pkey2 = '4';
-NOTICE: check_pkeys_fkey_cascade: 1 tuple(s) of fkeys are deleted
-NOTICE: check_pkeys_fkey_cascade: 1 tuple(s) of fkeys2 are deleted
update pkeys set pkey1 = 7, pkey2 = '70' where pkey1 = 50 and pkey2 = '5';
-NOTICE: check_pkeys_fkey_cascade: 1 tuple(s) of fkeys are deleted
ERROR: check_fkeys2_fkey_restrict: tuple referenced in fkeys
update pkeys set pkey1 = 7, pkey2 = '70' where pkey1 = 10 and pkey2 = '1';
-NOTICE: check_pkeys_fkey_cascade: 1 tuple(s) of fkeys are deleted
-NOTICE: check_pkeys_fkey_cascade: 1 tuple(s) of fkeys2 are deleted
DROP TABLE pkeys;
DROP TABLE fkeys;
DROP TABLE fkeys2;
/*
- * $Header: /cvsroot/pgsql/src/test/regress/regress.c,v 1.49 2001/11/05 17:46:40 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/test/regress/regress.c,v 1.50 2002/03/06 06:10:50 momjian Exp $
*/
#include "postgres.h"
))));
}
- elog(NOTICE, "funny_dup17 (fired %s) on level %3d: %d/%d tuples inserted/selected",
+ elog(DEBUG3, "funny_dup17 (fired %s) on level %3d: %d/%d tuples inserted/selected",
when, *level, inserted, selected);
SPI_finish();