*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.28 1997/11/02 15:24:09 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.29 1998/01/05 03:28:57 momjian Exp $
*
* NOTES
* The old interface functions have been converted to macros
break;
default:
if (att[i]->attlen < sizeof(int32))
- elog(WARN, "ComputeDataSize: attribute %d has len %d",
+ elog(ABORT, "ComputeDataSize: attribute %d has len %d",
i, att[i]->attlen);
if (att[i]->attalign == 'd')
data_length = DOUBLEALIGN(data_length) + att[i]->attlen;
break;
default:
if (att[i]->attlen < sizeof(int32))
- elog(WARN, "DataFill: attribute %d has len %d",
+ elog(ABORT, "DataFill: attribute %d has len %d",
i, att[i]->attlen);
if (att[i]->attalign == 'd')
{
break;
case 0:
- elog(WARN, "heap_attisnull: zero attnum disallowed");
+ elog(ABORT, "heap_attisnull: zero attnum disallowed");
default:
- elog(WARN, "heap_attisnull: undefined negative attnum");
+ elog(ABORT, "heap_attisnull: undefined negative attnum");
}
return (0);
return sizeof f->t_cmax;
default:
- elog(WARN, "sysattrlen: System attribute number %d unknown.", attno);
+ elog(ABORT, "sysattrlen: System attribute number %d unknown.", attno);
return 0;
}
}
break;
default:
byval = true;
- elog(WARN, "sysattrbyval: System attribute number %d unknown.",
+ elog(ABORT, "sysattrbyval: System attribute number %d unknown.",
attno);
break;
}
case MaxCommandIdAttributeNumber:
return ((Datum) (long) tup->t_cmax);
default:
- elog(WARN, "heap_getsysattr: undefined attnum %d", attnum);
+ elog(ABORT, "heap_getsysattr: undefined attnum %d", attnum);
}
return ((Datum) NULL);
}
default:
if (att[j]->attlen < sizeof(int32))
{
- elog(WARN,
+ elog(ABORT,
"fastgetattr: attribute %d has len %d",
j, att[j]->attlen);
}
break;
default:
if (att[i]->attlen < sizeof(int32))
- elog(WARN,
+ elog(ABORT,
"fastgetattr2: attribute %d has len %d",
i, att[i]->attlen);
if (att[i]->attalign == 'd')
break;
default:
if (att[attnum]->attlen < sizeof(int32))
- elog(WARN, "fastgetattr3: attribute %d has len %d",
+ elog(ABORT, "fastgetattr3: attribute %d has len %d",
attnum, att[attnum]->attlen);
if (att[attnum]->attalign == 'd')
off = DOUBLEALIGN(off);
/* XXX For now, just prevent an undetectable executor related error */
if (tuple->t_len > MAXTUPLEN)
{
- elog(WARN, "palloctup: cannot handle length %d tuples",
+ elog(ABORT, "palloctup: cannot handle length %d tuples",
tuple->t_len);
}
}
if (numberOfAttributes > MaxHeapAttributeNumber)
- elog(WARN, "heap_formtuple: numberOfAttributes of %d > %d",
+ elog(ABORT, "heap_formtuple: numberOfAttributes of %d > %d",
numberOfAttributes, MaxHeapAttributeNumber);
if (hasnull)
}
else if (repl[attoff] != 'r')
{
- elog(WARN, "heap_modifytuple: repl is \\%3d", repl[attoff]);
+ elog(ABORT, "heap_modifytuple: repl is \\%3d", repl[attoff]);
}
else
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/common/indextuple.c,v 1.20 1997/11/02 15:24:11 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/common/indextuple.c,v 1.21 1998/01/05 03:28:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
int numberOfAttributes = tupleDescriptor->natts;
if (numberOfAttributes > MaxIndexAttributeNumber)
- elog(WARN, "index_formtuple: numberOfAttributes of %d > %d",
+ elog(ABORT, "index_formtuple: numberOfAttributes of %d > %d",
numberOfAttributes, MaxIndexAttributeNumber);
*/
if (size & 0xE000)
- elog(WARN, "index_formtuple: data takes %d bytes: too big", size);
+ elog(ABORT, "index_formtuple: data takes %d bytes: too big", size);
infomask |= size;
off = (att[j]->attalign == 'd') ?
DOUBLEALIGN(off) : LONGALIGN(off);
else
- elog(WARN, "fastgetiattr: attribute %d has len %d",
+ elog(ABORT, "fastgetiattr: attribute %d has len %d",
j, att[j]->attlen);
break;
DOUBLEALIGN(off) + att[i]->attlen :
LONGALIGN(off) + att[i]->attlen;
else
- elog(WARN, "fastgetiattr2: attribute %d has len %d",
+ elog(ABORT, "fastgetiattr2: attribute %d has len %d",
i, att[i]->attlen);
break;
break;
default:
if (att[attnum]->attlen < sizeof(int32))
- elog(WARN, "fastgetattr3: attribute %d has len %d",
+ elog(ABORT, "fastgetattr3: attribute %d has len %d",
attnum, att[attnum]->attlen);
if (att[attnum]->attalign == 'd')
off = DOUBLEALIGN(off);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/common/printtup.c,v 1.20 1997/12/08 04:42:43 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/common/printtup.c,v 1.21 1998/01/05 03:29:00 momjian Exp $
*
*-------------------------------------------------------------------------
*/
return ((Oid)
((TypeTupleForm) GETSTRUCT(typeTuple))->typoutput);
- elog(WARN, "typtoout: Cache lookup of type %d failed", type);
+ elog(ABORT, "typtoout: Cache lookup of type %d failed", type);
return (InvalidOid);
}
return ((Oid)
((TypeTupleForm) GETSTRUCT(typeTuple))->typelem);
- elog(WARN, "typtoout: Cache lookup of type %d failed", type);
+ elog(ABORT, "typtoout: Cache lookup of type %d failed", type);
return (InvalidOid);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.29 1997/11/25 21:58:35 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.30 1998/01/05 03:29:01 momjian Exp $
*
* NOTES
* some of the executor utility code such as "ExecTypeFromTL" should be
* RelationNameCreateHeapRelation() calls BuildDesc() which
* calls this routine and since EMP does not exist yet, the
* system cache lookup below fails. That's fine, but rather
- * then doing a elog(WARN) we just leave that information
+ * then doing a elog(ABORT) we just leave that information
* uninitialized, return false, then fix things up later.
* -cim 6/14/90
* ----------------
TupleDescMakeSelfReference(desc, attnum, relname);
}
else
- elog(WARN, "DefineRelation: no such type %s",
+ elog(ABORT, "DefineRelation: no such type %s",
typename);
}
*/
if (oldPred == NULL && (nb = RelationGetNumberOfBlocks(index)) != 0)
- elog(WARN, "%.16s already contains data", &(index->rd_rel->relname.data[0]));
+ elog(ABORT, "%.16s already contains data", &(index->rd_rel->relname.data[0]));
/* initialize the root page (if this is a new index) */
if (oldPred == NULL)
0, 0, 0);
itupform = (IndexTupleForm) GETSTRUCT(htup);
if (!HeapTupleIsValid(htup))
- elog(WARN, "initGISTstate: index %d not found", index->rd_id);
+ elog(ABORT, "initGISTstate: index %d not found", index->rd_id);
giststate->haskeytype = itupform->indhaskeytype;
if (giststate->haskeytype)
{
0, 0);
if (!HeapTupleIsValid(htup))
{
- elog(WARN, "initGISTstate: no attribute tuple %d %d",
+ elog(ABORT, "initGISTstate: no attribute tuple %d %d",
itupform->indexrelid, FirstOffsetNumber);
return;
}
if (!IndexScanIsValid(s))
{
- elog(WARN, "gistrescan: invalid scan.");
+ elog(ABORT, "gistrescan: invalid scan.");
return;
}
}
if (l == (GISTScanList) NULL)
- elog(WARN, "GiST scan list corrupted -- cannot find 0x%lx", s);
+ elog(ABORT, "GiST scan list corrupted -- cannot find 0x%lx", s);
if (prev == (GISTScanList) NULL)
GISTScans = l->gsl_next;
break;
default:
- elog(WARN, "Bad operation in GiST scan adjust: %d", op);
+ elog(ABORT, "Bad operation in GiST scan adjust: %d", op);
}
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/hash/hashinsert.c,v 1.10 1997/09/08 02:20:16 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashinsert.c,v 1.11 1998/01/05 03:29:15 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/* we need a scan key to do our search, so build one */
itup = &(hitem->hash_itup);
if ((natts = rel->rd_rel->relnatts) != 1)
- elog(WARN, "Hash indices valid for only one index key.");
+ elog(ABORT, "Hash indices valid for only one index key.");
itup_scankey = _hash_mkscankey(rel, itup, metap);
/*
if (PageGetFreeSpace(page) < itemsz)
{
/* it doesn't fit on an empty page -- give up */
- elog(WARN, "hash item too large");
+ elog(ABORT, "hash item too large");
}
}
_hash_checkpage(page, LH_OVERFLOW_PAGE);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/hash/hashovfl.c,v 1.13 1997/09/18 20:19:43 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashovfl.c,v 1.14 1998/01/05 03:29:20 momjian Exp $
*
* NOTES
* Overflow pages look like ordinary relation pages.
oaddr = _hash_getovfladdr(rel, metabufp);
if (oaddr == InvalidOvflAddress)
{
- elog(WARN, "_hash_addovflpage: problem with _hash_getovfladdr.");
+ elog(ABORT, "_hash_addovflpage: problem with _hash_getovfladdr.");
}
ovflblkno = OADDR_TO_BLKNO(OADDR_OF(SPLITNUM(oaddr), OPAGENUM(oaddr)));
Assert(BlockNumberIsValid(ovflblkno));
{
if (++splitnum >= NCACHED)
{
- elog(WARN, OVMSG);
+ elog(ABORT, OVMSG);
}
metap->OVFL_POINT = splitnum;
metap->SPARES[splitnum] = metap->SPARES[splitnum - 1];
free_page++;
if (free_page >= NCACHED)
{
- elog(WARN, OVMSG);
+ elog(ABORT, OVMSG);
}
/*
if (_hash_initbitmap(rel, metap, OADDR_OF(splitnum, offset),
1, free_page))
{
- elog(WARN, "overflow_page: problem with _hash_initbitmap.");
+ elog(ABORT, "overflow_page: problem with _hash_initbitmap.");
}
metap->SPARES[splitnum]++;
offset++;
{
if (++splitnum >= NCACHED)
{
- elog(WARN, OVMSG);
+ elog(ABORT, OVMSG);
}
metap->OVFL_POINT = splitnum;
metap->SPARES[splitnum] = metap->SPARES[splitnum - 1];
offset = (i ? bit - metap->SPARES[i - 1] : bit);
if (offset >= SPLITMASK)
{
- elog(WARN, OVMSG);
+ elog(ABORT, OVMSG);
}
/* initialize this page */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/hash/hashpage.c,v 1.13 1997/09/18 20:19:46 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashpage.c,v 1.14 1998/01/05 03:29:22 momjian Exp $
*
* NOTES
* Postgres hash pages look like ordinary relation pages. The opaque
if ((nblocks = RelationGetNumberOfBlocks(rel)) != 0)
{
- elog(WARN, "Cannot initialize non-empty hash table %s",
+ elog(ABORT, "Cannot initialize non-empty hash table %s",
RelationGetRelationName(rel));
}
* created the first two buckets above.
*/
if (_hash_initbitmap(rel, metap, OADDR_OF(lg2nelem, 1), lg2nelem + 1, 0))
- elog(WARN, "Problem with _hash_initbitmap.");
+ elog(ABORT, "Problem with _hash_initbitmap.");
/* all done */
_hash_wrtnorelbuf(rel, metabuf);
if (blkno == P_NEW)
{
- elog(WARN, "_hash_getbuf: internal error: hash AM does not use P_NEW");
+ elog(ABORT, "_hash_getbuf: internal error: hash AM does not use P_NEW");
}
switch (access)
{
_hash_setpagelock(rel, blkno, access);
break;
default:
- elog(WARN, "_hash_getbuf: invalid access (%d) on new blk: %s",
+ elog(ABORT, "_hash_getbuf: invalid access (%d) on new blk: %s",
access, RelationGetRelationName(rel));
break;
}
_hash_unsetpagelock(rel, blkno, access);
break;
default:
- elog(WARN, "_hash_relbuf: invalid access (%d) on blk %x: %s",
+ elog(ABORT, "_hash_relbuf: invalid access (%d) on blk %x: %s",
access, blkno, RelationGetRelationName(rel));
}
_hash_relbuf(rel, *bufp, from_access);
break;
default:
- elog(WARN, "_hash_chgbufaccess: invalid access (%d) on blk %x: %s",
+ elog(ABORT, "_hash_chgbufaccess: invalid access (%d) on blk %x: %s",
from_access, blkno, RelationGetRelationName(rel));
break;
}
RelationSetSingleRLockPage(rel, &iptr);
break;
default:
- elog(WARN, "_hash_setpagelock: invalid access (%d) on blk %x: %s",
+ elog(ABORT, "_hash_setpagelock: invalid access (%d) on blk %x: %s",
access, blkno, RelationGetRelationName(rel));
break;
}
RelationUnsetSingleRLockPage(rel, &iptr);
break;
default:
- elog(WARN, "_hash_unsetpagelock: invalid access (%d) on blk %x: %s",
+ elog(ABORT, "_hash_unsetpagelock: invalid access (%d) on blk %x: %s",
access, blkno, RelationGetRelationName(rel));
break;
}
_hash_checkpage(opage, LH_OVERFLOW_PAGE);
if (PageIsEmpty(opage))
{
- elog(WARN, "_hash_splitpage: empty overflow page %d", oblkno);
+ elog(ABORT, "_hash_splitpage: empty overflow page %d", oblkno);
}
oopaque = (HashPageOpaque) PageGetSpecialPointer(opage);
}
/* we're guaranteed that an ovfl page has at least 1 tuple */
if (PageIsEmpty(opage))
{
- elog(WARN, "_hash_splitpage: empty ovfl page %d!",
+ elog(ABORT, "_hash_splitpage: empty ovfl page %d!",
oblkno);
}
ooffnum = FirstOffsetNumber;
oopaque = (HashPageOpaque) PageGetSpecialPointer(opage);
if (PageIsEmpty(opage))
{
- elog(WARN, "_hash_splitpage: empty overflow page %d",
+ elog(ABORT, "_hash_splitpage: empty overflow page %d",
oblkno);
}
ooffnum = FirstOffsetNumber;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/hash/hashscan.c,v 1.11 1997/09/08 21:40:48 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashscan.c,v 1.12 1998/01/05 03:29:24 momjian Exp $
*
* NOTES
* Because we can be doing an index scan on a relation while we
}
if (chk == (HashScanList) NULL)
- elog(WARN, "hash scan list trashed; can't find 0x%lx", scan);
+ elog(ABORT, "hash scan list trashed; can't find 0x%lx", scan);
if (last == (HashScanList) NULL)
HashScans = chk->hashsl_next;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/hash/hashutil.c,v 1.11 1997/09/08 02:20:25 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashutil.c,v 1.12 1998/01/05 03:29:26 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/* disallow nulls in hash keys */
if (itup->t_info & INDEX_NULL_MASK)
- elog(WARN, "hash indices cannot include null keys");
+ elog(ABORT, "hash indices cannot include null keys");
/* make a copy of the index tuple with room for the sequence number */
tuplen = IndexTupleSize(itup);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/heap/heapam.c,v 1.23 1997/11/21 18:03:55 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/heap/heapam.c,v 1.24 1998/01/05 03:29:29 momjian Exp $
*
*
* INTERFACE ROUTINES
#ifndef NO_BUFFERISVALID
if (!BufferIsValid(*b))
- elog(WARN, "heapgettup: failed ReadBuffer");
+ elog(ABORT, "heapgettup: failed ReadBuffer");
#endif
dp = (Page) BufferGetPage(*b);
#ifndef NO_BUFFERISVALID
if (!BufferIsValid(*b))
{
- elog(WARN, "heapgettup: failed ReadBuffer");
+ elog(ABORT, "heapgettup: failed ReadBuffer");
}
#endif
#ifndef NO_BUFFERISVALID
if (!BufferIsValid(*b))
{
- elog(WARN, "heapgettup: failed ReadBuffer");
+ elog(ABORT, "heapgettup: failed ReadBuffer");
}
#endif
#ifndef NO_BUFFERISVALID
if (!BufferIsValid(*b))
{
- elog(WARN, "heapgettup: failed ReadBuffer");
+ elog(ABORT, "heapgettup: failed ReadBuffer");
}
#endif
dp = (Page) BufferGetPage(*b);
if (RelationIsValid(r) && r->rd_rel->relkind == RELKIND_INDEX)
{
- elog(WARN, "%s is an index relation", r->rd_rel->relname.data);
+ elog(ABORT, "%s is an index relation", r->rd_rel->relname.data);
}
return (r);
if (RelationIsValid(r) && r->rd_rel->relkind == RELKIND_INDEX)
{
- elog(WARN, "%s is an index relation", r->rd_rel->relname.data);
+ elog(ABORT, "%s is an index relation", r->rd_rel->relname.data);
}
return (r);
* ----------------
*/
if (RelationIsValid(relation) == false)
- elog(WARN, "heap_beginscan: !RelationIsValid(relation)");
+ elog(ABORT, "heap_beginscan: !RelationIsValid(relation)");
/* ----------------
* set relation level read lock
* ----------------
*/
if (sdesc == NULL)
- elog(WARN, "heap_getnext: NULL relscan");
+ elog(ABORT, "heap_getnext: NULL relscan");
/* ----------------
* initialize return buffer to InvalidBuffer
#ifndef NO_BUFFERISVALID
if (!BufferIsValid(buffer))
{
- elog(WARN, "heap_fetch: %s relation: ReadBuffer(%lx) failed",
+ elog(ABORT, "heap_fetch: %s relation: ReadBuffer(%lx) failed",
&relation->rd_rel->relname, (long) tid);
}
#endif
#ifndef NO_BUFFERISVALID
if (!BufferIsValid(b))
{ /* XXX L_SH better ??? */
- elog(WARN, "heap_delete: failed ReadBuffer");
+ elog(ABORT, "heap_delete: failed ReadBuffer");
}
#endif /* NO_BUFFERISVALID */
/* XXX call something else */
ReleaseBuffer(b);
- elog(WARN, "heap_delete: (am)invalid tid");
+ elog(ABORT, "heap_delete: (am)invalid tid");
}
/* ----------------
if (!BufferIsValid(buffer))
{
/* XXX L_SH better ??? */
- elog(WARN, "amreplace: failed ReadBuffer");
+ elog(ABORT, "amreplace: failed ReadBuffer");
}
#endif /* NO_BUFFERISVALID */
if (!tuple)
{
ReleaseBuffer(buffer);
- elog(WARN, "heap_replace: (am)invalid otid");
+ elog(ABORT, "heap_replace: (am)invalid otid");
}
/* XXX order problems if not atomic assignment ??? */
*
*
* IDENTIFICATION
- * $Id: hio.c,v 1.11 1997/09/08 02:20:30 momjian Exp $
+ * $Id: hio.c,v 1.12 1998/01/05 03:29:30 momjian Exp $
*
*-------------------------------------------------------------------------
*/
#ifndef NO_BUFFERISVALID
if (!BufferIsValid(buffer))
{
- elog(WARN, "RelationPutHeapTuple: no buffer for %ld in %s",
+ elog(ABORT, "RelationPutHeapTuple: no buffer for %ld in %s",
blockIndex, &relation->rd_rel->relname);
}
#endif
PageInit(pageHeader, BufferGetPageSize(buffer), 0);
if (len > PageGetFreeSpace(pageHeader))
- elog(WARN, "Tuple is too big: size %d", len);
+ elog(ABORT, "Tuple is too big: size %d", len);
}
offnum = PageAddItem((Page) pageHeader, (Item) tuple,
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/index/genam.c,v 1.9 1997/09/08 02:20:33 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/index/genam.c,v 1.10 1998/01/05 03:29:32 momjian Exp $
*
* NOTES
* many of the old access method routines have been turned into
IndexScanDesc scan;
if (!RelationIsValid(relation))
- elog(WARN, "RelationGetIndexScan: relation invalid");
+ elog(ABORT, "RelationGetIndexScan: relation invalid");
scan = (IndexScanDesc) palloc(sizeof(IndexScanDescData));
ScanKey key)
{
if (!IndexScanIsValid(scan))
- elog(WARN, "IndexScanRestart: invalid scan");
+ elog(ABORT, "IndexScanRestart: invalid scan");
ItemPointerSetInvalid(&scan->previousItemData);
ItemPointerSetInvalid(&scan->currentItemData);
IndexScanEnd(IndexScanDesc scan)
{
if (!IndexScanIsValid(scan))
- elog(WARN, "IndexScanEnd: invalid scan");
+ elog(ABORT, "IndexScanEnd: invalid scan");
pfree(scan);
}
IndexScanRestorePosition(IndexScanDesc scan)
{
if (scan->flags & ScanUnmarked)
- elog(WARN, "IndexScanRestorePosition: no mark to restore");
+ elog(ABORT, "IndexScanRestorePosition: no mark to restore");
scan->previousItemData = scan->previousMarkData;
scan->currentItemData = scan->currentMarkData;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/index/indexam.c,v 1.17 1997/09/12 04:07:15 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/index/indexam.c,v 1.18 1998/01/05 03:29:34 momjian Exp $
*
* INTERFACE ROUTINES
* index_open - open an index relation by relationId
#define GET_REL_PROCEDURE(x,y) \
procedure = relation->rd_am->y; \
if (! RegProcedureIsValid(procedure)) \
- elog(WARN, "index_%s: invalid %s regproc", \
+ elog(ABORT, "index_%s: invalid %s regproc", \
CppAsString(x), CppAsString(y))
#define GET_SCAN_PROCEDURE(x,y) \
procedure = scan->relation->rd_am->y; \
if (! RegProcedureIsValid(procedure)) \
- elog(WARN, "index_%s: invalid %s regproc", \
+ elog(ABORT, "index_%s: invalid %s regproc", \
CppAsString(x), CppAsString(y))
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/index/Attic/istrat.c,v 1.13 1997/11/20 23:20:07 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/index/Attic/istrat.c,v 1.14 1998/01/05 03:29:38 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
if (!StrategyNumberIsValid(strategy))
{
- elog(WARN, "RelationGetStrategy: corrupted evaluation");
+ elog(ABORT, "RelationGetStrategy: corrupted evaluation");
}
}
}
}
- elog(WARN, "RelationInvokeStrategy: cannot evaluate strategy %d",
+ elog(ABORT, "RelationInvokeStrategy: cannot evaluate strategy %d",
strategy);
/* not reached, just to make compiler happy */
tuple = heap_getnext(scan, false, (Buffer *) NULL);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "OperatorObjectIdFillScanKeyEntry: unknown operator %lu",
+ elog(ABORT, "OperatorObjectIdFillScanKeyEntry: unknown operator %lu",
(uint32) operatorObjectId);
}
if (!RegProcedureIsValid(entry->sk_procedure))
{
- elog(WARN,
+ elog(ABORT,
"OperatorObjectIdFillScanKeyEntry: no procedure for operator %lu",
(uint32) operatorObjectId);
}
scan = heap_beginscan(relation, false, false, 1, entry);
tuple = heap_getnext(scan, 0, (Buffer *) NULL);
if (!HeapTupleIsValid(tuple))
- elog(WARN, "IndexSupportInitialize: corrupted catalogs");
+ elog(ABORT, "IndexSupportInitialize: corrupted catalogs");
/*
* XXX note that the following assumes the INDEX tuple is well formed
{
if (attributeIndex == 0)
{
- elog(WARN, "IndexSupportInitialize: no pg_index tuple");
+ elog(ABORT, "IndexSupportInitialize: no pg_index tuple");
}
break;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.22 1997/12/09 01:40:30 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.23 1998/01/05 03:29:45 momjian Exp $
*
*-------------------------------------------------------------------------
*/
htup = heap_fetch(heapRel, true, &(itup->t_tid), NULL);
if (htup != (HeapTuple) NULL)
{ /* it is a duplicate */
- elog(WARN, "Cannot insert a duplicate key into a unique index");
+ elog(ABORT, "Cannot insert a duplicate key into a unique index");
}
/* get next offnum */
if (offset < maxoff)
* if(IndexTupleDSize(newItem->bti_itup) >
* IndexTupleDSize(item->bti_itup)) { elog(NOTICE, "trying to
* overwrite a smaller value with a bigger one in _bt_updateitem");
- * elog(WARN, "this is not good."); }
+ * elog(ABORT, "this is not good."); }
*/
oldIndexTuple = &(item->bti_itup);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtpage.c,v 1.13 1997/09/18 20:19:49 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtpage.c,v 1.14 1998/01/05 03:29:50 momjian Exp $
*
* NOTES
* Postgres btree pages look like ordinary relation pages. The opaque
if ((nblocks = RelationGetNumberOfBlocks(rel)) != 0)
{
- elog(WARN, "Cannot initialize non-empty btree %s",
+ elog(ABORT, "Cannot initialize non-empty btree %s",
RelationGetRelationName(rel));
}
op = (BTPageOpaque) PageGetSpecialPointer(metap);
if (!(op->btpo_flags & BTP_META))
{
- elog(WARN, "Invalid metapage for index %s",
+ elog(ABORT, "Invalid metapage for index %s",
RelationGetRelationName(rel));
}
metad = BTPageGetMeta(metap);
if (metad->btm_magic != BTREE_MAGIC)
{
- elog(WARN, "Index %s is not a btree",
+ elog(ABORT, "Index %s is not a btree",
RelationGetRelationName(rel));
}
if (metad->btm_version != BTREE_VERSION)
{
- elog(WARN, "Version mismatch on %s: version %d file, version %d code",
+ elog(ABORT, "Version mismatch on %s: version %d file, version %d code",
RelationGetRelationName(rel),
metad->btm_version, BTREE_VERSION);
}
if (metad->btm_magic != BTREE_MAGIC)
{
- elog(WARN, "Index %s is not a btree",
+ elog(ABORT, "Index %s is not a btree",
RelationGetRelationName(rel));
}
if (metad->btm_version != BTREE_VERSION)
{
- elog(WARN, "Version mismatch on %s: version %d file, version %d code",
+ elog(ABORT, "Version mismatch on %s: version %d file, version %d code",
RelationGetRelationName(rel),
metad->btm_version, BTREE_VERSION);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/nbtree/Attic/nbtscan.c,v 1.10 1997/09/08 20:54:24 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/Attic/nbtscan.c,v 1.11 1998/01/05 03:29:52 momjian Exp $
*
*
* NOTES
}
if (chk == (BTScanList) NULL)
- elog(WARN, "btree scan list trashed; can't find 0x%lx", scan);
+ elog(ABORT, "btree scan list trashed; can't find 0x%lx", scan);
if (last == (BTScanList) NULL)
BTScans = chk->btsl_next;
_bt_step(scan, &buf, BackwardScanDirection);
break;
default:
- elog(WARN, "_bt_scandel: bad operation '%d'", op);
+ elog(ABORT, "_bt_scandel: bad operation '%d'", op);
/* NOTREACHED */
}
so->btso_curbuf = buf;
_bt_step(scan, &buf, BackwardScanDirection);
break;
default:
- elog(WARN, "_bt_scandel: bad operation '%d'", op);
+ elog(ABORT, "_bt_scandel: bad operation '%d'", op);
/* NOTREACHED */
}
so->btso_mrkbuf = buf;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtsearch.c,v 1.27 1997/10/22 19:02:52 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtsearch.c,v 1.28 1998/01/05 03:29:53 momjian Exp $
*
*-------------------------------------------------------------------------
*/
*/
if (!P_RIGHTMOST(opaque))
{
- elog(WARN, "_bt_compare: invalid comparison to high key");
+ elog(ABORT, "_bt_compare: invalid comparison to high key");
}
#if 0
/* _bt_orderkeys disallows it, but it's place to add some code latter */
if (so->keyData[0].sk_flags & SK_ISNULL)
{
- elog(WARN, "_bt_first: btree doesn't support is(not)null, yet");
+ elog(ABORT, "_bt_first: btree doesn't support is(not)null, yet");
return ((RetrieveIndexResult) NULL);
}
proc = index_getprocid(rel, 1, BTORDER_PROC);
* us up less often since they're only done by the vacuum daemon.
*/
- elog(WARN, "btree synchronization error: concurrent update botched scan");
+ elog(ABORT, "btree synchronization error: concurrent update botched scan");
return (false);
}
if (ScanDirectionIsForward(dir))
{
if (!P_LEFTMOST(opaque))/* non-leftmost page ? */
- elog(WARN, "_bt_endpoint: leftmost page (%u) has not leftmost flag", blkno);
+ elog(ABORT, "_bt_endpoint: leftmost page (%u) has not leftmost flag", blkno);
start = P_RIGHTMOST(opaque) ? P_HIKEY : P_FIRSTKEY;
/*
if (PageIsEmpty(page))
{
if (start != P_HIKEY) /* non-rightmost page */
- elog(WARN, "_bt_endpoint: non-rightmost page (%u) is empty", blkno);
+ elog(ABORT, "_bt_endpoint: non-rightmost page (%u) is empty", blkno);
/*
* It's left- & right- most page - root page, - and it's
}
else
{
- elog(WARN, "Illegal scan direction %d", dir);
+ elog(ABORT, "Illegal scan direction %d", dir);
}
btitem = (BTItem) PageGetItem(page, PageGetItemId(page, start));
*
*
* IDENTIFICATION
- * $Id: nbtsort.c,v 1.24 1997/09/18 20:19:53 momjian Exp $
+ * $Id: nbtsort.c,v 1.25 1998/01/05 03:29:55 momjian Exp $
*
* NOTES
*
if (_bt_inspool->isunique && !equal_isnull)
{
_bt_spooldestroy((void *) _bt_inspool);
- elog(WARN, "Cannot create unique index. Table contains non-unique values");
+ elog(ABORT, "Cannot create unique index. Table contains non-unique values");
}
return (0); /* 1 = 2 */
}
if (q->btpq_nelem >= MAXELEM)
{
- elog(WARN, "_bt_pqadd: queue overflow");
+ elog(ABORT, "_bt_pqadd: queue overflow");
}
child = q->btpq_nelem++;
if (tape == (BTTapeBlock *) NULL)
{
- elog(WARN, "_bt_tapecreate: out of memory");
+ elog(ABORT, "_bt_tapecreate: out of memory");
}
tape->bttb_magic = BTTAPEMAGIC;
if (btspool == (BTSpool *) NULL || fname == (char *) NULL)
{
- elog(WARN, "_bt_spoolinit: out of memory");
+ elog(ABORT, "_bt_spoolinit: out of memory");
}
MemSet((char *) btspool, 0, sizeof(BTSpool));
btspool->bts_ntapes = ntapes;
if (btspool->bts_itape == (BTTapeBlock **) NULL ||
btspool->bts_otape == (BTTapeBlock **) NULL)
{
- elog(WARN, "_bt_spoolinit: out of memory");
+ elog(ABORT, "_bt_spoolinit: out of memory");
}
for (i = 0; i < ntapes; ++i)
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtutils.c,v 1.15 1997/09/18 20:19:55 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtutils.c,v 1.16 1998/01/05 03:29:56 momjian Exp $
*
*-------------------------------------------------------------------------
*/
cur = &key[0];
if (cur->sk_attno != 1)
- elog(WARN, "_bt_orderkeys: key(s) for attribute 1 missed");
+ elog(ABORT, "_bt_orderkeys: key(s) for attribute 1 missed");
if (numberOfKeys == 1)
{
{
if (cur->sk_attno != attno + 1 && i < numberOfKeys)
{
- elog(WARN, "_bt_orderkeys: key(s) for attribute %d missed", attno + 1);
+ elog(ABORT, "_bt_orderkeys: key(s) for attribute %d missed", attno + 1);
}
/*
/*
* see comments in btbuild
*
- * if (itup->t_info & INDEX_NULL_MASK) elog(WARN, "btree indices cannot
+ * if (itup->t_info & INDEX_NULL_MASK) elog(ABORT, "btree indices cannot
* include null keys");
*/
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtproc.c,v 1.12 1997/09/18 20:19:56 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtproc.c,v 1.13 1998/01/05 03:29:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
BOX *n;
if ((n = (BOX *) palloc(sizeof(*n))) == (BOX *) NULL)
- elog(WARN, "Cannot allocate box for union");
+ elog(ABORT, "Cannot allocate box for union");
n->high.x = Max(a->high.x, b->high.x);
n->high.y = Max(a->high.y, b->high.y);
BOX *n;
if ((n = (BOX *) palloc(sizeof(*n))) == (BOX *) NULL)
- elog(WARN, "Cannot allocate box for union");
+ elog(ABORT, "Cannot allocate box for union");
n->high.x = Min(a->high.x, b->high.x);
n->high.y = Min(a->high.y, b->high.y);
p = (POLYGON *) PALLOCTYPE(POLYGON);
if (!PointerIsValid(p))
- elog(WARN, "Cannot allocate polygon for union");
+ elog(ABORT, "Cannot allocate polygon for union");
MemSet((char *) p, 0, sizeof(POLYGON)); /* zero any holes */
p->size = sizeof(POLYGON);
p = (POLYGON *) PALLOCTYPE(POLYGON);
if (!PointerIsValid(p))
- elog(WARN, "Cannot allocate polygon for intersection");
+ elog(ABORT, "Cannot allocate polygon for intersection");
MemSet((char *) p, 0, sizeof(POLYGON)); /* zero any holes */
p->size = sizeof(POLYGON);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtree.c,v 1.19 1997/11/20 23:20:26 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtree.c,v 1.20 1998/01/05 03:30:02 momjian Exp $
*
*-------------------------------------------------------------------------
*/
*/
if (oldPred == NULL && (nb = RelationGetNumberOfBlocks(index)) != 0)
- elog(WARN, "%s already contains data", index->rd_rel->relname.data);
+ elog(ABORT, "%s already contains data", index->rd_rel->relname.data);
/* initialize the root page (if this is a new index) */
if (oldPred == NULL)
*/
if (IndexTupleSize(old) != IndexTupleSize(ltup))
- elog(WARN, "Variable-length rtree keys are not supported.");
+ elog(ABORT, "Variable-length rtree keys are not supported.");
/* install pointer to left child */
memmove(old, ltup, IndexTupleSize(ltup));
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtscan.c,v 1.13 1997/09/08 21:41:40 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtscan.c,v 1.14 1998/01/05 03:30:05 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (!IndexScanIsValid(s))
{
- elog(WARN, "rtrescan: invalid scan.");
+ elog(ABORT, "rtrescan: invalid scan.");
return;
}
}
if (l == (RTScanList) NULL)
- elog(WARN, "rtree scan list corrupted -- cannot find 0x%lx", s);
+ elog(ABORT, "rtree scan list corrupted -- cannot find 0x%lx", s);
if (prev == (RTScanList) NULL)
RTScans = l->rtsl_next;
break;
default:
- elog(WARN, "Bad operation in rtree scan adjust: %d", op);
+ elog(ABORT, "Bad operation in rtree scan adjust: %d", op);
}
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/transam/transam.c,v 1.14 1997/11/02 15:24:42 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/transam/transam.c,v 1.15 1998/01/05 03:30:07 momjian Exp $
*
* NOTES
* This file contains the high level access-method interface to the
* here the block didn't contain the information we wanted
* ----------------
*/
- elog(WARN, "TransactionLogTest: failed to get xidstatus");
+ elog(ABORT, "TransactionLogTest: failed to get xidstatus");
/*
* so lint is happy...
*/
TransGetLastRecordedTransaction(logRelation, logLastXid, &fail);
if (fail == true)
- elog(WARN, "TransRecover: failed TransGetLastRecordedTransaction");
+ elog(ABORT, "TransRecover: failed TransGetLastRecordedTransaction");
/* ----------------
* next get the "last" and "next" variables
* ----------------
*/
if (TransactionIdIsLessThan(varNextXid, logLastXid))
- elog(WARN, "TransRecover: varNextXid < logLastXid");
+ elog(ABORT, "TransRecover: varNextXid < logLastXid");
/* ----------------
* intregity test (2)
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/transam/Attic/transsup.c,v 1.14 1997/11/02 15:24:44 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/transam/Attic/transsup.c,v 1.15 1998/01/05 03:30:10 momjian Exp $
*
* NOTES
* This file contains support functions for the high
if (relation == LogRelation)
itemsPerBlock = TP_NumXidStatusPerBlock;
else
- elog(WARN, "TransComputeBlockNumber: unknown relation");
+ elog(ABORT, "TransComputeBlockNumber: unknown relation");
/* ----------------
* warning! if the transaction id's get too large
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/transam/varsup.c,v 1.13 1997/11/02 15:24:45 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/transam/varsup.c,v 1.14 1998/01/05 03:30:12 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (!BufferIsValid(buf))
{
SpinRelease(OidGenLockId);
- elog(WARN, "VariableRelationGetNextXid: ReadBuffer failed");
+ elog(ABORT, "VariableRelationGetNextXid: ReadBuffer failed");
}
var = (VariableRelationContents) BufferGetBlock(buf);
if (!BufferIsValid(buf))
{
SpinRelease(OidGenLockId);
- elog(WARN, "VariableRelationPutNextXid: ReadBuffer failed");
+ elog(ABORT, "VariableRelationPutNextXid: ReadBuffer failed");
}
var = (VariableRelationContents) BufferGetBlock(buf);
if (!BufferIsValid(buf))
{
SpinRelease(OidGenLockId);
- elog(WARN, "VariableRelationGetNextXid: ReadBuffer failed");
+ elog(ABORT, "VariableRelationGetNextXid: ReadBuffer failed");
}
var = (VariableRelationContents) BufferGetBlock(buf);
if (!PointerIsValid(oidP))
{
SpinRelease(OidGenLockId);
- elog(WARN, "VariableRelationPutNextOid: invalid oid pointer");
+ elog(ABORT, "VariableRelationPutNextOid: invalid oid pointer");
}
/* ----------------
if (!BufferIsValid(buf))
{
SpinRelease(OidGenLockId);
- elog(WARN, "VariableRelationPutNextOid: ReadBuffer failed");
+ elog(ABORT, "VariableRelationPutNextOid: ReadBuffer failed");
}
var = (VariableRelationContents) BufferGetBlock(buf);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.17 1997/11/02 15:24:46 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.18 1998/01/05 03:30:13 momjian Exp $
*
* NOTES
* Transaction aborts can now occur two ways:
if (CurrentTransactionStateData.commandId == FirstCommandId)
{
CommandIdCounterOverflowFlag = true;
- elog(WARN, "You may only have 2^32-1 commands per transaction");
+ elog(ABORT, "You may only have 2^32-1 commands per transaction");
}
CurrentTransactionStateData.scanCommandId =
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/bootstrap/bootparse.y,v 1.10 1997/12/17 18:21:37 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/bootstrap/bootparse.y,v 1.11 1998/01/05 03:30:16 momjian Exp $
*
*-------------------------------------------------------------------------
*/
LPAREN tuplelist RPAREN
{
if (num_tuples_read != numattr)
- elog(WARN,"incorrect number of values for tuple");
+ elog(ABORT,"incorrect number of values for tuple");
if (reldesc == (Relation)NULL)
{
- elog(WARN,"must OPEN RELATION before INSERT\n");
+ elog(ABORT,"must OPEN RELATION before INSERT\n");
err_out();
}
if (DebugMode)
* Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/bootstrap/bootstrap.c,v 1.30 1998/01/01 05:40:28 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/bootstrap/bootstrap.c,v 1.31 1998/01/05 03:30:18 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (reldesc)
{
if (namestrcmp(RelationGetRelationName(reldesc), name) != 0)
- elog(WARN, "closerel: close of '%s' when '%s' was expected",
+ elog(ABORT, "closerel: close of '%s' when '%s' was expected",
name, relname ? relname : "(null)");
}
else
- elog(WARN, "closerel: close of '%s' before any relation was opened",
+ elog(ABORT, "closerel: close of '%s' before any relation was opened",
name);
}
if (reldesc == NULL)
{
- elog(WARN, "Warning: no opened relation to close.\n");
+ elog(ABORT, "Warning: no opened relation to close.\n");
}
else
{
heap_close(rdesc);
return (gettype(type));
}
- elog(WARN, "Error: unknown type '%s'.\n", type);
+ elog(ABORT, "Error: unknown type '%s'.\n", type);
err_out();
/* not reached, here to make compiler happy */
return 0;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/catalog.c,v 1.10 1997/09/08 21:42:12 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/catalog.c,v 1.11 1998/01/05 03:30:22 momjian Exp $
*
*-------------------------------------------------------------------------
*/
GetNewObjectId(&lastoid);
if (!OidIsValid(lastoid))
- elog(WARN, "newoid: GetNewObjectId returns invalid oid");
+ elog(ABORT, "newoid: GetNewObjectId returns invalid oid");
return lastoid;
}
AttributeTupleForm *att = tupleDesc->attrs;
if (natts < 0 || natts > MaxHeapAttributeNumber)
- elog(WARN, "fillatt: %d attributes is too large", natts);
+ elog(ABORT, "fillatt: %d attributes is too large", natts);
if (natts == 0)
{
elog(DEBUG, "fillatt: called with natts == 0");
0, 0, 0);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "fillatt: unknown atttypid %ld",
+ elog(ABORT, "fillatt: unknown atttypid %ld",
(*attributeP)->atttypid);
}
else
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/heap.c,v 1.41 1997/12/11 17:35:59 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/heap.c,v 1.42 1998/01/05 03:30:27 momjian Exp $
*
* INTERFACE ROUTINES
* heap_create() - Create an uncataloged heap relation
if (IsSystemRelationName(relname) && IsNormalProcessingMode())
{
- elog(WARN,
+ elog(ABORT,
"Illegal class name: %s -- pg_ is reserved for system catalogs",
relname);
}
*
* this is used to make certain the tuple descriptor contains a
* valid set of attribute names. a problem simply generates
- * elog(WARN) which aborts the current transaction.
+ * elog(ABORT) which aborts the current transaction.
* --------------------------------
*/
static void
if (nameeq(&(HeapAtt[j]->attname),
&(tupdesc->attrs[i]->attname)))
{
- elog(WARN,
+ elog(ABORT,
"create: system attribute named \"%s\"",
HeapAtt[j]->attname.data);
}
if (nameeq(&(tupdesc->attrs[j]->attname),
&(tupdesc->attrs[i]->attname)))
{
- elog(WARN,
+ elog(ABORT,
"create: repeated attribute \"%s\"",
tupdesc->attrs[j]->attname.data);
}
*/
AssertState(IsNormalProcessingMode() || IsBootstrapProcessingMode());
if (natts == 0 || natts > MaxHeapAttributeNumber)
- elog(WARN, "amcreate: from 1 to %d attributes must be specified",
+ elog(ABORT, "amcreate: from 1 to %d attributes must be specified",
MaxHeapAttributeNumber);
CheckAttributeNames(tupdesc);
if (RelationAlreadyExists(pg_class_desc, relname))
{
heap_close(pg_class_desc);
- elog(WARN, "amcreate: %s relation already exists", relname);
+ elog(ABORT, "amcreate: %s relation already exists", relname);
}
/* ----------------
heap_endscan(scan);
heap_close(catalogRelation);
- elog(WARN, "relation <%d> inherits \"%s\"",
+ elog(ABORT, "relation <%d> inherits \"%s\"",
((InheritsTupleForm) GETSTRUCT(tuple))->inhrel,
RelationGetRelationName(relation));
}
{
heap_endscan(pg_class_scan);
heap_close(pg_class_desc);
- elog(WARN, "DeletePgRelationTuple: %s relation nonexistent",
+ elog(ABORT, "DeletePgRelationTuple: %s relation nonexistent",
&rdesc->rd_rel->relname);
}
{
heap_endscan(pg_type_scan);
heap_close(pg_type_desc);
- elog(WARN, "DeletePgTypeTuple: %s type nonexistent",
+ elog(ABORT, "DeletePgTypeTuple: %s type nonexistent",
&rdesc->rd_rel->relname);
}
heap_endscan(pg_attribute_scan);
heap_close(pg_attribute_desc);
- elog(WARN, "DeletePgTypeTuple: att of type %s exists in relation %d",
+ elog(ABORT, "DeletePgTypeTuple: att of type %s exists in relation %d",
&rdesc->rd_rel->relname, relid);
}
heap_endscan(pg_attribute_scan);
*/
rdesc = heap_openr(relname);
if (rdesc == NULL)
- elog(WARN, "Relation %s Does Not Exist!", relname);
+ elog(ABORT, "Relation %s Does Not Exist!", relname);
RelationSetLockForWrite(rdesc);
rid = rdesc->rd_id;
* ----------------
*/
if (IsSystemRelationName(RelationGetRelationName(rdesc)->data))
- elog(WARN, "amdestroy: cannot destroy %s relation",
+ elog(ABORT, "amdestroy: cannot destroy %s relation",
&rdesc->rd_rel->relname);
/* ----------------
if (length(query->rtable) > 1 ||
flatten_tlist(query->targetList) != NIL)
- elog(WARN, "DEFAULT: cannot use attribute(s)");
+ elog(ABORT, "DEFAULT: cannot use attribute(s)");
te = (TargetEntry *) lfirst(query->targetList);
resdom = te->resdom;
expr = te->expr;
if (((Const *) expr)->consttype != atp->atttypid)
{
if (*cast != 0)
- elog(WARN, "DEFAULT: const type mismatched");
+ elog(ABORT, "DEFAULT: const type mismatched");
sprintf(cast, ":: %s", typeidTypeName(atp->atttypid));
goto start;
}
}
else if (exprType(expr) != atp->atttypid)
- elog(WARN, "DEFAULT: type mismatched");
+ elog(ABORT, "DEFAULT: type mismatched");
adbin = nodeToString(expr);
oldcxt = MemoryContextSwitchTo((MemoryContext) CacheCxt);
query = (Query *) (queryTree_list->qtrees[0]);
if (length(query->rtable) > 1)
- elog(WARN, "CHECK: only relation %.*s can be referenced",
+ elog(ABORT, "CHECK: only relation %.*s can be referenced",
NAMEDATALEN, rel->rd_rel->relname.data);
plan = (Plan *) lfirst(planTree_list);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/index.c,v 1.31 1997/11/28 04:39:38 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/index.c,v 1.32 1998/01/05 03:30:30 momjian Exp $
*
*
* INTERFACE ROUTINES
false);
if (OidIsValid(indoid))
- elog(WARN, "Cannot create index: '%s' already exists",
+ elog(ABORT, "Cannot create index: '%s' already exists",
indexRelationName);
/* ----------------
* ----------------
*/
if (!OidIsValid(heapoid))
- elog(WARN, "Cannot create index on '%s': relation does not exist",
+ elog(ABORT, "Cannot create index on '%s': relation does not exist",
heapRelationName);
/* ----------------
ObjectIdGetDatum(retType),
0, 0, 0);
if (!HeapTupleIsValid(tuple))
- elog(WARN, "Function %s return type does not exist", FIgetname(funcInfo));
+ elog(ABORT, "Function %s return type does not exist", FIgetname(funcInfo));
/*
* Assign some of the attributes values. Leave the rest as 0.
*/
atnum = attNums[i];
if (atnum > natts)
- elog(WARN, "Cannot create index: attribute %d does not exist",
+ elog(ABORT, "Cannot create index: attribute %d does not exist",
atnum);
if (attributeList)
{
* ----------------
*/
if (atnum <= FirstLowInvalidHeapAttributeNumber || atnum >= 0)
- elog(WARN, "Cannot create index on system attribute: attribute number out of range (%d)", atnum);
+ elog(ABORT, "Cannot create index on system attribute: attribute number out of range (%d)", atnum);
atind = (-atnum) - 1;
from = (char *) (&sysatts[atind]);
PointerGetDatum(IndexKeyType->name),
0, 0, 0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "create index: type '%s' undefined",
+ elog(ABORT, "create index: type '%s' undefined",
IndexKeyType->name);
((AttributeTupleForm) to)->atttypid = tup->t_oid;
((AttributeTupleForm) to)->attbyval =
* ----------------
*/
if (numatts < 1)
- elog(WARN, "must index at least one attribute");
+ elog(ABORT, "must index at least one attribute");
/* ----------------
* get heap relation oid and open the heap relation
* physically remove the file
*/
if (FileNameUnlink(relpath(indexRelation->rd_rel->relname.data)) < 0)
- elog(WARN, "amdestroyr: unlink: %m");
+ elog(ABORT, "amdestroyr: unlink: %m");
index_close(indexRelation);
}
whichRel = RelationIdGetRelation(relid);
if (!RelationIsValid(whichRel))
- elog(WARN, "UpdateStats: cannot open relation id %d", relid);
+ elog(ABORT, "UpdateStats: cannot open relation id %d", relid);
/* ----------------
* Find the RELATION relation tuple for the given relation.
pg_class = heap_openr(RelationRelationName);
if (!RelationIsValid(pg_class))
{
- elog(WARN, "UpdateStats: could not open RELATION relation");
+ elog(ABORT, "UpdateStats: could not open RELATION relation");
}
key[0].sk_argument = ObjectIdGetDatum(relid);
if (!HeapScanIsValid(pg_class_scan))
{
heap_close(pg_class);
- elog(WARN, "UpdateStats: cannot scan RELATION relation");
+ elog(ABORT, "UpdateStats: cannot scan RELATION relation");
}
/* if the heap_open above succeeded, then so will this heap_getnext() */
0, 0, 0);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "IndexIsUnique: can't find index id %d",
+ elog(ABORT, "IndexIsUnique: can't find index id %d",
indexId);
}
index = (IndexTupleForm) GETSTRUCT(tuple);
tuple = heap_getnext(scandesc, 0, NULL);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "IndexIsUniqueNoCache: can't find index id %d",
+ elog(ABORT, "IndexIsUniqueNoCache: can't find index id %d",
indexId);
}
index = (IndexTupleForm) GETSTRUCT(tuple);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/pg_aggregate.c,v 1.9 1997/09/18 20:20:15 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/pg_aggregate.c,v 1.10 1998/01/05 03:30:32 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/* sanity checks */
if (!aggName)
- elog(WARN, "AggregateCreate: no aggregate name supplied");
+ elog(ABORT, "AggregateCreate: no aggregate name supplied");
if (!aggtransfn1Name && !aggtransfn2Name)
- elog(WARN, "AggregateCreate: aggregate must have at least one transition function");
+ elog(ABORT, "AggregateCreate: aggregate must have at least one transition function");
tup = SearchSysCacheTuple(TYPNAME,
PointerGetDatum(aggbasetypeName),
0, 0, 0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "AggregateCreate: Type '%s' undefined", aggbasetypeName);
+ elog(ABORT, "AggregateCreate: Type '%s' undefined", aggbasetypeName);
xbase = tup->t_oid;
if (aggtransfn1Name)
PointerGetDatum(aggtransfn1typeName),
0, 0, 0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "AggregateCreate: Type '%s' undefined",
+ elog(ABORT, "AggregateCreate: Type '%s' undefined",
aggtransfn1typeName);
xret1 = tup->t_oid;
PointerGetDatum(fnArgs),
0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "AggregateCreate: '%s('%s', '%s') does not exist",
+ elog(ABORT, "AggregateCreate: '%s('%s', '%s') does not exist",
aggtransfn1Name, aggtransfn1typeName, aggbasetypeName);
if (((Form_pg_proc) GETSTRUCT(tup))->prorettype != xret1)
- elog(WARN, "AggregateCreate: return type of '%s' is not '%s'",
+ elog(ABORT, "AggregateCreate: return type of '%s' is not '%s'",
aggtransfn1Name,
aggtransfn1typeName);
xfn1 = tup->t_oid;
if (!OidIsValid(xfn1) || !OidIsValid(xret1) ||
!OidIsValid(xbase))
- elog(WARN, "AggregateCreate: bogus function '%s'", aggfinalfnName);
+ elog(ABORT, "AggregateCreate: bogus function '%s'", aggfinalfnName);
}
if (aggtransfn2Name)
PointerGetDatum(aggtransfn2typeName),
0, 0, 0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "AggregateCreate: Type '%s' undefined",
+ elog(ABORT, "AggregateCreate: Type '%s' undefined",
aggtransfn2typeName);
xret2 = tup->t_oid;
PointerGetDatum(fnArgs),
0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "AggregateCreate: '%s'('%s') does not exist",
+ elog(ABORT, "AggregateCreate: '%s'('%s') does not exist",
aggtransfn2Name, aggtransfn2typeName);
if (((Form_pg_proc) GETSTRUCT(tup))->prorettype != xret2)
- elog(WARN, "AggregateCreate: return type of '%s' is not '%s'",
+ elog(ABORT, "AggregateCreate: return type of '%s' is not '%s'",
aggtransfn2Name, aggtransfn2typeName);
xfn2 = tup->t_oid;
if (!OidIsValid(xfn2) || !OidIsValid(xret2))
- elog(WARN, "AggregateCreate: bogus function '%s'", aggfinalfnName);
+ elog(ABORT, "AggregateCreate: bogus function '%s'", aggfinalfnName);
}
tup = SearchSysCacheTuple(AGGNAME, PointerGetDatum(aggName),
ObjectIdGetDatum(xbase),
0, 0);
if (HeapTupleIsValid(tup))
- elog(WARN,
+ elog(ABORT,
"AggregateCreate: aggregate '%s' with base type '%s' already exists",
aggName, aggbasetypeName);
/* more sanity checks */
if (aggtransfn1Name && aggtransfn2Name && !aggfinalfnName)
- elog(WARN, "AggregateCreate: Aggregate must have final function with both transition functions");
+ elog(ABORT, "AggregateCreate: Aggregate must have final function with both transition functions");
if ((!aggtransfn1Name || !aggtransfn2Name) && aggfinalfnName)
- elog(WARN, "AggregateCreate: Aggregate cannot have final function without both transition functions");
+ elog(ABORT, "AggregateCreate: Aggregate cannot have final function without both transition functions");
if (aggfinalfnName)
{
PointerGetDatum(fnArgs),
0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "AggregateCreate: '%s'('%s','%s') does not exist",
+ elog(ABORT, "AggregateCreate: '%s'('%s','%s') does not exist",
aggfinalfnName, aggtransfn1typeName, aggtransfn2typeName);
ffn = tup->t_oid;
proc = (Form_pg_proc) GETSTRUCT(tup);
fret = proc->prorettype;
if (!OidIsValid(ffn) || !OidIsValid(fret))
- elog(WARN, "AggregateCreate: bogus function '%s'", aggfinalfnName);
+ elog(ABORT, "AggregateCreate: bogus function '%s'", aggfinalfnName);
}
/*
* aggregates to return NULL if they are evaluated on empty sets.
*/
if (OidIsValid(xfn2) && !agginitval2)
- elog(WARN, "AggregateCreate: transition function 2 MUST have an initial value");
+ elog(ABORT, "AggregateCreate: transition function 2 MUST have an initial value");
/* initialize nulls and values */
for (i = 0; i < Natts_pg_aggregate; i++)
nulls[Anum_pg_aggregate_agginitval2 - 1] = 'n';
if (!RelationIsValid(aggdesc = heap_openr(AggregateRelationName)))
- elog(WARN, "AggregateCreate: could not open '%s'",
+ elog(ABORT, "AggregateCreate: could not open '%s'",
AggregateRelationName);
tupDesc = aggdesc->rd_att;
if (!HeapTupleIsValid(tup = heap_formtuple(tupDesc,
values,
nulls)))
- elog(WARN, "AggregateCreate: heap_formtuple failed");
+ elog(ABORT, "AggregateCreate: heap_formtuple failed");
if (!OidIsValid(heap_insert(aggdesc, tup)))
- elog(WARN, "AggregateCreate: heap_insert failed");
+ elog(ABORT, "AggregateCreate: heap_insert failed");
heap_close(aggdesc);
}
PointerGetDatum(basetype),
0, 0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "AggNameGetInitVal: cache lookup failed for aggregate '%s'",
+ elog(ABORT, "AggNameGetInitVal: cache lookup failed for aggregate '%s'",
aggName);
if (xfuncno == 1)
{
aggRel = heap_openr(AggregateRelationName);
if (!RelationIsValid(aggRel))
- elog(WARN, "AggNameGetInitVal: could not open \"%-.*s\"",
+ elog(ABORT, "AggNameGetInitVal: could not open \"%-.*s\"",
AggregateRelationName);
/*
if (!HeapTupleIsValid(tup))
{
pfree(strInitVal);
- elog(WARN, "AggNameGetInitVal: cache lookup failed on aggregate transition function return type");
+ elog(ABORT, "AggNameGetInitVal: cache lookup failed on aggregate transition function return type");
}
initVal = fmgr(((TypeTupleForm) GETSTRUCT(tup))->typinput, strInitVal, -1);
pfree(strInitVal);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/pg_operator.c,v 1.17 1997/11/25 21:58:46 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/pg_operator.c,v 1.18 1998/01/05 03:30:32 momjian Exp $
*
* NOTES
* these routines moved here from commands/define.c and somewhat cleaned up.
leftObjectId = TypeGet(leftTypeName, &leftDefined);
if (!OidIsValid(leftObjectId) || !leftDefined)
- elog(WARN, "OperatorGet: left type '%s' nonexistent", leftTypeName);
+ elog(ABORT, "OperatorGet: left type '%s' nonexistent", leftTypeName);
}
if (rightTypeName)
rightObjectId = TypeGet(rightTypeName, &rightDefined);
if (!OidIsValid(rightObjectId) || !rightDefined)
- elog(WARN, "OperatorGet: right type '%s' nonexistent",
+ elog(ABORT, "OperatorGet: right type '%s' nonexistent",
rightTypeName);
}
if (!((OidIsValid(leftObjectId) && leftDefined) ||
(OidIsValid(rightObjectId) && rightDefined)))
- elog(WARN, "OperatorGet: no argument types??");
+ elog(ABORT, "OperatorGet: no argument types??");
/* ----------------
* open the pg_operator relation
if (!((OidIsValid(leftObjectId) && leftDefined) ||
(OidIsValid(rightObjectId) && rightDefined)))
- elog(WARN, "OperatorShellMake: no valid argument types??");
+ elog(ABORT, "OperatorShellMake: no valid argument types??");
/* ----------------
* open pg_operator
rightTypeName);
if (OidIsValid(operatorObjectId) && !definedOK)
- elog(WARN, "OperatorDef: operator \"%s\" already defined",
+ elog(ABORT, "OperatorDef: operator \"%s\" already defined",
operatorName);
if (leftTypeName)
if (!((OidIsValid(leftTypeId && leftDefined)) ||
(OidIsValid(rightTypeId && rightDefined))))
- elog(WARN, "OperatorGet: no argument types??");
+ elog(ABORT, "OperatorGet: no argument types??");
for (i = 0; i < Natts_pg_operator; ++i)
{
}
if (!OidIsValid(other_oid))
- elog(WARN,
+ elog(ABORT,
"OperatorDef: can't create operator '%s'",
name[j]);
values[i++] = ObjectIdGetDatum(other_oid);
setheapoverride(false);
}
else
- elog(WARN, "OperatorDef: no operator %d", other_oid);
+ elog(ABORT, "OperatorDef: no operator %d", other_oid);
heap_endscan(pg_operator_scan);
int definedOK;
if (!leftTypeName && !rightTypeName)
- elog(WARN, "OperatorCreate : at least one of leftarg or rightarg must be defined");
+ elog(ABORT, "OperatorCreate : at least one of leftarg or rightarg must be defined");
/* ----------------
* get the oid's of the operator's associated operators, if possible.
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/pg_proc.c,v 1.11 1997/12/11 17:36:01 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/pg_proc.c,v 1.12 1998/01/05 03:30:33 momjian Exp $
*
*-------------------------------------------------------------------------
*/
Value *t = lfirst(x);
if (parameterCount == 8)
- elog(WARN, "Procedures cannot take more than 8 arguments");
+ elog(ABORT, "Procedures cannot take more than 8 arguments");
if (strcmp(strVal(t), "opaque") == 0)
{
if (strcmp(languageName, "sql") == 0)
{
- elog(WARN, "ProcedureDefine: sql functions cannot take type \"opaque\"");
+ elog(ABORT, "ProcedureDefine: sql functions cannot take type \"opaque\"");
}
toid = 0;
}
if (!OidIsValid(toid))
{
- elog(WARN, "ProcedureCreate: arg type '%s' is not defined",
+ elog(ABORT, "ProcedureCreate: arg type '%s' is not defined",
strVal(t));
}
0);
if (HeapTupleIsValid(tup))
- elog(WARN, "ProcedureCreate: procedure %s already exists with same arguments",
+ elog(ABORT, "ProcedureCreate: procedure %s already exists with same arguments",
procedureName);
if (!strcmp(languageName, "sql"))
0, 0, 0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "ProcedureCreate: no such language %s",
+ elog(ABORT, "ProcedureCreate: no such language %s",
languageName);
languageObjectId = tup->t_oid;
{
if (strcmp(languageName, "sql") == 0)
{
- elog(WARN, "ProcedureCreate: sql functions cannot return type \"opaque\"");
+ elog(ABORT, "ProcedureCreate: sql functions cannot return type \"opaque\"");
}
typeObjectId = 0;
}
typeObjectId = TypeShellMake(returnTypeName);
if (!OidIsValid(typeObjectId))
{
- elog(WARN, "ProcedureCreate: could not create type '%s'",
+ elog(ABORT, "ProcedureCreate: could not create type '%s'",
returnTypeName);
}
}
defined &&
(relid = typeidTypeRelid(toid)) != 0 &&
get_attnum(relid, procedureName) != InvalidAttrNumber)
- elog(WARN, "method %s already an attribute of type %s",
+ elog(ABORT, "method %s already an attribute of type %s",
procedureName, strVal(lfirst(argList)));
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/pg_type.c,v 1.15 1997/11/26 04:50:21 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/pg_type.c,v 1.16 1998/01/05 03:30:35 momjian Exp $
*
*-------------------------------------------------------------------------
*/
typeObjectId = TypeGet(typeName, &defined);
if (OidIsValid(typeObjectId) && defined)
{
- elog(WARN, "TypeCreate: type %s already defined", typeName);
+ elog(ABORT, "TypeCreate: type %s already defined", typeName);
}
/* ----------------
elementObjectId = TypeGet(elementTypeName, &defined);
if (!defined)
{
- elog(WARN, "TypeCreate: type %s is not defined", elementTypeName);
+ elog(ABORT, "TypeCreate: type %s is not defined", elementTypeName);
}
}
type_oid = TypeGet(newTypeName, &defined);
if (OidIsValid(type_oid) && defined)
{
- elog(WARN, "TypeRename: type %s already defined", newTypeName);
+ elog(ABORT, "TypeRename: type %s already defined", newTypeName);
}
/* get the type tuple from the catalog index scan manager */
}
else
{
- elog(WARN, "TypeRename: type %s not defined", oldTypeName);
+ elog(ABORT, "TypeRename: type %s not defined", oldTypeName);
}
/* finish up */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/_deadcode/Attic/version.c,v 1.9 1997/12/11 17:36:08 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/_deadcode/Attic/version.c,v 1.10 1998/01/05 03:30:58 momjian Exp $
*
* NOTES
* At the point the version is defined, 2 physical relations are created
rdesc = heap_openr(bname);
if (rdesc == NULL)
{
- elog(WARN, "Unable to expand all -- amopenr failed ");
+ elog(ABORT, "Unable to expand all -- amopenr failed ");
return;
}
maxattrs = RelationGetNumberOfAttributes(rdesc);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/cluster.c,v 1.19 1997/11/28 17:26:55 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/cluster.c,v 1.20 1998/01/05 03:30:38 momjian Exp $
*
*-------------------------------------------------------------------------
*/
OldHeap = heap_openr(oldrelname);
if (!RelationIsValid(OldHeap))
{
- elog(WARN, "cluster: unknown relation: \"%s\"",
+ elog(ABORT, "cluster: unknown relation: \"%s\"",
oldrelname);
}
OIDOldHeap = OldHeap->rd_id;/* Get OID for the index scan */
OldIndex = index_openr(oldindexname); /* Open old index relation */
if (!RelationIsValid(OldIndex))
{
- elog(WARN, "cluster: unknown index: \"%s\"",
+ elog(ABORT, "cluster: unknown index: \"%s\"",
oldindexname);
}
OIDOldIndex = OldIndex->rd_id; /* OID for the index scan */
OIDNewHeap = heap_create_with_catalog(NewName, tupdesc);
if (!OidIsValid(OIDNewHeap))
- elog(WARN, "clusterheap: cannot create temporary heap relation\n");
+ elog(ABORT, "clusterheap: cannot create temporary heap relation\n");
NewHeap = heap_open(OIDNewHeap);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/command.c,v 1.21 1997/11/20 23:21:00 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/command.c,v 1.22 1998/01/05 03:30:39 momjian Exp $
*
* NOTES
* The PortalExecutorHeapMemory crap needs to be eliminated
* normally, only the owner of a class can change its schema.
*/
if (IsSystemRelationName(relationName))
- elog(WARN, "PerformAddAttribute: class \"%s\" is a system catalog",
+ elog(ABORT, "PerformAddAttribute: class \"%s\" is a system catalog",
relationName);
#ifndef NO_SECURITY
if (!pg_ownercheck(userName, relationName, RELNAME))
- elog(WARN, "PerformAddAttribute: you do not own class \"%s\"",
+ elog(ABORT, "PerformAddAttribute: you do not own class \"%s\"",
relationName);
#endif
* we can't add a not null attribute
*/
if (colDef->is_not_null)
- elog(WARN, "Can't add a NOT NULL attribute to an existing relation");
+ elog(ABORT, "Can't add a NOT NULL attribute to an existing relation");
if (colDef->defval)
- elog(WARN, "ADD ATTRIBUTE: DEFAULT not yet implemented");
+ elog(ABORT, "ADD ATTRIBUTE: DEFAULT not yet implemented");
/*
* if the first element in the 'schema' list is a "*" then we are
relrdesc = heap_openr(relationName);
if (!RelationIsValid(relrdesc))
{
- elog(WARN, "PerformAddAttribute: unknown relation: \"%s\"",
+ elog(ABORT, "PerformAddAttribute: unknown relation: \"%s\"",
relationName);
}
myrelid = relrdesc->rd_id;
relrdesc = heap_open(childrelid);
if (!RelationIsValid(relrdesc))
{
- elog(WARN, "PerformAddAttribute: can't find catalog entry for inheriting class with oid %d",
+ elog(ABORT, "PerformAddAttribute: can't find catalog entry for inheriting class with oid %d",
childrelid);
}
PerformAddAttribute((relrdesc->rd_rel->relname).data,
if (!PointerIsValid(reltup))
{
heap_close(relrdesc);
- elog(WARN, "PerformAddAttribute: relation \"%s\" not found",
+ elog(ABORT, "PerformAddAttribute: relation \"%s\" not found",
relationName);
}
*/
if (((Form_pg_class) GETSTRUCT(reltup))->relkind == RELKIND_INDEX)
{
- elog(WARN, "PerformAddAttribute: index relation \"%s\" not changed",
+ elog(ABORT, "PerformAddAttribute: index relation \"%s\" not changed",
relationName);
return;
}
{
pfree(reltup); /* XXX temp */
heap_close(relrdesc); /* XXX temp */
- elog(WARN, "PerformAddAttribute: relations limited to %d attributes",
+ elog(ABORT, "PerformAddAttribute: relations limited to %d attributes",
MaxHeapAttributeNumber);
return;
}
heap_endscan(attsdesc); /* XXX temp */
heap_close(attrdesc); /* XXX temp */
heap_close(relrdesc); /* XXX temp */
- elog(WARN, "PerformAddAttribute: attribute \"%s\" already exists in class \"%s\"",
+ elog(ABORT, "PerformAddAttribute: attribute \"%s\" already exists in class \"%s\"",
key[1].sk_argument,
relationName);
return;
if (!HeapTupleIsValid(typeTuple))
{
- elog(WARN, "Add: type \"%s\" nonexistent", p);
+ elog(ABORT, "Add: type \"%s\" nonexistent", p);
}
namestrcpy(&(attribute->attname), (char *) key[1].sk_argument);
attribute->atttypid = typeTuple->t_oid;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.35 1997/11/20 23:21:03 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.36 1998/01/05 03:30:41 momjian Exp $
*
*-------------------------------------------------------------------------
*/
rel = heap_openr(relname);
if (rel == NULL)
- elog(WARN, "COPY command failed. Class %s "
+ elog(ABORT, "COPY command failed. Class %s "
"does not exist.", relname);
result = pg_aclcheck(relname, UserName, required_access);
if (result != ACLCHECK_OK)
- elog(WARN, "%s: %s", relname, aclcheck_error_strings[result]);
+ elog(ABORT, "%s: %s", relname, aclcheck_error_strings[result]);
/* Above should not return */
else if (!superuser() && !pipe)
- elog(WARN, "You must have Postgres superuser privilege to do a COPY "
+ elog(ABORT, "You must have Postgres superuser privilege to do a COPY "
"directly to or from a file. Anyone can COPY to stdout or "
"from stdin. Psql's \\copy command also works for anyone.");
/* Above should not return. */
if (from)
{ /* copy from file to database */
if (rel->rd_rel->relkind == RELKIND_SEQUENCE)
- elog(WARN, "You can't change sequence relation %s", relname);
+ elog(ABORT, "You can't change sequence relation %s", relname);
if (pipe)
{
if (IsUnderPostmaster)
{
fp = AllocateFile(filename, "r");
if (fp == NULL)
- elog(WARN, "COPY command, running in backend with "
+ elog(ABORT, "COPY command, running in backend with "
"effective uid %d, could not open file '%s' for "
"reading. Errno = %s (%d).",
geteuid(), filename, strerror(errno), errno);
fp = AllocateFile(filename, "w");
umask(oumask);
if (fp == NULL)
- elog(WARN, "COPY command, running in backend with "
+ elog(ABORT, "COPY command, running in backend with "
"effective uid %d, could not open file '%s' for "
"writing. Errno = %s (%d).",
geteuid(), filename, strerror(errno), errno);
{
loaded_oid = oidin(string);
if (loaded_oid < BootstrapObjectIdData)
- elog(WARN, "COPY TEXT: Invalid Oid");
+ elog(ABORT, "COPY TEXT: Invalid Oid");
}
}
for (i = 0; i < attr_count && !done; i++)
!(rel->rd_att->attrs[i]->attbyval))
{
#ifdef COPY_DEBUG
- elog(WARN,
+ elog(ABORT,
"copy from: line %d - Bad file format", lineno);
#else
- elog(WARN, "copy from: Bad file format");
+ elog(ABORT, "copy from: Bad file format");
#endif
}
}
{
fread(&loaded_oid, sizeof(int32), 1, fp);
if (loaded_oid < BootstrapObjectIdData)
- elog(WARN, "COPY BINARY: Invalid Oid");
+ elog(ABORT, "COPY BINARY: Invalid Oid");
}
fread(&null_ct, sizeof(int32), 1, fp);
if (null_ct > 0)
ptr += sizeof(int32);
break;
default:
- elog(WARN, "COPY BINARY: impossible size!");
+ elog(ABORT, "COPY BINARY: impossible size!");
break;
}
}
if (HeapTupleIsValid(typeTuple))
return ((int) ((TypeTupleForm) GETSTRUCT(typeTuple))->typoutput);
- elog(WARN, "GetOutputFunction: Cache lookup of type %d failed", type);
+ elog(ABORT, "GetOutputFunction: Cache lookup of type %d failed", type);
return (InvalidOid);
}
if (HeapTupleIsValid(typeTuple))
return ((int) ((TypeTupleForm) GETSTRUCT(typeTuple))->typelem);
- elog(WARN, "GetOutputFunction: Cache lookup of type %d failed", type);
+ elog(ABORT, "GetOutputFunction: Cache lookup of type %d failed", type);
return (InvalidOid);
}
if (HeapTupleIsValid(typeTuple))
return ((int) ((TypeTupleForm) GETSTRUCT(typeTuple))->typinput);
- elog(WARN, "GetInputFunction: Cache lookup of type %d failed", type);
+ elog(ABORT, "GetInputFunction: Cache lookup of type %d failed", type);
return (InvalidOid);
}
if (HeapTupleIsValid(typeTuple))
return ((int) ((TypeTupleForm) GETSTRUCT(typeTuple))->typbyval);
- elog(WARN, "GetInputFunction: Cache lookup of type %d failed", type);
+ elog(ABORT, "GetInputFunction: Cache lookup of type %d failed", type);
return (InvalidOid);
}
case '.':
c = getc(fp);
if (c != '\n')
- elog(WARN, "CopyReadAttribute - end of record marker corrupted");
+ elog(ABORT, "CopyReadAttribute - end of record marker corrupted");
return (NULL);
break;
}
if (!done)
attribute[i++] = c;
if (i == EXT_ATTLEN - 1)
- elog(WARN, "CopyReadAttribute - attribute length too long");
+ elog(ABORT, "CopyReadAttribute - attribute length too long");
}
attribute[i] = '\0';
return (&attribute[0]);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/creatinh.c,v 1.22 1997/12/04 23:15:28 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/creatinh.c,v 1.23 1998/01/05 03:30:44 momjian Exp $
*
*-------------------------------------------------------------------------
*/
List *constraints;
if (strlen(stmt->relname) >= NAMEDATALEN)
- elog(WARN, "the relation name %s is >= %d characters long", stmt->relname,
+ elog(ABORT, "the relation name %s is >= %d characters long", stmt->relname,
NAMEDATALEN);
StrNCpy(relname, stmt->relname, NAMEDATALEN); /* make full length for
* copy */
numberOfAttributes = length(schema);
if (numberOfAttributes <= 0)
{
- elog(WARN, "DefineRelation: %s",
+ elog(ABORT, "DefineRelation: %s",
"please inherit from a relation or define an attribute");
}
for (i = 0; i < ncheck; i++)
{
if (strcmp(check[i].ccname, cdef->name) == 0)
- elog(WARN, "DefineRelation: name (%s) of CHECK constraint duplicated", cdef->name);
+ elog(ABORT, "DefineRelation: name (%s) of CHECK constraint duplicated", cdef->name);
}
check[ncheck].ccname = cdef->name;
}
if (!strcmp(coldef->colname, restdef->colname))
{
- elog(WARN, "attribute '%s' duplicated",
+ elog(ABORT, "attribute '%s' duplicated",
coldef->colname);
}
}
{
if (!strcmp(strVal(lfirst(entry)), strVal(lfirst(rest))))
{
- elog(WARN, "relation '%s' duplicated",
+ elog(ABORT, "relation '%s' duplicated",
strVal(lfirst(entry)));
}
}
relation = heap_openr(name);
if (relation == NULL)
{
- elog(WARN,
+ elog(ABORT,
"MergeAttr: Can't inherit from non-existent superclass '%s'", name);
}
if (relation->rd_rel->relkind == 'S')
{
- elog(WARN, "MergeAttr: Can't inherit from sequence superclass '%s'", name);
+ elog(ABORT, "MergeAttr: Can't inherit from sequence superclass '%s'", name);
}
tupleDesc = RelationGetTupleDescriptor(relation);
constr = tupleDesc->constr;
*/
if (strcmp(attributeType, def->typename->name) != 0)
{
- elog(WARN, "%s and %s conflict for %s",
+ elog(ABORT, "%s and %s conflict for %s",
attributeType, def->typename->name, attributeName);
}
return 1;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.3 1997/12/11 17:36:04 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.4 1998/01/05 03:30:44 momjian Exp $
*
*-------------------------------------------------------------------------
*/
lp = ExpandDatabasePath(loc);
if (lp == NULL)
- elog(WARN,"Unable to locate path '%s'"
+ elog(ABORT,"Unable to locate path '%s'"
"\n\tThis may be due to a missing environment variable"
" in the server",loc);
if (mkdir(lp,S_IRWXU) != 0)
- elog(WARN,"Unable to create database directory %s",lp);
+ elog(ABORT,"Unable to create database directory %s",lp);
sprintf(buf, "%s %s%cbase%ctemplate1%c* %s",
COPY_CMD, DataDir, SEP_CHAR, SEP_CHAR, SEP_CHAR, lp);
path = ExpandDatabasePath(dbpath);
if (path == NULL)
- elog(WARN,"Unable to locate path '%s'"
+ elog(ABORT,"Unable to locate path '%s'"
"\n\tThis may be due to a missing environment variable"
" in the server",dbpath);
scan = heap_beginscan(dbrel, 0, false, 1, &scanKey);
if (!HeapScanIsValid(scan))
- elog(WARN, "%s: cannot begin scan of pg_database.", command);
+ elog(ABORT, "%s: cannot begin scan of pg_database.", command);
/*
* since we want to return the tuple out of this proc, and we're going
* check_permissions() -- verify that the user is permitted to do this.
*
* If the user is not allowed to carry out this operation, this routine
- * elog(WARN, ...)s, which will abort the xact. As a side effect, the
+ * elog(ABORT, ...)s, which will abort the xact. As a side effect, the
* user's pg_user tuple OID is returned in userIdP and the target database's
* OID is returned in dbIdP.
*/
/* Check to make sure user has permission to use createdb */
if (!use_createdb)
{
- elog(WARN, "user \"%s\" is not allowed to create/destroy databases",
+ elog(ABORT, "user \"%s\" is not allowed to create/destroy databases",
userName);
}
/* Make sure we are not mucking with the template database */
if (!strcmp(dbname, "template1"))
{
- elog(WARN, "%s cannot be executed on the template database.", command);
+ elog(ABORT, "%s cannot be executed on the template database.", command);
}
/* Check to make sure database is not the currently open database */
if (!strcmp(dbname, GetDatabaseName()))
{
- elog(WARN, "%s cannot be executed on an open database", command);
+ elog(ABORT, "%s cannot be executed on an open database", command);
}
/* Check to make sure database is owned by this user */
if (dbfound && !strcmp(command, "createdb"))
{
- elog(WARN, "createdb: database %s already exists.", dbname);
+ elog(ABORT, "createdb: database %s already exists.", dbname);
}
else if (!dbfound && !strcmp(command, "destroydb"))
{
- elog(WARN, "destroydb: database %s does not exist.", dbname);
+ elog(ABORT, "destroydb: database %s does not exist.", dbname);
}
else if (dbfound && !strcmp(command, "destroydb")
&& dbowner != *userIdP && use_super == false)
{
- elog(WARN, "%s: database %s is not owned by you.", command, dbname);
+ elog(ABORT, "%s: database %s is not owned by you.", command, dbname);
}
FreeFile(fp);
if (kill(pid, SIGKILLDAEMON1) < 0)
{
- elog(WARN, "can't kill vacuum daemon (pid %d) on %s",
+ elog(ABORT, "can't kill vacuum daemon (pid %d) on %s",
pid, dbname);
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/defind.c,v 1.18 1997/12/22 05:41:49 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/defind.c,v 1.19 1998/01/05 03:30:46 momjian Exp $
*
*-------------------------------------------------------------------------
*/
numberOfAttributes = length(attributeList);
if (numberOfAttributes <= 0)
{
- elog(WARN, "DefineIndex: must specify at least one attribute");
+ elog(ABORT, "DefineIndex: must specify at least one attribute");
}
/*
0, 0, 0);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "DefineIndex: %s relation not found",
+ elog(ABORT, "DefineIndex: %s relation not found",
heapRelationName);
}
relationId = tuple->t_oid;
if (unique && strcmp(accessMethodName, "btree") != 0)
- elog(WARN, "DefineIndex: unique indices are only available with the btree access method");
+ elog(ABORT, "DefineIndex: unique indices are only available with the btree access method");
if (numberOfAttributes > 1 && strcmp(accessMethodName, "btree") != 0)
- elog(WARN, "DefineIndex: multi-column indices are only available with the btree access method");
+ elog(ABORT, "DefineIndex: multi-column indices are only available with the btree access method");
/*
* compute access method id
0, 0, 0);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "DefineIndex: %s access method not found",
+ elog(ABORT, "DefineIndex: %s access method not found",
accessMethodName);
}
accessMethodId = tuple->t_oid;
nargs = length(funcIndex->args);
if (nargs > INDEX_MAX_KEYS)
{
- elog(WARN,
+ elog(ABORT,
"Too many args to function, limit of %d",
INDEX_MAX_KEYS);
}
0, 0, 0);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "ExtendIndex: %s index not found",
+ elog(ABORT, "ExtendIndex: %s index not found",
indexRelationName);
}
indexId = tuple->t_oid;
0, 0, 0);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "ExtendIndex: %s is not an index",
+ elog(ABORT, "ExtendIndex: %s is not an index",
indexRelationName);
}
pfree(predString);
}
if (oldPred == NULL)
- elog(WARN, "ExtendIndex: %s is not a partial index",
+ elog(ABORT, "ExtendIndex: %s is not a partial index",
indexRelationName);
/*
ObjectIdGetDatum(indproc),
0, 0, 0);
if (!HeapTupleIsValid(tuple))
- elog(WARN, "ExtendIndex: index procedure not found");
+ elog(ABORT, "ExtendIndex: index procedure not found");
namecpy(&(funcInfo->funcName),
&(((Form_pg_proc) GETSTRUCT(tuple))->proname));
else if (or_clause(predicate) || and_clause(predicate))
clauses = ((Expr *) predicate)->args;
else
- elog(WARN, "Unsupported partial-index predicate expression type");
+ elog(ABORT, "Unsupported partial-index predicate expression type");
foreach(clause, clauses)
{
!IsA(pred_var, Var) ||
!IsA(pred_const, Const))
{
- elog(WARN, "Unsupported partial-index predicate clause type");
+ elog(ABORT, "Unsupported partial-index predicate clause type");
}
if (getrelid(pred_var->varno, rangeTable) != baseRelOid)
- elog(WARN,
+ elog(ABORT,
"Partial-index predicates may refer only to the base relation");
}
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "DefineIndex: %s class not found",
+ elog(ABORT, "DefineIndex: %s class not found",
funcIndex->class);
}
*opOidP = tuple->t_oid;
if (!HeapTupleIsValid(tuple))
{
- elog(WARN,
+ elog(ABORT,
"DefineIndex: attribute \"%s\" not found",
arg);
}
attribute = lfirst(rest);
if (attribute->name == NULL)
- elog(WARN, "missing attribute for define index");
+ elog(ABORT, "missing attribute for define index");
tuple = SearchSysCacheTuple(ATTNAME,
ObjectIdGetDatum(relId),
0, 0);
if (!HeapTupleIsValid(tuple))
{
- elog(WARN,
+ elog(ABORT,
"DefineIndex: attribute \"%s\" not found",
attribute->name);
}
attribute->class = GetDefaultOpClass(attform->atttypid);
if (attribute->class == NULL)
{
- elog(WARN,
+ elog(ABORT,
"Can't find a default operator class for type %d.",
attform->atttypid);
}
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "DefineIndex: %s class not found",
+ elog(ABORT, "DefineIndex: %s class not found",
attribute->class);
}
*opOidP++ = tuple->t_oid;
if (!HeapTupleIsValid(tuple))
{
- elog(WARN, "index \"%s\" nonexistent", name);
+ elog(ABORT, "index \"%s\" nonexistent", name);
}
if (((Form_pg_class) GETSTRUCT(tuple))->relkind != RELKIND_INDEX)
{
- elog(WARN, "relation \"%s\" is of type \"%c\"",
+ elog(ABORT, "relation \"%s\" is of type \"%c\"",
name,
((Form_pg_class) GETSTRUCT(tuple))->relkind);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/define.c,v 1.19 1997/12/05 01:12:40 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/define.c,v 1.20 1998/01/05 03:30:48 momjian Exp $
*
* DESCRIPTION
* The "DefineFoo" routines take the parse tree and pick out the
* we don't have untrusted functions any more. The 4.2
* implementation is lousy anyway so I took it out. -ay 10/94
*/
- elog(WARN, "untrusted function has been decommissioned.");
+ elog(ABORT, "untrusted function has been decommissioned.");
}
else if (strcasecmp(param->name, "byte_pct") == 0)
{
if (!HeapTupleIsValid(languageTuple)) {
- elog(WARN,
+ elog(ABORT,
"Unrecognized language specified in a CREATE FUNCTION: "
"'%s'. Recognized languages are sql, C, internal "
"and the created procedural languages.",
/* Check that this language is a PL */
languageStruct = (Form_pg_language) GETSTRUCT(languageTuple);
if (!(languageStruct->lanispl)) {
- elog(WARN,
+ elog(ABORT,
"Language '%s' isn't defined as PL", languageName);
}
* restricted to be defined by postgres superusers only
*/
if (languageStruct->lanpltrusted == false && !superuser()) {
- elog(WARN, "Only users with Postgres superuser privilege "
+ elog(ABORT, "Only users with Postgres superuser privilege "
"are permitted to create a function in the '%s' "
"language.",
languageName);
interpret_AS_clause(languageName, stmt->as, &prosrc_str, &probin_str);
if (strcmp(languageName, "sql") != 0 && lanisPL == false && !superuser())
- elog(WARN,
+ elog(ABORT,
"Only users with Postgres superuser privilege are permitted "
"to create a function "
"in the '%s' language. Others may use the 'sql' language "
{
/* see gram.y, must be setof */
if (nodeTag(defel->arg) == T_TypeName)
- elog(WARN, "setof type not implemented for leftarg");
+ elog(ABORT, "setof type not implemented for leftarg");
if (nodeTag(defel->arg) == T_String)
{
}
else
{
- elog(WARN, "type for leftarg is malformed.");
+ elog(ABORT, "type for leftarg is malformed.");
}
}
else if (!strcasecmp(defel->defname, "rightarg"))
{
/* see gram.y, must be setof */
if (nodeTag(defel->arg) == T_TypeName)
- elog(WARN, "setof type not implemented for rightarg");
+ elog(ABORT, "setof type not implemented for rightarg");
if (nodeTag(defel->arg) == T_String)
{
}
else
{
- elog(WARN, "type for rightarg is malformed.");
+ elog(ABORT, "type for rightarg is malformed.");
}
}
else if (!strcasecmp(defel->defname, "procedure"))
*/
if (functionName == NULL)
{
- elog(WARN, "Define: \"procedure\" unspecified");
+ elog(ABORT, "Define: \"procedure\" unspecified");
}
/* ----------------
* make sure we have our required definitions
*/
if (baseType == NULL)
- elog(WARN, "Define: \"basetype\" unspecified");
+ elog(ABORT, "Define: \"basetype\" unspecified");
if (stepfunc1Name != NULL)
{
if (stepfunc1Type == NULL)
- elog(WARN, "Define: \"stype1\" unspecified");
+ elog(ABORT, "Define: \"stype1\" unspecified");
}
if (stepfunc2Name != NULL)
{
if (stepfunc2Type == NULL)
- elog(WARN, "Define: \"stype2\" unspecified");
+ elog(ABORT, "Define: \"stype2\" unspecified");
}
/*
*/
if (strlen(typeName) >= (NAMEDATALEN - 1))
{
- elog(WARN, "DefineType: type names must be %d characters or less",
+ elog(ABORT, "DefineType: type names must be %d characters or less",
NAMEDATALEN - 1);
}
}
else
{
- elog(WARN, "DefineType: \"%s\" alignment not recognized",
+ elog(ABORT, "DefineType: \"%s\" alignment not recognized",
a);
}
}
* make sure we have our required definitions
*/
if (inputName == NULL)
- elog(WARN, "Define: \"input\" unspecified");
+ elog(ABORT, "Define: \"input\" unspecified");
if (outputName == NULL)
- elog(WARN, "Define: \"output\" unspecified");
+ elog(ABORT, "Define: \"output\" unspecified");
/* ----------------
* now have TypeCreate do all the real work.
defGetString(DefElem *def)
{
if (nodeTag(def->arg) != T_String)
- elog(WARN, "Define: \"%s\" = what?", def->defname);
+ elog(ABORT, "Define: \"%s\" = what?", def->defname);
return (strVal(def->arg));
}
!strcasecmp(strVal(def->arg), "variable"))
return -1; /* variable length */
- elog(WARN, "Define: \"%s\" = what?", def->defname);
+ elog(ABORT, "Define: \"%s\" = what?", def->defname);
return -1;
}
*/
if (!superuser())
{
- elog(WARN, "Only users with Postgres superuser privilege are "
+ elog(ABORT, "Only users with Postgres superuser privilege are "
"permitted to create procedural languages");
}
0, 0, 0);
if (HeapTupleIsValid(langTup))
{
- elog(WARN, "Language %s already exists", languageName);
+ elog(ABORT, "Language %s already exists", languageName);
}
/* ----------------
0);
if (!HeapTupleIsValid(procTup))
{
- elog(WARN, "PL handler function %s() doesn't exist",
+ elog(ABORT, "PL handler function %s() doesn't exist",
stmt->plhandler);
}
if (((Form_pg_proc) GETSTRUCT(procTup))->prorettype != InvalidOid)
{
- elog(WARN, "PL handler function %s() isn't of return type Opaque",
+ elog(ABORT, "PL handler function %s() isn't of return type Opaque",
stmt->plhandler);
}
*/
if (!superuser())
{
- elog(WARN, "Only users with Postgres superuser privilege are "
+ elog(ABORT, "Only users with Postgres superuser privilege are "
"permitted to drop procedural languages");
}
0, 0, 0);
if (!HeapTupleIsValid(langTup))
{
- elog(WARN, "Language %s doesn't exist", languageName);
+ elog(ABORT, "Language %s doesn't exist", languageName);
}
if (!((Form_pg_language) GETSTRUCT(langTup))->lanispl)
{
- elog(WARN, "Language %s isn't a created procedural language",
+ elog(ABORT, "Language %s isn't a created procedural language",
languageName);
}
if (!HeapTupleIsValid(tup))
{
- elog(WARN, "Language with name '%s' not found", languageName);
+ elog(ABORT, "Language with name '%s' not found", languageName);
}
heap_delete(rdesc, &(tup->t_ctid));
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/recipe.c,v 1.15 1997/11/28 17:27:08 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/recipe.c,v 1.16 1998/01/05 03:30:50 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
if (nodeTag(orig->qual) == T_List)
{
- elog(WARN, "tg_rewriteQuery: Whoa! why is my qual a List???");
+ elog(ABORT, "tg_rewriteQuery: Whoa! why is my qual a List???");
}
orig->qual = tg_rewriteParamsInExpr(orig->qual, inputQlist);
}
}
else
{
- elog(WARN, "tg_rewriteParamsInExpr:can't substitute for parameter %d when that input is unconnected", p->paramid);
+ elog(ABORT, "tg_rewriteParamsInExpr:can't substitute for parameter %d when that input is unconnected", p->paramid);
}
}
{
if (parameterCount == 8)
{
- elog(WARN,
+ elog(ABORT,
"getParamTypes: Ingredients cannot take > 8 arguments");
}
t = elem->inTypes->val[j];
if (strcmp(t, "opaque") == 0)
{
- elog(WARN,
+ elog(ABORT,
"getParamTypes: Ingredient functions cannot take type 'opaque'");
}
else
toid = TypeGet(elem->inTypes->val[j], &defined);
if (!OidIsValid(toid))
{
- elog(WARN, "getParamTypes: arg type '%s' is not defined", t);
+ elog(ABORT, "getParamTypes: arg type '%s' is not defined", t);
}
if (!defined)
{
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/remove.c,v 1.18 1997/11/28 17:27:10 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/remove.c,v 1.19 1998/01/05 03:30:51 momjian Exp $
*
*-------------------------------------------------------------------------
*/
typeId1 = TypeGet(typeName1, &defined);
if (!OidIsValid(typeId1))
{
- elog(WARN, "RemoveOperator: type '%s' does not exist", typeName1);
+ elog(ABORT, "RemoveOperator: type '%s' does not exist", typeName1);
return;
}
}
typeId2 = TypeGet(typeName2, &defined);
if (!OidIsValid(typeId2))
{
- elog(WARN, "RemoveOperator: type '%s' does not exist", typeName2);
+ elog(ABORT, "RemoveOperator: type '%s' does not exist", typeName2);
return;
}
}
if (!pg_ownercheck(userName,
(char *) ObjectIdGetDatum(tup->t_oid),
OPROID))
- elog(WARN, "RemoveOperator: operator '%s': permission denied",
+ elog(ABORT, "RemoveOperator: operator '%s': permission denied",
operatorName);
#endif
ItemPointerCopy(&tup->t_ctid, &itemPointerData);
{
if (OidIsValid(typeId1) && OidIsValid(typeId2))
{
- elog(WARN, "RemoveOperator: binary operator '%s' taking '%s' and '%s' does not exist",
+ elog(ABORT, "RemoveOperator: binary operator '%s' taking '%s' and '%s' does not exist",
operatorName,
typeName1,
typeName2);
}
else if (OidIsValid(typeId1))
{
- elog(WARN, "RemoveOperator: right unary operator '%s' taking '%s' does not exist",
+ elog(ABORT, "RemoveOperator: right unary operator '%s' taking '%s' does not exist",
operatorName,
typeName1);
}
else
{
- elog(WARN, "RemoveOperator: left unary operator '%s' taking '%s' does not exist",
+ elog(ABORT, "RemoveOperator: left unary operator '%s' taking '%s' does not exist",
operatorName,
typeName2);
}
#ifndef NO_SECURITY
userName = GetPgUserName();
if (!pg_ownercheck(userName, typeName, TYPNAME))
- elog(WARN, "RemoveType: type '%s': permission denied",
+ elog(ABORT, "RemoveType: type '%s': permission denied",
typeName);
#endif
{
heap_endscan(scan);
heap_close(relation);
- elog(WARN, "RemoveType: type '%s' does not exist",
+ elog(ABORT, "RemoveType: type '%s' does not exist",
typeName);
}
typeOid = tup->t_oid;
if (!HeapTupleIsValid(tup))
{
- elog(WARN, "RemoveType: type '%s': array stub not found",
+ elog(ABORT, "RemoveType: type '%s': array stub not found",
typeName);
}
typeOid = tup->t_oid;
if (!HeapTupleIsValid(tup))
{
- elog(WARN, "RemoveFunction: type '%s' not found", typename);
+ elog(ABORT, "RemoveFunction: type '%s' not found", typename);
}
argList[i] = tup->t_oid;
}
userName = GetPgUserName();
if (!pg_func_ownercheck(userName, functionName, nargs, argList))
{
- elog(WARN, "RemoveFunction: function '%s': permission denied",
+ elog(ABORT, "RemoveFunction: function '%s': permission denied",
functionName);
}
#endif
/* ok, function has been found */
if (the_proc->prolang == INTERNALlanguageId)
- elog(WARN, "RemoveFunction: function \"%s\" is built-in",
+ elog(ABORT, "RemoveFunction: function \"%s\" is built-in",
functionName);
ItemPointerCopy(&tup->t_ctid, &itemPointerData);
basetypeID = TypeGet(aggType, &defined);
if (!OidIsValid(basetypeID))
{
- elog(WARN, "RemoveAggregate: type '%s' does not exist", aggType);
+ elog(ABORT, "RemoveAggregate: type '%s' does not exist", aggType);
}
}
else
{
if (aggType)
{
- elog(WARN, "RemoveAggregate: aggregate '%s' on type '%s': permission denied",
+ elog(ABORT, "RemoveAggregate: aggregate '%s' on type '%s': permission denied",
aggName, aggType);
}
else
{
- elog(WARN, "RemoveAggregate: aggregate '%s': permission denied",
+ elog(ABORT, "RemoveAggregate: aggregate '%s': permission denied",
aggName);
}
}
heap_close(relation);
if (aggType)
{
- elog(WARN, "RemoveAggregate: aggregate '%s' for '%s' does not exist",
+ elog(ABORT, "RemoveAggregate: aggregate '%s' for '%s' does not exist",
aggName, aggType);
}
else
{
- elog(WARN, "RemoveAggregate: aggregate '%s' for all types does not exist",
+ elog(ABORT, "RemoveAggregate: aggregate '%s' for all types does not exist",
aggName);
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/Attic/rename.c,v 1.9 1997/09/08 02:22:14 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/Attic/rename.c,v 1.10 1998/01/05 03:30:52 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* normally, only the owner of a class can change its schema.
*/
if (IsSystemRelationName(relname))
- elog(WARN, "renameatt: class \"%s\" is a system catalog",
+ elog(ABORT, "renameatt: class \"%s\" is a system catalog",
relname);
#ifndef NO_SECURITY
if (!IsBootstrapProcessingMode() &&
!pg_ownercheck(userName, relname, RELNAME))
- elog(WARN, "renameatt: you do not own class \"%s\"",
+ elog(ABORT, "renameatt: you do not own class \"%s\"",
relname);
#endif
relrdesc = heap_openr(relname);
if (!RelationIsValid(relrdesc))
{
- elog(WARN, "renameatt: unknown relation: \"%s\"",
+ elog(ABORT, "renameatt: unknown relation: \"%s\"",
relname);
}
myrelid = relrdesc->rd_id;
relrdesc = heap_open(childrelid);
if (!RelationIsValid(relrdesc))
{
- elog(WARN, "renameatt: can't find catalog entry for inheriting class with oid %d",
+ elog(ABORT, "renameatt: can't find catalog entry for inheriting class with oid %d",
childrelid);
}
childname = (relrdesc->rd_rel->relname).data;
if (!PointerIsValid(reltup))
{
heap_close(relrdesc);
- elog(WARN, "renameatt: relation \"%s\" nonexistent",
+ elog(ABORT, "renameatt: relation \"%s\" nonexistent",
relname);
return;
}
if (!PointerIsValid(oldatttup))
{
heap_close(attrdesc);
- elog(WARN, "renameatt: attribute \"%s\" nonexistent",
+ elog(ABORT, "renameatt: attribute \"%s\" nonexistent",
oldattname);
}
if (((AttributeTupleForm) GETSTRUCT(oldatttup))->attnum < 0)
{
- elog(WARN, "renameatt: system attribute \"%s\" not renamed",
+ elog(ABORT, "renameatt: system attribute \"%s\" not renamed",
oldattname);
}
{
pfree(oldatttup);
heap_close(attrdesc);
- elog(WARN, "renameatt: attribute \"%s\" exists",
+ elog(ABORT, "renameatt: attribute \"%s\" exists",
newattname);
}
if (IsSystemRelationName(oldrelname))
{
- elog(WARN, "renamerel: system relation \"%s\" not renamed",
+ elog(ABORT, "renamerel: system relation \"%s\" not renamed",
oldrelname);
return;
}
if (IsSystemRelationName(newrelname))
{
- elog(WARN, "renamerel: Illegal class name: \"%s\" -- pg_ is reserved for system catalogs",
+ elog(ABORT, "renamerel: Illegal class name: \"%s\" -- pg_ is reserved for system catalogs",
newrelname);
return;
}
if (!PointerIsValid(oldreltup))
{
heap_close(relrdesc);
- elog(WARN, "renamerel: relation \"%s\" does not exist",
+ elog(ABORT, "renamerel: relation \"%s\" does not exist",
oldrelname);
}
{
pfree(oldreltup);
heap_close(relrdesc);
- elog(WARN, "renamerel: relation \"%s\" exists",
+ elog(ABORT, "renamerel: relation \"%s\" exists",
newrelname);
}
strcpy(oldpath, relpath(oldrelname));
strcpy(newpath, relpath(newrelname));
if (rename(oldpath, newpath) < 0)
- elog(WARN, "renamerel: unable to rename file: %m");
+ elog(ABORT, "renamerel: unable to rename file: %m");
memmove((char *) (((Form_pg_class) GETSTRUCT(oldreltup))->relname.data),
newrelname,
buf = ReadBuffer(rel, P_NEW);
if (!BufferIsValid(buf))
- elog(WARN, "DefineSequence: ReadBuffer failed");
+ elog(ABORT, "DefineSequence: ReadBuffer failed");
page = (PageHeader) BufferGetPage(buf);
heap_insert(rel, tuple);
if (WriteBuffer(buf) == STATUS_ERROR)
- elog(WARN, "DefineSequence: WriteBuffer failed");
+ elog(ABORT, "DefineSequence: WriteBuffer failed");
RelationUnsetLockForWrite(rel);
heap_close(rel);
if (rescnt > 0)
break; /* stop caching */
if (seq->is_cycled != 't')
- elog(WARN, "%s.nextval: got MAXVALUE (%d)",
+ elog(ABORT, "%s.nextval: got MAXVALUE (%d)",
elm->name, maxv);
next = minv;
}
if (rescnt > 0)
break; /* stop caching */
if (seq->is_cycled != 't')
- elog(WARN, "%s.nextval: got MINVALUE (%d)",
+ elog(ABORT, "%s.nextval: got MINVALUE (%d)",
elm->name, minv);
next = maxv;
}
seq->is_called = 't';
if (WriteBuffer(buf) == STATUS_ERROR)
- elog(WARN, "%s.nextval: WriteBuffer failed", elm->name);
+ elog(ABORT, "%s.nextval: WriteBuffer failed", elm->name);
ItemPointerSet(&iptr, 0, FirstOffsetNumber);
RelationUnsetSingleWLockPage(elm->rel, &iptr);
if (elm->increment == 0) /* nextval/read_info were not called */
{
- elog(WARN, "%s.currval is not yet defined in this session", elm->name);
+ elog(ABORT, "%s.currval is not yet defined in this session", elm->name);
}
result = elm->last;
RelationSetSingleWLockPage(elm->rel, &iptr);
if (RelationGetNumberOfBlocks(elm->rel) != 1)
- elog(WARN, "%s.%s: invalid number of blocks in sequence",
+ elog(ABORT, "%s.%s: invalid number of blocks in sequence",
elm->name, caller);
*buf = ReadBuffer(elm->rel, 0);
if (!BufferIsValid(*buf))
- elog(WARN, "%s.%s: ReadBuffer failed", elm->name, caller);
+ elog(ABORT, "%s.%s: ReadBuffer failed", elm->name, caller);
page = (PageHeader) BufferGetPage(*buf);
sm = (sequence_magic *) PageGetSpecialPointer(page);
if (sm->magic != SEQ_MAGIC)
- elog(WARN, "%s.%s: bad magic (%08X)", elm->name, caller, sm->magic);
+ elog(ABORT, "%s.%s: bad magic (%08X)", elm->name, caller, sm->magic);
lp = PageGetItemId(page, FirstOffsetNumber);
Assert(ItemIdIsUsed(lp));
temp->rel = heap_openr(name);
if (!RelationIsValid(temp->rel))
- elog(WARN, "%s.%s: sequence does not exist", name, caller);
+ elog(ABORT, "%s.%s: sequence does not exist", name, caller);
RelationSetWIntentLock(temp->rel);
if (temp->rel->rd_rel->relkind != RELKIND_SEQUENCE)
- elog(WARN, "%s.%s: %s is not sequence !", name, caller, name);
+ elog(ABORT, "%s.%s: %s is not sequence !", name, caller, name);
if (elm != (SeqTable) NULL) /* we opened sequence from our */
{ /* SeqTable - check relid ! */
else if (!strcasecmp(defel->defname, "cycle"))
{
if (defel->arg != (Node *) NULL)
- elog(WARN, "DefineSequence: CYCLE ??");
+ elog(ABORT, "DefineSequence: CYCLE ??");
new->is_cycled = 't';
}
else
- elog(WARN, "DefineSequence: option \"%s\" not recognized",
+ elog(ABORT, "DefineSequence: option \"%s\" not recognized",
defel->defname);
}
if (increment_by == (DefElem *) NULL) /* INCREMENT BY */
new->increment_by = 1;
else if ((new->increment_by = get_param(increment_by)) == 0)
- elog(WARN, "DefineSequence: can't INCREMENT by 0");
+ elog(ABORT, "DefineSequence: can't INCREMENT by 0");
if (max_value == (DefElem *) NULL) /* MAXVALUE */
if (new->increment_by > 0)
new->min_value = get_param(min_value);
if (new->min_value >= new->max_value)
- elog(WARN, "DefineSequence: MINVALUE (%d) can't be >= MAXVALUE (%d)",
+ elog(ABORT, "DefineSequence: MINVALUE (%d) can't be >= MAXVALUE (%d)",
new->min_value, new->max_value);
if (last_value == (DefElem *) NULL) /* START WITH */
new->last_value = get_param(last_value);
if (new->last_value < new->min_value)
- elog(WARN, "DefineSequence: START value (%d) can't be < MINVALUE (%d)",
+ elog(ABORT, "DefineSequence: START value (%d) can't be < MINVALUE (%d)",
new->last_value, new->min_value);
if (new->last_value > new->max_value)
- elog(WARN, "DefineSequence: START value (%d) can't be > MAXVALUE (%d)",
+ elog(ABORT, "DefineSequence: START value (%d) can't be > MAXVALUE (%d)",
new->last_value, new->max_value);
if (cache_value == (DefElem *) NULL) /* CACHE */
new->cache_value = 1;
else if ((new->cache_value = get_param(cache_value)) <= 0)
- elog(WARN, "DefineSequence: CACHE (%d) can't be <= 0",
+ elog(ABORT, "DefineSequence: CACHE (%d) can't be <= 0",
new->cache_value);
}
get_param(DefElem *def)
{
if (def->arg == (Node *) NULL)
- elog(WARN, "DefineSequence: \"%s\" value unspecified", def->defname);
+ elog(ABORT, "DefineSequence: \"%s\" value unspecified", def->defname);
if (nodeTag(def->arg) == T_Integer)
return (intVal(def->arg));
- elog(WARN, "DefineSequence: \"%s\" is to be integer", def->defname);
+ elog(ABORT, "DefineSequence: \"%s\" is to be integer", def->defname);
return (-1);
}
int i;
if (IsSystemRelationName(stmt->relname))
- elog(WARN, "CreateTrigger: can't create trigger for system relation %s", stmt->relname);
+ elog(ABORT, "CreateTrigger: can't create trigger for system relation %s", stmt->relname);
#ifndef NO_SECURITY
if (!pg_ownercheck(GetPgUserName(), stmt->relname, RELNAME))
- elog(WARN, "%s: %s", stmt->relname, aclcheck_error_strings[ACLCHECK_NOT_OWNER]);
+ elog(ABORT, "%s: %s", stmt->relname, aclcheck_error_strings[ACLCHECK_NOT_OWNER]);
#endif
rel = heap_openr(stmt->relname);
if (!RelationIsValid(rel))
- elog(WARN, "CreateTrigger: there is no relation %s", stmt->relname);
+ elog(ABORT, "CreateTrigger: there is no relation %s", stmt->relname);
RelationSetLockForWrite(rel);
if (stmt->row)
TRIGGER_SETT_ROW(tgtype);
else
- elog(WARN, "CreateTrigger: STATEMENT triggers are unimplemented, yet");
+ elog(ABORT, "CreateTrigger: STATEMENT triggers are unimplemented, yet");
for (i = 0; i < 3 && stmt->actions[i]; i++)
{
{
case 'i':
if (TRIGGER_FOR_INSERT(tgtype))
- elog(WARN, "CreateTrigger: double INSERT event specified");
+ elog(ABORT, "CreateTrigger: double INSERT event specified");
TRIGGER_SETT_INSERT(tgtype);
break;
case 'd':
if (TRIGGER_FOR_DELETE(tgtype))
- elog(WARN, "CreateTrigger: double DELETE event specified");
+ elog(ABORT, "CreateTrigger: double DELETE event specified");
TRIGGER_SETT_DELETE(tgtype);
break;
case 'u':
if (TRIGGER_FOR_UPDATE(tgtype))
- elog(WARN, "CreateTrigger: double UPDATE event specified");
+ elog(ABORT, "CreateTrigger: double UPDATE event specified");
TRIGGER_SETT_UPDATE(tgtype);
break;
default:
- elog(WARN, "CreateTrigger: unknown event specified");
+ elog(ABORT, "CreateTrigger: unknown event specified");
break;
}
}
Form_pg_trigger pg_trigger = (Form_pg_trigger) GETSTRUCT(tuple);
if (namestrcmp(&(pg_trigger->tgname), stmt->trigname) == 0)
- elog(WARN, "CreateTrigger: trigger %s already defined on relation %s",
+ elog(ABORT, "CreateTrigger: trigger %s already defined on relation %s",
stmt->trigname, stmt->relname);
else
found++;
if (!HeapTupleIsValid(tuple) ||
((Form_pg_proc) GETSTRUCT(tuple))->prorettype != 0 ||
((Form_pg_proc) GETSTRUCT(tuple))->pronargs != 0)
- elog(WARN, "CreateTrigger: function %s () does not exist", stmt->funcname);
+ elog(ABORT, "CreateTrigger: function %s () does not exist", stmt->funcname);
if (((Form_pg_proc) GETSTRUCT(tuple))->prolang != ClanguageId)
{
0, 0, 0);
if (!HeapTupleIsValid(langTup))
{
- elog(WARN, "CreateTrigger: cache lookup for PL failed");
+ elog(ABORT, "CreateTrigger: cache lookup for PL failed");
}
if (((Form_pg_language) GETSTRUCT(langTup))->lanispl == false)
{
- elog(WARN, "CreateTrigger: only C and PL functions are supported");
+ elog(ABORT, "CreateTrigger: only C and PL functions are supported");
}
}
if (!PointerIsValid(tuple))
{
heap_close(relrdesc);
- elog(WARN, "CreateTrigger: relation %s not found in pg_class", stmt->relname);
+ elog(ABORT, "CreateTrigger: relation %s not found in pg_class", stmt->relname);
}
((Form_pg_class) GETSTRUCT(tuple))->reltriggers = found + 1;
RelationInvalidateHeapTuple(relrdesc, tuple);
#ifndef NO_SECURITY
if (!pg_ownercheck(GetPgUserName(), stmt->relname, RELNAME))
- elog(WARN, "%s: %s", stmt->relname, aclcheck_error_strings[ACLCHECK_NOT_OWNER]);
+ elog(ABORT, "%s: %s", stmt->relname, aclcheck_error_strings[ACLCHECK_NOT_OWNER]);
#endif
rel = heap_openr(stmt->relname);
if (!RelationIsValid(rel))
- elog(WARN, "DropTrigger: there is no relation %s", stmt->relname);
+ elog(ABORT, "DropTrigger: there is no relation %s", stmt->relname);
RelationSetLockForWrite(rel);
found++;
}
if (tgfound == 0)
- elog(WARN, "DropTrigger: there is no trigger %s on relation %s",
+ elog(ABORT, "DropTrigger: there is no trigger %s on relation %s",
stmt->trigname, stmt->relname);
if (tgfound > 1)
elog(NOTICE, "DropTrigger: found (and deleted) %d trigger %s on relation %s",
if (!PointerIsValid(tuple))
{
heap_close(relrdesc);
- elog(WARN, "DropTrigger: relation %s not found in pg_class", stmt->relname);
+ elog(ABORT, "DropTrigger: relation %s not found in pg_class", stmt->relname);
}
((Form_pg_class) GETSTRUCT(tuple))->reltriggers = found;
RelationInvalidateHeapTuple(relrdesc, tuple);
if (!HeapTupleIsValid(tuple))
continue;
if (found == ntrigs)
- elog(WARN, "RelationBuildTriggers: unexpected record found for rel %.*s",
+ elog(ABORT, "RelationBuildTriggers: unexpected record found for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
pg_trigger = (Form_pg_trigger) GETSTRUCT(tuple);
Anum_pg_trigger_tgargs,
tgrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "RelationBuildTriggers: tgargs IS NULL for rel %.*s",
+ elog(ABORT, "RelationBuildTriggers: tgargs IS NULL for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
if (build->tgnargs > 0)
{
Anum_pg_trigger_tgargs,
tgrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "RelationBuildTriggers: tgargs IS NULL for rel %.*s",
+ elog(ABORT, "RelationBuildTriggers: tgargs IS NULL for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
p = (char *) VARDATA(val);
build->tgargs = (char **) palloc(build->tgnargs * sizeof(char *));
}
if (found < ntrigs)
- elog(WARN, "RelationBuildTriggers: %d record not found for rel %.*s",
+ elog(ABORT, "RelationBuildTriggers: %d record not found for rel %.*s",
ntrigs - found,
NAMEDATALEN, relation->rd_rel->relname.data);
0, 0, 0);
if (!HeapTupleIsValid(procTuple))
{
- elog(WARN, "ExecCallTriggerFunc(): Cache lookup for proc %ld failed",
+ elog(ABORT, "ExecCallTriggerFunc(): Cache lookup for proc %ld failed",
ObjectIdGetDatum(trigger->tgfoid));
}
procStruct = (Form_pg_proc) GETSTRUCT(procTuple);
0, 0, 0);
if (!HeapTupleIsValid(langTuple))
{
- elog(WARN, "ExecCallTriggerFunc(): Cache lookup for language %ld failed",
+ elog(ABORT, "ExecCallTriggerFunc(): Cache lookup for language %ld failed",
ObjectIdGetDatum(procStruct->prolang));
}
langStruct = (Form_pg_language) GETSTRUCT(langTuple);
b = ReadBuffer(relation, ItemPointerGetBlockNumber(tid));
if (!BufferIsValid(b))
- elog(WARN, "GetTupleForTrigger: failed ReadBuffer");
+ elog(ABORT, "GetTupleForTrigger: failed ReadBuffer");
dp = (PageHeader) BufferGetPage(b);
lp = PageGetItemId(dp, ItemPointerGetOffsetNumber(tid));
if (!tuple)
{
ReleaseBuffer(b);
- elog(WARN, "GetTupleForTrigger: (am)invalid tid");
+ elog(ABORT, "GetTupleForTrigger: (am)invalid tid");
}
}
pg_user = GetPgUserName();
if (pg_aclcheck(UserRelationName, pg_user, ACL_RD | ACL_WR | ACL_AP) != ACLCHECK_OK) {
UserAbortTransactionBlock();
- elog(WARN, "defineUser: user \"%s\" does not have SELECT and INSERT privilege for \"%s\"",
+ elog(ABORT, "defineUser: user \"%s\" does not have SELECT and INSERT privilege for \"%s\"",
pg_user, UserRelationName);
return;
}
RelationUnsetLockForWrite(pg_user_rel);
heap_close(pg_user_rel);
UserAbortTransactionBlock();
- elog(WARN, "defineUser: user \"%s\" has already been created", stmt->user);
+ elog(ABORT, "defineUser: user \"%s\" has already been created", stmt->user);
return;
}
pg_user = GetPgUserName();
if (pg_aclcheck(UserRelationName, pg_user, ACL_RD | ACL_WR) != ACLCHECK_OK) {
UserAbortTransactionBlock();
- elog(WARN, "alterUser: user \"%s\" does not have SELECT and UPDATE privilege for \"%s\"",
+ elog(ABORT, "alterUser: user \"%s\" does not have SELECT and UPDATE privilege for \"%s\"",
pg_user, UserRelationName);
return;
}
RelationUnsetLockForWrite(pg_user_rel);
heap_close(pg_user_rel);
UserAbortTransactionBlock();
- elog(WARN, "alterUser: user \"%s\" does not exist", stmt->user);
+ elog(ABORT, "alterUser: user \"%s\" does not exist", stmt->user);
return;
}
pg_user = GetPgUserName();
if (pg_aclcheck(UserRelationName, pg_user, ACL_RD | ACL_WR) != ACLCHECK_OK) {
UserAbortTransactionBlock();
- elog(WARN, "removeUser: user \"%s\" does not have SELECT and DELETE privilege for \"%s\"",
+ elog(ABORT, "removeUser: user \"%s\" does not have SELECT and DELETE privilege for \"%s\"",
pg_user, UserRelationName);
return;
}
RelationUnsetLockForWrite(pg_user_rel);
heap_close(pg_user_rel);
UserAbortTransactionBlock();
- elog(WARN, "removeUser: user \"%s\" does not exist", user);
+ elog(ABORT, "removeUser: user \"%s\" does not exist", user);
return;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.55 1997/12/19 02:05:33 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.56 1998/01/05 03:30:57 momjian Exp $
*
*-------------------------------------------------------------------------
*/
int fd;
if ((fd = open("pg_vlock", O_CREAT | O_EXCL, 0600)) < 0)
- elog(WARN, "can't create lock file -- another vacuum cleaner running?");
+ elog(ABORT, "can't create lock file -- another vacuum cleaner running?");
close(fd);
{
/* on entry, not in a transaction */
if (unlink("pg_vlock") < 0)
- elog(WARN, "vacuum: can't destroy lock file!");
+ elog(ABORT, "vacuum: can't destroy lock file!");
/* okay, we're done */
VacuumRunning = false;
List *le;
if (length(va_cols) > attr_cnt)
- elog(WARN, "vacuum: too many attributes specified for relation %s",
+ elog(ABORT, "vacuum: too many attributes specified for relation %s",
(RelationGetRelationName(onerel))->data);
attnums = (int *) palloc(attr_cnt * sizeof(int));
foreach(le, va_cols)
attnums[tcnt++] = i;
else
{
- elog(WARN, "vacuum: there is no attribute %s in %s",
+ elog(ABORT, "vacuum: there is no attribute %s in %s",
col, (RelationGetRelationName(onerel))->data);
}
}
InvalidOffsetNumber, LP_USED);
if (newoff == InvalidOffsetNumber)
{
- elog(WARN, "\
+ elog(ABORT, "\
failed to add item with len = %u to page %u (free space %u, nusd %u, noff %u)",
tlen, ToVpd->vpd_blkno, ToVpd->vpd_free,
ToVpd->vpd_nusd, ToVpd->vpd_noff);
rsdesc = heap_beginscan(rd, false, false, 1, &rskey);
if (!HeapTupleIsValid(rtup = heap_getnext(rsdesc, 0, &rbuf)))
- elog(WARN, "pg_class entry for relid %d vanished during vacuuming",
+ elog(ABORT, "pg_class entry for relid %d vanished during vacuuming",
relid);
/* overwrite the existing statistics in the tuple */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/view.c,v 1.17 1997/11/28 17:27:13 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/view.c,v 1.18 1998/01/05 03:30:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
else
{
- elog(WARN, "attempted to define virtual relation with no attrs");
+ elog(ABORT, "attempted to define virtual relation with no attrs");
}
/*
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/execAmi.c,v 1.12 1997/11/28 04:40:03 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/execAmi.c,v 1.13 1998/01/05 03:31:01 momjian Exp $
*
*-------------------------------------------------------------------------
*/
break;
default:
- elog(WARN, "ExecReScan: not a seqscan or indexscan node.");
+ elog(ABORT, "ExecReScan: not a seqscan or indexscan node.");
return;
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/execMain.c,v 1.35 1997/11/28 17:27:20 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/execMain.c,v 1.36 1998/01/05 03:31:06 momjian Exp $
*
*-------------------------------------------------------------------------
*/
ObjectIdGetDatum(relid),
0, 0, 0);
if (!HeapTupleIsValid(htp))
- elog(WARN, "ExecCheckPerms: bogus RT relid: %d",
+ elog(ABORT, "ExecCheckPerms: bogus RT relid: %d",
relid);
StrNCpy(rname.data,
((Form_pg_class) GETSTRUCT(htp))->relname.data,
opstr = "write";
break;
default:
- elog(WARN, "ExecCheckPerms: bogus operation %d",
+ elog(ABORT, "ExecCheckPerms: bogus operation %d",
operation);
}
}
}
if (!ok)
{
- elog(WARN, "%s: %s", rname.data, aclcheck_error_strings[aclcheck_result]);
+ elog(ABORT, "%s: %s", rname.data, aclcheck_error_strings[aclcheck_result]);
}
}
resultRelationDesc = heap_open(resultRelationOid);
if (resultRelationDesc->rd_rel->relkind == RELKIND_SEQUENCE)
- elog(WARN, "You can't change sequence relation %s",
+ elog(ABORT, "You can't change sequence relation %s",
resultRelationDesc->rd_rel->relname.data);
/*
"ctid",
&datum,
&isNull))
- elog(WARN, "ExecutePlan: NO (junk) `ctid' was found!");
+ elog(ABORT, "ExecutePlan: NO (junk) `ctid' was found!");
if (isNull)
- elog(WARN, "ExecutePlan: (junk) `ctid' is NULL!");
+ elog(ABORT, "ExecutePlan: (junk) `ctid' is NULL!");
tupleid = (ItemPointer) DatumGetPointer(datum);
tuple_ctid = *tupleid; /* make sure we don't free the
for (attrChk = 1; attrChk <= rel->rd_att->natts; attrChk++)
{
if (rel->rd_att->attrs[attrChk - 1]->attnotnull && heap_attisnull(tuple, attrChk))
- elog(WARN, "%s: Fail to add null value in not null attribute %s",
+ elog(ABORT, "%s: Fail to add null value in not null attribute %s",
caller, rel->rd_att->attrs[attrChk - 1]->attname.data);
}
}
char *failed;
if ((failed = ExecRelCheck(rel, tuple)) != NULL)
- elog(WARN, "%s: rejected due to CHECK constraint %s", caller, failed);
+ elog(ABORT, "%s: rejected due to CHECK constraint %s", caller, failed);
}
return (newtuple);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/execProcnode.c,v 1.5 1997/09/08 21:42:59 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/execProcnode.c,v 1.6 1998/01/05 03:31:08 momjian Exp $
*
*-------------------------------------------------------------------------
*/
return ExecCountSlotsTee((Tee *) node);
default:
- elog(WARN, "ExecCountSlotsNode: node not yet supported: %d",
+ elog(ABORT, "ExecCountSlotsNode: node not yet supported: %d",
nodeTag(node));
break;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/execQual.c,v 1.20 1997/11/26 03:54:00 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/execQual.c,v 1.21 1998/01/05 03:31:11 momjian Exp $
*
*-------------------------------------------------------------------------
*/
return (Datum) NULL;
}
if (i != j)
- elog(WARN,
+ elog(ABORT,
"ExecEvalArrayRef: upper and lower indices mismatch");
lIndex = lower.indx;
}
*/
if (strcmp(paramList->name, thisParameterName) != 0)
{
- elog(WARN,
+ elog(ABORT,
"ExecEvalParam: new/old params with same id & diff names");
}
}
/*
* oops! this is not supposed to happen!
*/
- elog(WARN, "ExecEvalParam: invalid paramkind %d",
+ elog(ABORT, "ExecEvalParam: invalid paramkind %d",
thisParameterKind);
}
if (!matchFound)
* ooops! we couldn't find this parameter in the parameter list.
* Signal an error
*/
- elog(WARN, "ExecEvalParam: Unknown value for parameter %s",
+ elog(ABORT, "ExecEvalParam: Unknown value for parameter %s",
thisParameterName);
}
Datum retval;
if (!AttributeNumberIsValid(attrno))
- elog(WARN, "GetAttributeByNum: Invalid attribute number");
+ elog(ABORT, "GetAttributeByNum: Invalid attribute number");
if (!AttrNumberIsForUserDefinedAttr(attrno))
- elog(WARN, "GetAttributeByNum: cannot access system attributes here");
+ elog(ABORT, "GetAttributeByNum: cannot access system attributes here");
if (isNull == (bool *) NULL)
- elog(WARN, "GetAttributeByNum: a NULL isNull flag was passed");
+ elog(ABORT, "GetAttributeByNum: a NULL isNull flag was passed");
if (TupIsNull(slot))
{
int i;
if (attname == NULL)
- elog(WARN, "GetAttributeByName: Invalid attribute name");
+ elog(ABORT, "GetAttributeByName: Invalid attribute name");
if (isNull == (bool *) NULL)
- elog(WARN, "GetAttributeByName: a NULL isNull flag was passed");
+ elog(ABORT, "GetAttributeByName: a NULL isNull flag was passed");
if (TupIsNull(slot))
{
}
if (attrno == InvalidAttrNumber)
- elog(WARN, "GetAttributeByName: attribute %s not found", attname);
+ elog(ABORT, "GetAttributeByName: attribute %s not found", attname);
retval = heap_getattr(slot->val,
slot->ttc_buffer,
bool argDone;
if (fcache->nargs > MAXFMGRARGS)
- elog(WARN, "ExecMakeFunctionResult: too many arguments");
+ elog(ABORT, "ExecMakeFunctionResult: too many arguments");
/*
* If the setArg in the fcache is set we have an argument
retDatum = (Datum) ExecEvalNot(expr, econtext, isNull);
break;
default:
- elog(WARN, "ExecEvalExpr: unknown expression type");
+ elog(ABORT, "ExecEvalExpr: unknown expression type");
break;
}
break;
}
default:
- elog(WARN, "ExecEvalExpr: unknown expression type");
+ elog(ABORT, "ExecEvalExpr: unknown expression type");
break;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/execTuples.c,v 1.13 1997/12/18 12:53:42 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/execTuples.c,v 1.14 1998/01/05 03:31:12 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* table->size = newsize;
*/
elog(NOTICE, "Plan requires more slots than are available");
- elog(WARN, "send mail to your local executor guru to fix this");
+ elog(ABORT, "send mail to your local executor guru to fix this");
}
/* ----------------
* should never get here
* ----------------
*/
- elog(WARN, "NodeGetResultTupleSlot: node not yet supported: %d ",
+ elog(ABORT, "NodeGetResultTupleSlot: node not yet supported: %d ",
nodeTag(node));
return NULL;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/execUtils.c,v 1.21 1997/11/20 23:21:26 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/execUtils.c,v 1.22 1998/01/05 03:31:13 momjian Exp $
*
*-------------------------------------------------------------------------
*/
*/
att = typeInfo[index];
if (att == NULL)
- elog(WARN, "ExecSetTypeInfo: trying to assign through NULL");
+ elog(ABORT, "ExecSetTypeInfo: trying to assign through NULL");
/* ----------------
* assign values to the tuple descriptor, being careful not
heap_close(rd);
}
else
- elog(WARN, "setVarAttrLenForCreateTable: can't get length for variable-length field");
+ elog(ABORT, "setVarAttrLenForCreateTable: can't get length for variable-length field");
}
tl = lnext(tl);
}
ObjectIdGetDatum(agg->basetype),
0, 0);
if (!HeapTupleIsValid(aggTuple))
- elog(WARN, "ExecAgg: cache lookup failed for aggregate \"%s\"(%s)",
+ elog(ABORT, "ExecAgg: cache lookup failed for aggregate \"%s\"(%s)",
aggname,
typeidTypeName(agg->basetype));
aggp = (Form_pg_aggregate) GETSTRUCT(aggTuple);
* ------------------------------------------
*/
if (isNull2)
- elog(WARN, "ExecAgg: agginitval2 is null");
+ elog(ABORT, "ExecAgg: agginitval2 is null");
}
if (OidIsValid(xfn1_oid))
&isNull, &isDone);
break;
default:
- elog(WARN, "ExecAgg: Bad Agg->Target for Agg %d", i);
+ elog(ABORT, "ExecAgg: Bad Agg->Target for Agg %d", i);
}
if (isNull && !aggregates[i]->usenulls)
break;
default:
- elog(WARN, "ExecAgg: Bad Agg->Target for Agg %d", i);
+ elog(ABORT, "ExecAgg: Bad Agg->Target for Agg %d", i);
}
if (attlen == -1)
{
args[0] = (char *) value2[i];
}
else
- elog(WARN, "ExecAgg: no valid transition functions??");
+ elog(ABORT, "ExecAgg: no valid transition functions??");
value1[i] =
(Datum) fmgr_c(aggfns->finalfn, aggfns->finalfn_oid,
aggfns->finalfn_nargs, (FmgrValues *) args,
value1[i] = value2[i];
}
else
- elog(WARN, "ExecAgg: no valid transition functions??");
+ elog(ABORT, "ExecAgg: no valid transition functions??");
}
/*
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/nodeHash.c,v 1.13 1997/09/08 21:43:11 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/nodeHash.c,v 1.14 1998/01/05 03:31:16 momjian Exp $
*
*-------------------------------------------------------------------------
*/
hashtable = node->hashtable;
if (hashtable == NULL)
- elog(WARN, "ExecHash: hash table is NULL.");
+ elog(ABORT, "ExecHash: hash table is NULL.");
nbatch = hashtable->nbatch;
if (hashtable == NULL)
{
- elog(WARN, "not enough memory for hashjoin.");
+ elog(ABORT, "not enough memory for hashjoin.");
}
/* ----------------
* initialize the hash table header
if (hashtable == NULL)
{
perror("repalloc");
- elog(WARN, "can't expand hashtable.");
+ elog(ABORT, "can't expand hashtable.");
}
#else
/* ------------------
* - Chris Dunlop, <chris@onthe.net.au>
* ------------------
*/
- elog(WARN, "hash table out of memory. Use -B parameter to increase buffers.");
+ elog(ABORT, "hash table out of memory. Use -B parameter to increase buffers.");
#endif
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/nodeIndexscan.c,v 1.11 1997/11/20 23:21:28 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/nodeIndexscan.c,v 1.12 1998/01/05 03:31:18 momjian Exp $
*
*-------------------------------------------------------------------------
*/
op = (Oper *) clause->oper;
if (!IsA(op, Oper))
- elog(WARN, "ExecInitIndexScan: op not an Oper!");
+ elog(ABORT, "ExecInitIndexScan: op not an Oper!");
opid = op->opid;
* ----------------
*/
if (scanvar == LEFT_OP)
- elog(WARN, "ExecInitIndexScan: %s",
+ elog(ABORT, "ExecInitIndexScan: %s",
"both left and right op's are rel-vars");
/* ----------------
* ----------------
*/
if (scanvar == LEFT_OP)
- elog(WARN, "ExecInitIndexScan: %s",
+ elog(ABORT, "ExecInitIndexScan: %s",
"both left and right ops are rel-vars");
varattno = 1;
* ----------------
*/
if (scanvar == NO_OP)
- elog(WARN, "ExecInitIndexScan: %s",
+ elog(ABORT, "ExecInitIndexScan: %s",
"neither leftop nor rightop refer to scan relation");
/* ----------------
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/nodeSort.c,v 1.10 1997/09/15 14:27:37 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/nodeSort.c,v 1.11 1998/01/05 03:31:20 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* ----------------
*/
if (keycount <= 0)
- elog(WARN, "FormSortKeys: keycount <= 0");
+ elog(ABORT, "FormSortKeys: keycount <= 0");
sortkeys = (ScanKey) palloc(keycount * sizeof(ScanKeyData));
/* ----------------
* ExecEndTee
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/Attic/nodeTee.c,v 1.13 1997/11/28 17:27:31 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/Attic/nodeTee.c,v 1.14 1998/01/05 03:31:21 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
else
{
- elog(WARN, "A Tee node can only be executed from its left or right parent\n");
+ elog(ABORT, "A Tee node can only be executed from its left or right parent\n");
return NULL;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/lib/stringinfo.c,v 1.5 1997/09/08 02:23:05 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/lib/stringinfo.c,v 1.6 1998/01/05 03:31:24 momjian Exp $
*
*-------------------------------------------------------------------------
*/
res = (StringInfo) palloc(sizeof(StringInfoData));
if (res == NULL)
{
- elog(WARN, "makeStringInfo: Out of memory!");
+ elog(ABORT, "makeStringInfo: Out of memory!");
}
size = 100;
res->data = palloc(size);
if (res->data == NULL)
{
- elog(WARN,
+ elog(ABORT,
"makeStringInfo: Out of memory! (%ld bytes requested)", size);
}
res->maxlen = size;
s = palloc(newlen);
if (s == NULL)
{
- elog(WARN,
+ elog(ABORT,
"appendStringInfo: Out of memory (%d bytes requested)",
newlen);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/libpq/be-fsstubs.c,v 1.17 1997/12/08 04:42:45 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/libpq/be-fsstubs.c,v 1.18 1998/01/05 03:31:26 momjian Exp $
*
* NOTES
* This should be moved to a more appropriate place. It is here
if (fd >= MAX_LOBJ_FDS)
{
- elog(WARN, "lo_close: large obj descriptor (%d) out of range", fd);
+ elog(ABORT, "lo_close: large obj descriptor (%d) out of range", fd);
return -2;
}
if (cookies[fd] == NULL)
{
- elog(WARN, "lo_close: invalid large obj descriptor (%d)", fd);
+ elog(ABORT, "lo_close: invalid large obj descriptor (%d)", fd);
return -3;
}
#if FSDB
if (fd >= MAX_LOBJ_FDS)
{
- elog(WARN, "lo_seek: large obj descriptor (%d) out of range", fd);
+ elog(ABORT, "lo_seek: large obj descriptor (%d) out of range", fd);
return -2;
}
{
if (fd >= MAX_LOBJ_FDS)
{
- elog(WARN, "lo_tell: large object descriptor (%d) out of range", fd);
+ elog(ABORT, "lo_tell: large object descriptor (%d) out of range", fd);
return -2;
}
if (cookies[fd] == NULL)
{
- elog(WARN, "lo_tell: invalid large object descriptor (%d)", fd);
+ elog(ABORT, "lo_tell: invalid large object descriptor (%d)", fd);
return -3;
}
return inv_tell(cookies[fd]);
fd = open(fnamebuf, O_RDONLY, 0666);
if (fd < 0)
{ /* error */
- elog(WARN, "be_lo_import: can't open unix file\"%s\"\n",
+ elog(ABORT, "be_lo_import: can't open unix file\"%s\"\n",
fnamebuf);
}
lobj = inv_create(INV_READ | INV_WRITE);
if (lobj == NULL)
{
- elog(WARN, "lo_import: can't create inv object for \"%s\"",
+ elog(ABORT, "lo_import: can't create inv object for \"%s\"",
fnamebuf);
}
tmp = inv_write(lobj, buf, nbytes);
if (tmp < nbytes)
{
- elog(WARN, "lo_import: error while reading \"%s\"",
+ elog(ABORT, "lo_import: error while reading \"%s\"",
fnamebuf);
}
}
lobj = inv_open(lobjId, INV_READ);
if (lobj == NULL)
{
- elog(WARN, "lo_export: can't open inv object %d",
+ elog(ABORT, "lo_export: can't open inv object %d",
lobjId);
}
umask(oumask);
if (fd < 0)
{ /* error */
- elog(WARN, "lo_export: can't open unix file\"%s\"",
+ elog(ABORT, "lo_export: can't open unix file\"%s\"",
fnamebuf);
}
tmp = write(fd, buf, nbytes);
if (tmp < nbytes)
{
- elog(WARN, "lo_export: error while writing \"%s\"",
+ elog(ABORT, "lo_export: error while writing \"%s\"",
fnamebuf);
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/libpq/Attic/be-pqexec.c,v 1.11 1997/12/12 16:26:14 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/libpq/Attic/be-pqexec.c,v 1.12 1998/01/05 03:31:28 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
else if (args[i].len > sizeof(int4))
{
- elog(WARN, "arg_length of argument %d too long", i);
+ elog(ABORT, "arg_length of argument %d too long", i);
}
else
{
* If a query is does not return tuples, return "C query-command".
* If there is an error: return "E error-message".
*
- * Note: if we get a serious error or an elog(WARN), then PQexec never
+ * Note: if we get a serious error or an elog(ABORT), then PQexec never
* returns because the system longjmp's back to the main loop.
* ----------------
*/
case 'P':
a = PQparray(&res[1]);
if (a == NULL)
- elog(WARN, "pqtest_PQexec: PQparray could not find portal %s",
+ elog(ABORT, "pqtest_PQexec: PQparray could not find portal %s",
res);
t = PQntuples(a);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/libpq/pqcomm.c,v 1.31 1997/12/16 15:58:14 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/libpq/pqcomm.c,v 1.32 1998/01/05 03:31:30 momjian Exp $
*
*-------------------------------------------------------------------------
*/
(struct sockaddr *) & port->raddr,
&addrlen)) < 0)
{
- elog(WARN, "postmaster: StreamConnection: accept: %m");
+ elog(ABORT, "postmaster: StreamConnection: accept: %m");
return (STATUS_ERROR);
}
if (getsockname(port->sock, (struct sockaddr *) & port->laddr,
&addrlen) < 0)
{
- elog(WARN, "postmaster: StreamConnection: getsockname: %m");
+ elog(ABORT, "postmaster: StreamConnection: getsockname: %m");
return (STATUS_ERROR);
}
if (family == AF_INET)
pe = getprotobyname("TCP");
if (pe == NULL)
{
- elog(WARN, "postmaster: getprotobyname failed");
+ elog(ABORT, "postmaster: getprotobyname failed");
return (STATUS_ERROR);
}
if (setsockopt(port->sock, pe->p_proto, TCP_NODELAY,
&on, sizeof(on)) < 0)
{
- elog(WARN, "postmaster: setsockopt failed");
+ elog(ABORT, "postmaster: setsockopt failed");
return (STATUS_ERROR);
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.10 1997/09/08 21:44:02 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.11 1998/01/05 03:31:34 momjian Exp $
*
*-------------------------------------------------------------------------
*/
return (true);
break;
default:
- elog(WARN, "_equalParam: Invalid paramkind value: %d",
+ elog(ABORT, "_equalParam: Invalid paramkind value: %d",
a->paramkind);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/nodes/list.c,v 1.8 1997/12/19 16:54:15 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/nodes/list.c,v 1.9 1998/01/05 03:31:38 momjian Exp $
*
* NOTES
* XXX a few of the following functions are duplicated to handle
if (l2 == NIL)
return l1;
if (l1 == l2)
- elog(WARN, "tryout to nconc a list to itself");
+ elog(ABORT, "tryout to nconc a list to itself");
for (temp = l1; lnext(temp) != NULL; temp = lnext(temp))
;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/nodes/read.c,v 1.5 1997/09/08 02:23:43 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/nodes/read.c,v 1.6 1998/01/05 03:31:40 momjian Exp $
*
* HISTORY
* AUTHOR DATE MAJOR EVENT
make_dotted_pair_cell = true;
break;
default:
- elog(WARN, "nodeRead: Bad type %d", type);
+ elog(ABORT, "nodeRead: Bad type %d", type);
break;
}
if (make_dotted_pair_cell)
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.12 1997/12/27 06:40:59 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.13 1998/01/05 03:31:45 momjian Exp $
*
* NOTES
* Most of the read functions for plan nodes are tested. (In fact, they
}
else
{
- elog(WARN, "badly formatted planstring \"%.10s\"...\n", token);
+ elog(ABORT, "badly formatted planstring \"%.10s\"...\n", token);
}
return ((Node *) return_value);
{
if (length > sizeof(Datum))
{
- elog(WARN, "readValue: byval & length = %d", length);
+ elog(ABORT, "readValue: byval & length = %d", length);
}
s = (char *) (&res);
for (i = 0; i < sizeof(Datum); i++)
token = lsptok(NULL, &tokenLength); /* skip the ']' */
if (token[0] != ']')
{
- elog(WARN, "readValue: ']' expected, length =%d", length);
+ elog(ABORT, "readValue: ']' expected, length =%d", length);
}
return (res);
* geqo_erx.c--
* edge recombination crossover [ER]
*
-* $Id: geqo_erx.c,v 1.5 1997/09/08 21:44:16 momjian Exp $
+* $Id: geqo_erx.c,v 1.6 1998/01/05 03:31:48 momjian Exp $
*
*-------------------------------------------------------------------------
*/
minimum_count = 1;
}
else if (minimum_count == -1)
- elog(WARN, "gimme_gene: Internal error - minimum_count not set");
+ elog(ABORT, "gimme_gene: Internal error - minimum_count not set");
else if (edge_table[(int) friend].unused_edges == minimum_edges)
minimum_count++;
}
/* ... should never be reached */
- elog(WARN, "gimme_gene: neither shared nor minimum number nor random edge found");
+ elog(ABORT, "gimme_gene: neither shared nor minimum number nor random edge found");
return 0; /* to keep the compiler quiet */
}
/* ... should never be reached */
- elog(WARN, "edge_failure: no edge detected");
+ elog(ABORT, "edge_failure: no edge detected");
return 0; /* to keep the compiler quiet */
}
*
* Copyright (c) 1994, Regents of the University of California
*
- * $Id: geqo_eval.c,v 1.15 1997/09/08 21:44:19 momjian Exp $
+ * $Id: geqo_eval.c,v 1.16 1998/01/05 03:31:49 momjian Exp $
*
*-------------------------------------------------------------------------
*/
return lfirst(r);
i++;
}
- elog(WARN, "geqo_nth: Internal error - ran off end of list");
+ elog(ABORT, "geqo_nth: Internal error - ran off end of list");
return NULL; /* to keep compiler happy */
}
*
* Copyright (c) 1994, Regents of the University of California
*
- * $Id: geqo_misc.c,v 1.5 1997/09/08 21:44:26 momjian Exp $
+ * $Id: geqo_misc.c,v 1.6 1998/01/05 03:31:51 momjian Exp $
*
*-------------------------------------------------------------------------
*/
double cumulative = 0.0;
if (pool->size == 0)
- elog(WARN, "avg_pool: pool_size of zero");
+ elog(ABORT, "avg_pool: pool_size of zero");
for (i = 0; i < pool->size; i++)
cumulative = cumulative + pool->data[i].worth;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/predmig.c,v 1.6 1997/09/08 21:45:07 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/predmig.c,v 1.7 1998/01/05 03:31:54 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/* sanity check */
if ((!streamroot && laststream) ||
(streamroot && !laststream))
- elog(WARN, "called xfunc_predmig with bad inputs");
+ elog(ABORT, "called xfunc_predmig with bad inputs");
if (streamroot)
Assert(xfunc_check_stream(streamroot));
orignode = (Stream) get_downstream(orignode))
/* empty body in for loop */ ;
if (!orignode)
- elog(WARN, "Didn't find matching node in original stream");
+ elog(ABORT, "Didn't find matching node in original stream");
/* pull up this node as far as it should go */
{
if ((Stream) get_upstream((Stream) get_downstream(temp)) != temp)
{
- elog(WARN, "bad pointers in stream");
+ elog(ABORT, "bad pointers in stream");
return (false);
}
if (!is_clause(temp))
{
if ((tmp = xfunc_num_relids(temp)) >= numrelids)
{
- elog(WARN, "Joins got reordered!");
+ elog(ABORT, "Joins got reordered!");
return (false);
}
numrelids = tmp;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/prune.c,v 1.8 1997/12/23 03:27:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/prune.c,v 1.9 1998/01/05 03:31:55 momjian Exp $
*
*-------------------------------------------------------------------------
*/
rel->size = compute_joinrel_size(cheapest);
}
else
- elog(WARN, "non JoinPath called");
+ elog(ABORT, "non JoinPath called");
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/xfunc.c,v 1.9 1997/12/22 05:41:59 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/xfunc.c,v 1.10 1998/01/05 03:31:56 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
else
{
- elog(WARN, "Clause node of undetermined type");
+ elog(ABORT, "Clause node of undetermined type");
return (-1);
}
}
{
/* don't trust the opid in the Oper node. Use the opno. */
if (!(funcid = get_opcode(get_opno((Oper) node))))
- elog(WARN, "Oper's function is undefined");
+ elog(ABORT, "Oper's function is undefined");
}
else
{
/* look up tuple in cache */
tupl = SearchSysCacheTuple(PROOID, ObjectIdGetDatum(funcid), 0, 0, 0);
if (!HeapTupleIsValid(tupl))
- elog(WARN, "Cache lookup failed for procedure %d", funcid);
+ elog(ABORT, "Cache lookup failed for procedure %d", funcid);
proc = (Form_pg_proc) GETSTRUCT(tupl);
/*
PointerGetDatum(get_vartype((Var) clause)),
0, 0, 0);
if (!HeapTupleIsValid(tupl))
- elog(WARN, "Cache lookup failed for type %d",
+ elog(ABORT, "Cache lookup failed for type %d",
get_vartype((Var) clause));
type = (TypeTupleForm) GETSTRUCT(tupl);
if (get_varattno((Var) clause) == 0)
ObjectIdGetDatum(get_opno((Oper) get_op(clause))),
0, 0, 0);
if (!HeapTupleIsValid(tupl))
- elog(WARN, "Cache lookup failed for procedure %d",
+ elog(ABORT, "Cache lookup failed for procedure %d",
get_opno((Oper) get_op(clause)));
return (xfunc_func_width
((RegProcedure) (((OperatorTupleForm) (GETSTRUCT(tupl)))->oprcode),
}
else
{
- elog(WARN, "Clause node of undetermined type");
+ elog(ABORT, "Clause node of undetermined type");
return (-1);
}
}
else
{
- elog(WARN, "Clause node of undetermined type");
+ elog(ABORT, "Clause node of undetermined type");
return ((List) LispNil);
}
}
xfunc_fixvars(lfirst(tmpclause), rel, varno);
else
{
- elog(WARN, "Clause node of undetermined type");
+ elog(ABORT, "Clause node of undetermined type");
}
}
Assert(RegProcedureIsValid(funcid));
tupl = SearchSysCacheTuple(PROOID, ObjectIdGetDatum(funcid), 0, 0, 0);
if (!HeapTupleIsValid(tupl))
- elog(WARN, "Cache lookup failed for procedure %d", funcid);
+ elog(ABORT, "Cache lookup failed for procedure %d", funcid);
proc = (Form_pg_proc) GETSTRUCT(tupl);
/* if function returns a tuple, get the width of that */
ObjectIdGetDatum(proc->prorettype),
0, 0, 0);
if (!HeapTupleIsValid(tupl))
- elog(WARN, "Cache lookup failed for type %d", proc->prorettype);
+ elog(ABORT, "Cache lookup failed for type %d", proc->prorettype);
type = (TypeTupleForm) GETSTRUCT(tupl);
/* if the type length is known, return that */
if (type->typlen != -1)
sanity = true; /* found a matching item to remove! */
if (!sanity)
- elog(WARN, "xfunc_LispRemove: didn't find a match!");
+ elog(ABORT, "xfunc_LispRemove: didn't find a match!");
return (result);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/createplan.c,v 1.20 1997/12/18 12:54:04 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/createplan.c,v 1.21 1998/01/05 03:31:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
break;
default:
- elog(WARN, "create_scan_node: unknown node type",
+ elog(ABORT, "create_scan_node: unknown node type",
best_path->pathtype);
break;
}
break;
default:
/* do nothing */
- elog(WARN, "create_join_node: unknown node type",
+ elog(ABORT, "create_join_node: unknown node type",
best_path->path.pathtype);
}
temp = best_path->parent->relids;
if (temp == NULL)
- elog(WARN, "scanrelid is empty");
+ elog(ABORT, "scanrelid is empty");
else
scan_relid = (Index) lfirsti(temp); /* ??? who takes care of
* lnext? - ay */
ObjectIdGetDatum(lfirsti(ixid)),
0, 0, 0);
if (!HeapTupleIsValid(indexTuple))
- elog(WARN, "create_plan: index %d not found",
+ elog(ABORT, "create_plan: index %d not found",
lfirsti(ixid));
index = (IndexTupleForm) GETSTRUCT(indexTuple);
if (index->indislossy)
break;
default:
- elog(WARN, "make_temp: unknown temp type %d", temptype);
+ elog(ABORT, "make_temp: unknown temp type %d", temptype);
}
return (retval);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planmain.c,v 1.13 1997/12/22 05:42:04 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planmain.c,v 1.14 1998/01/05 03:32:03 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (length(glc) != 0)
{
- elog(WARN, "group attribute disappeared from target list");
+ elog(ABORT, "group attribute disappeared from target list");
}
/*
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.18 1997/12/29 01:12:45 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.19 1998/01/05 03:32:04 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (rettype == InvalidOid)
return;
else
- elog(WARN, "return type mismatch in function decl: final query is a catalog utility");
+ elog(ABORT, "return type mismatch in function decl: final query is a catalog utility");
}
/* okay, it's an ordinary query */
if (rettype == InvalidOid)
{
if (cmd == CMD_SELECT)
- elog(WARN,
+ elog(ABORT,
"function declared with no return type, but final query is a retrieve");
else
return;
/* by here, the function is declared to return some type */
if ((typ = typeidType(rettype)) == NULL)
- elog(WARN, "can't find return type %d for function\n", rettype);
+ elog(ABORT, "can't find return type %d for function\n", rettype);
/*
* test 3: if the function is declared to return a value, then the
* final query had better be a retrieve.
*/
if (cmd != CMD_SELECT)
- elog(WARN, "function declared to return type %s, but final query is not a retrieve", typeTypeName(typ));
+ elog(ABORT, "function declared to return type %s, but final query is not a retrieve", typeTypeName(typ));
/*
* test 4: for base type returns, the target list should have exactly
if (typeTypeRelid(typ) == InvalidOid)
{
if (exec_tlist_length(tlist) > 1)
- elog(WARN, "function declared to return %s returns multiple values in final retrieve", typeTypeName(typ));
+ elog(ABORT, "function declared to return %s returns multiple values in final retrieve", typeTypeName(typ));
resnode = (Resdom *) ((TargetEntry *) lfirst(tlist))->resdom;
if (resnode->restype != rettype)
- elog(WARN, "return type mismatch in function: declared to return %s, returns %s", typeTypeName(typ), typeidTypeName(resnode->restype));
+ elog(ABORT, "return type mismatch in function: declared to return %s, returns %s", typeTypeName(typ), typeidTypeName(resnode->restype));
/* by here, base return types match */
return;
reln = heap_open(typeTypeRelid(typ));
if (!RelationIsValid(reln))
- elog(WARN, "cannot open relation relid %d", typeTypeRelid(typ));
+ elog(ABORT, "cannot open relation relid %d", typeTypeRelid(typ));
relid = reln->rd_id;
relnatts = reln->rd_rel->relnatts;
if (exec_tlist_length(tlist) != relnatts)
- elog(WARN, "function declared to return type %s does not retrieve (%s.*)", typeTypeName(typ), typeTypeName(typ));
+ elog(ABORT, "function declared to return type %s does not retrieve (%s.*)", typeTypeName(typ), typeTypeName(typ));
/* expect attributes 1 .. n in order */
for (i = 1; i <= relnatts; i++)
else if (IsA(thenode, Func))
tletype = (Oid) get_functype((Func *) thenode);
else
- elog(WARN, "function declared to return type %s does not retrieve (%s.all)", typeTypeName(typ), typeTypeName(typ));
+ elog(ABORT, "function declared to return type %s does not retrieve (%s.all)", typeTypeName(typ), typeTypeName(typ));
}
else
- elog(WARN, "function declared to return type %s does not retrieve (%s.all)", typeTypeName(typ), typeTypeName(typ));
+ elog(ABORT, "function declared to return type %s does not retrieve (%s.all)", typeTypeName(typ), typeTypeName(typ));
#endif
/* reach right in there, why don't you? */
if (tletype != reln->rd_att->attrs[i - 1]->atttypid)
- elog(WARN, "function declared to return type %s does not retrieve (%s.all)", typeTypeName(typ), typeTypeName(typ));
+ elog(ABORT, "function declared to return type %s does not retrieve (%s.all)", typeTypeName(typ), typeTypeName(typ));
}
heap_close(reln);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/setrefs.c,v 1.10 1997/12/22 05:42:10 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/plan/setrefs.c,v 1.11 1998/01/05 03:32:05 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
else
{
- elog(WARN, "calling set_temp_tlist_references with empty lefttree");
+ elog(ABORT, "calling set_temp_tlist_references with empty lefttree");
}
}
/*
* Ooops! we can not handle that!
*/
- elog(WARN, "replace_result_clause: Can not handle this tlist!\n");
+ elog(ABORT, "replace_result_clause: Can not handle this tlist!\n");
}
}
/*
* Ooops! we can not handle that!
*/
- elog(WARN, "replace_agg_clause: Can not handle this tlist!\n");
+ elog(ABORT, "replace_agg_clause: Can not handle this tlist!\n");
}
}
/*
* Ooops! we can not handle that!
*/
- elog(WARN, "del_agg_clause: Can not handle this tlist!\n");
+ elog(ABORT, "del_agg_clause: Can not handle this tlist!\n");
}
return NULL;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/optimizer/util/plancat.c,v 1.11 1997/11/20 23:22:01 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/optimizer/util/plancat.c,v 1.12 1998/01/05 03:32:09 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
else
{
- elog(WARN, "RelationCatalogInformation: Relation %d not found",
+ elog(ABORT, "RelationCatalogInformation: Relation %d not found",
relationObjectId);
}
1, &indexKey);
}
if (!HeapScanIsValid(scan))
- elog(WARN, "index_info: scan not started");
+ elog(ABORT, "index_info: scan not started");
indexTuple = heap_getnext(scan, 0, (Buffer *) NULL);
if (!HeapTupleIsValid(indexTuple))
{
UInt16GetDatum(amstrategy),
0);
if (!HeapTupleIsValid(amopTuple))
- elog(WARN, "index_info: no amop %d %d %d",
+ elog(ABORT, "index_info: no amop %d %d %d",
relam, index->indclass[i], amstrategy);
info->orderOprs[i] =
((Form_pg_amop) GETSTRUCT(amopTuple))->amopopr;
(char *) constFlag,
NULL);
if (!PointerIsValid(result))
- elog(WARN, "RestrictionClauseSelectivity: bad pointer");
+ elog(ABORT, "RestrictionClauseSelectivity: bad pointer");
if (*result < 0.0 || *result > 1.0)
- elog(WARN, "RestrictionClauseSelectivity: bad value %lf",
+ elog(ABORT, "RestrictionClauseSelectivity: bad value %lf",
*result);
return ((Cost) *result);
(char *) (int) attributeNumber2,
NULL);
if (!PointerIsValid(result))
- elog(WARN, "JoinClauseSelectivity: bad pointer");
+ elog(ABORT, "JoinClauseSelectivity: bad pointer");
if (*result < 0.0 || *result > 1.0)
- elog(WARN, "JoinClauseSelectivity: bad value %lf",
+ elog(ABORT, "JoinClauseSelectivity: bad value %lf",
*result);
return ((Cost) *result);
ObjectIdGetDatum(indexrelid),
0, 0, 0);
if (!HeapTupleIsValid(indRel))
- elog(WARN, "IndexSelectivity: index %d not found",
+ elog(ABORT, "IndexSelectivity: index %d not found",
indexrelid);
relam = ((Form_pg_class) GETSTRUCT(indRel))->relam;
ObjectIdGetDatum(indexrelid),
0, 0, 0);
if (!HeapTupleIsValid(indexTuple))
- elog(WARN, "IndexSelectivity: index %d not found",
+ elog(ABORT, "IndexSelectivity: index %d not found",
indexrelid);
index = (IndexTupleForm) GETSTRUCT(indexTuple);
ObjectIdGetDatum(relam),
0);
if (!HeapTupleIsValid(amopTuple))
- elog(WARN, "IndexSelectivity: no amop %d %d",
+ elog(ABORT, "IndexSelectivity: no amop %d %d",
indclass, operatorObjectIds[n]);
amop = (Form_pg_amop) GETSTRUCT(amopTuple);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.60 1997/12/29 05:13:35 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.61 1998/01/05 03:32:12 momjian Exp $
*
*-------------------------------------------------------------------------
*/
printf("transformCreateStmt- found NOT NULL constraint on column %s\n",column->colname);
#endif
if (column->is_not_null)
- elog(WARN,"CREATE TABLE/NOT NULL already specified"
+ elog(ERROR,"CREATE TABLE/NOT NULL already specified"
" for %s.%s", stmt->relname, column->colname);
column->is_not_null = TRUE;
break;
printf("transformCreateStmt- found DEFAULT clause on column %s\n",column->colname);
#endif
if (column->defval != NULL)
- elog(WARN,"CREATE TABLE/DEFAULT multiple values specified"
+ elog(ERROR,"CREATE TABLE/DEFAULT multiple values specified"
" for %s.%s", stmt->relname, column->colname);
column->defval = constraint->def;
break;
break;
default:
- elog(WARN,"parser: internal error; unrecognized constraint",NULL);
+ elog(ERROR,"parser: internal error; unrecognized constraint",NULL);
break;
}
clist = lnext(clist);
case CONSTR_NOTNULL:
case CONSTR_DEFAULT:
- elog(WARN,"parser: internal error; illegal context for constraint",NULL);
+ elog(ERROR,"parser: internal error; illegal context for constraint",NULL);
break;
default:
- elog(WARN,"parser: internal error; unrecognized constraint",NULL);
+ elog(ERROR,"parser: internal error; unrecognized constraint",NULL);
break;
}
break;
default:
- elog(WARN,"parser: internal error; unrecognized node",NULL);
+ elog(ERROR,"parser: internal error; unrecognized node",NULL);
}
elements = lnext(elements);
{
constraint = lfirst(dlist);
if (nodeTag(constraint) != T_Constraint)
- elog(WARN,"parser: internal error; unrecognized deferred node",NULL);
+ elog(ERROR,"parser: internal error; unrecognized deferred node",NULL);
#if PARSEDEBUG
printf("transformCreateStmt- found deferred constraint %s\n",
if (constraint->contype == CONSTR_PRIMARY)
if (have_pkey)
- elog(WARN,"CREATE TABLE/PRIMARY KEY multiple primary keys"
+ elog(ERROR,"CREATE TABLE/PRIMARY KEY multiple primary keys"
" for table %s are not legal", stmt->relname);
else
have_pkey = TRUE;
else if (constraint->contype != CONSTR_UNIQUE)
- elog(WARN,"parser: internal error; unrecognized deferred constraint",NULL);
+ elog(ERROR,"parser: internal error; unrecognized deferred constraint",NULL);
#if PARSEDEBUG
printf("transformCreateStmt- found deferred %s clause\n",
else if (constraint->contype == CONSTR_PRIMARY)
{
if (have_pkey)
- elog(WARN,"CREATE TABLE/PRIMARY KEY multiple keys for table %s are not legal", stmt->relname);
+ elog(ERROR,"CREATE TABLE/PRIMARY KEY multiple keys for table %s are not legal", stmt->relname);
have_pkey = TRUE;
index->idxname = makeTableName(stmt->relname, "pkey", NULL);
columns = lnext(columns);
}
if (column == NULL)
- elog(WARN,"parser: column '%s' in key does not exist",key->name);
+ elog(ERROR,"parser: column '%s' in key does not exist",key->name);
if (constraint->contype == CONSTR_PRIMARY)
{
}
if (index->idxname == NULL)
- elog(WARN,"parser: unable to construct implicit index for table %s"
+ elog(ERROR,"parser: unable to construct implicit index for table %s"
"; name too long", stmt->relname);
else
elog(NOTICE,"CREATE TABLE/%s will create implicit index %s for table %s",
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 1.83 1998/01/04 04:31:08 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 1.84 1998/01/05 03:32:18 momjian Exp $
*
* HISTORY
* AUTHOR DATE MAJOR EVENT
Node *lp = lfirst($3);
if (length($3) != 1)
- elog(WARN,"ALTER TABLE/ADD() allows one column only",NULL);
+ elog(ABORT,"ALTER TABLE/ADD() allows one column only",NULL);
$$ = lp;
}
| DROP opt_column ColId
- { elog(WARN,"ALTER TABLE/DROP COLUMN not yet implemented",NULL); }
+ { elog(ABORT,"ALTER TABLE/DROP COLUMN not yet implemented",NULL); }
| ALTER opt_column ColId SET DEFAULT default_expr
- { elog(WARN,"ALTER TABLE/ALTER COLUMN/SET DEFAULT not yet implemented",NULL); }
+ { elog(ABORT,"ALTER TABLE/ALTER COLUMN/SET DEFAULT not yet implemented",NULL); }
| ALTER opt_column ColId DROP DEFAULT
- { elog(WARN,"ALTER TABLE/ALTER COLUMN/DROP DEFAULT not yet implemented",NULL); }
+ { elog(ABORT,"ALTER TABLE/ALTER COLUMN/DROP DEFAULT not yet implemented",NULL); }
| ADD ConstraintElem
- { elog(WARN,"ALTER TABLE/ADD CONSTRAINT not yet implemented",NULL); }
+ { elog(ABORT,"ALTER TABLE/ADD CONSTRAINT not yet implemented",NULL); }
;
| default_expr '*' default_expr
{ $$ = nconc( $1, lcons( makeString( "*"), $3)); }
| default_expr '=' default_expr
- { elog(WARN,"boolean expressions not supported in DEFAULT",NULL); }
+ { elog(ABORT,"boolean expressions not supported in DEFAULT",NULL); }
| default_expr '<' default_expr
- { elog(WARN,"boolean expressions not supported in DEFAULT",NULL); }
+ { elog(ABORT,"boolean expressions not supported in DEFAULT",NULL); }
| default_expr '>' default_expr
- { elog(WARN,"boolean expressions not supported in DEFAULT",NULL); }
+ { elog(ABORT,"boolean expressions not supported in DEFAULT",NULL); }
| ':' default_expr
{ $$ = lcons( makeString( ":"), $2); }
| ';' default_expr
| default_expr Op default_expr
{
if (!strcmp("<=", $2) || !strcmp(">=", $2))
- elog(WARN,"boolean expressions not supported in DEFAULT",NULL);
+ elog(ABORT,"boolean expressions not supported in DEFAULT",NULL);
$$ = nconc( $1, lcons( makeString( $2), $3));
}
| Op default_expr
TriggerForSpec: FOR name name
{
if ( strcmp ($2, "each") != 0 )
- elog(WARN,"parser: syntax error near %s",$2);
+ elog(ABORT,"parser: syntax error near %s",$2);
if ( strcmp ($3, "row") == 0 )
$$ = TRUE;
else if ( strcmp ($3, "statement") == 0 )
$$ = FALSE;
else
- elog(WARN,"parser: syntax error near %s",$3);
+ elog(ABORT,"parser: syntax error near %s",$3);
}
;
fetch_how_many: Iconst
{ $$ = $1;
- if ($1 <= 0) elog(WARN,"Please specify nonnegative count for fetch",NULL); }
+ if ($1 <= 0) elog(ABORT,"Please specify nonnegative count for fetch",NULL); }
| ALL { $$ = 0; /* 0 means fetch all tuples*/ }
| /*EMPTY*/ { $$ = 1; /*default*/ }
;
{
RecipeStmt *n;
if (!IsTransactionBlock())
- elog(WARN,"EXECUTE RECIPE may only be used in begin/end transaction blocks",NULL);
+ elog(ABORT,"EXECUTE RECIPE may only be used in begin/end transaction blocks",NULL);
n = makeNode(RecipeStmt);
n->recipeName = $3;
oper_argtypes: name
{
- elog(WARN,"parser: argument type missing (use NONE for unary operators)",NULL);
+ elog(ABORT,"parser: argument type missing (use NONE for unary operators)",NULL);
}
| name ',' name
{ $$ = makeList(makeString($1), makeString($3), -1); }
n->vacrel = $4;
n->va_spec = $5;
if ( $5 != NIL && !$4 )
- elog(WARN,"parser: syntax error at or near \"(\"",NULL);
+ elog(ABORT,"parser: syntax error at or near \"(\"",NULL);
$$ = (Node *)n;
}
;
* -- mao
*/
if (!IsTransactionBlock())
- elog(WARN,"Named portals may only be used in begin/end transaction blocks",NULL);
+ elog(ABORT,"Named portals may only be used in begin/end transaction blocks",NULL);
n->portalname = $2;
n->binary = $3;
from_clause: FROM '(' relation_expr join_expr JOIN relation_expr join_spec ')'
{
$$ = NIL;
- elog(WARN,"JOIN not yet implemented",NULL);
+ elog(ABORT,"JOIN not yet implemented",NULL);
}
| FROM from_list { $$ = $2; }
| /*EMPTY*/ { $$ = NIL; }
from_list: from_list ',' from_val
{ $$ = lappend($1, $3); }
| from_val CROSS JOIN from_val
- { elog(WARN,"CROSS JOIN not yet implemented",NULL); }
+ { elog(ABORT,"CROSS JOIN not yet implemented",NULL); }
| from_val
{ $$ = lcons($1, NIL); }
;
join_expr: NATURAL join_expr { $$ = NULL; }
| FULL join_outer
- { elog(WARN,"FULL OUTER JOIN not yet implemented",NULL); }
+ { elog(ABORT,"FULL OUTER JOIN not yet implemented",NULL); }
| LEFT join_outer
- { elog(WARN,"LEFT OUTER JOIN not yet implemented",NULL); }
+ { elog(ABORT,"LEFT OUTER JOIN not yet implemented",NULL); }
| RIGHT join_outer
- { elog(WARN,"RIGHT OUTER JOIN not yet implemented",NULL); }
+ { elog(ABORT,"RIGHT OUTER JOIN not yet implemented",NULL); }
| OUTER_P
- { elog(WARN,"OUTER JOIN not yet implemented",NULL); }
+ { elog(ABORT,"OUTER JOIN not yet implemented",NULL); }
| INNER_P
- { elog(WARN,"INNER JOIN not yet implemented",NULL); }
+ { elog(ABORT,"INNER JOIN not yet implemented",NULL); }
| UNION
- { elog(WARN,"UNION JOIN not yet implemented",NULL); }
+ { elog(ABORT,"UNION JOIN not yet implemented",NULL); }
| /*EMPTY*/
- { elog(WARN,"INNER JOIN not yet implemented",NULL); }
+ { elog(ABORT,"INNER JOIN not yet implemented",NULL); }
;
join_outer: OUTER_P { $$ = NULL; }
opt_float: '(' Iconst ')'
{
if ($2 < 1)
- elog(WARN,"precision for FLOAT must be at least 1",NULL);
+ elog(ABORT,"precision for FLOAT must be at least 1",NULL);
else if ($2 < 7)
$$ = xlateSqlType("float4");
else if ($2 < 16)
$$ = xlateSqlType("float8");
else
- elog(WARN,"precision for FLOAT must be less than 16",NULL);
+ elog(ABORT,"precision for FLOAT must be less than 16",NULL);
}
| /*EMPTY*/
{
opt_numeric: '(' Iconst ',' Iconst ')'
{
if ($2 != 9)
- elog(WARN,"NUMERIC precision %d must be 9",$2);
+ elog(ABORT,"NUMERIC precision %d must be 9",$2);
if ($4 != 0)
- elog(WARN,"NUMERIC scale %d must be zero",$4);
+ elog(ABORT,"NUMERIC scale %d must be zero",$4);
}
| '(' Iconst ')'
{
if ($2 != 9)
- elog(WARN,"NUMERIC precision %d must be 9",$2);
+ elog(ABORT,"NUMERIC precision %d must be 9",$2);
}
| /*EMPTY*/
{
opt_decimal: '(' Iconst ',' Iconst ')'
{
if ($2 > 9)
- elog(WARN,"DECIMAL precision %d exceeds implementation limit of 9",$2);
+ elog(ABORT,"DECIMAL precision %d exceeds implementation limit of 9",$2);
if ($4 != 0)
- elog(WARN,"DECIMAL scale %d must be zero",$4);
+ elog(ABORT,"DECIMAL scale %d must be zero",$4);
$$ = NULL;
}
| '(' Iconst ')'
{
if ($2 > 9)
- elog(WARN,"DECIMAL precision %d exceeds implementation limit of 9",$2);
+ elog(ABORT,"DECIMAL precision %d exceeds implementation limit of 9",$2);
$$ = NULL;
}
| /*EMPTY*/
else
yyerror("parse error");
if ($3 < 1)
- elog(WARN,"length for '%s' type must be at least 1",$1);
+ elog(ABORT,"length for '%s' type must be at least 1",$1);
else if ($3 > 4096)
/* we can store a char() of length up to the size
* of a page (8KB) - page headers and friends but
* just to be safe here... - ay 6/95
* XXX note this hardcoded limit - thomas 1997-07-13
*/
- elog(WARN,"length for type '%s' cannot exceed 4096",$1);
+ elog(ABORT,"length for type '%s' cannot exceed 4096",$1);
/* we actually implement this sort of like a varlen, so
* the first 4 bytes is the length. (the difference
}
};
if ($4 != NULL)
- elog(WARN,"COLLATE %s not yet implemented",$4);
+ elog(ABORT,"COLLATE %s not yet implemented",$4);
$$ = type;
}
| CHAR opt_varying { $$ = xlateSqlType($2? "varchar": "char"); }
*/
| EXISTS '(' SubSelect ')'
{
- elog(WARN,"EXISTS not yet implemented",NULL);
+ elog(ABORT,"EXISTS not yet implemented",NULL);
$$ = $3;
}
| EXTRACT '(' extract_list ')'
in_expr: SubSelect
{
- elog(WARN,"IN (SUBSELECT) not yet implemented",NULL);
+ elog(ABORT,"IN (SUBSELECT) not yet implemented",NULL);
$$ = $1;
}
| in_expr_nodes
not_in_expr: SubSelect
{
- elog(WARN,"NOT IN (SUBSELECT) not yet implemented",NULL);
+ elog(ABORT,"NOT IN (SUBSELECT) not yet implemented",NULL);
$$ = $1;
}
| not_in_expr_nodes
/* disallow refs to variable system tables */
if (strcmp(LogRelationName, $1) == 0
|| strcmp(VariableRelationName, $1) == 0)
- elog(WARN,"%s cannot be accessed by users",$1);
+ elog(ABORT,"%s cannot be accessed by users",$1);
else
$$ = $1;
StrNCpy(saved_relname, $1, NAMEDATALEN);
if (QueryIsRule)
$$ = "*CURRENT*";
else
- elog(WARN,"CURRENT used in non-rule query",NULL);
+ elog(ABORT,"CURRENT used in non-rule query",NULL);
}
| NEW
{
if (QueryIsRule)
$$ = "*NEW*";
else
- elog(WARN,"NEW used in non-rule query",NULL);
+ elog(ABORT,"NEW used in non-rule query",NULL);
}
;
Node *larg, *rarg;
if (length(largs) != length(rargs))
- elog(WARN,"Unequal number of entries in row expression",NULL);
+ elog(ABORT,"Unequal number of entries in row expression",NULL);
if (lnext(largs) != NIL)
expr = makeRowExpr(opr,lnext(largs),lnext(rargs));
}
else
{
- elog(WARN,"Operator '%s' not implemented for row expressions",opr);
+ elog(ABORT,"Operator '%s' not implemented for row expressions",opr);
}
#if FALSE
ResTarget *d;
if (length(src) != length(dst))
- elog(WARN,"CREATE TABLE/AS SELECT has mismatched column count",NULL);
+ elog(ABORT,"CREATE TABLE/AS SELECT has mismatched column count",NULL);
while ((src != NIL) && (dst != NIL))
{
{
char *defval = NULL;
if (nodeTag(n) != T_A_Const) {
- elog(WARN,"Cannot handle non-constant parameter",NULL);
+ elog(ABORT,"Cannot handle non-constant parameter",NULL);
} else if (n->val.type == T_Float) {
defval = (char*) palloc(20+1);
strcat( defval, "'");
} else {
- elog(WARN,"Internal error in makeConstantList(): cannot encode node",NULL);
+ elog(ABORT,"Internal error in makeConstantList(): cannot encode node",NULL);
};
#ifdef PARSEDEBUG
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/keywords.c,v 1.28 1997/12/16 05:04:00 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/keywords.c,v 1.29 1998/01/05 03:32:22 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (ScanKeywords[i].value == atomval)
return (ScanKeywords[i].name);
- elog(WARN, "AtomGetString called with bogus atom # : %d", atomval);
+ elog(ERROR, "AtomGetString called with bogus atom # : %d", atomval);
return (NULL);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_agg.c,v 1.5 1998/01/04 04:31:14 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_agg.c,v 1.6 1998/01/05 03:32:25 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (tle->resdom->resno == grpcl->entry->resdom->resno)
{
if (contain_agg_clause((Node *) expr))
- elog(WARN, "parser: aggregates not allowed in GROUP BY clause");
+ elog(ERROR, "parser: aggregates not allowed in GROUP BY clause");
return TRUE;
}
}
* non-group column in target list may fail.)
*/
if (contain_agg_clause(qry->qual))
- elog(WARN, "parser: aggregates not allowed in WHERE clause");
+ elog(ERROR, "parser: aggregates not allowed in WHERE clause");
/*
* the target list can only contain aggregates, group columns and
TargetEntry *tle = lfirst(tl);
if (!tleIsAggOrGroupCol(tle, qry->groupClause))
- elog(WARN,
+ elog(ERROR,
"parser: illegal use of aggregates or non-group column in target list");
}
* Need to change here when we get HAVING works. Currently
* qry->havingQual is NULL. - vadim 04/05/97
if (!exprIsAggOrGroupCol(qry->havingQual, qry->groupClause))
- elog(WARN,
+ elog(ERROR,
"parser: illegal use of aggregates or non-group column in HAVING clause");
*/
return;
0, 0);
if (!HeapTupleIsValid(theAggTuple))
{
- elog(WARN, "aggregate %s does not exist", aggname);
+ elog(ERROR, "aggregate %s does not exist", aggname);
}
/*
break;
}
if (first_valid_rte == NULL)
- elog(WARN, "Can't find column to do aggregate(*) on.");
+ elog(ERROR, "Can't find column to do aggregate(*) on.");
attr->relname = first_valid_rte->refname;
attr->attrs = lcons(makeString(
tp1 = typeidType(basetype);
tp2 = typeidType(vartype);
elog(NOTICE, "Aggregate type mismatch:");
- elog(WARN, "%s works on %s, not %s", aggname,
+ elog(ERROR, "%s works on %s, not %s", aggname,
typeTypeName(tp1), typeTypeName(tp2));
}
}
if (basetypeID == InvalidOid)
{
- elog(WARN, "%s: aggregate '%s' for all types does not exist", caller, aggname);
+ elog(ERROR, "%s: aggregate '%s' for all types does not exist", caller, aggname);
}
else
{
- elog(WARN, "%s: aggregate '%s' for '%s' does not exist", caller, aggname,
+ elog(ERROR, "%s: aggregate '%s' for '%s' does not exist", caller, aggname,
typeidTypeName(basetypeID));
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_clause.c,v 1.6 1997/12/29 04:31:31 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_clause.c,v 1.7 1998/01/05 03:32:26 momjian Exp $
*
*-------------------------------------------------------------------------
*/
pstate->p_in_where_clause = false;
if (exprType(qual) != BOOLOID)
{
- elog(WARN,
+ elog(ERROR,
"where clause must return type bool, not %s",
typeidTypeName(exprType(qual)));
}
if (real_rtable_pos == test_rtable_pos)
{
if (target_result != NULL)
- elog(WARN, "Order/Group By '%s' is ambiguous", sortgroupby->name);
+ elog(ERROR, "Order/Group By '%s' is ambiguous", sortgroupby->name);
else
target_result = target;
}
else
{
if (target_result != NULL)
- elog(WARN, "Order/Group By '%s' is ambiguous", sortgroupby->name);
+ elog(ERROR, "Order/Group By '%s' is ambiguous", sortgroupby->name);
else
target_result = target;
}
restarget = find_targetlist_entry(pstate, lfirst(grouplist), targetlist);
if (restarget == NULL)
- elog(WARN, "The field being grouped by must appear in the target list");
+ elog(ERROR, "The field being grouped by must appear in the target list");
grpcl->entry = restarget;
resdom = restarget->resdom;
restarget = find_targetlist_entry(pstate, sortby, targetlist);
if (restarget == NULL)
- elog(WARN, "The field being ordered by must appear in the target list");
+ elog(ERROR, "The field being ordered by must appear in the target list");
sortcl->resdom = resdom = restarget->resdom;
sortcl->opoid = oprid(oper(sortby->useOp,
}
if (i == NIL)
{
- elog(WARN, "The field specified in the UNIQUE ON clause is not in the targetlist");
+ elog(ERROR, "The field specified in the UNIQUE ON clause is not in the targetlist");
}
s = sortlist;
foreach(s, sortlist)
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_expr.c,v 1.5 1998/01/04 04:53:50 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_expr.c,v 1.6 1998/01/05 03:32:27 momjian Exp $
*
*-------------------------------------------------------------------------
*/
uexpr = transformExpr(pstate, ai->uidx, precedence); /* must exists */
if (exprType(uexpr) != INT4OID)
- elog(WARN, "array index expressions must be int4's");
+ elog(ERROR, "array index expressions must be int4's");
if (ai->lidx != NULL)
{
lexpr = transformExpr(pstate, ai->lidx, precedence);
if (exprType(lexpr) != INT4OID)
- elog(WARN, "array index expressions must be int4's");
+ elog(ERROR, "array index expressions must be int4's");
}
#if 0
pfree(ai->uidx);
toid = param_type(paramno);
if (!OidIsValid(toid))
{
- elog(WARN, "Parameter '$%d' is out of range", paramno);
+ elog(ERROR, "Parameter '$%d' is out of range", paramno);
}
param = makeNode(Param);
param->paramkind = PARAM_NUM;
Node *rexpr = transformExpr(pstate, a->rexpr, precedence);
if (exprType(lexpr) != BOOLOID)
- elog(WARN, "left-hand side of AND is type '%s', not bool",
+ elog(ERROR, "left-hand side of AND is type '%s', not bool",
typeidTypeName(exprType(lexpr)));
if (exprType(rexpr) != BOOLOID)
- elog(WARN, "right-hand side of AND is type '%s', not bool",
+ elog(ERROR, "right-hand side of AND is type '%s', not bool",
typeidTypeName(exprType(rexpr)));
expr->typeOid = BOOLOID;
Node *rexpr = transformExpr(pstate, a->rexpr, precedence);
if (exprType(lexpr) != BOOLOID)
- elog(WARN, "left-hand side of OR is type '%s', not bool",
+ elog(ERROR, "left-hand side of OR is type '%s', not bool",
typeidTypeName(exprType(lexpr)));
if (exprType(rexpr) != BOOLOID)
- elog(WARN, "right-hand side of OR is type '%s', not bool",
+ elog(ERROR, "right-hand side of OR is type '%s', not bool",
typeidTypeName(exprType(rexpr)));
expr->typeOid = BOOLOID;
expr->opType = OR_EXPR;
Node *rexpr = transformExpr(pstate, a->rexpr, precedence);
if (exprType(rexpr) != BOOLOID)
- elog(WARN, "argument to NOT is type '%s', not bool",
+ elog(ERROR, "argument to NOT is type '%s', not bool",
typeidTypeName(exprType(rexpr)));
expr->typeOid = BOOLOID;
expr->opType = NOT_EXPR;
}
default:
/* should not reach here */
- elog(WARN, "transformExpr: does not know how to transform node %d",
+ elog(ERROR, "transformExpr: does not know how to transform node %d",
nodeTag(expr));
break;
}
}
if (result == NULL)
- elog(WARN, "attribute '%s' not found", ident->name);
+ elog(ERROR, "attribute '%s' not found", ident->name);
return result;
}
type = UNKNOWNOID;
break;
default:
- elog(WARN, "exprType: don't know how to get type for %d node",
+ elog(ERROR, "exprType: don't know how to get type for %d node",
nodeTag(expr));
break;
}
sprintf(const_string, "%ld", expr->val.ival);
break;
default:
- elog(WARN,
+ elog(ERROR,
"parser_typecast: cannot cast this expression to type '%s'",
typename->name);
}
break;
default:
- elog(WARN, "unknown type %d", CInteger(lfirst(expr)));
+ elog(ERROR, "unknown type %d", CInteger(lfirst(expr)));
}
#endif
const_string = (char *) textout((struct varlena *) const_string);
break;
default:
- elog(WARN, "unknown type %u", exprType);
+ elog(ERROR, "unknown type %u", exprType);
}
if (!exprType)
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_func.c,v 1.4 1998/01/04 04:31:18 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_func.c,v 1.5 1998/01/05 03:32:28 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
first_arg = lfirst(fargs);
if (first_arg == NULL)
- elog(WARN, "function '%s' does not allow NULL input", funcname);
+ elog(ERROR, "function '%s' does not allow NULL input", funcname);
}
/*
heap_close(rd);
}
else
- elog(WARN,
+ elog(ERROR,
"Type '%s' is not a relation type",
typeidTypeName(toid));
argrelid = typeidTypeRelid(toid);
*/
if ((get_attnum(argrelid, funcname) == InvalidAttrNumber)
&& strcmp(funcname, "*"))
- elog(WARN, "Functions on sets are not yet supported");
+ elog(ERROR, "Functions on sets are not yet supported");
}
if (retval)
if (exprType(pair) == UNKNOWNOID &&
!IsA(pair, Const))
{
- elog(WARN, "ParseFunc: no function named '%s' that takes in an unknown type as argument #%d", funcname, nargs);
+ elog(ERROR, "ParseFunc: no function named '%s' that takes in an unknown type as argument #%d", funcname, nargs);
}
else
toid = exprType(pair);
}
if (!exists)
- elog(WARN, "no such attribute or function '%s'", funcname);
+ elog(ERROR, "no such attribute or function '%s'", funcname);
/* got it */
funcnode = makeNode(Func);
Assert(length(fargs) == 1);
seq = (Const *) lfirst(fargs);
if (!IsA((Node *) seq, Const))
- elog(WARN, "%s: only constant sequence names are acceptable", funcname);
+ elog(ERROR, "%s: only constant sequence names are acceptable", funcname);
seqname = lower ((text*)DatumGetPointer(seq->constvalue));
pfree (DatumGetPointer(seq->constvalue));
seq->constvalue = PointerGetDatum (seqname);
if ((aclcheck_result = pg_aclcheck(seqrel, GetPgUserName(),
((funcid == SeqNextValueRegProcedure) ? ACL_WR : ACL_RD)))
!= ACLCHECK_OK)
- elog(WARN, "%s.%s: %s",
+ elog(ERROR, "%s.%s: %s",
seqrel, funcname, aclcheck_error_strings[aclcheck_result]);
pfree(seqrel);
if (funcid == SeqNextValueRegProcedure && pstate->p_in_where_clause)
- elog(WARN, "nextval of a sequence in WHERE disallowed");
+ elog(ERROR, "nextval of a sequence in WHERE disallowed");
}
expr = makeNode(Expr);
0, 0, 0);
if (!HeapTupleIsValid(func_tuple))
- elog(WARN, "function %d does not exist", funcid);
+ elog(ERROR, "function %d does not exist", funcid);
funcrettype = (Oid)
((Form_pg_proc) GETSTRUCT(func_tuple))->prorettype;
{
tp = typeidType(oid_array[0]);
if (typeTypeFlag(tp) == 'c')
- elog(WARN, "no such attribute or function \"%s\"",
+ elog(ERROR, "no such attribute or function \"%s\"",
funcname);
}
func_error("func_get_detail", funcname, nargs, oid_array);
/* save the type id, rather than the relation id */
if ((rd = heap_open(qentry->sqe_relid)) == (Relation) NULL)
- elog(WARN, "relid %d does not exist", qentry->sqe_relid);
+ elog(ERROR, "relid %d does not exist", qentry->sqe_relid);
qentry->sqe_relid = typeTypeId(typenameType(RelationGetRelationName(rd)->data));
heap_close(rd);
attno = get_attnum(relid, attname);
if (attno < 0)
- elog(WARN, "cannot reference attribute '%s' of tuple params/return values for functions", attname);
+ elog(ERROR, "cannot reference attribute '%s' of tuple params/return values for functions", attname);
typeid = get_atttype(relid, attno);
resnode = makeResdom(1,
}
else
{
- elog(WARN,
+ elog(ERROR,
"Function '%s' has bad returntype %d",
funcname, argtype);
}
}
- elog(WARN, "Function '%s' has bad returntype %d",
+ elog(ERROR, "Function '%s' has bad returntype %d",
funcname, argtype);
break;
}
ptr += strlen(ptr);
}
- elog(WARN, "%s: function %s(%s) does not exist", caller, funcname, p);
+ elog(ERROR, "%s: function %s(%s) does not exist", caller, funcname, p);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_node.c,v 1.4 1997/12/29 05:13:46 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_node.c,v 1.5 1998/01/05 03:32:29 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
elog(NOTICE, "An operand to the '%s' operator returns a set of %s,",
op, typeTypeName(optype));
- elog(WARN, "but '%s' takes single values, not sets.",
+ elog(ERROR, "but '%s' takes single values, not sets.",
op);
}
}
rd = heap_open(rte->relid);
- attid = attnameAttNum(rd, attrname); /* could elog(WARN) */
+ attid = attnameAttNum(rd, attrname); /* could elog(ERROR) */
vartypeid = attnumTypeId(rd, attid);
varnode = makeVar(vnum, attid, vartypeid, vnum, attid);
0, 0, 0);
if (!HeapTupleIsValid(type_tuple))
- elog(WARN, "make_array_ref: Cache lookup failed for type %d\n",
+ elog(ERROR, "make_array_ref: Cache lookup failed for type %d\n",
typearray);
/* get the array type struct from the type tuple */
if (type_struct_array->typelem == InvalidOid)
{
- elog(WARN, "make_array_ref: type %s is not an array",
+ elog(ERROR, "make_array_ref: type %s is not an array",
(Name) &(type_struct_array->typname.data[0]));
}
ObjectIdGetDatum(type_struct_array->typelem),
0, 0, 0);
if (!HeapTupleIsValid(type_tuple))
- elog(WARN, "make_array_ref: Cache lookup failed for type %d\n",
+ elog(ERROR, "make_array_ref: Cache lookup failed for type %d\n",
typearray);
type_struct_element = (TypeTupleForm) GETSTRUCT(type_tuple);
0, 0, 0);
if (!HeapTupleIsValid(type_tuple))
- elog(WARN, "make_array_ref: Cache lookup failed for type %d\n",
+ elog(ERROR, "make_array_ref: Cache lookup failed for type %d\n",
typearray);
/* get the array type struct from the type tuple */
if (type_struct_array->typelem == InvalidOid)
{
- elog(WARN, "make_array_ref: type %s is not an array",
+ elog(ERROR, "make_array_ref: type %s is not an array",
(Name) &(type_struct_array->typname.data[0]));
}
/* get the type tuple for the element type */
0, 0, 0);
if (!HeapTupleIsValid(type_tuple))
- elog(WARN, "make_array_ref: Cache lookup failed for type %d\n",
+ elog(ERROR, "make_array_ref: Cache lookup failed for type %d\n",
typearray);
type_struct_element = (TypeTupleForm) GETSTRUCT(type_tuple);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_oper.c,v 1.4 1998/01/01 05:44:54 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_oper.c,v 1.5 1998/01/05 03:32:29 momjian Exp $
*
*-------------------------------------------------------------------------
*/
elog(NOTICE, "there is more than one operator %s for types", op);
elog(NOTICE, "%s and %s. You will have to retype this query",
typeTypeName(tp1), typeTypeName(tp2));
- elog(WARN, "using an explicit cast");
+ elog(ERROR, "using an explicit cast");
}
return (NULL);
}
ncandidates = unary_oper_get_candidates(op, arg, &candidates, 'r');
if (ncandidates == 0)
{
- elog(WARN,
+ elog(ERROR,
"Can't find right op: %s for type %d", op, arg);
return (NULL);
}
{
elog(NOTICE, "there is more than one right operator %s", op);
elog(NOTICE, "you will have to retype this query");
- elog(WARN, "using an explicit cast");
+ elog(ERROR, "using an explicit cast");
return (NULL);
}
}
ncandidates = unary_oper_get_candidates(op, arg, &candidates, 'l');
if (ncandidates == 0)
{
- elog(WARN,
+ elog(ERROR,
"Can't find left op: %s for type %d", op, arg);
return (NULL);
}
{
elog(NOTICE, "there is more than one left operator %s", op);
elog(NOTICE, "you will have to retype this query");
- elog(WARN, "using an explicit cast");
+ elog(ERROR, "using an explicit cast");
return (NULL);
}
}
}
else
{
- elog(WARN, "left hand side of operator %s has an unknown type, probably a bad attribute name", op);
+ elog(ERROR, "left hand side of operator %s has an unknown type, probably a bad attribute name", op);
}
if (typeidIsValid(arg2))
}
else
{
- elog(WARN, "right hand side of operator %s has an unknown type, probably a bad attribute name", op);
+ elog(ERROR, "right hand side of operator %s has an unknown type, probably a bad attribute name", op);
}
#if FALSE
op, typeTypeName(tp1), typeTypeName(tp2));
elog(NOTICE, "You will either have to retype this query using an");
elog(NOTICE, "explicit cast, or you will have to define the operator");
- elog(WARN, "%s for %s and %s using CREATE OPERATOR",
+ elog(ERROR, "%s for %s and %s using CREATE OPERATOR",
op, typeTypeName(tp1), typeTypeName(tp2));
#endif
- elog(WARN, "There is no operator '%s' for types '%s' and '%s'"
+ elog(ERROR, "There is no operator '%s' for types '%s' and '%s'"
"\n\tYou will either have to retype this query using an explicit cast,"
"\n\tor you will have to define the operator using CREATE OPERATOR",
op, typeTypeName(tp1), typeTypeName(tp2));
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_relation.c,v 1.4 1998/01/04 04:31:19 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_relation.c,v 1.5 1998/01/05 03:32:30 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
if (!pstate->p_is_insert ||
rte != pstate->p_target_rangetblentry)
- elog(WARN, "Column %s is ambiguous", colname);
+ elog(ERROR, "Column %s is ambiguous", colname);
}
else
rte_result = rte;
if (pstate != NULL &&
refnameRangeTableEntry(pstate->p_rtable, refname) != NULL)
- elog(WARN, "Table name %s specified more than once", refname);
+ elog(ERROR, "Table name %s specified more than once", refname);
rte->relname = pstrdup(relname);
rte->refname = pstrdup(refname);
relation = heap_openr(relname);
if (relation == NULL)
{
- elog(WARN, "%s: %s",
+ elog(ERROR, "%s: %s",
relname, aclcheck_error_strings[ACLCHECK_NO_CLASS]);
}
if (rdesc == NULL)
{
- elog(WARN, "Unable to expand all -- heap_open failed on %s",
+ elog(ERROR, "Unable to expand all -- heap_open failed on %s",
rte->refname);
return NIL;
}
return (special_attr[i].code);
/* on failure */
- elog(WARN, "Relation %s does not have attribute %s",
+ elog(ERROR, "Relation %s does not have attribute %s",
RelationGetRelationName(rd), a);
return 0; /* lint */
}
return (name);
}
}
- elog(WARN, "Illegal attr no %d for relation %s",
+ elog(ERROR, "Illegal attr no %d for relation %s",
attrno, RelationGetRelationName(rd));
}
else if (attrno >= 1 && attrno <= RelationGetNumberOfAttributes(rd))
}
else
{
- elog(WARN, "Illegal attr no %d for relation %s",
+ elog(ERROR, "Illegal attr no %d for relation %s",
attrno, RelationGetRelationName(rd));
}
pstate->p_insert_columns = lnext(pstate->p_insert_columns);
}
else
- elog(WARN, "insert: more expressions than target columns");
+ elog(ERROR, "insert: more expressions than target columns");
}
if (pstate->p_is_insert || pstate->p_is_update)
checkTargetTypes(pstate, *resname, refname, colname);
{
rte = colnameRangeTableEntry(pstate, colname);
if (rte == (RangeTblEntry *) NULL)
- elog(WARN, "attribute %s not found", colname);
+ elog(ERROR, "attribute %s not found", colname);
refname = rte->refname;
}
/*
if (pstate->p_is_insert && rte == pstate->p_target_rangetblentry)
- elog(WARN, "%s not available in this context", colname);
+ elog(ERROR, "%s not available in this context", colname);
*/
rd = heap_open(rte->relid);
attrtype_target = attnumTypeId(pstate->p_target_relation, resdomno_target);
if (attrtype_id != attrtype_target)
- elog(WARN, "Type of %s does not match target column %s",
+ elog(ERROR, "Type of %s does not match target column %s",
colname, target_colname);
if ((attrtype_id == BPCHAROID || attrtype_id == VARCHAROID) &&
rd->rd_att->attrs[resdomno_id - 1]->attlen !=
pstate->p_target_relation->rd_att->attrs[resdomno_target - 1]->attlen)
- elog(WARN, "Length of %s does not match length of target column %s",
+ elog(ERROR, "Length of %s does not match length of target column %s",
colname, target_colname);
heap_close(rd);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_target.c,v 1.4 1998/01/04 04:31:22 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_target.c,v 1.5 1998/01/05 03:32:31 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (exprType(expr) != UNKNOWNOID ||
!IsA(expr, Const))
- elog(WARN, "yyparse: string constant expected");
+ elog(ERROR, "yyparse: string constant expected");
val = (char *) textout((struct varlena *)
((Const *) expr)->constvalue);
aind->uidx = transformExpr(pstate, aind->uidx, EXPR_COLUMN_FIRST);
if (!IsA(aind->uidx, Const))
- elog(WARN,
+ elog(ERROR,
"Array Index for Append should be a constant");
uindx[i] = ((Const *) aind->uidx)->constvalue;
if (aind->lidx != NULL)
{
aind->lidx = transformExpr(pstate, aind->lidx, EXPR_COLUMN_FIRST);
if (!IsA(aind->lidx, Const))
- elog(WARN,
+ elog(ERROR,
"Array Index for Append should be a constant");
lindx[i] = ((Const *) aind->lidx)->constvalue;
}
lindx[i] = 1;
}
if (lindx[i] > uindx[i])
- elog(WARN, "yyparse: lower index cannot be greater than upper index");
+ elog(ERROR, "yyparse: lower index cannot be greater than upper index");
sprintf(str, "[%d:%d]", lindx[i], uindx[i]);
str += strlen(str);
i++;
resdomno = attnameAttNum(rd, res->name);
ndims = attnumAttNelems(rd, resdomno);
if (i != ndims)
- elog(WARN, "yyparse: array dimensions do not match");
+ elog(ERROR, "yyparse: array dimensions do not match");
constval = makeNode(Value);
constval->type = T_String;
constval->val.str = save_str;
}
default:
/* internal error */
- elog(WARN,
+ elog(ERROR,
"internal error: do not know how to transform targetlist");
break;
}
Resdom *resnode;
if (expr == NULL)
- elog(WARN, "make_targetlist_expr: invalid use of NULL expression");
+ elog(ERROR, "make_targetlist_expr: invalid use of NULL expression");
type_id = exprType(expr);
if (type_id == InvalidOid)
else if ((attrtype == FLOAT4OID) && (type_id == FLOAT8OID))
lfirst(expr) = lispInteger(FLOAT4OID);
else
- elog(WARN, "unequal type in tlist : %s \n", colname);
+ elog(ERROR, "unequal type in tlist : %s \n", colname);
}
Input_is_string = false;
else
{
/* currently, we can't handle casting of expressions */
- elog(WARN, "parser: attribute '%s' is of type '%s' but expression is of type '%s'",
+ elog(ERROR, "parser: attribute '%s' is of type '%s' but expression is of type '%s'",
colname,
typeidTypeName(attrtype),
typeidTypeName(type_id));
attnameAttNum(pstate->p_target_relation, name);
foreach(nxt, lnext(tl))
if (!strcmp(name, ((Ident *) lfirst(nxt))->name))
- elog (WARN, "Attribute '%s' should be specified only once", name);
+ elog(ERROR, "Attribute '%s' should be specified only once", name);
}
}
/* this should not happen */
if (rtable == NULL)
- elog(WARN, "cannot expand: null p_rtable");
+ elog(ERROR, "cannot expand: null p_rtable");
/*
* go through the range table and make a list of range table entries
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_type.c,v 1.2 1997/11/26 01:11:32 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_type.c,v 1.3 1998/01/05 03:32:33 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (!(tup = SearchSysCacheTuple(TYPOID, ObjectIdGetDatum(id),
0, 0, 0)))
{
- elog(WARN, "type id lookup of %ud failed", id);
+ elog(ERROR, "type id lookup of %ud failed", id);
return (NULL);
}
typetuple = (TypeTupleForm) GETSTRUCT(tup);
if (!(tup = SearchSysCacheTuple(TYPOID, ObjectIdGetDatum(id),
0, 0, 0)))
{
- elog(WARN, "type id lookup of %ud failed", id);
+ elog(ERROR, "type id lookup of %ud failed", id);
return (NULL);
}
return ((Type) tup);
if (s == NULL)
{
- elog(WARN, "type(): Null type");
+ elog(ERROR, "type(): Null type");
}
if (!(tup = SearchSysCacheTuple(TYPNAME, PointerGetDatum(s), 0, 0, 0)))
{
- elog(WARN, "type name lookup of %s failed", s);
+ elog(ERROR, "type name lookup of %s failed", s);
}
return ((Type) tup);
}
typeTypeId(Type tp)
{
if (tp == NULL)
- elog(WARN, "typeTypeId() called with NULL type struct");
+ elog(ERROR, "typeTypeId() called with NULL type struct");
return (tp->t_oid);
}
ObjectIdGetDatum(type_id),
0, 0, 0);
if (!HeapTupleIsValid(typeTuple))
- elog(WARN, "typeidRetoutfunc: Invalid type - oid = %u", type_id);
+ elog(ERROR, "typeidRetoutfunc: Invalid type - oid = %u", type_id);
type = (TypeTupleForm) GETSTRUCT(typeTuple);
outfunc = type->typoutput;
ObjectIdGetDatum(type_id),
0, 0, 0);
if (!HeapTupleIsValid(typeTuple))
- elog(WARN, "typeidTypeRelid: Invalid type - oid = %u", type_id);
+ elog(ERROR, "typeidTypeRelid: Invalid type - oid = %u", type_id);
type = (TypeTupleForm) GETSTRUCT(typeTuple);
infunc = type->typrelid;
ObjectIdGetDatum(type_id),
0, 0, 0)))
{
- elog(WARN, "type id lookup of %u failed", type_id);
+ elog(ERROR, "type id lookup of %u failed", type_id);
}
type = (TypeTupleForm) GETSTRUCT(typeTuple);
0, 0, 0);
if (!HeapTupleIsValid(type_tuple))
- elog(WARN, "GetArrayElementType: Cache lookup failed for type %d",
+ elog(ERROR, "GetArrayElementType: Cache lookup failed for type %d",
typearray);
/* get the array type struct from the type tuple */
if (type_struct_array->typelem == InvalidOid)
{
- elog(WARN, "GetArrayElementType: type %s is not an array",
+ elog(ERROR, "GetArrayElementType: type %s is not an array",
(Name) &(type_struct_array->typname.data[0]));
}
ObjectIdGetDatum(type_id),
0, 0, 0);
if (!HeapTupleIsValid(typeTuple))
- elog(WARN, "typeidRetinfunc: Invalid type - oid = %u", type_id);
+ elog(ERROR, "typeidRetinfunc: Invalid type - oid = %u", type_id);
type = (TypeTupleForm) GETSTRUCT(typeTuple);
infunc = type->typinput;
PointerGetDatum(typename),
0, 0, 0)))
{
- elog(WARN, "type name lookup of %s failed", typename);
+ elog(ERROR, "type name lookup of %s failed", typename);
}
type = (TypeTupleForm) GETSTRUCT(typeTuple);
/* A lexical scanner generated by flex */
/* Scanner skeleton version:
- * $Header: /cvsroot/pgsql/src/backend/parser/Attic/scan.c,v 1.5 1997/12/09 03:11:00 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/Attic/scan.c,v 1.6 1998/01/05 03:32:34 momjian Exp $
*/
#define FLEX_SCANNER
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/Attic/scan.c,v 1.5 1997/12/09 03:11:00 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/Attic/scan.c,v 1.6 1998/01/05 03:32:34 momjian Exp $
*
*-------------------------------------------------------------------------
*/
errno = 0;
yylval.ival = strtol((char *)literal,&endptr,2);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad binary integer input '%s'",literal);
+ elog(ABORT,"Bad binary integer input '%s'",literal);
return (ICONST);
}
YY_BREAK
#line 206 "scan.l"
{
if ((llen+yyleng) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
llen += yyleng;
}
errno = 0;
yylval.ival = strtol((char *)literal,&endptr,16);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad hexadecimal integer input '%s'",literal);
+ elog(ABORT,"Bad hexadecimal integer input '%s'",literal);
return (ICONST);
}
YY_BREAK
#line 243 "scan.l"
{
if ((llen+yyleng) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
llen += yyleng;
}
#line 249 "scan.l"
{
if ((llen+yyleng-1) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
*(literal+llen) = '\'';
llen += yyleng;
#line 257 "scan.l"
{
if ((llen+yyleng-1) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
llen += yyleng;
}
#line 277 "scan.l"
{
if ((llen+yyleng) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
llen += yyleng;
}
errno = 0;
yylval.ival = strtol((char *)yytext,&endptr,10);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad integer input '%s'",yytext);
+ elog(ABORT,"Bad integer input '%s'",yytext);
return (ICONST);
}
YY_BREAK
errno = 0;
yylval.dval = strtod(((char *)yytext),&endptr);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad float8 input '%s'",yytext);
+ elog(ABORT,"Bad float8 input '%s'",yytext);
CheckFloat8Val(yylval.dval);
return (FCONST);
}
errno = 0;
yylval.ival = strtol((char *)yytext,&endptr,10);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad integer input '%s'",yytext);
+ elog(ABORT,"Bad integer input '%s'",yytext);
return (ICONST);
}
YY_BREAK
errno = 0;
yylval.dval = strtod((char *)yytext,&endptr);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad float input '%s'",yytext);
+ elog(ABORT,"Bad float input '%s'",yytext);
CheckFloat8Val(yylval.dval);
return (FCONST);
}
void yyerror(char message[])
{
- elog(WARN, "parser: %s at or near \"%s\"", message, yytext);
+ elog(ABORT, "parser: %s at or near \"%s\"", message, yytext);
}
int yywrap()
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.32 1997/12/05 01:12:53 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.33 1998/01/05 03:32:35 momjian Exp $
*
*-------------------------------------------------------------------------
*/
errno = 0;
yylval.ival = strtol((char *)literal,&endptr,2);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad binary integer input '%s'",literal);
+ elog(ABORT,"Bad binary integer input '%s'",literal);
return (ICONST);
}
<xh>{xhinside} |
<xb>{xbinside} {
if ((llen+yyleng) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
llen += yyleng;
}
errno = 0;
yylval.ival = strtol((char *)literal,&endptr,16);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad hexadecimal integer input '%s'",literal);
+ elog(ABORT,"Bad hexadecimal integer input '%s'",literal);
return (ICONST);
}
<xq>{xqdouble} |
<xq>{xqinside} {
if ((llen+yyleng) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
llen += yyleng;
}
<xq>{xqembedded} {
if ((llen+yyleng-1) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
*(literal+llen) = '\'';
llen += yyleng;
<xq>{xqliteral} {
if ((llen+yyleng-1) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
llen += yyleng;
}
}
<xd>{xdinside} {
if ((llen+yyleng) > (MAX_PARSE_BUFFER - 1))
- elog(WARN,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
+ elog(ABORT,"quoted string parse buffer of %d chars exceeded",MAX_PARSE_BUFFER);
memcpy(literal+llen, yytext, yyleng+1);
llen += yyleng;
}
errno = 0;
yylval.ival = strtol((char *)yytext,&endptr,10);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad integer input '%s'",yytext);
+ elog(ABORT,"Bad integer input '%s'",yytext);
return (ICONST);
}
{real}/{space}*-{number} {
errno = 0;
yylval.dval = strtod(((char *)yytext),&endptr);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad float8 input '%s'",yytext);
+ elog(ABORT,"Bad float8 input '%s'",yytext);
CheckFloat8Val(yylval.dval);
return (FCONST);
}
errno = 0;
yylval.ival = strtol((char *)yytext,&endptr,10);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad integer input '%s'",yytext);
+ elog(ABORT,"Bad integer input '%s'",yytext);
return (ICONST);
}
{real} {
errno = 0;
yylval.dval = strtod((char *)yytext,&endptr);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN,"Bad float input '%s'",yytext);
+ elog(ABORT,"Bad float input '%s'",yytext);
CheckFloat8Val(yylval.dval);
return (FCONST);
}
void yyerror(char message[])
{
- elog(WARN, "parser: %s at or near \"%s\"", message, yytext);
+ elog(ABORT, "parser: %s at or near \"%s\"", message, yytext);
}
int yywrap()
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/port/dynloader/linux.c,v 1.4 1998/01/02 03:40:04 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/port/dynloader/linux.c,v 1.5 1998/01/05 03:32:39 momjian Exp $
*
*-------------------------------------------------------------------------
*/
pg_dlopen(char *filename)
{
#ifndef HAVE_DLD_H
- elog(WARN, "dynamic load not supported");
+ elog(ABORT, "dynamic load not supported");
return (NULL);
#else
static int dl_initialized = 0;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteDefine.c,v 1.9 1997/12/11 17:36:38 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteDefine.c,v 1.10 1998/01/05 03:32:44 momjian Exp $
*
*-------------------------------------------------------------------------
*/
eventrel = heap_openr(evobj);
if (eventrel == NULL)
{
- elog(WARN, "rules cannot be defined on relations not in schema");
+ elog(ABORT, "rules cannot be defined on relations not in schema");
}
eventrel_oid = RelationGetRelationId(eventrel);
evqual = "nil";
if (IsDefinedRewriteRule(rulname))
- elog(WARN, "Attempt to insert rule '%s' failed: already exists",
+ elog(ABORT, "Attempt to insert rule '%s' failed: already exists",
rulname);
strcpyq(actionbuf, actiontree);
strcpyq(qualbuf, evqual);
if (strlen(template) + strlen(rulname) + strlen(actionbuf) +
strlen(qualbuf) + 20 /* fudge fac */ > RULE_PLAN_SIZE)
{
- elog(WARN, "DefineQueryRewrite: rule plan string too big.");
+ elog(ABORT, "DefineQueryRewrite: rule plan string too big.");
}
sprintf(rulebuf, template,
rulname, evtype, eventrel_oid, evslot_index, actionbuf,
if (((event_type == CMD_INSERT) || (event_type == CMD_DELETE)) &&
eslot_string)
{
- elog(WARN,
+ elog(ABORT,
"rules not allowed for insert or delete events to an attribute");
}
if (event_qual && !*action && is_instead)
- elog(WARN,
+ elog(ABORT,
"event_quals on 'instead nothing' rules not currently supported");
#if 0
event_relation = heap_openr(event_obj->relname);
if (event_relation == NULL)
{
- elog(WARN, "virtual relations not supported yet");
+ elog(ABORT, "virtual relations not supported yet");
}
ev_relid = RelationGetRelationId(event_relation);
/* what is the max size of type text? XXX -- glass */
if (length(action) > 15)
- elog(WARN, "max # of actions exceeded");
+ elog(ABORT, "max # of actions exceeded");
prs2_addToRelation(ev_relid, ruleId, event_type, event_attno,
is_instead, event_qual, action);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteHandler.c,v 1.7 1998/01/04 04:31:28 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteHandler.c,v 1.8 1998/01/05 03:32:45 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (++numQueryRewriteInvoked > REWRITE_INVOKE_MAX)
{
- elog(WARN, "query rewritten %d times, may contain cycles",
+ elog(ABORT, "query rewritten %d times, may contain cycles",
numQueryRewriteInvoked - 1);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteRemove.c,v 1.7 1997/11/24 05:08:40 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteRemove.c,v 1.8 1998/01/05 03:32:46 momjian Exp $
*
*-------------------------------------------------------------------------
*/
htp = SearchSysCacheTuple(REWRITENAME, PointerGetDatum(rulename),
0, 0, 0);
if (!HeapTupleIsValid(htp))
- elog(WARN, "RewriteGetRuleEventRel: rule \"%s\" not found",
+ elog(ABORT, "RewriteGetRuleEventRel: rule \"%s\" not found",
rulename);
eventrel = ((Form_pg_rewrite) GETSTRUCT(htp))->ev_class;
htp = SearchSysCacheTuple(RELOID, PointerGetDatum(eventrel),
0, 0, 0);
if (!HeapTupleIsValid(htp))
- elog(WARN, "RewriteGetRuleEventRel: class %d not found",
+ elog(ABORT, "RewriteGetRuleEventRel: class %d not found",
eventrel);
return ((Form_pg_class) GETSTRUCT(htp))->relname.data;
}
if (!HeapTupleIsValid(tuple))
{
heap_close(RewriteRelation);
- elog(WARN, "No rule with name = '%s' was found.\n", ruleName);
+ elog(ABORT, "No rule with name = '%s' was found.\n", ruleName);
}
/*
if (isNull)
{
/* XXX strange!!! */
- elog(WARN, "RemoveRewriteRule: null event target relation!");
+ elog(ABORT, "RemoveRewriteRule: null event target relation!");
}
eventRelationOid = DatumGetObjectId(eventRelationOidDatum);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteSupport.c,v 1.12 1997/11/20 23:22:39 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteSupport.c,v 1.13 1998/01/05 03:32:47 momjian Exp $
*
*-------------------------------------------------------------------------
*/
ObjectIdGetDatum(ruleoid),
0, 0, 0);
if (ruletuple == NULL)
- elog(WARN, "rule %u isn't in rewrite system relation", ruleoid);
+ elog(ABORT, "rule %u isn't in rewrite system relation", ruleoid);
ruleaction = (char *)heap_getattr(ruletuple,
InvalidBuffer,
if (action_is_null || instead_is_null)
{
- elog(WARN, "internal error: rewrite rule not properly set up");
+ elog(ABORT, "internal error: rewrite rule not properly set up");
}
ruleaction = textout((struct varlena *) ruleaction);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_init.c,v 1.15 1997/11/02 15:25:36 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_init.c,v 1.16 1998/01/05 03:32:51 momjian Exp $
*
*-------------------------------------------------------------------------
*/
*/
if (sizeof(struct sbufdesc) != PADDED_SBUFDESC_SIZE ||
sizeof(struct sbufdesc_unpadded) > PADDED_SBUFDESC_SIZE)
- elog(WARN, "Internal error: sbufdesc does not have the proper size, "
+ elog(ABORT, "Internal error: sbufdesc does not have the proper size, "
"contact the Postgres developers");
if (sizeof(struct sbufdesc_unpadded) <= PADDED_SBUFDESC_SIZE / 2)
- elog(WARN, "Internal error: sbufdesc is greatly over-sized, "
+ elog(ABORT, "Internal error: sbufdesc is greatly over-sized, "
"contact the Postgres developers");
Data_Descriptors = NBuffers;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_table.c,v 1.8 1997/09/08 21:46:46 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_table.c,v 1.9 1998/01/05 03:32:52 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (!result)
{
- elog(WARN, "BufTableLookup: BufferLookup table corrupted");
+ elog(ABORT, "BufTableLookup: BufferLookup table corrupted");
return (NULL);
}
if (!found)
if (!(result && found))
{
- elog(WARN, "BufTableDelete: BufferLookup table corrupted");
+ elog(ABORT, "BufTableDelete: BufferLookup table corrupted");
return (FALSE);
}
if (!result)
{
Assert(0);
- elog(WARN, "BufTableInsert: BufferLookup table corrupted");
+ elog(ABORT, "BufTableInsert: BufferLookup table corrupted");
return (FALSE);
}
/* found something else in the table ! */
if (found)
{
Assert(0);
- elog(WARN, "BufTableInsert: BufferLookup table corrupted");
+ elog(ABORT, "BufTableInsert: BufferLookup table corrupted");
return (FALSE);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/buffer/bufmgr.c,v 1.29 1997/11/21 18:11:04 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/buffer/bufmgr.c,v 1.30 1998/01/05 03:32:54 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/*
* But it can return buf == NULL if we are in aborting transaction
- * now and so elog(WARN,...) in GetFreeBuffer will not abort
+ * now and so elog(ABORT,...) in GetFreeBuffer will not abort
* again.
*/
if (buf == NULL)
if (status == SM_FAIL)
{
- elog(WARN, "FlushBuffer: cannot flush block %u of the relation %s",
+ elog(ABORT, "FlushBuffer: cannot flush block %u of the relation %s",
bufHdr->tag.blockNum, bufHdr->sb_relname);
return (STATUS_ERROR);
}
UnpinBuffer(bufHdr);
if (bufHdr->flags & BM_IO_ERROR)
{
- elog(WARN, "BufferSync: write error %u for %s",
+ elog(ABORT, "BufferSync: write error %u for %s",
bufHdr->tag.blockNum, bufHdr->sb_relname);
}
if (reln != (Relation) NULL)
if (status == SM_FAIL)
{
bufHdr->flags |= BM_IO_ERROR;
- elog(WARN, "BufferSync: cannot write %u for %s",
+ elog(ABORT, "BufferSync: cannot write %u for %s",
bufHdr->tag.blockNum, bufHdr->sb_relname);
}
BufferFlushCount++;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/buffer/freelist.c,v 1.7 1997/09/08 20:56:47 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/buffer/freelist.c,v 1.8 1998/01/05 03:32:56 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
/* queue is empty. All buffers in the buffer pool are pinned. */
- elog(WARN, "out of free buffers: time to abort !\n");
+ elog(ABORT, "out of free buffers: time to abort !\n");
return (NULL);
}
buf = &(BufferDescriptors[SharedFreeList->freeNext]);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/buffer/localbuf.c,v 1.14 1997/11/21 18:11:07 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/buffer/localbuf.c,v 1.15 1998/01/05 03:32:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
}
if (bufHdr == NULL)
- elog(WARN, "no empty local buffer.");
+ elog(ABORT, "no empty local buffer.");
/*
* this buffer is not referenced but it might still be dirty (the last
* Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Id: fd.c,v 1.27 1997/11/07 06:38:15 thomas Exp $
+ * $Id: fd.c,v 1.28 1998/01/05 03:33:00 momjian Exp $
*
* NOTES:
*
if (fileName == NULL)
{
- elog(WARN, "fileNameOpenFile: NULL fname");
+ elog(ABORT, "fileNameOpenFile: NULL fname");
}
vfdP->fileName = malloc(strlen(fileName) + 1);
strcpy(vfdP->fileName, fileName);
lseek(VfdCache[file].fd, offset, whence);
return returnCode;
default:
- elog(WARN, "FileSeek: invalid whence: %d", whence);
+ elog(ABORT, "FileSeek: invalid whence: %d", whence);
break;
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipc.c,v 1.16 1997/09/18 20:21:26 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipc.c,v 1.17 1998/01/05 03:33:04 momjian Exp $
*
* NOTES
*
IpcPrivateMem[memid].id = memid;
IpcPrivateMem[memid].memptr = malloc(size);
if (IpcPrivateMem[memid].memptr == NULL)
- elog(WARN, "PrivateMemoryCreate: not enough memory to malloc");
+ elog(ABORT, "PrivateMemoryCreate: not enough memory to malloc");
MemSet(IpcPrivateMem[memid].memptr, 0, size); /* XXX PURIFY */
return (memid++);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmem.c,v 1.14 1997/09/18 20:21:30 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmem.c,v 1.15 1998/01/05 03:33:06 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
SpinRelease(BindingLock);
- elog(WARN, "ShmemInitPID: BindingTable corrupted");
+ elog(ABORT, "ShmemInitPID: BindingTable corrupted");
return (FALSE);
}
if (!result)
{
- elog(WARN, "ShmemPIDDestroy: PID table corrupted");
+ elog(ABORT, "ShmemPIDDestroy: PID table corrupted");
return (INVALID_OFFSET);
}
SpinRelease(BindingLock);
- elog(WARN, "ShmemInitStruct: Binding Table corrupted");
+ elog(ABORT, "ShmemInitStruct: Binding Table corrupted");
return (NULL);
}
}
SpinRelease(BindingLock);
- elog(WARN, "TransactionIdIsInProgress: BindingTable corrupted");
+ elog(ABORT, "TransactionIdIsInProgress: BindingTable corrupted");
return (false);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/large_object/inv_api.c,v 1.24 1997/11/28 17:27:50 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/large_object/inv_api.c,v 1.25 1998/01/05 03:33:09 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (SearchSysCacheTuple(RELNAME, PointerGetDatum(objname),
0, 0, 0) != NULL)
{
- elog(WARN,
+ elog(ABORT,
"internal error: %s already exists -- cannot create large obj",
objname);
}
if (SearchSysCacheTuple(RELNAME, PointerGetDatum(indname),
0, 0, 0) != NULL)
{
- elog(WARN,
+ elog(ABORT,
"internal error: %s already exists -- cannot create large obj",
indname);
}
if (!RelationIsValid(r))
{
- elog(WARN, "cannot create large object on %s under inversion",
+ elog(ABORT, "cannot create large object on %s under inversion",
smgrout(DEFAULT_SMGR));
}
if (!RelationIsValid(indr))
{
- elog(WARN, "cannot create index for large obj on %s under inversion",
+ elog(ABORT, "cannot create index for large obj on %s under inversion",
smgrout(DEFAULT_SMGR));
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lmgr.c,v 1.9 1997/11/24 05:08:43 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lmgr.c,v 1.10 1998/01/05 03:33:16 momjian Exp $
*
*-------------------------------------------------------------------------
*/
*/
if (!LockInfoIsValid(linfo))
{
- elog(WARN,
+ elog(ABORT,
"Releasing a lock on %s with invalid lock information",
RelationGetRelationName(relation));
}
if (!LockInfoIsValid(linfo))
{
- elog(WARN,
+ elog(ABORT,
"Releasing a lock on %s with invalid lock information",
RelationGetRelationName(relation));
}
return;
if (!LockInfoIsValid(relation->lockInfo))
- elog(WARN,
+ elog(ABORT,
"Releasing a lock on %s with invalid lock information",
RelationGetRelationName(relation));
return;
if (!LockInfoIsValid(relation->lockInfo))
- elog(WARN,
+ elog(ABORT,
"Releasing a lock on %s with invalid lock information",
RelationGetRelationName(relation));
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.16 1997/09/18 20:21:35 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.17 1998/01/05 03:33:22 momjian Exp $
*
* NOTES
* Outside modules can create a lock table and acquire/release
lock->holders[lockt]--;
LOCK_DUMP_AUX("WaitOnLock: aborting on lock", lock, lockt);
SpinRelease(ltable->ctl->masterLock);
- elog(WARN, "WaitOnLock: error on wakeup - Aborting this transaction");
+ elog(ABORT, "WaitOnLock: error on wakeup - Aborting this transaction");
}
LOCK_DUMP_AUX("WaitOnLock: wakeup on lock", lock, lockt);
#endif
/*
- * let the caller print its own error message, too. Do not elog(WARN).
+ * let the caller print its own error message, too. Do not elog(ABORT).
*/
if (!lock)
{
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/Attic/multi.c,v 1.8 1997/09/18 20:21:38 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/Attic/multi.c,v 1.9 1998/01/05 03:33:25 momjian Exp $
*
* NOTES:
* (1) The lock.c module assumes that the caller here is doing
MultiTableId = tableId;
if (!(MultiTableId))
{
- elog(WARN, "InitMultiLockm: couldnt initialize lock table");
+ elog(ABORT, "InitMultiLockm: couldnt initialize lock table");
}
/* -----------------------
* No short term lock table for now. -Jeff 15 July 1991
*
* ShortTermTableId = LockTabRename(tableId);
* if (! (ShortTermTableId)) {
- * elog(WARN,"InitMultiLockm: couldnt rename lock table");
+ * elog(ABORT,"InitMultiLockm: couldnt rename lock table");
* }
* -----------------------
*/
locks[2] = lockt;
break;
default:
- elog(WARN, "MultiAcquire: bad lock level");
+ elog(ABORT, "MultiAcquire: bad lock level");
return (FALSE);
}
locks[2] = lockt;
break;
default:
- elog(WARN, "MultiRelease: bad lockt");
+ elog(ABORT, "MultiRelease: bad lockt");
}
/*
status = LockRelease(tableId, tmpTag, locks[i]);
if (!status)
{
- elog(WARN, "MultiRelease: couldn't release after error");
+ elog(ABORT, "MultiRelease: couldn't release after error");
}
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.23 1997/10/30 17:23:59 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.24 1998/01/05 03:33:26 momjian Exp $
*
*-------------------------------------------------------------------------
*/
* This is so that we can support more backends. (system-wide semaphore
* sets run out pretty fast.) -ay 4/95
*
- * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.23 1997/10/30 17:23:59 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.24 1998/01/05 03:33:26 momjian Exp $
*/
#include <sys/time.h>
#include <unistd.h>
if (!found)
{
/* this should not happen. InitProcGlobal() is called before this. */
- elog(WARN, "InitProcess: Proc Header uninitialized");
+ elog(ABORT, "InitProcess: Proc Header uninitialized");
}
if (MyProc != NULL)
{
SpinRelease(ProcStructLock);
- elog(WARN, "ProcInit: you already exist");
+ elog(ABORT, "ProcInit: you already exist");
return;
}
}
/* if we reach here, all the semaphores are in use. */
- elog(WARN, "InitProc: cannot allocate a free semaphore");
+ elog(ABORT, "InitProc: cannot allocate a free semaphore");
}
/*
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/page/bufpage.c,v 1.11 1997/09/18 20:21:41 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/page/bufpage.c,v 1.12 1998/01/05 03:33:29 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (((*itemId).lp_flags & LP_USED) ||
((*itemId).lp_len != 0))
{
- elog(WARN, "PageAddItem: tried overwrite of used ItemId");
+ elog(ABORT, "PageAddItem: tried overwrite of used ItemId");
return (InvalidOffsetNumber);
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/smgr/md.c,v 1.24 1997/11/07 06:38:19 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/smgr/md.c,v 1.25 1998/01/05 03:33:32 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
v->mdfd_chain = _mdfd_openseg(reln, segno, O_CREAT);
if (v->mdfd_chain == (MdfdVec *) NULL)
- elog(WARN, "cannot count blocks for %.16s -- open failed",
+ elog(ABORT, "cannot count blocks for %.16s -- open failed",
RelationGetRelationName(reln));
}
if (fd < 0)
{
if ((fd = mdopen(reln)) < 0)
- elog(WARN, "cannot open relation %.16s",
+ elog(ABORT, "cannot open relation %.16s",
RelationGetRelationName(reln));
reln->rd_fd = fd;
}
v->mdfd_chain = _mdfd_openseg(reln, i, oflag);
if (v->mdfd_chain == (MdfdVec *) NULL)
- elog(WARN, "cannot open segment %d of relation %.16s",
+ elog(ABORT, "cannot open segment %d of relation %.16s",
i, RelationGetRelationName(reln));
}
v = v->mdfd_chain;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/smgr/smgr.c,v 1.11 1997/09/08 21:47:38 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/smgr/smgr.c,v 1.12 1998/01/05 03:33:33 momjian Exp $
*
*-------------------------------------------------------------------------
*/
int fd;
if ((fd = (*(smgrsw[which].smgr_create)) (reln)) < 0)
- elog(WARN, "cannot open %s",
+ elog(ABORT, "cannot open %s",
&(reln->rd_rel->relname.data[0]));
return (fd);
int status;
if ((status = (*(smgrsw[which].smgr_unlink)) (reln)) == SM_FAIL)
- elog(WARN, "cannot unlink %s",
+ elog(ABORT, "cannot unlink %s",
&(reln->rd_rel->relname.data[0]));
return (status);
status = (*(smgrsw[which].smgr_extend)) (reln, buffer);
if (status == SM_FAIL)
- elog(WARN, "%s: cannot extend",
+ elog(ABORT, "%s: cannot extend",
&(reln->rd_rel->relname.data[0]));
return (status);
int fd;
if ((fd = (*(smgrsw[which].smgr_open)) (reln)) < 0)
- elog(WARN, "cannot open %s",
+ elog(ABORT, "cannot open %s",
&(reln->rd_rel->relname.data[0]));
return (fd);
smgrclose(int16 which, Relation reln)
{
if ((*(smgrsw[which].smgr_close)) (reln) == SM_FAIL)
- elog(WARN, "cannot close %s",
+ elog(ABORT, "cannot close %s",
&(reln->rd_rel->relname.data[0]));
return (SM_SUCCESS);
status = (*(smgrsw[which].smgr_read)) (reln, blocknum, buffer);
if (status == SM_FAIL)
- elog(WARN, "cannot read block %d of %s",
+ elog(ABORT, "cannot read block %d of %s",
blocknum, &(reln->rd_rel->relname.data[0]));
return (status);
status = (*(smgrsw[which].smgr_write)) (reln, blocknum, buffer);
if (status == SM_FAIL)
- elog(WARN, "cannot write block %d of %s",
+ elog(ABORT, "cannot write block %d of %s",
blocknum, &(reln->rd_rel->relname.data[0]));
return (status);
status = (*(smgrsw[which].smgr_flush)) (reln, blocknum, buffer);
if (status == SM_FAIL)
- elog(WARN, "cannot flush block %d of %s to stable store",
+ elog(ABORT, "cannot flush block %d of %s to stable store",
blocknum, &(reln->rd_rel->relname.data[0]));
return (status);
blkno, buffer);
if (status == SM_FAIL)
- elog(WARN, "cannot write block %d of %s [%s] blind",
+ elog(ABORT, "cannot write block %d of %s [%s] blind",
blkno, relstr, dbstr);
pfree(dbstr);
int nblocks;
if ((nblocks = (*(smgrsw[which].smgr_nblocks)) (reln)) < 0)
- elog(WARN, "cannot count blocks for %s",
+ elog(ABORT, "cannot count blocks for %s",
&(reln->rd_rel->relname.data[0]));
return (nblocks);
if (smgrsw[which].smgr_truncate)
{
if ((newblks = (*(smgrsw[which].smgr_truncate)) (reln, nblocks)) < 0)
- elog(WARN, "cannot truncate %s to %d blocks",
+ elog(ABORT, "cannot truncate %s to %d blocks",
&(reln->rd_rel->relname.data[0]), nblocks);
}
smgriswo(int16 smgrno)
{
if (smgrno < 0 || smgrno >= NSmgr)
- elog(WARN, "illegal storage manager number %d", smgrno);
+ elog(ABORT, "illegal storage manager number %d", smgrno);
return (smgrwo[smgrno]);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/smgr/smgrtype.c,v 1.5 1997/09/08 21:47:42 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/smgr/smgrtype.c,v 1.6 1998/01/05 03:33:35 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if (strcmp(s, StorageManager[i].smgr_name) == 0)
return ((int2) i);
}
- elog(WARN, "smgrin: illegal storage manager name %s", s);
+ elog(ABORT, "smgrin: illegal storage manager name %s", s);
return 0;
}
char *s;
if (i >= NStorageManagers || i < 0)
- elog(WARN, "Illegal storage manager id %d", i);
+ elog(ABORT, "Illegal storage manager id %d", i);
s = (char *) palloc(strlen(StorageManager[i].smgr_name) + 1);
strcpy(s, StorageManager[i].smgr_name);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/Attic/aclchk.c,v 1.20 1997/11/25 22:06:08 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/Attic/aclchk.c,v 1.21 1998/01/05 03:33:40 momjian Exp $
*
* NOTES
* See acl.h.
*/
relation = heap_openr(RelationRelationName);
if (!RelationIsValid(relation))
- elog(WARN, "ChangeAcl: could not open '%s'??",
+ elog(ABORT, "ChangeAcl: could not open '%s'??",
RelationRelationName);
fmgr_info(NameEqualRegProcedure, &relkey[0].sk_func, &relkey[0].sk_nargs);
relkey[0].sk_argument = NameGetDatum(relname);
{
heap_endscan(hsdp);
heap_close(relation);
- elog(WARN, "ChangeAcl: class \"%s\" not found",
+ elog(ABORT, "ChangeAcl: class \"%s\" not found",
relname);
return;
}
}
else
{
- elog(WARN, "non-existent group \"%s\"", groname);
+ elog(ABORT, "non-existent group \"%s\"", groname);
}
return (id);
}
case ACL_IDTYPE_WORLD:
break;
default:
- elog(WARN, "aclcheck: bogus ACL id type: %d", idtype);
+ elog(ABORT, "aclcheck: bogus ACL id type: %d", idtype);
break;
}
htp = SearchSysCacheTuple(USENAME, PointerGetDatum(usename),
0, 0, 0);
if (!HeapTupleIsValid(htp))
- elog(WARN, "pg_aclcheck: user \"%s\" not found",
+ elog(ABORT, "pg_aclcheck: user \"%s\" not found",
usename);
id = (AclId) ((Form_pg_user) GETSTRUCT(htp))->usesysid;
0, 0, 0);
if (!HeapTupleIsValid(htp))
{
- elog(WARN, "pg_aclcheck: class \"%s\" not found",
+ elog(ABORT, "pg_aclcheck: class \"%s\" not found",
relname);
- /* an elog(WARN) kills us, so no need to return anything. */
+ /* an elog(ABORT) kills us, so no need to return anything. */
}
if (!heap_attisnull(htp, Anum_pg_class_relacl))
{
htp = SearchSysCacheTuple(USENAME, PointerGetDatum(usename),
0, 0, 0);
if (!HeapTupleIsValid(htp))
- elog(WARN, "pg_ownercheck: user \"%s\" not found",
+ elog(ABORT, "pg_ownercheck: user \"%s\" not found",
usename);
user_id = (AclId) ((Form_pg_user) GETSTRUCT(htp))->usesysid;
{
case OPROID:
if (!HeapTupleIsValid(htp))
- elog(WARN, "pg_ownercheck: operator %ld not found",
+ elog(ABORT, "pg_ownercheck: operator %ld not found",
PointerGetDatum(value));
owner_id = ((OperatorTupleForm) GETSTRUCT(htp))->oprowner;
break;
case PRONAME:
if (!HeapTupleIsValid(htp))
- elog(WARN, "pg_ownercheck: function \"%s\" not found",
+ elog(ABORT, "pg_ownercheck: function \"%s\" not found",
value);
owner_id = ((Form_pg_proc) GETSTRUCT(htp))->proowner;
break;
case RELNAME:
if (!HeapTupleIsValid(htp))
- elog(WARN, "pg_ownercheck: class \"%s\" not found",
+ elog(ABORT, "pg_ownercheck: class \"%s\" not found",
value);
owner_id = ((Form_pg_class) GETSTRUCT(htp))->relowner;
break;
case TYPNAME:
if (!HeapTupleIsValid(htp))
- elog(WARN, "pg_ownercheck: type \"%s\" not found",
+ elog(ABORT, "pg_ownercheck: type \"%s\" not found",
value);
owner_id = ((TypeTupleForm) GETSTRUCT(htp))->typowner;
break;
default:
- elog(WARN, "pg_ownercheck: invalid cache id: %d",
+ elog(ABORT, "pg_ownercheck: invalid cache id: %d",
cacheid);
break;
}
htp = SearchSysCacheTuple(USENAME, PointerGetDatum(usename),
0, 0, 0);
if (!HeapTupleIsValid(htp))
- elog(WARN, "pg_func_ownercheck: user \"%s\" not found",
+ elog(ABORT, "pg_func_ownercheck: user \"%s\" not found",
usename);
user_id = (AclId) ((Form_pg_user) GETSTRUCT(htp))->usesysid;
htp = SearchSysCacheTuple(USENAME, PointerGetDatum(usename),
0, 0, 0);
if (!HeapTupleIsValid(htp))
- elog(WARN, "pg_aggr_ownercheck: user \"%s\" not found",
+ elog(ABORT, "pg_aggr_ownercheck: user \"%s\" not found",
usename);
user_id = (AclId) ((Form_pg_user) GETSTRUCT(htp))->usesysid;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/fastpath.c,v 1.8 1997/12/06 22:57:03 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/fastpath.c,v 1.9 1998/01/05 03:33:44 momjian Exp $
*
* NOTES
* This cruft is the server side of PQfn.
* Since the validity of this structure is determined by whether the
* funcid is OK, we clear the funcid here. It must not be set to the
* correct value until we are about to return with a good struct
- * fp_info, since we can be interrupted (i.e., with an elog(WARN,
+ * fp_info, since we can be interrupted (i.e., with an elog(ABORT,
* ...)) at any time.
*/
MemSet((char *) fip, 0, (int) sizeof(struct fp_info));
0, 0, 0);
if (!HeapTupleIsValid(func_htp))
{
- elog(WARN, "update_fp_info: cache lookup for function %d failed",
+ elog(ABORT, "update_fp_info: cache lookup for function %d failed",
func_id);
}
pp = (Form_pg_proc) GETSTRUCT(func_htp);
0, 0, 0);
if (!HeapTupleIsValid(type_htp))
{
- elog(WARN, "update_fp_info: bad argument type %d for %d",
+ elog(ABORT, "update_fp_info: bad argument type %d for %d",
argtypes[i], func_id);
}
tp = (TypeTupleForm) GETSTRUCT(type_htp);
0, 0, 0);
if (!HeapTupleIsValid(type_htp))
{
- elog(WARN, "update_fp_info: bad return type %d for %d",
+ elog(ABORT, "update_fp_info: bad return type %d for %d",
rettype, func_id);
}
tp = (TypeTupleForm) GETSTRUCT(type_htp);
*
* RETURNS:
* nothing of significance.
- * All errors result in elog(WARN,...).
+ * All errors result in elog(ABORT,...).
*/
int
HandleFunctionRequest()
if (fip->nargs != nargs)
{
- elog(WARN, "HandleFunctionRequest: actual arguments (%d) != registered arguments (%d)",
+ elog(ABORT, "HandleFunctionRequest: actual arguments (%d) != registered arguments (%d)",
nargs, fip->nargs);
}
{ /* ... varlena */
if (!(p = palloc(argsize + VARHDRSZ)))
{
- elog(WARN, "HandleFunctionRequest: palloc failed");
+ elog(ABORT, "HandleFunctionRequest: palloc failed");
}
VARSIZE(p) = argsize + VARHDRSZ;
pq_getnchar(VARDATA(p), 0, argsize);
/* XXX cross our fingers and trust "argsize" */
if (!(p = palloc(argsize)))
{
- elog(WARN, "HandleFunctionRequest: palloc failed");
+ elog(ABORT, "HandleFunctionRequest: palloc failed");
}
pq_getnchar(p, 0, argsize);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.57 1997/12/16 15:57:00 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.58 1998/01/05 03:33:46 momjian Exp $
*
* NOTES
* this is the "main" module of the postgres backend and
sigjmp_buf Warn_restart;
#endif /* defined(nextstep) */
-int InWarn;
+int InErrorOrAbort;
extern int NBuffers;
* signal handler routines used in PostgresMain()
*
* handle_warn() is used to catch kill(getpid(),1) which
- * occurs when elog(WARN) is called.
+ * occurs when elog(ABORT) is called.
*
* quickdie() occurs when signalled by the postmaster.
* Some backend has bought the farm,
static void
FloatExceptionHandler(SIGNAL_ARGS)
{
- elog(WARN, "floating point exception!"
+ elog(ABORT, "floating point exception!"
" The last floating point operation either exceeded legal ranges"
" or was a divide by zero");
}
* so that the slaves signal the master to abort the transaction
* rather than calling AbortCurrentTransaction() themselves.
*
- * Note: elog(WARN) causes a kill(getpid(),1) to occur sending
+ * Note: elog(ABORT) causes a kill(getpid(),1) to occur sending
* us back here.
* ----------------
*/
if (sigsetjmp(Warn_restart, 1) != 0)
{
- InWarn = 1;
+ InErrorOrAbort = 1;
time(&tim);
AbortCurrentTransaction();
}
- InWarn = 0;
+ InErrorOrAbort = 0;
/* ----------------
* POSTGRES main processing loop begins here
if (IsUnderPostmaster == false)
{
puts("\nPOSTGRES backend interactive interface");
- puts("$Revision: 1.57 $ $Date: 1997/12/16 15:57:00 $");
+ puts("$Revision: 1.58 $ $Date: 1998/01/05 03:33:46 $");
}
/* ----------------
break;
default:
- elog(WARN, "unknown frontend message was recieved");
+ elog(ABORT, "unknown frontend message was recieved");
}
/* ----------------
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.11 1997/09/18 20:22:05 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.12 1998/01/05 03:33:48 momjian Exp $
*
*-------------------------------------------------------------------------
*/
*/
if (PortalNameIsSpecial(portalName))
- elog(WARN,
+ elog(ABORT,
"The portal name %s is reserved for internal use",
portalName);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/utility.c,v 1.33 1998/01/01 05:48:14 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/utility.c,v 1.34 1998/01/05 03:33:49 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
relname = strVal(lfirst(arg));
if (IsSystemRelationName(relname))
- elog(WARN, "class \"%s\" is a system catalog",
+ elog(ABORT, "class \"%s\" is a system catalog",
relname);
rel = heap_openr(relname);
if (RelationIsValid(rel))
{
if (stmt->sequence &&
rel->rd_rel->relkind != RELKIND_SEQUENCE)
- elog(WARN, "Use DROP TABLE to drop table '%s'",
+ elog(ABORT, "Use DROP TABLE to drop table '%s'",
relname);
if (!(stmt->sequence) &&
rel->rd_rel->relkind == RELKIND_SEQUENCE)
- elog(WARN, "Use DROP SEQUENCE to drop sequence '%s'",
+ elog(ABORT, "Use DROP SEQUENCE to drop sequence '%s'",
relname);
heap_close(rel);
}
#ifndef NO_SECURITY
if (!pg_ownercheck(userName, relname, RELNAME))
- elog(WARN, "you do not own class \"%s\"",
+ elog(ABORT, "you do not own class \"%s\"",
relname);
#endif
}
relname = stmt->relname;
if (IsSystemRelationName(relname))
- elog(WARN, "class \"%s\" is a system catalog",
+ elog(ABORT, "class \"%s\" is a system catalog",
relname);
#ifndef NO_SECURITY
if (!pg_ownercheck(userName, relname, RELNAME))
- elog(WARN, "you do not own class \"%s\"",
+ elog(ABORT, "you do not own class \"%s\"",
relname);
#endif
{
relname = strVal(lfirst(i));
if (!pg_ownercheck(userName, relname, RELNAME))
- elog(WARN, "you do not own class \"%s\"",
+ elog(ABORT, "you do not own class \"%s\"",
relname);
}
#endif
relname = stmt->object->relname;
aclcheck_result = pg_aclcheck(relname, userName, ACL_RU);
if (aclcheck_result != ACLCHECK_OK)
- elog(WARN, "%s: %s", relname, aclcheck_error_strings[aclcheck_result]);
+ elog(ABORT, "%s: %s", relname, aclcheck_error_strings[aclcheck_result]);
#endif
commandTag = "CREATE";
CHECK_IF_ABORTED();
case INDEX:
relname = stmt->name;
if (IsSystemRelationName(relname))
- elog(WARN, "class \"%s\" is a system catalog index",
+ elog(ABORT, "class \"%s\" is a system catalog index",
relname);
#ifndef NO_SECURITY
if (!pg_ownercheck(userName, relname, RELNAME))
- elog(WARN, "%s: %s", relname, aclcheck_error_strings[ACLCHECK_NOT_OWNER]);
+ elog(ABORT, "%s: %s", relname, aclcheck_error_strings[ACLCHECK_NOT_OWNER]);
#endif
RemoveIndex(relname);
break;
aclcheck_result = pg_aclcheck(relationName, userName, ACL_RU);
if (aclcheck_result != ACLCHECK_OK)
{
- elog(WARN, "%s: %s", relationName, aclcheck_error_strings[aclcheck_result]);
+ elog(ABORT, "%s: %s", relationName, aclcheck_error_strings[aclcheck_result]);
}
#endif
RemoveRewriteRule(rulename);
ruleName = MakeRetrieveViewRuleName(viewName);
relationName = RewriteGetRuleEventRel(ruleName);
if (!pg_ownercheck(userName, relationName, RELNAME))
- elog(WARN, "%s: %s", relationName, aclcheck_error_strings[ACLCHECK_NOT_OWNER]);
+ elog(ABORT, "%s: %s", relationName, aclcheck_error_strings[ACLCHECK_NOT_OWNER]);
pfree(ruleName);
#endif
RemoveView(viewName);
case T_VersionStmt:
{
- elog(WARN, "CREATE VERSION is not currently implemented");
+ elog(ABORT, "CREATE VERSION is not currently implemented");
}
break;
filename = stmt->filename;
closeAllVfds();
if ((fp = AllocateFile(filename, "r")) == NULL)
- elog(WARN, "LOAD: could not open file %s", filename);
+ elog(ABORT, "LOAD: could not open file %s", filename);
FreeFile(fp);
load_file(filename);
}
*
*/
default:
- elog(WARN, "ProcessUtility: command #%d unsupported",
+ elog(ABORT, "ProcessUtility: command #%d unsupported",
nodeTag(parsetree));
break;
}
* Routines for handling of 'SET var TO',
* 'SHOW var' and 'RESET var' statements.
*
- * $Id: variable.c,v 1.24 1997/12/04 23:17:13 thomas Exp $
+ * $Id: variable.c,v 1.25 1998/01/05 03:33:50 momjian Exp $
*
*/
while (isspace(*str))
str++;
if (*str == ',' || *str == '=')
- elog(WARN, "Syntax error near (%s): empty setting", str);
+ elog(ABORT, "Syntax error near (%s): empty setting", str);
/* end of string? then return NULL */
if (!(*str))
}
else if ((val == NULL) || (*str != '='))
{
- elog(WARN, "Syntax error near (%s)", str);
+ elog(ABORT, "Syntax error near (%s)", str);
};
str++; /* '=': get value */
str++;
if (*str == ',' || !(*str))
- elog(WARN, "Syntax error near (=%s)", str);
+ elog(ABORT, "Syntax error near (=%s)", str);
start = str;
if (*str == ',')
return (++str);
- elog(WARN, "Syntax error near (%s)", str);
+ elog(ABORT, "Syntax error near (%s)", str);
return str;
}
rest = get_token(&tok, &val, value);
if (tok == NULL)
- elog(WARN, "Value undefined");
+ elog(ABORT, "Value undefined");
if ((rest) && (*rest != '\0'))
- elog(WARN, "Unable to parse '%s'", value);
+ elog(ABORT, "Unable to parse '%s'", value);
if (strcasecmp(tok, "on") == 0)
{
{
geqo_rels = pg_atoi(val, sizeof(int32), '\0');
if (geqo_rels <= 1)
- elog(WARN, "Bad value for # of relations (%s)", val);
+ elog(ABORT, "Bad value for # of relations (%s)", val);
PFREE(val);
}
_use_geqo_ = true;
else if (strcasecmp(tok, "off") == 0)
{
if ((val != NULL) && (*val != '\0'))
- elog(WARN, "%s does not allow a parameter", tok);
+ elog(ABORT, "%s does not allow a parameter", tok);
_use_geqo_ = false;
}
else
- elog(WARN, "Bad value for GEQO (%s)", value);
+ elog(ABORT, "Bad value for GEQO (%s)", value);
PFREE(tok);
return TRUE;
else if (strcasecmp(value, "off") == 0)
_use_right_sided_plans_ = false;
else
- elog(WARN, "Bad value for Right-sided Plans (%s)", value);
+ elog(ABORT, "Bad value for Right-sided Plans (%s)", value);
return TRUE;
}
}
else
{
- elog(WARN, "Bad value for date style (%s)", tok);
+ elog(ABORT, "Bad value for date style (%s)", tok);
}
PFREE(tok);
}
strcpy(tzbuf, "TZ=");
strcat(tzbuf, tok);
if (putenv(tzbuf) != 0)
- elog(WARN, "Unable to set TZ environment variable to %s", tok);
+ elog(ABORT, "Unable to set TZ environment variable to %s", tok);
tzset();
PFREE(tok);
strcpy(tzbuf, "TZ=");
strcat(tzbuf, TZvalue);
if (putenv(tzbuf) != 0)
- elog(WARN, "Unable to set TZ environment variable to %s", TZvalue);
+ elog(ABORT, "Unable to set TZ environment variable to %s", TZvalue);
}
else
{
strcpy(tzbuf, "=");
if (putenv(tzbuf) != 0)
- elog(WARN, "Unable to clear TZ environment variable", NULL);
+ elog(ABORT, "Unable to clear TZ environment variable", NULL);
}
tzset();
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/acl.c,v 1.21 1997/12/29 05:13:57 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/acl.c,v 1.22 1998/01/05 03:33:53 momjian Exp $
*
*-------------------------------------------------------------------------
*/
for (id = s, len = 0; isalnum(*s) || *s == '_'; ++len, ++s)
;
if (len > sizeof(NameData))
- elog(WARN, "getid: identifier cannot be >%d characters",
+ elog(ABORT, "getid: identifier cannot be >%d characters",
sizeof(NameData));
if (len > 0)
memmove(n, id, len);
}
else if (strcmp(name, ACL_IDTYPE_UID_KEYWORD))
{
- elog(WARN, "aclparse: bad keyword, must be [group|user]");
+ elog(ABORT, "aclparse: bad keyword, must be [group|user]");
}
s = getid(s, name); /* move s to the name beyond the keyword */
if (name[0] == '\0')
- elog(WARN, "aclparse: a name must follow the [group|user] keyword");
+ elog(ABORT, "aclparse: a name must follow the [group|user] keyword");
}
if (name[0] == '\0')
aip->ai_idtype = ACL_IDTYPE_WORLD;
*modechg = ACL_MODECHG_EQL;
break;
default:
- elog(WARN, "aclparse: mode change flag must use \"%s\"",
+ elog(ABORT, "aclparse: mode change flag must use \"%s\"",
ACL_MODECHG_STR);
}
aip->ai_mode |= ACL_RU;
break;
default:
- elog(WARN, "aclparse: mode flags must use \"%s\"",
+ elog(ABORT, "aclparse: mode flags must use \"%s\"",
ACL_MODE_STR);
}
}
htp = SearchSysCacheTuple(USENAME, PointerGetDatum(name),
0, 0, 0);
if (!HeapTupleIsValid(htp))
- elog(WARN, "aclparse: non-existent user \"%s\"", name);
+ elog(ABORT, "aclparse: non-existent user \"%s\"", name);
aip->ai_id = ((Form_pg_user) GETSTRUCT(htp))->usesysid;
break;
case ACL_IDTYPE_GID:
Size size;
if (n < 0)
- elog(WARN, "makeacl: invalid size: %d\n", n);
+ elog(ABORT, "makeacl: invalid size: %d\n", n);
size = ACL_N_SIZE(n);
if (!(new_acl = (Acl *) palloc(size)))
- elog(WARN, "makeacl: palloc failed on %d\n", size);
+ elog(ABORT, "makeacl: palloc failed on %d\n", size);
MemSet((char *) new_acl, 0, size);
new_acl->size = size;
new_acl->ndim = 1;
AclItem *aip;
if (!s)
- elog(WARN, "aclitemin: null string");
+ elog(ABORT, "aclitemin: null string");
aip = (AclItem *) palloc(sizeof(AclItem));
if (!aip)
- elog(WARN, "aclitemin: palloc failed");
+ elog(ABORT, "aclitemin: palloc failed");
s = aclparse(s, aip, &modechg);
if (modechg != ACL_MODECHG_EQL)
- elog(WARN, "aclitemin: cannot accept anything but = ACLs");
+ elog(ABORT, "aclitemin: cannot accept anything but = ACLs");
while (isspace(*s))
++s;
if (*s)
- elog(WARN, "aclitemin: extra garbage at end of specification");
+ elog(ABORT, "aclitemin: extra garbage at end of specification");
return (aip);
}
p = out = palloc(strlen("group =arwR ") + 1 + NAMEDATALEN);
if (!out)
- elog(WARN, "aclitemout: palloc failed");
+ elog(ABORT, "aclitemout: palloc failed");
*p = '\0';
switch (aip->ai_idtype)
case ACL_IDTYPE_WORLD:
break;
default:
- elog(WARN, "aclitemout: bad ai_idtype: %d", aip->ai_idtype);
+ elog(ABORT, "aclitemout: bad ai_idtype: %d", aip->ai_idtype);
break;
}
while (*p)
new_aip = ACL_DAT(new_acl);
if (dst == 0)
{ /* start */
- elog(WARN, "aclinsert3: insertion before world ACL??");
+ elog(ABORT, "aclinsert3: insertion before world ACL??");
}
else if (dst >= num)
{ /* end */
new_aip = ACL_DAT(new_acl);
if (dst == 0)
{ /* start */
- elog(WARN, "aclremove: removal of the world ACL??");
+ elog(ABORT, "aclremove: removal of the world ACL??");
}
else if (dst == old_num - 1)
{ /* end */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/arrayfuncs.c,v 1.21 1997/12/06 22:57:10 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/arrayfuncs.c,v 1.22 1998/01/05 03:33:54 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
for (q = p; isdigit(*q); q++);
if (*q != ']')
- elog(WARN, "array_in: missing ']' in array declaration");
+ elog(ABORT, "array_in: missing ']' in array declaration");
*q = '\0';
dim[ndim] = atoi(p);
if ((dim[ndim] < 0) || (lBound[ndim] < 0))
- elog(WARN, "array_in: array dimensions need to be positive");
+ elog(ABORT, "array_in: array dimensions need to be positive");
dim[ndim] = dim[ndim] - lBound[ndim] + 1;
if (dim[ndim] < 0)
- elog(WARN, "array_in: upper_bound cannot be < lower_bound");
+ elog(ABORT, "array_in: upper_bound cannot be < lower_bound");
p = q + 1;
ndim++;
}
}
else
{
- elog(WARN, "array_in: Need to specify dimension");
+ elog(ABORT, "array_in: Need to specify dimension");
}
}
else
while (isspace(*p))
p++;
if (strncmp(p, ASSGN, strlen(ASSGN)))
- elog(WARN, "array_in: missing assignment operator");
+ elog(ABORT, "array_in: missing assignment operator");
p += strlen(ASSGN);
while (isspace(*p))
p++;
memmove((char *) ARR_LBOUND(retval), (char *) lBound, ndim * sizeof(int));
memmove(ARR_DATA_PTR(retval), dataPtr, bytes);
#endif
- elog(WARN, "large object arrays not supported");
+ elog(ABORT, "large object arrays not supported");
}
pfree(string_save);
return ((char *) retval);
* Signal a premature end of the string. DZ -
* 2-9-1996
*/
- elog(WARN, "malformed array constant: %s", str);
+ elog(ABORT, "malformed array constant: %s", str);
break;
case '\"':
scanning_string = !scanning_string;
p++;
nest_level++;
if (nest_level > ndim)
- elog(WARN, "array_in: illformed array constant");
+ elog(ABORT, "array_in: illformed array constant");
indx[nest_level - 1] = 0;
indx[ndim - 1] = 0;
}
}
*q = '\0';
if (i >= nitems)
- elog(WARN, "array_in: illformed array constant");
+ elog(ABORT, "array_in: illformed array constant");
values[i] = (*inputproc) (p, typelem);
p = ++q;
if (!eoArray)
if (!strcmp(word, "-chunk"))
{
if (str == NULL)
- elog(WARN, "array_in: access pattern file required");
+ elog(ABORT, "array_in: access pattern file required");
str = _AdvanceBy1word(str, &accessfile);
}
else if (!strcmp(word, "-noreorg"))
{
if (str == NULL)
- elog(WARN, "array_in: chunk file required");
+ elog(ABORT, "array_in: chunk file required");
str = _AdvanceBy1word(str, &chunkfile);
}
else
{
- elog(WARN, "usage: <input file> -chunk DEFAULT/<access pattern file> -invert/-native [-noreorg <chunk file>]");
+ elog(ABORT, "usage: <input file> -chunk DEFAULT/<access pattern file> -invert/-native [-noreorg <chunk file>]");
}
}
if (inputfile == NULL)
- elog(WARN, "array_in: missing file name");
+ elog(ABORT, "array_in: missing file name");
lobjId = lo_creat(0);
*fd = lo_open(lobjId, INV_READ);
if (*fd < 0)
- elog(WARN, "Large object create failed");
+ elog(ABORT, "Large object create failed");
retStr = inputfile;
*nbytes = strlen(retStr) + 2;
FILE *afd;
if ((afd = AllocateFile(accessfile, "r")) == NULL)
- elog(WARN, "unable to open access pattern file");
+ elog(ABORT, "unable to open access pattern file");
*chunkFlag = true;
retStr = _ChunkArray(*fd, afd, ndim, dim, baseSize, nbytes,
chunkfile);
* fixed length arrays -- these are assumed to be 1-d
*/
if (indx[0] * elmlen > arraylen)
- elog(WARN, "array_ref: array bound exceeded");
+ elog(ABORT, "array_ref: array bound exceeded");
retval = (char *) array + indx[0] * elmlen;
return _ArrayCast(retval, reftype, elmlen);
}
for (i = 0; i < n; i++)
if (lowerIndx[i] > upperIndx[i])
- elog(WARN, "lowerIndex cannot be larger than upperIndx");
+ elog(ABORT, "lowerIndex cannot be larger than upperIndx");
mda_get_range(n, span, lowerIndx, upperIndx);
if (ARR_IS_LO(array))
rsize;
if (len < 0)
- elog(WARN, "array_clip: array of variable length objects not supported");
+ elog(ABORT, "array_clip: array of variable length objects not supported");
#ifdef LOARRAY
lo_name = (char *) ARR_DATA_PTR(array);
if ((fd = LOopen(lo_name, ARR_IS_INV(array) ? INV_READ : O_RDONLY)) < 0)
* fixed length arrays -- these are assumed to be 1-d
*/
if (indx[0] * elmlen > arraylen)
- elog(WARN, "array_ref: array bound exceeded");
+ elog(ABORT, "array_ref: array bound exceeded");
pos = (char *) array + indx[0] * elmlen;
ArrayCastAndSet(dataPtr, (bool) reftype, elmlen, pos);
return ((char *) array);
if (!SanityCheckInput(ndim, n, dim, lb, indx))
{
- elog(WARN, "array_set: array bound exceeded");
+ elog(ABORT, "array_set: array bound exceeded");
return ((char *) array);
}
offset = GetOffset(n, dim, lb, indx);
if (array == (ArrayType *) NULL)
RETURN_NULL;
if (len < 0)
- elog(WARN, "array_assgn:updates on arrays of variable length elements not allowed");
+ elog(ABORT, "array_assgn:updates on arrays of variable length elements not allowed");
dim = ARR_DIMS(array);
lb = ARR_LBOUND(array);
for (i = 0; i < n; i++)
if (lowerIndx[i] > upperIndx[i])
- elog(WARN, "lowerIndex larger than upperIndx");
+ elog(ABORT, "lowerIndex larger than upperIndx");
if (ARR_IS_LO(array))
{
if (!HeapTupleIsValid(typeTuple))
{
- elog(WARN, "array_out: Cache lookup failed for type %d\n",
+ elog(ABORT, "array_out: Cache lookup failed for type %d\n",
element_type);
return;
}
case 4:
return ((Datum) *(int32 *) value);
default:
- elog(WARN, "array_ref: byval and elt len > 4!");
+ elog(ABORT, "array_ref: byval and elt len > 4!");
break;
}
}
strcpy(saveName, p);
#ifdef LOARRAY
if ((*fd = LOcreat(saveName, 0600, flag)) < 0)
- elog(WARN, "Large object create failed");
+ elog(ABORT, "Large object create failed");
#endif
return (p);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/bool.c,v 1.11 1997/11/07 06:30:20 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/bool.c,v 1.12 1998/01/05 03:33:55 momjian Exp $
*
*-------------------------------------------------------------------------
*/
break;
}
- elog(WARN,"Bad boolean external representation '%s'", b);
+ elog(ABORT,"Bad boolean external representation '%s'", b);
/* not reached */
return (FALSE);
} /* boolin() */
* workings can be found in the book "Software Solutions in C" by
* Dale Schumacher, Academic Press, ISBN: 0-12-632360-7.
*
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/cash.c,v 1.18 1997/10/25 05:11:06 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/cash.c,v 1.19 1998/01/05 03:33:56 momjian Exp $
*/
#include <stdio.h>
s++;
if (*s != '\0')
- elog(WARN, "Bad money external representation %s", str);
+ elog(ABORT, "Bad money external representation %s", str);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't input cash '%s'", str);
+ elog(ABORT, "Memory allocation failed, can't input cash '%s'", str);
*result = (value * sgn);
if (minus)
{
if (!PointerIsValid(result = PALLOC(CASH_BUFSZ + 2 - count + strlen(nsymbol))))
- elog(WARN, "Memory allocation failed, can't output cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't output cash", NULL);
/* Position code of 0 means use parens */
if (convention == 0)
else
{
if (!PointerIsValid(result = PALLOC(CASH_BUFSZ + 2 - count)))
- elog(WARN, "Memory allocation failed, can't output cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't output cash", NULL);
strcpy(result, buf + count);
}
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't add cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't add cash", NULL);
*result = (*c1 + *c2);
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't subtract cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't subtract cash", NULL);
*result = (*c1 - *c2);
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't multiply cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't multiply cash", NULL);
*result = ((*f) * (*c));
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't divide cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't divide cash", NULL);
if (*f == 0.0)
- elog(WARN, "cash_div: divide by 0.0 error");
+ elog(ABORT, "cash_div: divide by 0.0 error");
*result = rint(*c / *f);
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't multiply cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't multiply cash", NULL);
*result = ((*f) * (*c));
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't divide cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't divide cash", NULL);
if (*f == 0.0)
- elog(WARN, "cash_div: divide by 0.0 error");
+ elog(ABORT, "cash_div: divide by 0.0 error");
*result = rint(*c / *f);
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't multiply cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't multiply cash", NULL);
*result = ((i) * (*c));
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't divide cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't divide cash", NULL);
if (i == 0)
- elog(WARN, "cash_idiv: divide by 0 error");
+ elog(ABORT, "cash_idiv: divide by 0 error");
*result = rint(*c / i);
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't multiply cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't multiply cash", NULL);
*result = ((s) * (*c));
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't divide cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't divide cash", NULL);
if (s == 0)
- elog(WARN, "cash_div: divide by 0 error");
+ elog(ABORT, "cash_div: divide by 0 error");
*result = rint(*c / s);
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't return larger cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't return larger cash", NULL);
*result = ((*c1 > *c2) ? *c1 : *c2);
return (NULL);
if (!PointerIsValid(result = PALLOCTYPE(Cash)))
- elog(WARN, "Memory allocation failed, can't return smaller cash", NULL);
+ elog(ABORT, "Memory allocation failed, can't return smaller cash", NULL);
*result = ((*c1 < *c2) ? *c1 : *c2);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/chunk.c,v 1.11 1997/12/06 22:57:12 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/chunk.c,v 1.12 1998/01/05 03:33:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
else
cfd = LOopen(chunkfile, O_RDONLY);
if (cfd < 0)
- elog(WARN, "Unable to open chunk file");
+ elog(ABORT, "Unable to open chunk file");
#endif
strcpy(cInfo.lo_name, chunkfile);
*/
fscanf(fd, "%d", &N);
if (N > MAXPAT)
- elog(WARN, "array_in: too many access pattern elements");
+ elog(ABORT, "array_in: too many access pattern elements");
for (i = 0; i < N; i++)
for (j = 0; j < ndim + 1; j++)
if (fscanf(fd, "%d ", &(A[i][j])) == EOF)
- elog(WARN, "array_in: bad access pattern input");
+ elog(ABORT, "array_in: bad access pattern input");
/*
* estimate chunk size
/* Assuming only one file */
if (lo_lseek(fp, pos, from) < 0)
- elog(WARN, "File seek error");
+ elog(ABORT, "File seek error");
#ifdef LOARRAY
v = (struct varlena *) LOread(fp, size);
#endif
if (VARSIZE(v) - VARHDRSZ < size)
- elog(WARN, "File read error");
+ elog(ABORT, "File read error");
memmove(buff, VARDATA(v), size);
pfree(v);
return (1);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/date.c,v 1.19 1997/09/20 16:17:45 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/date.c,v 1.20 1998/01/05 03:33:59 momjian Exp $
*
* NOTES
* This code is actually (almost) unused.
char lowstr[MAXDATELEN + 1];
if (!PointerIsValid(str))
- elog(WARN, "Bad (null) date external representation", NULL);
+ elog(ABORT, "Bad (null) date external representation", NULL);
if (strlen(str) > MAXDATELEN)
- elog(WARN, "Bad (length) reltime external representation '%s'", str);
+ elog(ABORT, "Bad (length) reltime external representation '%s'", str);
if ((ParseDateTime(str, lowstr, field, ftype, MAXDATEFIELDS, &nf) != 0)
|| (DecodeDateDelta(field, ftype, nf, &dtype, tm, &fsec) != 0))
- elog(WARN, "Bad reltime external representation '%s'", str);
+ elog(ABORT, "Bad reltime external representation '%s'", str);
#ifdef DATEDEBUG
printf("reltimein- %d fields are type %d (DTK_DATE=%d)\n", nf, dtype, DTK_DATE);
return (INVALID_RELTIME);
}
- elog(WARN, "Bad reltime (internal coding error) '%s'", str);
+ elog(ABORT, "Bad reltime (internal coding error) '%s'", str);
return (INVALID_RELTIME);
} /* reltimein() */
month;
if (!PointerIsValid(result = PALLOCTYPE(TimeSpan)))
- elog(WARN, "Memory allocation failed, can't convert reltime to timespan", NULL);
+ elog(ABORT, "Memory allocation failed, can't convert reltime to timespan", NULL);
switch (reltime)
{
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/datetime.c,v 1.18 1997/12/23 19:23:07 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/datetime.c,v 1.19 1998/01/05 03:34:00 momjian Exp $
*
*-------------------------------------------------------------------------
*/
char lowstr[MAXDATELEN + 1];
if (!PointerIsValid(str))
- elog(WARN, "Bad (null) date external representation", NULL);
+ elog(ABORT, "Bad (null) date external representation", NULL);
#ifdef DATEDEBUG
printf("date_in- input string is %s\n", str);
#endif
if ((ParseDateTime(str, lowstr, field, ftype, MAXDATEFIELDS, &nf) != 0)
|| (DecodeDateTime(field, ftype, nf, &dtype, tm, &fsec, &tzp) != 0))
- elog(WARN, "Bad date external representation %s", str);
+ elog(ABORT, "Bad date external representation %s", str);
switch (dtype)
{
break;
default:
- elog(WARN, "Unrecognized date external representation %s", str);
+ elog(ABORT, "Unrecognized date external representation %s", str);
}
if (tm->tm_year < 0 || tm->tm_year > 32767)
- elog(WARN, "date_in: year must be limited to values 0 through 32767 in '%s'", str);
+ elog(ABORT, "date_in: year must be limited to values 0 through 32767 in '%s'", str);
if (tm->tm_mon < 1 || tm->tm_mon > 12)
- elog(WARN, "date_in: month must be limited to values 1 through 12 in '%s'", str);
+ elog(ABORT, "date_in: month must be limited to values 1 through 12 in '%s'", str);
if (tm->tm_mday < 1 || tm->tm_mday > day_tab[isleap(tm->tm_year)][tm->tm_mon - 1])
- elog(WARN, "date_in: day must be limited to values 1 through %d in '%s'",
+ elog(ABORT, "date_in: day must be limited to values 1 through %d in '%s'",
day_tab[isleap(tm->tm_year)][tm->tm_mon - 1], str);
date = (date2j(tm->tm_year, tm->tm_mon, tm->tm_mday) - date2j(2000, 1, 1));
result = PALLOCTYPE(DateTime);
if (date2tm(dateVal, &tz, tm, &fsec, &tzn) != 0)
- elog(WARN, "Unable to convert date to datetime", NULL);
+ elog(ABORT, "Unable to convert date to datetime", NULL);
#ifdef DATEDEBUG
printf("date_datetime- date is %d.%02d.%02d\n", tm->tm_year, tm->tm_mon, tm->tm_mday);
#endif
if (tm2datetime(tm, fsec, &tz, result) != 0)
- elog(WARN, "Datetime out of range", NULL);
+ elog(ABORT, "Datetime out of range", NULL);
return (result);
} /* date_datetime() */
char *tzn;
if (!PointerIsValid(datetime))
- elog(WARN, "Unable to convert null datetime to date", NULL);
+ elog(ABORT, "Unable to convert null datetime to date", NULL);
if (DATETIME_NOT_FINITE(*datetime))
- elog(WARN, "Unable to convert datetime to date", NULL);
+ elog(ABORT, "Unable to convert datetime to date", NULL);
if (DATETIME_IS_EPOCH(*datetime))
{
else
{
if (datetime2tm(*datetime, &tz, tm, &fsec, &tzn) != 0)
- elog(WARN, "Unable to convert datetime to date", NULL);
+ elog(ABORT, "Unable to convert datetime to date", NULL);
}
result = (date2j(tm->tm_year, tm->tm_mon, tm->tm_mday) - date2j(2000, 1, 1));
case INVALID_ABSTIME:
case NOSTART_ABSTIME:
case NOEND_ABSTIME:
- elog(WARN, "Unable to convert reserved abstime value to date", NULL);
+ elog(ABORT, "Unable to convert reserved abstime value to date", NULL);
/*
* pretend to drop through to make compiler think that result
int ftype[MAXDATEFIELDS];
if (!PointerIsValid(str))
- elog(WARN, "Bad (null) time external representation", NULL);
+ elog(ABORT, "Bad (null) time external representation", NULL);
if ((ParseDateTime(str, lowstr, field, ftype, MAXDATEFIELDS, &nf) != 0)
|| (DecodeTimeOnly(field, ftype, nf, &dtype, tm, &fsec) != 0))
- elog(WARN, "Bad time external representation '%s'", str);
+ elog(ABORT, "Bad time external representation '%s'", str);
if ((tm->tm_hour < 0) || (tm->tm_hour > 23))
- elog(WARN, "Hour must be limited to values 0 through 23 in '%s'", str);
+ elog(ABORT, "Hour must be limited to values 0 through 23 in '%s'", str);
if ((tm->tm_min < 0) || (tm->tm_min > 59))
- elog(WARN, "Minute must be limited to values 0 through 59 in '%s'", str);
+ elog(ABORT, "Minute must be limited to values 0 through 59 in '%s'", str);
if ((tm->tm_sec < 0) || ((tm->tm_sec + fsec) >= 60))
- elog(WARN, "Second must be limited to values 0 through < 60 in '%s'", str);
+ elog(ABORT, "Second must be limited to values 0 through < 60 in '%s'", str);
time = PALLOCTYPE(TimeADT);
char *tzn;
if (!PointerIsValid(datetime))
- elog(WARN, "Unable to convert null datetime to date", NULL);
+ elog(ABORT, "Unable to convert null datetime to date", NULL);
if (DATETIME_NOT_FINITE(*datetime))
- elog(WARN, "Unable to convert datetime to date", NULL);
+ elog(ABORT, "Unable to convert datetime to date", NULL);
if (DATETIME_IS_EPOCH(*datetime))
{
else
{
if (datetime2tm(*datetime, &tz, tm, &fsec, &tzn) != 0)
- elog(WARN, "Unable to convert datetime to date", NULL);
+ elog(ABORT, "Unable to convert datetime to date", NULL);
}
result = PALLOCTYPE(TimeADT);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/datum.c,v 1.7 1997/09/08 02:30:35 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/datum.c,v 1.8 1998/01/05 03:34:01 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
else
{
- elog(WARN,
+ elog(ABORT,
"datumGetSize: Error: type=%ld, byVaL with len=%d",
(long) type, len);
}
s = (struct varlena *) DatumGetPointer(value);
if (!PointerIsValid(s))
{
- elog(WARN,
+ elog(ABORT,
"datumGetSize: Invalid Datum Pointer");
}
size = (Size) VARSIZE(s);
s = (char *) palloc(realSize);
if (s == NULL)
{
- elog(WARN, "datumCopy: out of memory\n");
+ elog(ABORT, "datumCopy: out of memory\n");
}
memmove(s, DatumGetPointer(value), realSize);
res = (Datum) s;
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/dt.c,v 1.47 1997/12/23 19:26:31 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/dt.c,v 1.48 1998/01/05 03:34:03 momjian Exp $
*
*-------------------------------------------------------------------------
*/
char lowstr[MAXDATELEN + 1];
if (!PointerIsValid(str))
- elog(WARN, "Bad (null) datetime external representation", NULL);
+ elog(ABORT, "Bad (null) datetime external representation", NULL);
if ((ParseDateTime(str, lowstr, field, ftype, MAXDATEFIELDS, &nf) != 0)
|| (DecodeDateTime(field, ftype, nf, &dtype, tm, &fsec, &tz) != 0))
- elog(WARN, "Bad datetime external representation '%s'", str);
+ elog(ABORT, "Bad datetime external representation '%s'", str);
result = PALLOCTYPE(DateTime);
{
case DTK_DATE:
if (tm2datetime(tm, fsec, &tz, result) != 0)
- elog(WARN, "Datetime out of range '%s'", str);
+ elog(ABORT, "Datetime out of range '%s'", str);
#ifdef DATEDEBUG
printf("datetime_in- date is %f\n", *result);
break;
default:
- elog(WARN, "Internal coding error, can't input datetime '%s'", str);
+ elog(ABORT, "Internal coding error, can't input datetime '%s'", str);
}
return (result);
fsec = 0;
if (!PointerIsValid(str))
- elog(WARN, "Bad (null) timespan external representation", NULL);
+ elog(ABORT, "Bad (null) timespan external representation", NULL);
if ((ParseDateTime(str, lowstr, field, ftype, MAXDATEFIELDS, &nf) != 0)
|| (DecodeDateDelta(field, ftype, nf, &dtype, tm, &fsec) != 0))
- elog(WARN, "Bad timespan external representation '%s'", str);
+ elog(ABORT, "Bad timespan external representation '%s'", str);
span = PALLOCTYPE(TimeSpan);
#if FALSE
TIMESPAN_INVALID(span);
#endif
- elog(WARN, "Bad timespan external representation '%s'", str);
+ elog(ABORT, "Bad timespan external representation '%s'", str);
}
break;
default:
- elog(WARN, "Internal coding error, can't input timespan '%s'", str);
+ elog(ABORT, "Internal coding error, can't input timespan '%s'", str);
}
return (span);
return (NULL);
if (EncodeTimeSpan(tm, fsec, DateStyle, buf) != 0)
- elog(WARN, "Unable to format timespan", NULL);
+ elog(ABORT, "Unable to format timespan", NULL);
result = PALLOC(strlen(buf) + 1);
tm->tm_year, tm->tm_mon, tm->tm_mday, tm->tm_hour, tm->tm_min, tm->tm_sec);
#endif
if (tm2datetime(tm, fsec, &tz, &dt) != 0)
- elog(WARN, "Unable to add datetime and timespan", NULL);
+ elog(ABORT, "Unable to add datetime and timespan", NULL);
}
else
return NULL;
if (!PointerIsValid(result = PALLOCTYPE(TimeSpan)))
- elog(WARN, "Memory allocation failed, can't subtract timespans", NULL);
+ elog(ABORT, "Memory allocation failed, can't subtract timespans", NULL);
if (*arg2 == 0.0)
- elog(WARN, "timespan_div: divide by 0.0 error");
+ elog(ABORT, "timespan_div: divide by 0.0 error");
result->month = rint(span1->month / *arg2);
result->time = JROUND(span1->time / *arg2);
if (tm2timespan(tm, fsec, result) != 0)
{
- elog(WARN, "Unable to decode datetime", NULL);
+ elog(ABORT, "Unable to decode datetime", NULL);
}
#if FALSE
}
else
{
- elog(WARN, "Unable to decode datetime", NULL);
+ elog(ABORT, "Unable to decode datetime", NULL);
}
return (result);
{
#if FALSE
/* should return null but Postgres doesn't like that currently. - tgl 97/06/12 */
- elog(WARN, "Datetime is not finite", NULL);
+ elog(ABORT, "Datetime is not finite", NULL);
#endif
*result = 0;
break;
default:
- elog(WARN, "Datetime units '%s' not supported", lowunits);
+ elog(ABORT, "Datetime units '%s' not supported", lowunits);
result = NULL;
}
}
if (tm2datetime(tm, fsec, &tz, result) != 0)
- elog(WARN, "Unable to truncate datetime to '%s'", lowunits);
+ elog(ABORT, "Unable to truncate datetime to '%s'", lowunits);
#if FALSE
}
}
else
{
- elog(WARN, "Datetime units '%s' not recognized", lowunits);
+ elog(ABORT, "Datetime units '%s' not recognized", lowunits);
result = NULL;
}
}
if (TIMESPAN_IS_INVALID(*timespan))
{
#if FALSE
- elog(WARN, "Timespan is not finite", NULL);
+ elog(ABORT, "Timespan is not finite", NULL);
#endif
result = NULL;
break;
default:
- elog(WARN, "Timespan units '%s' not supported", lowunits);
+ elog(ABORT, "Timespan units '%s' not supported", lowunits);
result = NULL;
}
if (tm2timespan(tm, fsec, result) != 0)
- elog(WARN, "Unable to truncate timespan to '%s'", lowunits);
+ elog(ABORT, "Unable to truncate timespan to '%s'", lowunits);
}
else
}
else
{
- elog(WARN, "Timespan units '%s' not recognized", units);
+ elog(ABORT, "Timespan units '%s' not recognized", units);
result = NULL;
}
{
#if FALSE
/* should return null but Postgres doesn't like that currently. - tgl 97/06/12 */
- elog(WARN, "Datetime is not finite", NULL);
+ elog(ABORT, "Datetime is not finite", NULL);
#endif
*result = 0;
break;
default:
- elog(WARN, "Datetime units '%s' not supported", lowunits);
+ elog(ABORT, "Datetime units '%s' not supported", lowunits);
*result = 0;
}
case DTK_DOW:
if (datetime2tm(dt, &tz, tm, &fsec, &tzn) != 0)
- elog(WARN, "Unable to encode datetime", NULL);
+ elog(ABORT, "Unable to encode datetime", NULL);
*result = j2day(date2j(tm->tm_year, tm->tm_mon, tm->tm_mday));
break;
case DTK_DOY:
if (datetime2tm(dt, &tz, tm, &fsec, &tzn) != 0)
- elog(WARN, "Unable to encode datetime", NULL);
+ elog(ABORT, "Unable to encode datetime", NULL);
*result = (date2j(tm->tm_year, tm->tm_mon, tm->tm_mday)
- date2j(tm->tm_year, 1, 1) + 1);
break;
default:
- elog(WARN, "Datetime units '%s' not supported", lowunits);
+ elog(ABORT, "Datetime units '%s' not supported", lowunits);
*result = 0;
}
}
else
{
- elog(WARN, "Datetime units '%s' not recognized", lowunits);
+ elog(ABORT, "Datetime units '%s' not recognized", lowunits);
*result = 0;
}
}
if (TIMESPAN_IS_INVALID(*timespan))
{
#if FALSE
- elog(WARN, "Timespan is not finite", NULL);
+ elog(ABORT, "Timespan is not finite", NULL);
#endif
*result = 0;
break;
default:
- elog(WARN, "Timespan units '%s' not yet supported", units);
+ elog(ABORT, "Timespan units '%s' not yet supported", units);
result = NULL;
}
}
else
{
- elog(WARN, "Timespan units '%s' not recognized", units);
+ elog(ABORT, "Timespan units '%s' not recognized", units);
*result = 0;
}
* could return null but Postgres doesn't like that currently. -
* tgl 97/06/12
*/
- elog(WARN, "Datetime is not finite", NULL);
+ elog(ABORT, "Datetime is not finite", NULL);
result = NULL;
}
dt = dt2local(dt, tz);
if (datetime2tm(dt, NULL, tm, &fsec, NULL) != 0)
- elog(WARN, "Datetime not legal", NULL);
+ elog(ABORT, "Datetime not legal", NULL);
up = upzone;
lp = lowzone;
}
else
{
- elog(WARN, "Time zone '%s' not recognized", lowzone);
+ elog(ABORT, "Time zone '%s' not recognized", lowzone);
result = NULL;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/filename.c,v 1.11 1997/10/25 01:10:36 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/filename.c,v 1.12 1998/01/05 03:34:06 momjian Exp $
*
*-------------------------------------------------------------------------
*/
if ((pw = getpwnam(userName)) == NULL)
{
- elog(WARN, "User %s is not a Unix user on the db server.",
+ elog(ABORT, "User %s is not a Unix user on the db server.",
userName);
}
/* printf("name: %s\n"); */
if ((pw = getpwnam(name)) == NULL)
{
- elog(WARN, "No such user: %s\n", name);
+ elog(ABORT, "No such user: %s\n", name);
ind = 0;
}
else
}
else
{
- elog(WARN, "Couldn't find %s in your environment", environment);
+ elog(ABORT, "Couldn't find %s in your environment", environment);
}
}
else
return ((char *) NULL);
ret = (char *) palloc(strlen(s) + 1);
if (!ret)
- elog(WARN, "filename_out: palloc failed");
+ elog(ABORT, "filename_out: palloc failed");
return (strcpy(ret, s));
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/float.c,v 1.24 1997/09/26 20:32:02 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/float.c,v 1.25 1998/01/05 03:34:07 momjian Exp $
*
*-------------------------------------------------------------------------
*/
return;
#else
if (fabs(val) > FLOAT4_MAX)
- elog(WARN, "Bad float4 input format -- overflow");
+ elog(ABORT, "Bad float4 input format -- overflow");
if (val != 0.0 && fabs(val) < FLOAT4_MIN)
- elog(WARN, "Bad float4 input format -- underflow");
+ elog(ABORT, "Bad float4 input format -- underflow");
return;
#endif /* UNSAFE_FLOATS */
}
return;
#else
if (fabs(val) > FLOAT8_MAX)
- elog(WARN, "Bad float8 input format -- overflow");
+ elog(ABORT, "Bad float8 input format -- overflow");
if (val != 0.0 && fabs(val) < FLOAT8_MIN)
- elog(WARN, "Bad float8 input format -- underflow");
+ elog(ABORT, "Bad float8 input format -- underflow");
return;
#endif /* UNSAFE_FLOATS */
}
errno = 0;
val = strtod(num, &endptr);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN, "Bad float4 input format '%s'", num);
+ elog(ABORT, "Bad float4 input format '%s'", num);
/*
* if we get here, we have a legal double, still need to check to see
errno = 0;
val = strtod(num, &endptr);
if (*endptr != '\0' || errno == ERANGE)
- elog(WARN, "Bad float8 input format '%s'", num);
+ elog(ABORT, "Bad float8 input format '%s'", num);
CheckFloat8Val(val);
*result = val;
return (float32) NULL;
if (*arg2 == 0.0)
- elog(WARN, "float4div: divide by zero error");
+ elog(ABORT, "float4div: divide by zero error");
val = *arg1 / *arg2;
result = (float64) palloc(sizeof(float64data));
if (*arg2 == 0.0)
- elog(WARN, "float8div: divide by zero error");
+ elog(ABORT, "float8div: divide by zero error");
val = *arg1 / *arg2;
CheckFloat8Val(val);
int32 result;
if (!PointerIsValid(num))
- elog(WARN, "dtoi4: unable to convert null", NULL);
+ elog(ABORT, "dtoi4: unable to convert null", NULL);
if ((*num < INT_MIN) || (*num > INT_MAX))
- elog(WARN, "dtoi4: integer out of range", NULL);
+ elog(ABORT, "dtoi4: integer out of range", NULL);
result = rint(*num);
return (result);
int16 result;
if (!PointerIsValid(num))
- elog(WARN, "dtoi2: unable to convert null", NULL);
+ elog(ABORT, "dtoi2: unable to convert null", NULL);
if ((*num < SHRT_MIN) || (*num > SHRT_MAX))
- elog(WARN, "dtoi2: integer out of range", NULL);
+ elog(ABORT, "dtoi2: integer out of range", NULL);
result = rint(*num);
return (result);
int32 result;
if (!PointerIsValid(num))
- elog(WARN, "ftoi4: unable to convert null", NULL);
+ elog(ABORT, "ftoi4: unable to convert null", NULL);
if ((*num < INT_MIN) || (*num > INT_MAX))
- elog(WARN, "ftoi4: integer out of range", NULL);
+ elog(ABORT, "ftoi4: integer out of range", NULL);
result = rint(*num);
return (result);
int16 result;
if (!PointerIsValid(num))
- elog(WARN, "ftoi2: unable to convert null", NULL);
+ elog(ABORT, "ftoi2: unable to convert null", NULL);
if ((*num < SHRT_MIN) || (*num > SHRT_MAX))
- elog(WARN, "ftoi2: integer out of range", NULL);
+ elog(ABORT, "ftoi2: integer out of range", NULL);
result = rint(*num);
return (result);
#else
if (!finite(*result))
#endif
- elog(WARN, "pow() result is out of range");
+ elog(ABORT, "pow() result is out of range");
CheckFloat8Val(*result);
return (result);
#else
if (!finite(*result))
#endif
- elog(WARN, "exp() result is out of range");
+ elog(ABORT, "exp() result is out of range");
CheckFloat8Val(*result);
return (result);
tmp = *arg1;
if (tmp == 0.0)
- elog(WARN, "can't take log of zero");
+ elog(ABORT, "can't take log of zero");
if (tmp < 0)
- elog(WARN, "can't take log of a negative number");
+ elog(ABORT, "can't take log of a negative number");
*result = (float64data) log(tmp);
CheckFloat8Val(*result);
result = (float64) palloc(sizeof(float64data));
if (*arg2 == 0.0)
- elog(WARN, "float48div: divide by zero");
+ elog(ABORT, "float48div: divide by zero");
*result = *arg1 / *arg2;
CheckFloat8Val(*result);
result = (float64) palloc(sizeof(float64data));
if (*arg2 == 0.0)
- elog(WARN, "float48div: divide by zero");
+ elog(ABORT, "float48div: divide by zero");
*result = *arg1 / *arg2;
CheckFloat8Val(*result);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/geo_ops.c,v 1.26 1997/09/25 14:09:04 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/geo_ops.c,v 1.27 1998/01/05 03:34:08 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{
*cp++ = LDELIM;
if (!pair_encode(pt->x, pt->y, cp))
- elog(WARN, "Unable to format path", NULL);
+ elog(ABORT, "Unable to format path", NULL);
cp += strlen(cp);
*cp++ = RDELIM;
*cp++ = DELIM;
y;
if (!PointerIsValid(str))
- elog(WARN, " Bad (null) box external representation", NULL);
+ elog(ABORT, " Bad (null) box external representation", NULL);
if ((!path_decode(FALSE, 2, str, &isopen, &s, &(box->high)))
|| (*s != '\0'))
- elog(WARN, "Bad box external representation '%s'", str);
+ elog(ABORT, "Bad box external representation '%s'", str);
/* reorder corners if necessary... */
if (box->high.x < box->low.x)
int depth = 0;
if (!PointerIsValid(str))
- elog(WARN, "Bad (null) path external representation");
+ elog(ABORT, "Bad (null) path external representation");
if ((npts = pair_count(str, ',')) <= 0)
- elog(WARN, "Bad path external representation '%s'", str);
+ elog(ABORT, "Bad path external representation '%s'", str);
s = str;
while (isspace(*s))
if ((!path_decode(TRUE, npts, s, &isopen, &s, &(path->p[0])))
&& (!((depth == 0) && (*s == '\0'))) && !((depth >= 1) && (*s == RDELIM)))
- elog(WARN, "Bad path external representation '%s'", str);
+ elog(ABORT, "Bad path external representation '%s'", str);
path->closed = (!isopen);
char *s;
if (!PointerIsValid(str))
- elog(WARN, "Bad (null) point external representation");
+ elog(ABORT, "Bad (null) point external representation");
if (!pair_decode(str, &x, &y, &s) || (strlen(s) > 0))
- elog(WARN, "Bad point external representation '%s'", str);
+ elog(ABORT, "Bad point external representation '%s'", str);
point = PALLOCTYPE(Point);
char *s;
if (!PointerIsValid(str))
- elog(WARN, " Bad (null) lseg external representation", NULL);
+ elog(ABORT, " Bad (null) lseg external representation", NULL);
lseg = PALLOCTYPE(LSEG);
if ((!path_decode(TRUE, 2, str, &isopen, &s, &(lseg->p[0])))
|| (*s != '\0'))
- elog(WARN, "Bad lseg external representation '%s'", str);
+ elog(ABORT, "Bad lseg external representation '%s'", str);
lseg->m = point_sl(&lseg->p[0], &lseg->p[1]);
LSEG seg;
if (!PointerIsValid(circle) || !PointerIsValid(poly))
- elog(WARN, "Invalid (null) input for distance", NULL);
+ elog(ABORT, "Invalid (null) input for distance", NULL);
if (point_inside(&(circle->center), poly->npts, poly->p))
{
close_pb(Point *pt, BOX *box)
{
/* think about this one for a while */
- elog(WARN, "close_pb not implemented", NULL);
+ elog(ABORT, "close_pb not implemented", NULL);
return (NULL);
}
close_sb(LSEG *lseg, BOX *box)
{
/* think about this one for a while */
- elog(WARN, "close_sb not implemented", NULL);
+ elog(ABORT, "close_sb not implemented", NULL);
return (NULL);
}
close_lb(LINE *line, BOX *box)
{
/* think about this one for a while */
- elog(WARN, "close_lb not implemented", NULL);
+ elog(ABORT, "close_lb not implemented", NULL);
return (NULL);
}
}
else
{
- elog(WARN, "Unable to create bounding box for empty polygon", NULL);
+ elog(ABORT, "Unable to create bounding box for empty polygon", NULL);
}
}
char *s;
if (!PointerIsValid(str))
- elog(WARN, " Bad (null) polygon external representation");
+ elog(ABORT, " Bad (null) polygon external representation");
if ((npts = pair_count(str, ',')) <= 0)
- elog(WARN, "Bad polygon external representation '%s'", str);
+ elog(ABORT, "Bad polygon external representation '%s'", str);
size = offsetof(POLYGON, p[0]) +(sizeof(poly->p[0]) * npts);
poly = PALLOC(size);
if ((!path_decode(FALSE, npts, str, &isopen, &s, &(poly->p[0])))
|| (*s != '\0'))
- elog(WARN, "Bad polygon external representation '%s'", str);
+ elog(ABORT, "Bad polygon external representation '%s'", str);
make_bound_box(poly);
div = (p2->x * p2->x) + (p2->y * p2->y);
if (div == 0.0)
- elog(WARN, "point_div: divide by 0.0 error");
+ elog(ABORT, "point_div: divide by 0.0 error");
result->x = ((p1->x * p2->x) + (p1->y * p2->y)) / div;
result->y = ((p2->x * p1->y) - (p2->y * p1->x)) / div;
if (!PointerIsValid(path))
return (NULL);
- elog(WARN, "path_center not implemented", NULL);
+ elog(ABORT, "path_center not implemented", NULL);
result = PALLOCTYPE(Point);
result = NULL;
return (NULL);
if (!path->closed)
- elog(WARN, "Open path cannot be converted to polygon", NULL);
+ elog(ABORT, "Open path cannot be converted to polygon", NULL);
size = offsetof(POLYGON, p[0]) +(sizeof(poly->p[0]) * path->npts);
poly = PALLOC(size);
return (NULL);
if (!isoldpath(path))
- elog(WARN, "upgradepath: path already upgraded?", NULL);
+ elog(ABORT, "upgradepath: path already upgraded?", NULL);
npts = (path->npts - 1);
size = offsetof(PATH, p[0]) +(sizeof(path->p[0]) * npts);
int depth = 0;
if (!PointerIsValid(str))
- elog(WARN, " Bad (null) circle external representation", NULL);
+ elog(ABORT, " Bad (null) circle external representation", NULL);
circle = PALLOCTYPE(CIRCLE);
}
if (!pair_decode(s, &circle->center.x, &circle->center.y, &s))
- elog(WARN, "Bad circle external representation '%s'", str);
+ elog(ABORT, "Bad circle external representation '%s'", str);
if (*s == DELIM)
s++;
s++;
if ((!single_decode(s, &circle->radius, &s)) || (circle->radius < 0))
- elog(WARN, "Bad circle external representation '%s'", str);
+ elog(ABORT, "Bad circle external representation '%s'", str);
while (depth > 0)
{
}
else
{
- elog(WARN, "Bad circle external representation '%s'", str);
+ elog(ABORT, "Bad circle external representation '%s'", str);
}
}
if (*s != '\0')
- elog(WARN, "Bad circle external representation '%s'", str);
+ elog(ABORT, "Bad circle external representation '%s'", str);
return (circle);
} /* circle_in() */
*cp++ = LDELIM_C;
*cp++ = LDELIM;
if (!pair_encode(circle->center.x, circle->center.y, cp))
- elog(WARN, "Unable to format circle", NULL);
+ elog(ABORT, "Unable to format circle", NULL);
cp += strlen(cp);
*cp++ = RDELIM;
*cp++ = DELIM;
if (!single_encode(circle->radius, cp))
- elog(WARN, "Unable to format circle", NULL);
+ elog(ABORT, "Unable to format circle", NULL);
cp += strlen(cp);
*cp++ = RDELIM_C;
return (NULL);
if (FPzero(circle->radius) || (npts < 2))
- elog(WARN, "Unable to convert circle to polygon", NULL);
+ elog(ABORT, "Unable to convert circle to polygon", NULL);
size = offsetof(POLYGON, p[0]) +(sizeof(poly->p[0]) * npts);
poly = PALLOC(size);
return (NULL);
if (poly->npts < 2)
- elog(WARN, "Unable to convert polygon to circle", NULL);
+ elog(ABORT, "Unable to convert polygon to circle", NULL);
circle = PALLOCTYPE(CIRCLE);
circle->radius /= poly->npts;
if (FPzero(circle->radius))
- elog(WARN, "Unable to convert polygon to circle", NULL);
+ elog(ABORT, "Unable to convert polygon to circle", NULL);
return (circle);
} /* poly_circle() */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.10 1997/11/17 16:24:17 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.11 1998/01/05 03:34:09 momjian Exp $
*
*-------------------------------------------------------------------------
*/
i4toi2(int32 arg1)
{
if (arg1 < SHRT_MIN)
- elog(WARN, "i4toi2: '%d' causes int2 underflow", arg1);
+ elog(ABORT, "i4toi2: '%d' causes int2 underflow", arg1);
if (arg1 > SHRT_MAX)
- elog(WARN, "i4toi2: '%d' causes int2 overflow", arg1);
+ elog(ABORT, "i4toi2: '%d' causes int2 overflow", arg1);
return ((int16) arg1);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/nabstime.c,v 1.36 1997/10/30 14:06:47 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/nabstime.c,v 1.37 1998/01/05 03:34:11 momjian Exp $
*
*-------------------------------------------------------------------------
*/
ftype[MAXDATEFIELDS];
if (!PointerIsValid(str))
- elog(WARN, "Bad (null) abstime external representation", NULL);
+ elog(ABORT, "Bad (null) abstime external representation", NULL);
if (strlen(str) > MAXDATELEN)
- elog(WARN, "Bad (length) abstime external representation '%s'", str);
+ elog(ABORT, "Bad (length) abstime external representation '%s'", str);
if ((ParseDateTime(str, lowstr, field, ftype, MAXDATEFIELDS, &nf) != 0)
|| (DecodeDateTime(field, ftype, nf, &dtype, tm, &fsec, &tz) != 0))
- elog(WARN, "Bad abstime external representation '%s'", str);
+ elog(ABORT, "Bad abstime external representation '%s'", str);
#ifdef DATEDEBUG
printf("nabstimein- %d fields are type %d (DTK_DATE=%d)\n", nf, dtype, DTK_DATE);
break;
default:
- elog(WARN, "Bad abstime (internal coding error) '%s'", str);
+ elog(ABORT, "Bad abstime (internal coding error) '%s'", str);
result = INVALID_ABSTIME;
break;
};
DateTime *result;
if (!PointerIsValid(result = PALLOCTYPE(DateTime)))
- elog(WARN, "Unable to allocate space to convert abstime to datetime", NULL);
+ elog(ABORT, "Unable to allocate space to convert abstime to datetime", NULL);
switch (abstime)
{
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.19 1997/12/20 00:10:29 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.20 1998/01/05 03:34:12 momjian Exp $
*
*-------------------------------------------------------------------------
*/
errno = 0;
l = strtol(s, &badp, 10);
if (errno) /* strtol must set ERANGE */
- elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
+ elog(ABORT, "pg_atoi: error reading \"%s\": %m", s);
if (badp && *badp && (*badp != c))
- elog(WARN, "pg_atoi: error in \"%s\": can\'t parse \"%s\"", s, badp);
+ elog(ABORT, "pg_atoi: error in \"%s\": can\'t parse \"%s\"", s, badp);
switch (size)
{
if (l < INT_MIN)
{
errno = ERANGE;
- elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
+ elog(ABORT, "pg_atoi: error reading \"%s\": %m", s);
}
if (l > INT_MAX)
{
errno = ERANGE;
- elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
+ elog(ABORT, "pg_atoi: error reading \"%s\": %m", s);
}
#endif /* HAS_LONG_LONG */
break;
if (l < SHRT_MIN)
{
errno = ERANGE;
- elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
+ elog(ABORT, "pg_atoi: error reading \"%s\": %m", s);
}
if (l > SHRT_MAX)
{
errno = ERANGE;
- elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
+ elog(ABORT, "pg_atoi: error reading \"%s\": %m", s);
}
break;
case sizeof(int8):
if (l < SCHAR_MIN)
{
errno = ERANGE;
- elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
+ elog(ABORT, "pg_atoi: error reading \"%s\": %m", s);
}
if (l > SCHAR_MAX)
{
errno = ERANGE;
- elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
+ elog(ABORT, "pg_atoi: error reading \"%s\": %m", s);
}
break;
default:
- elog(WARN, "pg_atoi: invalid result size: %d", size);
+ elog(ABORT, "pg_atoi: invalid result size: %d", size);
}
return ((int32) l);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/oidname.c,v 1.9 1997/10/25 01:10:41 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/oidname.c,v 1.10 1998/01/05 03:34:13 momjian Exp $
*
*-------------------------------------------------------------------------
*/
StrNCpy(oc->name.data, inptr, NAMEDATALEN);
}
else
- elog(WARN, "Bad input data for type oidname");
+ elog(ABORT, "Bad input data for type oidname");
return oc;
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/regexp.c,v 1.11 1997/10/25 01:10:44 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/regexp.c,v 1.12 1998/01/05 03:34:14 momjian Exp $
*
* Alistair Crooks added the code for the regex caching
* agc - cached the regular expressions used - there's a good chance
rev[oldest].cre_s = (char *) NULL;
pg95_regerror(regcomp_result, &rev[oldest].cre_re, errMsg,
sizeof(errMsg));
- elog(WARN, "regcomp failed with error %s", errMsg);
+ elog(ABORT, "regcomp failed with error %s", errMsg);
}
/* not reached */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/regproc.c,v 1.10 1997/11/20 23:23:00 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/regproc.c,v 1.11 1998/01/05 03:34:14 momjian Exp $
*
*-------------------------------------------------------------------------
*/
proc = heap_openr(ProcedureRelationName);
if (!RelationIsValid(proc))
{
- elog(WARN, "regprocin: could not open %s",
+ elog(ABORT, "regprocin: could not open %s",
ProcedureRelationName);
return (0);
}
if (!HeapScanIsValid(procscan))
{
heap_close(proc);
- elog(WARN, "regprocin: could not being scan of %s",
+ elog(ABORT, "regprocin: could not being scan of %s",
ProcedureRelationName);
return (0);
}
proc = heap_openr(ProcedureRelationName);
if (!RelationIsValid(proc))
{
- elog(WARN, "regprocout: could not open %s",
+ elog(ABORT, "regprocout: could not open %s",
ProcedureRelationName);
return (0);
}
if (!HeapScanIsValid(procscan))
{
heap_close(proc);
- elog(WARN, "regprocout: could not being scan of %s",
+ elog(ABORT, "regprocout: could not being scan of %s",
ProcedureRelationName);
return (0);
}
type = heap_openr(TypeRelationName);
if (!RelationIsValid(type))
{
- elog(WARN, "int8typeout: could not open %s",
+ elog(ABORT, "int8typeout: could not open %s",
TypeRelationName);
return (0);
}
if (!HeapScanIsValid(typescan))
{
heap_close(type);
- elog(WARN, "int8typeout: could not being scan of %s",
+ elog(ABORT, "int8typeout: could not being scan of %s",
TypeRelationName);
return (0);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/selfuncs.c,v 1.12 1997/11/24 05:09:03 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/selfuncs.c,v 1.13 1998/01/05 03:34:16 momjian Exp $
*
*-------------------------------------------------------------------------
*/
0, 0);
if (!HeapTupleIsValid(atp))
{
- elog(WARN, "getattdisbursion: no attribute tuple %d %d",
+ elog(ABORT, "getattdisbursion: no attribute tuple %d %d",
relid, attnum);
return (0);
}
*/
if (!HeapTupleIsValid(atp))
{
- elog(WARN, "getattdisbursion: no relation tuple %d", relid);
+ elog(ABORT, "getattdisbursion: no relation tuple %d", relid);
return (0);
}
ntuples = ((Form_pg_class) GETSTRUCT(atp))->reltuples;
*low = "n";
/*
- * XXX elog(WARN, "gethilokey: statistic tuple not
+ * XXX elog(ABORT, "gethilokey: statistic tuple not
* found");
*/
return;
}
if (!PointerIsValid(result))
- elog(WARN, "Btree Selectivity: bad pointer");
+ elog(ABORT, "Btree Selectivity: bad pointer");
if (*result < 0.0 || *result > 1.0)
- elog(WARN, "Btree Selectivity: bad value %lf", *result);
+ elog(ABORT, "Btree Selectivity: bad value %lf", *result);
return (result);
}
0, 0, 0);
if (!HeapTupleIsValid(atp))
{
- elog(WARN, "btreenpage: no index tuple %d", indexrelid);
+ elog(ABORT, "btreenpage: no index tuple %d", indexrelid);
return (0);
}
0, 0, 0);
if (!HeapTupleIsValid(atp))
{
- elog(WARN, "hashsel: no index tuple %d", indexrelid);
+ elog(ABORT, "hashsel: no index tuple %d", indexrelid);
return (0);
}
ntuples = ((Form_pg_class) GETSTRUCT(atp))->reltuples;
}
if (!PointerIsValid(result))
- elog(WARN, "Hash Table Selectivity: bad pointer");
+ elog(ABORT, "Hash Table Selectivity: bad pointer");
if (*result < 0.0 || *result > 1.0)
- elog(WARN, "Hash Table Selectivity: bad value %lf", *result);
+ elog(ABORT, "Hash Table Selectivity: bad value %lf", *result);
return (result);
0, 0, 0);
if (!HeapTupleIsValid(atp))
{
- elog(WARN, "hashsel: no index tuple %d", indexrelid);
+ elog(ABORT, "hashsel: no index tuple %d", indexrelid);
return (0);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/sets.c,v 1.9 1997/11/24 05:09:04 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/sets.c,v 1.10 1998/01/05 03:34:16 momjian Exp $
*
*-------------------------------------------------------------------------
*/
ObjectIdGetDatum(setoid),
0, 0, 0);
if (!HeapTupleIsValid(tup))
- elog(WARN, "setin: unable to define set %s", querystr);
+ elog(ABORT, "setin: unable to define set %s", querystr);
/*
* We can tell whether the set was already defined by checking the
setoid = newtup->t_oid;
}
else
- elog(WARN, "setin: could not find new set oid tuple");
+ elog(ABORT, "setin: could not find new set oid tuple");
heap_endscan(pg_proc_scan);
if (RelationGetRelationTupleForm(procrel)->relhasindex)
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/varchar.c,v 1.14 1997/12/23 19:24:43 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/varchar.c,v 1.15 1998/01/05 03:34:19 momjian Exp $
*
*-------------------------------------------------------------------------
*/
}
if (len > 4096)
- elog(WARN, "bpcharin: length of char() must be less than 4096");
+ elog(ABORT, "bpcharin: length of char() must be less than 4096");
result = (char *) palloc(typlen);
*(int32 *) result = typlen;
}
if (len > 4096)
- elog(WARN, "varcharin: length of char() must be less than 4096");
+ elog(ABORT, "varcharin: length of char() must be less than 4096");
result = (char *) palloc(typlen);
*(int32 *) result = typlen;
bpcharlen(char *arg)
{
if (!PointerIsValid(arg))
- elog(WARN, "Bad (null) char() external representation", NULL);
+ elog(ABORT, "Bad (null) char() external representation", NULL);
return(bcTruelen(arg));
} /* bpcharlen() */
varcharlen(char *arg)
{
if (!PointerIsValid(arg))
- elog(WARN, "Bad (null) varchar() external representation", NULL);
+ elog(ABORT, "Bad (null) varchar() external representation", NULL);
return(vcTruelen(arg));
} /* vclen() */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.26 1998/01/01 05:50:50 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.27 1998/01/05 03:34:20 momjian Exp $
*
*-------------------------------------------------------------------------
*/
*
* Non-printable characters must be passed as '\nnn' (octal) and are
* converted to internal form. '\' must be passed as '\\'.
- * elog(WARN, ...) if bad form.
+ * elog(ABORT, ...) if bad form.
*
* BUGS:
* The input is scaned twice.
text *result;
if (inputText == NULL)
- elog(WARN, "Bad input string for type bytea");
+ elog(ABORT, "Bad input string for type bytea");
for (byte = 0, tp = inputText; *tp != '\0'; byte++)
if (*tp++ == '\\')
else if (!isdigit(*tp++) ||
!isdigit(*tp++) ||
!isdigit(*tp++))
- elog(WARN, "Bad input string for type bytea");
+ elog(ABORT, "Bad input string for type bytea");
}
tp = inputText;
byte += VARHDRSZ;
textlen(text *t)
{
if (!PointerIsValid(t))
- elog(WARN,"Null input to textlen");
+ elog(ABORT,"Null input to textlen");
return (VARSIZE(t) - VARHDRSZ);
} /* textlen() */
if (n >= len)
{
- elog(WARN, "byteaGetByte: index (=%d) out of range [0..%d]",
+ elog(ABORT, "byteaGetByte: index (=%d) out of range [0..%d]",
n, len - 1);
}
if (n >= len)
{
- elog(WARN,
+ elog(ABORT,
"byteaSetByte: index (=%d) out of range [0..%d]",
n, len - 1);
}
res = (text *) palloc(VARSIZE(v));
if (res == NULL)
{
- elog(WARN, "byteaSetByte: Out of memory (%d bytes requested)",
+ elog(ABORT, "byteaSetByte: Out of memory (%d bytes requested)",
VARSIZE(v));
}
memmove((char *) res, (char *) v, VARSIZE(v));
*/
if (newBit != 0 && newBit != 1)
{
- elog(WARN, "byteaSetByte: new bit must be 0 or 1");
+ elog(ABORT, "byteaSetByte: new bit must be 0 or 1");
}
/*
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.18 1997/11/24 05:09:09 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.19 1998/01/05 03:34:22 momjian Exp $
*
* Notes:
* XXX This needs to use exception.h to handle recovery when
CACHE1_elog(DEBUG, "ResetSystemCache called");
if (DisableCache)
{
- elog(WARN, "ResetSystemCache: Called while cache disabled");
+ elog(ABORT, "ResetSystemCache: Called while cache disabled");
return;
}
nextelt = DLGetSucc(elt);
CatCacheRemoveCTup(cache, elt);
if (cache->cc_ntup == -1)
- elog(WARN, "ResetSystemCache: cc_ntup<0 (software error)");
+ elog(ABORT, "ResetSystemCache: cc_ntup<0 (software error)");
}
}
cache->cc_ntup = 0; /* in case of WARN error above */
if (DisableCache)
{
- elog(WARN, "SearchSysCache: Called while cache disabled");
+ elog(ABORT, "SearchSysCache: Called while cache disabled");
return ((HeapTuple) NULL);
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/fcache.c,v 1.7 1997/09/08 21:48:49 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/fcache.c,v 1.8 1998/01/05 03:34:24 momjian Exp $
*
*-------------------------------------------------------------------------
*/
tup = SearchSysCacheTuple(TYPNAME, PointerGetDatum(relname),
0, 0, 0);
if (!tup)
- elog(WARN, "Lookup failed on type tuple for class %s",
+ elog(ABORT, "Lookup failed on type tuple for class %s",
relname);
return tup->t_oid;
retval = (FunctionCachePtr) palloc(sizeof(FunctionCache));
if (!use_syscache)
- elog(WARN, "what the ????, init the fcache without the catalogs?");
+ elog(ABORT, "what the ????, init the fcache without the catalogs?");
procedureTuple = SearchSysCacheTuple(PROOID,
ObjectIdGetDatum(foid),
0, 0, 0);
if (!HeapTupleIsValid(procedureTuple))
- elog(WARN,
+ elog(ABORT,
"init_fcache: %s %d",
"Cache lookup failed for procedure", foid);
0, 0, 0);
if (!HeapTupleIsValid(typeTuple))
- elog(WARN,
+ elog(ABORT,
"init_fcache: %s %d",
"Cache lookup failed for type",
(procedureStruct)->prorettype);
}
else
{
- elog(WARN, "init_fcache: node must be Oper or Func!");
+ elog(ABORT, "init_fcache: node must be Oper or Func!");
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/lsyscache.c,v 1.7 1997/11/17 16:59:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/lsyscache.c,v 1.8 1998/01/05 03:34:26 momjian Exp $
*
* NOTES
* Eventually, the index information should go through here, too.
PointerGetDatum(attname),
0, 0);
if (!HeapTupleIsValid(htup))
- elog(WARN, "get_attisset: no attribute %s in relation %d",
+ elog(ABORT, "get_attisset: no attribute %s in relation %d",
attname, relid);
if (heap_attisnull(htup, attno))
return (false);
return (pstrdup(optup.oprname.data));
else
{
- elog(WARN, "can't look up operator %d\n", opno);
+ elog(ABORT, "can't look up operator %d\n", opno);
return NULL;
}
}
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.30 1997/11/21 18:11:26 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.31 1998/01/05 03:34:29 momjian Exp $
*
*-------------------------------------------------------------------------
*/
break;
default:
- elog(WARN, "ScanPgRelation: bad buildinfo");
+ elog(ABORT, "ScanPgRelation: bad buildinfo");
return NULL;
}
break;
default:
- elog(WARN, "ScanPgRelation: bad buildinfo");
+ elog(ABORT, "ScanPgRelation: bad buildinfo");
/*
* XXX I hope this is right. It seems better than returning
}
if (need > 0)
- elog(WARN, "catalog is missing %d attribute%s for relid %d",
+ elog(ABORT, "catalog is missing %d attribute%s for relid %d",
need, (need == 1 ? "" : "s"), relation->rd_id);
/* ----------------
atttup = (HeapTuple) AttributeNumIndexScan(attrel, relation->rd_id, i);
if (!HeapTupleIsValid(atttup))
- elog(WARN, "cannot find attribute %d of relation %.*s", i,
+ elog(ABORT, "cannot find attribute %d of relation %.*s", i,
NAMEDATALEN, &(relation->rd_rel->relname.data[0]));
attp = (AttributeTupleForm) GETSTRUCT(atttup);
if (adform->adnum != attrdef[i].adnum)
continue;
if (attrdef[i].adsrc != NULL)
- elog(WARN, "AttrDefaultFetch: second record found for attr %.*s in rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: second record found for attr %.*s in rel %.*s",
NAMEDATALEN, relation->rd_att->attrs[adform->adnum - 1]->attname.data,
NAMEDATALEN, relation->rd_rel->relname.data);
Anum_pg_attrdef_adbin,
adrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "AttrDefaultFetch: adbin IS NULL for attr %.*s in rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: adbin IS NULL for attr %.*s in rel %.*s",
NAMEDATALEN, relation->rd_att->attrs[adform->adnum - 1]->attname.data,
NAMEDATALEN, relation->rd_rel->relname.data);
attrdef[i].adbin = textout(val);
Anum_pg_attrdef_adsrc,
adrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "AttrDefaultFetch: adsrc IS NULL for attr %.*s in rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: adsrc IS NULL for attr %.*s in rel %.*s",
NAMEDATALEN, relation->rd_att->attrs[adform->adnum - 1]->attname.data,
NAMEDATALEN, relation->rd_rel->relname.data);
attrdef[i].adsrc = textout(val);
}
if (i >= ndef)
- elog(WARN, "AttrDefaultFetch: unexpected record found for attr %d in rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: unexpected record found for attr %d in rel %.*s",
adform->adnum,
NAMEDATALEN, relation->rd_rel->relname.data);
ReleaseBuffer(buffer);
}
if (found < ndef)
- elog(WARN, "AttrDefaultFetch: %d record not found for rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: %d record not found for rel %.*s",
ndef - found,
NAMEDATALEN, relation->rd_rel->relname.data);
if (!HeapTupleIsValid(tuple))
continue;
if (found == ncheck)
- elog(WARN, "RelCheckFetch: unexpected record found for rel %.*s",
+ elog(ABORT, "RelCheckFetch: unexpected record found for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
rcname = (Name) fastgetattr(tuple,
Anum_pg_relcheck_rcname,
rcrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "RelCheckFetch: rcname IS NULL for rel %.*s",
+ elog(ABORT, "RelCheckFetch: rcname IS NULL for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
check[found].ccname = nameout(rcname);
val = (struct varlena *) fastgetattr(tuple,
Anum_pg_relcheck_rcbin,
rcrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "RelCheckFetch: rcbin IS NULL for rel %.*s",
+ elog(ABORT, "RelCheckFetch: rcbin IS NULL for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
check[found].ccbin = textout(val);
val = (struct varlena *) fastgetattr(tuple,
Anum_pg_relcheck_rcsrc,
rcrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "RelCheckFetch: rcsrc IS NULL for rel %.*s",
+ elog(ABORT, "RelCheckFetch: rcsrc IS NULL for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
check[found].ccsrc = textout(val);
found++;
}
if (found < ncheck)
- elog(WARN, "RelCheckFetch: %d record not found for rel %.*s",
+ elog(ABORT, "RelCheckFetch: %d record not found for rel %.*s",
ncheck - found,
NAMEDATALEN, relation->rd_rel->relname.data);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/syscache.c,v 1.10 1997/10/28 15:03:06 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/syscache.c,v 1.11 1998/01/05 03:34:32 momjian Exp $
*
* NOTES
* These routines allow the parser/planner/executor to perform
cacheinfo[cacheId].iScanFunc);
if (!PointerIsValid((char *) SysCache[cacheId]))
{
- elog(WARN,
+ elog(ABORT,
"InitCatalogCache: Can't init cache %.16s(%d)",
cacheinfo[cacheId].name,
cacheId);
if (cacheId < 0 || cacheId >= SysCacheSize)
{
- elog(WARN, "SearchSysCacheTuple: Bad cache id %d", cacheId);
+ elog(ABORT, "SearchSysCacheTuple: Bad cache id %d", cacheId);
return ((HeapTuple) NULL);
}
cacheinfo[cacheId].iScanFunc);
if (!PointerIsValid(SysCache[cacheId]))
{
- elog(WARN,
+ elog(ABORT,
"InitCatalogCache: Can't init cache %.16s(%d)",
cacheinfo[cacheId].name,
cacheId);
if (!PointerIsValid(returnStruct))
{
- elog(WARN, "SearchSysCacheStruct: No receiving struct");
+ elog(ABORT, "SearchSysCacheStruct: No receiving struct");
return (0);
}
tp = SearchSysCacheTuple(cacheId, key1, key2, key3, key4);
}
else
{
- elog(WARN,
+ elog(ABORT,
"SearchSysCacheGetAttribute: Bad attr # %d in %s(%d)",
attributeNumber, cacheName, cacheId);
return (NULL);
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/error/elog.c,v 1.20 1997/11/09 04:43:35 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/error/elog.c,v 1.21 1998/01/05 03:34:36 momjian Exp $
*
*-------------------------------------------------------------------------
*/
i = 0;
if (i > 30)
i = i % 30;
- cp = "DEBUG:";
+ cp = "DEBUG: ";
break;
case DEBUG:
i = ElogDebugIndentLevel;
}
#endif /* !PG_STANDALONE */
- if (lev == WARN)
+ if (lev == ERROR || lev == ABORT)
{
- extern int InWarn;
+ extern int InErrorOrAbort;
ProcReleaseSpins(NULL); /* get rid of spinlocks we hold */
- if (!InWarn)
+ if (!InErrorOrAbort)
{
kill(getpid(), 1); /* abort to traffic cop */
pause();
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/fmgr/dfmgr.c,v 1.14 1997/12/20 00:10:42 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/fmgr/dfmgr.c,v 1.15 1998/01/05 03:34:41 momjian Exp $
*
*-------------------------------------------------------------------------
*/
0, 0, 0);
if (!HeapTupleIsValid(procedureTuple))
{
- elog(WARN, "fmgr: Cache lookup failed for procedure %d\n",
+ elog(ABORT, "fmgr: Cache lookup failed for procedure %d\n",
procedureId);
return ((func_ptr) NULL);
}
rdesc = heap_openr(ProcedureRelationName);
if (!RelationIsValid(rdesc))
{
- elog(WARN, "fmgr: Could not open relation %s",
+ elog(ABORT, "fmgr: Could not open relation %s",
ProcedureRelationName);
return ((func_ptr) NULL);
}
if (!PointerIsValid(probinattr) /* || isnull */ )
{
heap_close(rdesc);
- elog(WARN, "fmgr: Could not extract probin for %d from %s",
+ elog(ABORT, "fmgr: Could not extract probin for %d from %s",
procedureId, ProcedureRelationName);
return ((func_ptr) NULL);
}
{
if (stat(filename, &stat_buf) == -1)
{
- elog(WARN, "stat failed on file %s", filename);
+ elog(ABORT, "stat failed on file %s", filename);
}
for (file_scanner = file_list;
}
free((char *) file_scanner);
- elog(WARN, "Load of file %s failed: %s", filename, load_error);
+ elog(ABORT, "Load of file %s failed: %s", filename, load_error);
}
/*
if (retval == (func_ptr) NULL)
{
- elog(WARN, "Can't find function %s in file %s", funcname, filename);
+ elog(ABORT, "Can't find function %s in file %s", funcname, filename);
}
return (retval);
if (stat(filename, &stat_buf) == -1)
{
- elog(WARN, "stat failed on file %s", filename);
+ elog(ABORT, "stat failed on file %s", filename);
}
if (file_list != (DynamicFileList *) NULL
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/fmgr/fmgr.c,v 1.7 1997/10/28 15:05:32 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/fmgr/fmgr.c,v 1.8 1998/01/05 03:34:44 momjian Exp $
*
*-------------------------------------------------------------------------
*/
0, 0, 0);
if (!HeapTupleIsValid(procedureTuple))
{
- elog(WARN, "fmgr_pl(): Cache lookup of procedure %ld failed.",
+ elog(ABORT, "fmgr_pl(): Cache lookup of procedure %ld failed.",
ObjectIdGetDatum(func_id));
}
procedureStruct = (Form_pg_proc) GETSTRUCT(procedureTuple);
0, 0, 0);
if (!HeapTupleIsValid(languageTuple))
{
- elog(WARN, "fmgr_pl(): Cache lookup of language %ld for procedure %ld failed.",
+ elog(ABORT, "fmgr_pl(): Cache lookup of language %ld for procedure %ld failed.",
ObjectIdGetDatum(procedureStruct->prolang),
ObjectIdGetDatum(func_id));
}
fmgr_info(languageStruct->lanplcallfoid, &plcall_fn, &plcall_nargs);
if (plcall_fn == NULL)
{
- elog(WARN, "fmgr_pl(): failed to load PL handler for procedure %ld.",
+ elog(ABORT, "fmgr_pl(): failed to load PL handler for procedure %ld.",
ObjectIdGetDatum(func_id));
}
values->data[8]);
break;
default:
- elog(WARN, "fmgr_c: function %d: too many arguments (%d > %d)",
+ elog(ABORT, "fmgr_c: function %d: too many arguments (%d > %d)",
func_id, n_arguments, MAXFMGRARGS);
break;
}
0, 0, 0);
if (!HeapTupleIsValid(procedureTuple))
{
- elog(WARN, "fmgr_info: function %d: cache lookup failed\n",
+ elog(ABORT, "fmgr_info: function %d: cache lookup failed\n",
procedureId);
}
procedureStruct = (FormData_pg_proc *)
case INTERNALlanguageId:
user_fn = fmgr_lookupByName(procedureStruct->proname.data);
if (!user_fn)
- elog(WARN, "fmgr_info: function %s: not in internal table",
+ elog(ABORT, "fmgr_info: function %s: not in internal table",
procedureStruct->proname.data);
break;
case ClanguageId:
0, 0, 0);
if (!HeapTupleIsValid(languageTuple))
{
- elog(WARN, "fmgr_info: %s %ld",
+ elog(ABORT, "fmgr_info: %s %ld",
"Cache lookup for language %d failed",
ObjectIdGetDatum(procedureStruct->prolang));
}
}
else
{
- elog(WARN, "fmgr_info: function %d: unknown language %d",
+ elog(ABORT, "fmgr_info: function %d: unknown language %d",
procedureId, language);
}
break;
if (pronargs > MAXFMGRARGS)
{
- elog(WARN, "fmgr: function %d: too many arguments (%d > %d)",
+ elog(ABORT, "fmgr: function %d: too many arguments (%d > %d)",
procedureId, pronargs, MAXFMGRARGS);
}
for (i = 0; i < pronargs; ++i)
n_arguments = va_arg(pvar, int);
if (n_arguments > MAXFMGRARGS)
{
- elog(WARN, "fmgr_ptr: function %d: too many arguments (%d > %d)",
+ elog(ABORT, "fmgr_ptr: function %d: too many arguments (%d > %d)",
func_id, n_arguments, MAXFMGRARGS);
}
for (i = 0; i < n_arguments; ++i)
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/misc/Attic/database.c,v 1.3 1997/11/20 23:23:16 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/misc/Attic/database.c,v 1.4 1998/01/05 03:34:49 momjian Exp $
*
*-------------------------------------------------------------------------
*/
scan = heap_beginscan(dbrel, 0, false, 1, &scanKey);
if (!HeapScanIsValid(scan))
- elog(WARN, "GetDatabaseInfo: cannot begin scan of %s", DatabaseRelationName);
+ elog(ABORT, "GetDatabaseInfo: cannot begin scan of %s", DatabaseRelationName);
/*
* Since we're going to close the relation, copy the tuple.
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/sort/Attic/psort.c,v 1.28 1997/11/24 05:09:21 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/sort/Attic/psort.c,v 1.29 1998/01/05 03:34:56 momjian Exp $
*
* NOTES
* Sorts the first relation into the second relation.
PS(node)->Tape[0].tp_prev = tp;
if (PS(node)->TapeRange <= 1)
- elog(WARN, "inittapes: Could only allocate %d < 3 tapes\n",
+ elog(ABORT, "inittapes: Could only allocate %d < 3 tapes\n",
PS(node)->TapeRange + 1);
PS(node)->Level = 1;
file = AllocateFile(tp->tl_name, "w+");
if (file == NULL)
- elog(WARN, "Open: %s in %s line %d, %s", tp->tl_name,
+ elog(ABORT, "Open: %s in %s line %d, %s", tp->tl_name,
__FILE__, __LINE__, strerror(errno));
tp->tl_fd = fileno(file);
for (tp = Tapes; tp != NULL && tp->tl_fd != fd; tp = tp->tl_next)
;
if (tp == NULL)
- elog(WARN, "resettape: tape not found");
+ elog(ABORT, "resettape: tape not found");
file = freopen(tp->tl_name, "w+", file);
if (file == NULL)
*
* Copyright (c) 1994, Regents of the University of California
*
- * $Id: elog.h,v 1.5 1997/09/08 02:39:39 momjian Exp $
+ * $Id: elog.h,v 1.6 1998/01/05 03:35:05 momjian Exp $
*
*-------------------------------------------------------------------------
*/
#define ELOG_H
#define NOTICE 0 /* random info - no special action */
-#define WARN -1 /* Warning error - return to known state */
+#define ERROR -2 /* user error - return to known state */
+#define ABORT -1 /* system error - return to known state */
#define FATAL 1 /* Fatal error - abort process */
-#define DEBUG -2 /* debug message */
-#define NOIND -3 /* debug message, don't indent as far */
+#define DEBUG -3 /* debug message */
+#define NOIND -4 /* debug message, don't indent as far */
+#ifdef NOT_USED
#define PTIME 0x100 /* prepend time to message */
#define POS 0x200 /* prepend source position to message */
#define USERMSG 0x400 /* send message to user */
#define TERM 0x800 /* send message to terminal */
#define DBLOG 0x1000 /* put message in per db log */
#define SLOG 0x2000 /* put message in system log */
-#define ABORT 0x4000 /* abort process after logging */
+#define ABORTX 0x4000 /* abort process after logging */
+#endif
#define ELOG_MAXLEN 4096
QUERY: INSERT INTO ABSTIME_TBL (f1) VALUES ('-infinity'::abstime);
QUERY: INSERT INTO ABSTIME_TBL (f1) VALUES ('May 10, 1947 23:59:12');
QUERY: INSERT INTO ABSTIME_TBL (f1) VALUES ('Feb 35, 1946 10:00:00');
-WARN:Bad abstime external representation 'Feb 35, 1946 10:00:00'
+ERROR: Bad abstime external representation 'Feb 35, 1946 10:00:00'
QUERY: INSERT INTO ABSTIME_TBL (f1) VALUES ('Feb 28, 1984 25:08:10');
-WARN:Bad abstime external representation 'Feb 28, 1984 25:08:10'
+ERROR: Bad abstime external representation 'Feb 28, 1984 25:08:10'
QUERY: INSERT INTO ABSTIME_TBL (f1) VALUES ('bad date format');
-WARN:Bad abstime external representation 'bad date format'
+ERROR: Bad abstime external representation 'bad date format'
QUERY: INSERT INTO ABSTIME_TBL (f1) VALUES ('Jun 10, 1843');
QUERY: SELECT '' AS eight, ABSTIME_TBL.*;
eight|f1
QUERY: ALTER TABLE temp ADD COLUMN i char;
QUERY: ALTER TABLE temp ADD COLUMN j abstime[];
QUERY: ALTER TABLE temp ADD COLUMN k dt;
-WARN:type name lookup of dt failed
+ERROR: type name lookup of dt failed
QUERY: ALTER TABLE temp ADD COLUMN l tid;
QUERY: ALTER TABLE temp ADD COLUMN m xid;
QUERY: ALTER TABLE temp ADD COLUMN n oid8;
'1 2 3 4 5 6 7 8', 'magnetic disk', '(1.1,1.1)', '(4.1,4.1,3.1,3.1)',
'(0,2,4.1,4.1,3.1,3.1)', '(4.1,4.1,3.1,3.1)', '["current" "infinity"]',
'1/3', '1,char16', '{1.0,2.0,3.0,4.0}', '{1.0,2.0,3.0,4.0}', '{1,2,3,4}');
-WARN:Relation temp does not have attribute k
+ERROR: Relation temp does not have attribute k
QUERY: SELECT * FROM temp;
initial|a|b|c|d|e|f|g|h|i|j|l|m|n|p|q|r|s|t|u|v|w|x|y|z
-------+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
QUERY: ALTER TABLE temp ADD COLUMN i char;
QUERY: ALTER TABLE temp ADD COLUMN j abstime[];
QUERY: ALTER TABLE temp ADD COLUMN k dt;
-WARN:type name lookup of dt failed
+ERROR: type name lookup of dt failed
QUERY: ALTER TABLE temp ADD COLUMN l tid;
QUERY: ALTER TABLE temp ADD COLUMN m xid;
QUERY: ALTER TABLE temp ADD COLUMN n oid8;
'1 2 3 4 5 6 7 8', 'magnetic disk', '(1.1,1.1)', '(4.1,4.1,3.1,3.1)',
'(0,2,4.1,4.1,3.1,3.1)', '(4.1,4.1,3.1,3.1)', '["current" "infinity"]',
'1/3', '1,char16', '{1.0,2.0,3.0,4.0}', '{1.0,2.0,3.0,4.0}', '{1,2,3,4}');
-WARN:Relation temp does not have attribute k
+ERROR: Relation temp does not have attribute k
QUERY: SELECT * FROM temp;
initial|a|b|c|d|e|f|g|h|i|j|l|m|n|p|q|r|s|t|u|v|w|x|y|z
-------+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
QUERY: INSERT INTO BOOLTBL2 (f1) VALUES ('FALSE'::bool);
QUERY: INSERT INTO BOOLTBL2 (f1)
VALUES ('XXX'::bool);
-WARN:Bad boolean external representation 'XXX'
+ERROR: Bad boolean external representation 'XXX'
QUERY: SELECT '' AS f_4, BOOLTBL2.*;
f_4|f1
---+--
QUERY: INSERT INTO BOX_TBL (f1) VALUES ('(2.5, 2.5, 2.5,3.5)');
QUERY: INSERT INTO BOX_TBL (f1) VALUES ('(3.0, 3.0,3.0,3.0)');
QUERY: INSERT INTO BOX_TBL (f1) VALUES ('(2.3, 4.5)');
-WARN:Bad box external representation '(2.3, 4.5)'
+ERROR: Bad box external representation '(2.3, 4.5)'
QUERY: INSERT INTO BOX_TBL (f1) VALUES ('asdfasdf(ad');
-WARN:Bad box external representation 'asdfasdf(ad'
+ERROR: Bad box external representation 'asdfasdf(ad'
QUERY: SELECT '' AS four, BOX_TBL.*;
four|f1
----+-------------------
QUERY: INSERT INTO CIRCLE_TBL VALUES ('<(100,200),10>');
QUERY: INSERT INTO CIRCLE_TBL VALUES ('<(100,0),100>');
QUERY: INSERT INTO CIRCLE_TBL VALUES ('<(-100,0),-100>');
-WARN:Bad circle external representation '<(-100,0),-100>'
+ERROR: Bad circle external representation '<(-100,0),-100>'
QUERY: INSERT INTO CIRCLE_TBL VALUES ('1abc,3,5');
-WARN:Bad circle external representation '1abc,3,5'
+ERROR: Bad circle external representation '1abc,3,5'
QUERY: INSERT INTO CIRCLE_TBL VALUES ('(3,(1,2),3)');
-WARN:Bad circle external representation '(3,(1,2),3)'
+ERROR: Bad circle external representation '(3,(1,2),3)'
QUERY: SELECT * FROM CIRCLE_TBL;
f1
--------------
QUERY: INSERT INTO DATETIME_TBL VALUES ('Dec 31 17:32:01 2000');
QUERY: INSERT INTO DATETIME_TBL VALUES ('Jan 01 17:32:01 2001');
QUERY: INSERT INTO DATETIME_TBL VALUES ('Feb 16 17:32:01 -0097');
-WARN:Bad datetime external representation 'Feb 16 17:32:01 -0097'
+ERROR: Bad datetime external representation 'Feb 16 17:32:01 -0097'
QUERY: INSERT INTO DATETIME_TBL VALUES ('Feb 16 17:32:01 5097 BC');
-WARN:Datetime out of range 'Feb 16 17:32:01 5097 BC'
+ERROR: Datetime out of range 'Feb 16 17:32:01 5097 BC'
QUERY: SELECT '' AS sixtythree, d1 FROM DATETIME_TBL;
sixtythree|d1
----------+-------------------------------
QUERY: select 1
select
select * from nonesuch;
-WARN:parser: parse error at or near "select"
+ERROR: parser: parse error at or near "select"
QUERY: select nonesuch from pg_database;
-WARN:attribute 'nonesuch' not found
+ERROR: attribute 'nonesuch' not found
QUERY: select * from pg_database where nonesuch = pg_database.datname;
-WARN:attribute 'nonesuch' not found
+ERROR: attribute 'nonesuch' not found
QUERY: select * from pg_database where pg_database.datname = nonesuch;
-WARN:attribute 'nonesuch' not found
+ERROR: attribute 'nonesuch' not found
QUERY: select distinct on foobar from pg_database;
-WARN:parser: parse error at or near "from"
+ERROR: parser: parse error at or near "from"
QUERY: select distinct on foobar * from pg_database;
-WARN:The field specified in the UNIQUE ON clause is not in the targetlist
+ERROR: The field specified in the UNIQUE ON clause is not in the targetlist
QUERY: delete from;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: delete from nonesuch;
-WARN:nonesuch: Table does not exist.
+ERROR: nonesuch: Table does not exist.
QUERY: drop table;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop table nonesuch;
-WARN:Relation nonesuch Does Not Exist!
+ERROR: Relation nonesuch Does Not Exist!
QUERY: alter table rename;
-WARN:parser: parse error at or near "rename"
+ERROR: parser: parse error at or near "rename"
QUERY: alter table nonesuch rename to newnonesuch;
-WARN:renamerel: relation "nonesuch" does not exist
+ERROR: renamerel: relation "nonesuch" does not exist
QUERY: alter table nonesuch rename to stud_emp;
-WARN:renamerel: relation "nonesuch" does not exist
+ERROR: renamerel: relation "nonesuch" does not exist
QUERY: alter table stud_emp rename to pg_stud_emp;
-WARN:renamerel: Illegal class name: "pg_stud_emp" -- pg_ is reserved for system catalogs
+ERROR: renamerel: Illegal class name: "pg_stud_emp" -- pg_ is reserved for system catalogs
QUERY: alter table stud_emp rename to aggtest;
-WARN:renamerel: relation "aggtest" exists
+ERROR: renamerel: relation "aggtest" exists
QUERY: alter table stud_emp rename to stud_emp;
-WARN:renamerel: relation "stud_emp" exists
+ERROR: renamerel: relation "stud_emp" exists
QUERY: alter table nonesuchrel rename column nonesuchatt to newnonesuchatt;
-WARN:renameatt: relation "nonesuchrel" nonexistent
+ERROR: renameatt: relation "nonesuchrel" nonexistent
QUERY: alter table emp rename column nonesuchatt to newnonesuchatt;
-WARN:renameatt: attribute "nonesuchatt" nonexistent
+ERROR: renameatt: attribute "nonesuchatt" nonexistent
QUERY: alter table emp rename column salary to manager;
-WARN:renameatt: attribute "manager" exists
+ERROR: renameatt: attribute "manager" exists
QUERY: alter table emp rename column salary to oid;
-WARN:renameatt: attribute "oid" exists
+ERROR: renameatt: attribute "oid" exists
QUERY: abort;
NOTICE:UserAbortTransactionBlock and not in in-progress state
QUERY: end;
stype2 = int4,
initcond1 = '0',
initcond2 = '0');
-WARN:AggregateCreate: Aggregate must have final function with both transition functions
+ERROR: AggregateCreate: Aggregate must have final function with both transition functions
QUERY: create aggregate newavg2 (sfunc1 = int4pl,
basetype = int4,
stype1 = int4,
finalfunc = int4div,
initcond1 = '0',
initcond2 = '0');
-WARN:AggregateCreate: 'int4div'('int4','int2') does not exist
+ERROR: AggregateCreate: 'int4div'('int4','int2') does not exist
QUERY: create aggregate newavg3 (sfunc1 = int4pl,
basetype = int4,
stype1 = int4,
finalfunc = int2div,
initcond1 = '0',
initcond2 = '0');
-WARN:AggregateCreate: 'int2div'('int4','int4') does not exist
+ERROR: AggregateCreate: 'int2div'('int4','int4') does not exist
QUERY: create aggregate newcnt1 (sfunc2 = int4inc,
stype2 = int4,
initcond2 = '0');
-WARN:Define: "basetype" unspecified
+ERROR: Define: "basetype" unspecified
QUERY: create aggregate newcnt1 (sfunc2 = int4inc,
basetype = int4,
stype2 = int4);
-WARN:AggregateCreate: transition function 2 MUST have an initial value
+ERROR: AggregateCreate: transition function 2 MUST have an initial value
QUERY: drop index;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop index 314159;
-WARN:parser: parse error at or near "314159"
+ERROR: parser: parse error at or near "314159"
QUERY: drop index nonesuch;
-WARN:index "nonesuch" nonexistent
+ERROR: index "nonesuch" nonexistent
QUERY: drop aggregate;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop aggregate 314159;
-WARN:parser: parse error at or near "314159"
+ERROR: parser: parse error at or near "314159"
QUERY: drop aggregate nonesuch;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop aggregate newcnt1;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop aggregate newcnt nonesuch;
-WARN:RemoveAggregate: type 'nonesuch' does not exist
+ERROR: RemoveAggregate: type 'nonesuch' does not exist
QUERY: drop aggregate newcnt float4;
-WARN:RemoveAggregate: aggregate 'newcnt' for 'float4' does not exist
+ERROR: RemoveAggregate: aggregate 'newcnt' for 'float4' does not exist
QUERY: drop function ();
-WARN:parser: parse error at or near "("
+ERROR: parser: parse error at or near "("
QUERY: drop function 314159();
-WARN:parser: parse error at or near "314159"
+ERROR: parser: parse error at or near "314159"
QUERY: drop function nonesuch();
-WARN:RemoveFunction: function nonesuch() does not exist
+ERROR: RemoveFunction: function nonesuch() does not exist
QUERY: drop type;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop type 314159;
-WARN:parser: parse error at or near "314159"
+ERROR: parser: parse error at or near "314159"
QUERY: drop type nonesuch;
-WARN:RemoveType: type 'nonesuch' does not exist
+ERROR: RemoveType: type 'nonesuch' does not exist
QUERY: drop operator;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop operator equals;
-WARN:parser: parse error at or near "equals"
+ERROR: parser: parse error at or near "equals"
QUERY: drop operator ===;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop operator int4, int4;
-WARN:parser: parse error at or near "int4"
+ERROR: parser: parse error at or near "int4"
QUERY: drop operator (int4, int4);
-WARN:parser: parse error at or near "("
+ERROR: parser: parse error at or near "("
QUERY: drop operator === ();
-WARN:parser: parse error at or near ")"
+ERROR: parser: parse error at or near ")"
QUERY: drop operator === (int4);
-WARN:parser: argument type missing (use NONE for unary operators)
+ERROR: parser: argument type missing (use NONE for unary operators)
QUERY: drop operator === (int4, int4);
-WARN:RemoveOperator: binary operator '===' taking 'int4' and 'int4' does not exist
+ERROR: RemoveOperator: binary operator '===' taking 'int4' and 'int4' does not exist
QUERY: drop operator = (nonesuch);
-WARN:parser: argument type missing (use NONE for unary operators)
+ERROR: parser: argument type missing (use NONE for unary operators)
QUERY: drop operator = ( , int4);
-WARN:parser: parse error at or near ","
+ERROR: parser: parse error at or near ","
QUERY: drop operator = (nonesuch, int4);
-WARN:RemoveOperator: type 'nonesuch' does not exist
+ERROR: RemoveOperator: type 'nonesuch' does not exist
QUERY: drop operator = (int4, nonesuch);
-WARN:RemoveOperator: type 'nonesuch' does not exist
+ERROR: RemoveOperator: type 'nonesuch' does not exist
QUERY: drop operator = (int4, );
-WARN:parser: parse error at or near ")"
+ERROR: parser: parse error at or near ")"
QUERY: drop rule;
-WARN:parser: parse error at or near ";"
+ERROR: parser: parse error at or near ";"
QUERY: drop rule 314159;
-WARN:parser: parse error at or near "314159"
+ERROR: parser: parse error at or near "314159"
QUERY: drop rule nonesuch;
-WARN:RewriteGetRuleEventRel: rule "nonesuch" not found
+ERROR: RewriteGetRuleEventRel: rule "nonesuch" not found
QUERY: drop tuple rule nonesuch;
-WARN:parser: parse error at or near "tuple"
+ERROR: parser: parse error at or near "tuple"
QUERY: drop instance rule nonesuch;
-WARN:parser: parse error at or near "instance"
+ERROR: parser: parse error at or near "instance"
QUERY: drop rewrite rule nonesuch;
-WARN:parser: parse error at or near "rewrite"
+ERROR: parser: parse error at or near "rewrite"
QUERY: INSERT INTO FLOAT4_TBL(f1) VALUES ('1.2345678901234e+20');
QUERY: INSERT INTO FLOAT4_TBL(f1) VALUES ('1.2345678901234e-20');
QUERY: INSERT INTO FLOAT4_TBL(f1) VALUES ('10e40');
-WARN:Bad float4 input format -- overflow
+ERROR: Bad float4 input format -- overflow
QUERY: INSERT INTO FLOAT4_TBL(f1) VALUES ('-10e40');
-WARN:Bad float4 input format -- overflow
+ERROR: Bad float4 input format -- overflow
QUERY: INSERT INTO FLOAT4_TBL(f1) VALUES ('10e-40');
-WARN:Bad float4 input format -- underflow
+ERROR: Bad float4 input format -- underflow
QUERY: INSERT INTO FLOAT4_TBL(f1) VALUES ('-10e-40');
-WARN:Bad float4 input format -- underflow
+ERROR: Bad float4 input format -- underflow
QUERY: SELECT '' AS five, FLOAT4_TBL.*;
five|f1
----+-----------
(3 rows)
QUERY: SELECT '' AS bad, f.f1 / '0.0' from FLOAT4_TBL f;
-WARN:float4div: divide by zero error
+ERROR: float4div: divide by zero error
QUERY: SELECT '' AS five, FLOAT4_TBL.*;
five|f1
----+-----------
QUERY: INSERT INTO FLOAT8_TBL(f1) VALUES ('1.2345678901234e+200');
QUERY: INSERT INTO FLOAT8_TBL(f1) VALUES ('1.2345678901234e-200');
QUERY: INSERT INTO FLOAT8_TBL(f1) VALUES ('10e400');
-WARN:Bad float8 input format '10e400'
+ERROR: Bad float8 input format '10e400'
QUERY: INSERT INTO FLOAT8_TBL(f1) VALUES ('-10e400');
-WARN:Bad float8 input format '-10e400'
+ERROR: Bad float8 input format '-10e400'
QUERY: INSERT INTO FLOAT8_TBL(f1) VALUES ('10e-400');
-WARN:Bad float8 input format '10e-400'
+ERROR: Bad float8 input format '10e-400'
QUERY: INSERT INTO FLOAT8_TBL(f1) VALUES ('-10e-400');
-WARN:Bad float8 input format '-10e-400'
+ERROR: Bad float8 input format '-10e-400'
QUERY: SELECT '' AS five, FLOAT8_TBL.*;
five|f1
----+--------------------
SET f1 = FLOAT8_TBL.f1 * '-1'
WHERE FLOAT8_TBL.f1 > '0.0';
QUERY: SELECT '' AS bad, f.f1 * '1e200' from FLOAT8_TBL f;
-WARN:Bad float8 input format -- overflow
+ERROR: Bad float8 input format -- overflow
QUERY: SELECT '' AS bad, f.f1 ^ '1e200' from FLOAT8_TBL f;
-WARN:pow() result is out of range
+ERROR: pow() result is out of range
QUERY: SELECT '' AS bad, (; (f.f1)) from FLOAT8_TBL f where f.f1 = '0.0' ;
-WARN:can't take log of zero
+ERROR: can't take log of zero
QUERY: SELECT '' AS bad, (; (f.f1)) from FLOAT8_TBL f where f.f1 < '0.0' ;
-WARN:can't take log of a negative number
+ERROR: can't take log of a negative number
QUERY: SELECT '' AS bad, : (f.f1) from FLOAT8_TBL f;
bad| ?column?
---+--------------------
(5 rows)
QUERY: SELECT '' AS bad, f.f1 / '0.0' from FLOAT8_TBL f;
-WARN:float8div: divide by zero error
+ERROR: float8div: divide by zero error
QUERY: SELECT '' AS five, FLOAT8_TBL.*;
five|f1
----+---------------------
NOTICE:there is no operator # for types lseg and point
NOTICE:You will either have to retype this query using an
NOTICE:explicit cast, or you will have to define the operator
-WARN:# for lseg and point using CREATE OPERATOR
+ERROR: # for lseg and point using CREATE OPERATOR
QUERY: SELECT '' AS thirty, p.f1, l.s, p.f1 ## l.s AS closest
FROM LSEG_TBL l, POINT_TBL p;
thirty|f1 |s |closest
QUERY: INSERT INTO INT2_TBL(f1) VALUES ('1234');
QUERY: INSERT INTO INT2_TBL(f1) VALUES ('-1234');
QUERY: INSERT INTO INT2_TBL(f1) VALUES ('34.5');
-WARN:pg_atoi: error in "34.5": can't parse ".5"
+ERROR: pg_atoi: error in "34.5": can't parse ".5"
QUERY: INSERT INTO INT2_TBL(f1) VALUES ('32767');
QUERY: INSERT INTO INT2_TBL(f1) VALUES ('-32767');
QUERY: INSERT INTO INT2_TBL(f1) VALUES ('100000');
-WARN:pg_atoi: error reading "100000": Math result not representable
+ERROR: pg_atoi: error reading "100000": Math result not representable
QUERY: INSERT INTO INT2_TBL(f1) VALUES ('asdf');
-WARN:pg_atoi: error in "asdf": can't parse "asdf"
+ERROR: pg_atoi: error in "asdf": can't parse "asdf"
QUERY: SELECT '' AS five, INT2_TBL.*;
five| f1
----+------
QUERY: INSERT INTO INT4_TBL(f1) VALUES ('123456');
QUERY: INSERT INTO INT4_TBL(f1) VALUES ('-123456');
QUERY: INSERT INTO INT4_TBL(f1) VALUES ('34.5');
-WARN:pg_atoi: error in "34.5": can't parse ".5"
+ERROR: pg_atoi: error in "34.5": can't parse ".5"
QUERY: INSERT INTO INT4_TBL(f1) VALUES ('2147483647');
QUERY: INSERT INTO INT4_TBL(f1) VALUES ('-2147483647');
QUERY: INSERT INTO INT4_TBL(f1) VALUES ('1000000000000');
-WARN:pg_atoi: error reading "1000000000000": Math result not representable
+ERROR: pg_atoi: error reading "1000000000000": Math result not representable
QUERY: INSERT INTO INT4_TBL(f1) VALUES ('asdf');
-WARN:pg_atoi: error in "asdf": can't parse "asdf"
+ERROR: pg_atoi: error in "asdf": can't parse "asdf"
QUERY: SELECT '' AS five, INT4_TBL.*;
five| f1
----+-----------
QUERY: INSERT INTO LSEG_TBL VALUES ('[-1e6,2e2,3e5, -4e1]');
QUERY: INSERT INTO LSEG_TBL VALUES ('(11,22,33,44)');
QUERY: INSERT INTO LSEG_TBL VALUES ('(3asdf,2 ,3,4r2)');
-WARN:Bad lseg external representation '(3asdf,2 ,3,4r2)'
+ERROR: Bad lseg external representation '(3asdf,2 ,3,4r2)'
QUERY: INSERT INTO LSEG_TBL VALUES ('[1,2,3, 4');
-WARN:Bad lseg external representation '[1,2,3, 4'
+ERROR: Bad lseg external representation '[1,2,3, 4'
QUERY: INSERT INTO LSEG_TBL VALUES ('[(,2),(3,4)]');
-WARN:Bad lseg external representation '[(,2),(3,4)]'
+ERROR: Bad lseg external representation '[(,2),(3,4)]'
QUERY: INSERT INTO LSEG_TBL VALUES ('[(1,2),(3,4)');
-WARN:Bad lseg external representation '[(1,2),(3,4)'
+ERROR: Bad lseg external representation '[(1,2),(3,4)'
QUERY: select * from LSEG_TBL;
s
-----------------------------
NOTICE:there is no operator <= for types lseg and lseg
NOTICE:You will either have to retype this query using an
NOTICE:explicit cast, or you will have to define the operator
-WARN:<= for lseg and lseg using CREATE OPERATOR
+ERROR: <= for lseg and lseg using CREATE OPERATOR
QUERY: SELECT * FROM LSEG_TBL WHERE (s <-> '[(1,2),(3,4)]'::lseg) < 10;
s
------------------
QUERY: INSERT INTO OID_TBL(f1) VALUES ('-1040');
QUERY: INSERT INTO OID_TBL(f1) VALUES ('');
QUERY: INSERT INTO OID_TBL(f1) VALUES ('asdfasd');
-WARN:pg_atoi: error in "asdfasd": can't parse "asdfasd"
+ERROR: pg_atoi: error in "asdfasd": can't parse "asdfasd"
QUERY: SELECT '' AS five, OID_TBL.*;
five| f1
----+-----
QUERY: INSERT INTO OIDINT2_TBL(f1) VALUES ('987/-1234');
QUERY: INSERT INTO OIDINT2_TBL(f1) VALUES ('123456');
QUERY: INSERT INTO OIDINT2_TBL(f1) VALUES ('123456/123456');
-WARN:pg_atoi: error reading "123456": Math result not representable
+ERROR: pg_atoi: error reading "123456": Math result not representable
QUERY: INSERT INTO OIDINT2_TBL(f1) VALUES ('');
QUERY: INSERT INTO OIDINT2_TBL(f1) VALUES ('asdfasd');
-WARN:pg_atoi: error in "asdfasd": can't parse "asdfasd"
+ERROR: pg_atoi: error in "asdfasd": can't parse "asdfasd"
QUERY: SELECT '' AS five, OIDINT2_TBL.*;
five|f1
----+---------
QUERY: INSERT INTO OIDINT4_TBL(f1) VALUES ('987/-1234');
QUERY: INSERT INTO OIDINT4_TBL(f1) VALUES ('123456');
QUERY: INSERT INTO OIDINT4_TBL(f1) VALUES ('123456/1234568901234567890');
-WARN:pg_atoi: error reading "1234568901234567890": Math result not representable
+ERROR: pg_atoi: error reading "1234568901234567890": Math result not representable
QUERY: INSERT INTO OIDINT4_TBL(f1) VALUES ('');
QUERY: INSERT INTO OIDINT4_TBL(f1) VALUES ('asdfasd');
-WARN:pg_atoi: error in "asdfasd": can't parse "asdfasd"
+ERROR: pg_atoi: error in "asdfasd": can't parse "asdfasd"
QUERY: SELECT '' AS five, OIDINT4_TBL.*;
five|f1
----+---------
QUERY: INSERT INTO OIDNAME_TBL(f1) VALUES ('1235,efgh');
QUERY: INSERT INTO OIDNAME_TBL(f1) VALUES ('987,XXXX');
QUERY: INSERT INTO OIDNAME_TBL(f1) VALUES ('123456');
-WARN:Bad input data for type oidname
+ERROR: Bad input data for type oidname
QUERY: INSERT INTO OIDNAME_TBL(f1) VALUES ('123456,abcdefghijklmnopqrsutvwyz');
QUERY: INSERT INTO OIDNAME_TBL(f1) VALUES ('');
-WARN:Bad input data for type oidname
+ERROR: Bad input data for type oidname
QUERY: INSERT INTO OIDNAME_TBL(f1) VALUES ('asdfasd');
-WARN:Bad input data for type oidname
+ERROR: Bad input data for type oidname
QUERY: SELECT '' AS four, OIDNAME_TBL.*;
four|f1
----+--------------------------------
QUERY: INSERT INTO PATH_TBL VALUES ('[11,12,13,14]');
QUERY: INSERT INTO PATH_TBL VALUES ('(11,12,13,14)');
QUERY: INSERT INTO PATH_TBL VALUES ('[(,2),(3,4)]');
-WARN:Bad path external representation '[(,2),(3,4)]'
+ERROR: Bad path external representation '[(,2),(3,4)]'
QUERY: INSERT INTO PATH_TBL VALUES ('[(1,2),(3,4)');
-WARN:Bad path external representation '[(1,2),(3,4)'
+ERROR: Bad path external representation '[(1,2),(3,4)'
QUERY: SELECT f1 FROM PATH_TBL;
f1
-------------------------
QUERY: INSERT INTO POINT_TBL(f1) VALUES ('(5.1, 34.5)');
QUERY: INSERT INTO POINT_TBL(f1) VALUES ('(-5.0,-12.0)');
QUERY: INSERT INTO POINT_TBL(f1) VALUES ('asdfasdf');
-WARN:Bad point external representation 'asdfasdf'
+ERROR: Bad point external representation 'asdfasdf'
QUERY: INSERT INTO POINT_TBL(f1) VALUES ('10.0,10.0');
QUERY: INSERT INTO POINT_TBL(f1) VALUES ('(10.0 10.0)');
-WARN:Bad point external representation '(10.0 10.0)'
+ERROR: Bad point external representation '(10.0 10.0)'
QUERY: INSERT INTO POINT_TBL(f1) VALUES ('(10.0,10.0');
-WARN:Bad point external representation '(10.0,10.0'
+ERROR: Bad point external representation '(10.0,10.0'
QUERY: SELECT '' AS six, POINT_TBL.*;
six|f1
---+----------
QUERY: INSERT INTO POLYGON_TBL(f1) VALUES ('(0.0,0.0)');
QUERY: INSERT INTO POLYGON_TBL(f1) VALUES ('(0.0,1.0),(0.0,1.0)');
QUERY: INSERT INTO POLYGON_TBL(f1) VALUES ('0.0');
-WARN:Bad polygon external representation '0.0'
+ERROR: Bad polygon external representation '0.0'
QUERY: INSERT INTO POLYGON_TBL(f1) VALUES ('(0.0 0.0');
-WARN:Bad polygon external representation '(0.0 0.0'
+ERROR: Bad polygon external representation '(0.0 0.0'
QUERY: INSERT INTO POLYGON_TBL(f1) VALUES ('(0,1,2)');
-WARN:Bad polygon external representation '(0,1,2)'
+ERROR: Bad polygon external representation '(0,1,2)'
QUERY: INSERT INTO POLYGON_TBL(f1) VALUES ('(0,1,2,3');
-WARN:Bad polygon external representation '(0,1,2,3'
+ERROR: Bad polygon external representation '(0,1,2,3'
QUERY: INSERT INTO POLYGON_TBL(f1) VALUES ('asdf');
-WARN:Bad polygon external representation 'asdf'
+ERROR: Bad polygon external representation 'asdf'
QUERY: SELECT '' AS four, POLYGON_TBL.*;
four|f1
----+-------------------
QUERY: INSERT INTO RELTIME_TBL (f1) VALUES ('@ 3 months');
QUERY: INSERT INTO RELTIME_TBL (f1) VALUES ('@ 14 seconds ago');
QUERY: INSERT INTO RELTIME_TBL (f1) VALUES ('badly formatted reltime');
-WARN:Bad reltime external representation 'badly formatted reltime'
+ERROR: Bad reltime external representation 'badly formatted reltime'
QUERY: INSERT INTO RELTIME_TBL (f1) VALUES ('@ 30 eons ago');
-WARN:Bad reltime external representation '@ 30 eons ago'
+ERROR: Bad reltime external representation '@ 30 eons ago'
QUERY: SELECT '' AS six, RELTIME_TBL.*;
six|f1
---+-------------
QUERY: SELECT 'first line'
' - next line' /* this comment is not allowed here */
' - third line';
-WARN:parser: parse error at or near "'"
+ERROR: parser: parse error at or near "'"
QUERY: SELECT text(f1) FROM CHAR_TBL;
-WARN:func_get_detail: function text(bpchar) does not exist
+ERROR: func_get_detail: function text(bpchar) does not exist
QUERY: SELECT text(f1) FROM VARCHAR_TBL;
-WARN:func_get_detail: function text(varchar) does not exist
+ERROR: func_get_detail: function text(varchar) does not exist
QUERY: INSERT INTO TIMESPAN_TBL (f1) VALUES ('5 months');
QUERY: INSERT INTO TIMESPAN_TBL (f1) VALUES ('5 months 12 hours');
QUERY: INSERT INTO TIMESPAN_TBL (f1) VALUES ('badly formatted timespan');
-WARN:Bad timespan external representation 'badly formatted timespan'
+ERROR: Bad timespan external representation 'badly formatted timespan'
QUERY: INSERT INTO TIMESPAN_TBL (f1) VALUES ('@ 30 eons ago');
-WARN:Bad timespan external representation '@ 30 eons ago'
+ERROR: Bad timespan external representation '@ 30 eons ago'
QUERY: SELECT '' AS ten, TIMESPAN_TBL.*;
ten|f1
---+-----------------------------
VALUES ('["Feb 15 1990 12:15:03" "current"]');
QUERY: INSERT INTO TINTERVAL_TBL (f1)
VALUES ('["bad time specifications" ""]');
-WARN:Bad abstime external representation 'bad time specifications'
+ERROR: Bad abstime external representation 'bad time specifications'
QUERY: INSERT INTO TINTERVAL_TBL (f1)
VALUES ('["" "infinity"]');
-WARN:Bad abstime external representation ''
+ERROR: Bad abstime external representation ''
QUERY: SELECT '' AS five, TINTERVAL_TBL.*;
five|f1
----+---------------------------------------------------------------
QUERY: insert into fkeys2 values (40, '4', 5);
QUERY: insert into fkeys2 values (50, '5', 3);
QUERY: insert into fkeys2 values (70, '5', 3);
-WARN:check_fkeys2_pkey_exist: tuple references non-existing key in pkeys
+ERROR: check_fkeys2_pkey_exist: tuple references non-existing key in pkeys
QUERY: insert into fkeys values (10, '1', 2);
QUERY: insert into fkeys values (30, '3', 3);
QUERY: insert into fkeys values (40, '4', 2);
QUERY: insert into fkeys values (50, '5', 2);
QUERY: insert into fkeys values (70, '5', 1);
-WARN:check_fkeys_pkey_exist: tuple references non-existing key in pkeys
+ERROR: check_fkeys_pkey_exist: tuple references non-existing key in pkeys
QUERY: insert into fkeys values (60, '6', 4);
-WARN:check_fkeys_pkey2_exist: tuple references non-existing key in fkeys2
+ERROR: check_fkeys_pkey2_exist: tuple references non-existing key in fkeys2
QUERY: delete from pkeys where pkey1 = 30 and pkey2 = '3';
NOTICE:check_pkeys_fkey_cascade: 1 tuple(s) of fkeys are deleted
-WARN:check_fkeys2_fkey_restrict: tuple referenced in fkeys
+ERROR: check_fkeys2_fkey_restrict: tuple referenced in fkeys
QUERY: 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
QUERY: 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
-WARN:check_fkeys2_fkey_restrict: tuple referenced in fkeys
+ERROR: check_fkeys2_fkey_restrict: tuple referenced in fkeys
QUERY: 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
(1 row)
QUERY: update tttest set price_on = -1 where price_id = 1;
-WARN:ttdummy (tttest): you can't change price_on and/or price_off columns (use set_ttdummy)
+ERROR: ttdummy (tttest): you can't change price_on and/or price_off columns (use set_ttdummy)
QUERY: select set_ttdummy(0);
set_ttdummy
-----------
/*
- * $Header: /cvsroot/pgsql/src/test/regress/regress.c,v 1.17 1997/11/10 15:43:26 thomas Exp $
+ * $Header: /cvsroot/pgsql/src/test/regress/regress.c,v 1.18 1998/01/05 03:35:14 momjian Exp $
*/
#include <float.h> /* faked on sunos */
SPI_gettype(tupdesc, 1));
if ((ret = SPI_exec(sql, 0)) < 0)
- elog(WARN, "funny_dup17 (fired %s) on level %3d: SPI_exec (insert ...) returned %d",
+ elog(ABORT, "funny_dup17 (fired %s) on level %3d: SPI_exec (insert ...) returned %d",
when, *level, ret);
inserted = SPI_processed;
SPI_gettype(tupdesc, 1));
if ((ret = SPI_exec(sql, 0)) < 0)
- elog(WARN, "funny_dup17 (fired %s) on level %3d: SPI_exec (select ...) returned %d",
+ elog(ABORT, "funny_dup17 (fired %s) on level %3d: SPI_exec (select ...) returned %d",
when, *level, ret);
if (SPI_processed > 0)
int i;
if (!CurrentTriggerData)
- elog(WARN, "ttdummy: triggers are not initialized");
+ elog(ABORT, "ttdummy: triggers are not initialized");
if (TRIGGER_FIRED_FOR_STATEMENT(CurrentTriggerData->tg_event))
- elog(WARN, "ttdummy: can't process STATEMENT events");
+ elog(ABORT, "ttdummy: can't process STATEMENT events");
if (TRIGGER_FIRED_AFTER(CurrentTriggerData->tg_event))
- elog(WARN, "ttdummy: must be fired before event");
+ elog(ABORT, "ttdummy: must be fired before event");
if (TRIGGER_FIRED_BY_INSERT(CurrentTriggerData->tg_event))
elog (WARN, "ttdummy: can't process INSERT event");
if (TRIGGER_FIRED_BY_UPDATE(CurrentTriggerData->tg_event))
trigger = CurrentTriggerData->tg_trigger;
if (trigger->tgnargs != 2)
- elog(WARN, "ttdummy (%s): invalid (!= 2) number of arguments %d",
+ elog(ABORT, "ttdummy (%s): invalid (!= 2) number of arguments %d",
relname, trigger->tgnargs);
args = trigger->tgargs;
{
attnum[i] = SPI_fnumber (tupdesc, args[i]);
if ( attnum[i] < 0 )
- elog(WARN, "ttdummy (%s): there is no attribute %s", relname, args[i]);
+ elog(ABORT, "ttdummy (%s): there is no attribute %s", relname, args[i]);
if (SPI_gettypeid (tupdesc, attnum[i]) != INT4OID)
- elog(WARN, "ttdummy (%s): attributes %s and %s must be of abstime type",
+ elog(ABORT, "ttdummy (%s): attributes %s and %s must be of abstime type",
relname, args[0], args[1]);
}
oldon = SPI_getbinval (trigtuple, tupdesc, attnum[0], &isnull);
if (isnull)
- elog(WARN, "ttdummy (%s): %s must be NOT NULL", relname, args[0]);
+ elog(ABORT, "ttdummy (%s): %s must be NOT NULL", relname, args[0]);
oldoff = SPI_getbinval (trigtuple, tupdesc, attnum[1], &isnull);
if (isnull)
- elog(WARN, "ttdummy (%s): %s must be NOT NULL", relname, args[1]);
+ elog(ABORT, "ttdummy (%s): %s must be NOT NULL", relname, args[1]);
if (newtuple != NULL) /* UPDATE */
{
newon = SPI_getbinval (newtuple, tupdesc, attnum[0], &isnull);
if (isnull)
- elog(WARN, "ttdummy (%s): %s must be NOT NULL", relname, args[0]);
+ elog(ABORT, "ttdummy (%s): %s must be NOT NULL", relname, args[0]);
newoff = SPI_getbinval (newtuple, tupdesc, attnum[1], &isnull);
if (isnull)
- elog(WARN, "ttdummy (%s): %s must be NOT NULL", relname, args[1]);
+ elog(ABORT, "ttdummy (%s): %s must be NOT NULL", relname, args[1]);
if ( oldon != newon || oldoff != newoff )
elog (WARN, "ttdummy (%s): you can't change %s and/or %s columns (use set_ttdummy)",
/* Connect to SPI manager */
if ((ret = SPI_connect()) < 0)
- elog(WARN, "ttdummy (%s): SPI_connect returned %d", relname, ret);
+ elog(ABORT, "ttdummy (%s): SPI_connect returned %d", relname, ret);
/* Fetch tuple values and nulls */
cvals = (Datum *) palloc (natts * sizeof (Datum));
/* Prepare plan for query */
pplan = SPI_prepare(sql, natts, ctypes);
if (pplan == NULL)
- elog(WARN, "ttdummy (%s): SPI_prepare returned %d", relname, SPI_result);
+ elog(ABORT, "ttdummy (%s): SPI_prepare returned %d", relname, SPI_result);
pplan = SPI_saveplan(pplan);
if (pplan == NULL)
- elog(WARN, "ttdummy (%s): SPI_saveplan returned %d", relname, SPI_result);
+ elog(ABORT, "ttdummy (%s): SPI_saveplan returned %d", relname, SPI_result);
splan = pplan;
}
ret = SPI_execp(splan, cvals, cnulls, 0);
if (ret < 0)
- elog(WARN, "ttdummy (%s): SPI_execp returned %d", relname, ret);
+ elog(ABORT, "ttdummy (%s): SPI_execp returned %d", relname, ret);
/* Tuple to return to upper Executor ... */
if (newtuple) /* UPDATE */
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/tutorial/C-code/Attic/beard.c,v 1.3 1997/09/08 02:41:09 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/tutorial/C-code/Attic/beard.c,v 1.4 1998/01/05 03:35:52 momjian Exp $
*
*-------------------------------------------------------------------------
*/
int cc;
if ((pic_fd = lo_open(picture, INV_READ)) == -1)
- elog(WARN, "Cannot access picture large object");
+ elog(ABORT, "Cannot access picture large object");
if (lo_read(pic_fd, (char *) &ihdr, sizeof(ihdr)) != sizeof(ihdr))
- elog(WARN, "Picture large object corrupted");
+ elog(ABORT, "Picture large object corrupted");
beardOffset = (ihdr.size / 3) * 2;
* new large object
*/
if ((beard = lo_creat(INV_MD)) == 0) /* ?? is this right? */
- elog(WARN, "Cannot create new large object");
+ elog(ABORT, "Cannot create new large object");
if ((beard_fd = lo_open(beard, INV_WRITE)) == -1)
- elog(WARN, "Cannot access beard large object");
+ elog(ABORT, "Cannot access beard large object");
lo_lseek(pic_fd, beardOffset, SET_CUR);
while ((cc = lo_read(pic_fd, buf, BUFSIZE)) > 0)
{
if (lo_write(beard_fd, buf, cc) != cc)
- elog(WARN, "error while writing large object");
+ elog(ABORT, "error while writing large object");
}
lo_close(pic_fd);
if (sscanf(str, " ( %lf , %lf )", &x, &y) != 2)
{
- elog(WARN, "complex_in: error in parsing \"%s\"", str);
+ elog(ABORT, "complex_in: error in parsing \"%s\"", str);
return NULL;
}
result = (Complex *) palloc(sizeof(Complex));