mirror of
https://github.com/postgres/postgres.git
synced 2025-07-30 11:03:19 +03:00
Change elog(WARN) to elog(ERROR) and elog(ABORT).
This commit is contained in:
@ -7,11 +7,11 @@ QUERY: INSERT INTO ABSTIME_TBL (f1) VALUES ('infinity'::abstime);
|
||||
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
|
||||
|
@ -10,7 +10,7 @@ QUERY: ALTER TABLE temp ADD COLUMN h abstime;
|
||||
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;
|
||||
@ -33,7 +33,7 @@ QUERY: INSERT INTO temp (a, b, c, d, e, f, g, h, i, j, k, l, m, n, p, q, r, s, t
|
||||
'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
|
||||
-------+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
|
||||
@ -54,7 +54,7 @@ QUERY: ALTER TABLE temp ADD COLUMN h abstime;
|
||||
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;
|
||||
@ -77,7 +77,7 @@ QUERY: INSERT INTO temp (a, b, c, d, e, f, g, h, i, j, k, l, m, n, p, q, r, s, t
|
||||
'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
|
||||
-------+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
|
||||
|
@ -101,7 +101,7 @@ QUERY: INSERT INTO BOOLTBL2 (f1) VALUES ('False'::bool);
|
||||
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
|
||||
---+--
|
||||
|
@ -4,9 +4,9 @@ QUERY: INSERT INTO BOX_TBL (f1) VALUES ('(1.0,1.0,3.0,3.0)');
|
||||
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
|
||||
----+-------------------
|
||||
|
@ -6,11 +6,11 @@ QUERY: INSERT INTO CIRCLE_TBL VALUES ('((1,2),3)');
|
||||
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
|
||||
--------------
|
||||
|
@ -146,9 +146,9 @@ QUERY: INSERT INTO DATETIME_TBL VALUES ('Jan 01 17:32:01 2000');
|
||||
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
|
||||
----------+-------------------------------
|
||||
|
@ -1,45 +1,45 @@
|
||||
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;
|
||||
@ -51,7 +51,7 @@ QUERY: create aggregate newavg1 (sfunc1 = int4pl,
|
||||
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,
|
||||
@ -60,7 +60,7 @@ QUERY: create aggregate newavg2 (sfunc1 = int4pl,
|
||||
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,
|
||||
@ -69,80 +69,80 @@ QUERY: create aggregate newavg3 (sfunc1 = int4pl,
|
||||
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"
|
||||
|
@ -5,13 +5,13 @@ QUERY: INSERT INTO FLOAT4_TBL(f1) VALUES ('-34.84');
|
||||
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
|
||||
----+-----------
|
||||
@ -108,7 +108,7 @@ three|f1 |x
|
||||
(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
|
||||
----+-----------
|
||||
|
@ -5,13 +5,13 @@ QUERY: INSERT INTO FLOAT8_TBL(f1) VALUES ('-34.84');
|
||||
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
|
||||
----+--------------------
|
||||
@ -195,13 +195,13 @@ QUERY: UPDATE FLOAT8_TBL
|
||||
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?
|
||||
---+--------------------
|
||||
@ -213,7 +213,7 @@ 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
|
||||
----+---------------------
|
||||
|
@ -90,7 +90,7 @@ QUERY: SELECT '' AS count, p.f1, l.s, l.s # p.f1 AS intersection
|
||||
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
|
||||
|
@ -3,13 +3,13 @@ QUERY: INSERT INTO INT2_TBL(f1) VALUES ('0');
|
||||
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
|
||||
----+------
|
||||
|
@ -3,13 +3,13 @@ QUERY: INSERT INTO INT4_TBL(f1) VALUES ('0');
|
||||
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
|
||||
----+-----------
|
||||
|
@ -5,13 +5,13 @@ QUERY: INSERT INTO LSEG_TBL VALUES ('10,-10 ,-3,-4');
|
||||
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
|
||||
-----------------------------
|
||||
@ -26,7 +26,7 @@ QUERY: SELECT * FROM LSEG_TBL WHERE s <= '[(1,2),(3,4)]'::lseg;
|
||||
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
|
||||
------------------
|
||||
|
@ -5,7 +5,7 @@ QUERY: INSERT INTO OID_TBL(f1) VALUES ('987');
|
||||
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
|
||||
----+-----
|
||||
|
@ -4,10 +4,10 @@ QUERY: INSERT INTO OIDINT2_TBL(f1) VALUES ('1235/9873');
|
||||
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
|
||||
----+---------
|
||||
|
@ -4,10 +4,10 @@ QUERY: INSERT INTO OIDINT4_TBL(f1) VALUES ('1235/9873');
|
||||
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
|
||||
----+---------
|
||||
|
@ -3,12 +3,12 @@ QUERY: INSERT INTO OIDNAME_TBL(f1) VALUES ('1234,abcd');
|
||||
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
|
||||
----+--------------------------------
|
||||
|
@ -8,9 +8,9 @@ QUERY: INSERT INTO PATH_TBL VALUES ('[1,2,3, 4]');
|
||||
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
|
||||
-------------------------
|
||||
|
@ -5,12 +5,12 @@ QUERY: INSERT INTO POINT_TBL(f1) VALUES ('(-3.0,4.0)');
|
||||
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
|
||||
---+----------
|
||||
|
@ -4,15 +4,15 @@ QUERY: INSERT INTO POLYGON_TBL(f1) VALUES ('(3.0,1.0),(3.0,3.0),(1.0,0.0)');
|
||||
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
|
||||
----+-------------------
|
||||
|
@ -6,9 +6,9 @@ QUERY: INSERT INTO RELTIME_TBL (f1) VALUES ('@ 34 year');
|
||||
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
|
||||
---+-------------
|
||||
|
@ -10,8 +10,8 @@ first line - next line - third line
|
||||
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
|
||||
|
@ -10,9 +10,9 @@ QUERY: INSERT INTO TIMESPAN_TBL (f1) VALUES ('6 years');
|
||||
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
|
||||
---+-----------------------------
|
||||
|
@ -11,10 +11,10 @@ QUERY: INSERT INTO TINTERVAL_TBL (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
|
||||
----+---------------------------------------------------------------
|
||||
|
@ -40,24 +40,24 @@ QUERY: insert into fkeys2 values (30, '3', 2);
|
||||
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
|
||||
@ -258,7 +258,7 @@ set_ttdummy
|
||||
(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
|
||||
-----------
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* $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 */
|
||||
@ -372,7 +372,7 @@ funny_dup17()
|
||||
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;
|
||||
@ -384,7 +384,7 @@ funny_dup17()
|
||||
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)
|
||||
@ -444,11 +444,11 @@ ttdummy()
|
||||
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))
|
||||
@ -469,7 +469,7 @@ ttdummy()
|
||||
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;
|
||||
@ -482,28 +482,28 @@ ttdummy()
|
||||
{
|
||||
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)",
|
||||
@ -530,7 +530,7 @@ 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));
|
||||
@ -581,11 +581,11 @@ ttdummy()
|
||||
/* 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;
|
||||
}
|
||||
@ -593,7 +593,7 @@ ttdummy()
|
||||
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 */
|
||||
|
Reference in New Issue
Block a user