rules failed
I'm pretty new to PostgreSQL but have compiled and used 6.4.2 on LinuxPPC
R4. I just set up a machine with R5 and during regression the "rules"
section failed the test. I looked through the log files but couldn't make
sense of what "rules" deals with and what the relevance is to the databases
I may build. Is this a "problem" failure, as in, don't use the database for
anything important until it's fixed or more like the geometry failures that
have been around for a while.
Thanks for any advice
Mike
What did regression.diff tell you?
Rules (in general) rewrite queries, before they execute. They are used to
implement views. A failure of the Rule regression test could mean (very
serious) you have a platform specific problem that is affecting the rewrite
system, or (nothing to worry about) you compiled with a local that isn't
compatible with the expected output for money. It could mean other things
as well, but these are the extremes.
I'm sure someone can give you more insight with that diff information.
-DEJ
Show quoted text
-----Original Message-----
From: Mike Engelhart [SMTP:mengelhart@earthtrip.com]
Sent: Friday, July 09, 1999 4:19 PM
To: pgsql-general@postgreSQL.org
Subject: [GENERAL] rules failedI'm pretty new to PostgreSQL but have compiled and used 6.4.2 on LinuxPPC
R4. I just set up a machine with R5 and during regression the "rules"
section failed the test. I looked through the log files but couldn't make
sense of what "rules" deals with and what the relevance is to the
databases
I may build. Is this a "problem" failure, as in, don't use the database
for
anything important until it's fixed or more like the geometry failures
that
have been around for a while.Thanks for any advice
Mike
Import Notes
Resolved by subject fallback
What did regression.diff tell you?
I'm sure someone can give you more insight with that diff information.
-DEJ
well here is the relevant part from regression.diffs, but I don't understand
what it's supposed to be telling me...
Thanks,
Mike
*** expected/rules.out Thu Jun 3 02:01:21 1999
--- results/rules.out Fri Jul 9 14:04:16 1999
***************
*** 1066,1076 ****
QUERY: SELECT viewname, definition FROM pg_views ORDER BY viewname;
viewname |definition
!
------------------+---------------------------------------------------------
----------------------------------------------------------------------------
----------------------------------------------------------------------------
----------------------------------------------------------------------------
----------------------------------------------------------------------------
-----------------------------------------------------
iexit |SELECT "ih"."name", "ih"."thepath",
"interpt_pp"("ih"."thepath", "r"."thepath") AS "exit" FROM "ihighway" "ih",
"ramp" "r" WHERE "ih"."thepath" ## "r"."thepath";
pg_indexes |SELECT "c"."relname" AS "tablename", "i"."relname" AS
"indexname", "pg_get_indexdef"("x"."indexrelid") AS "indexdef" FROM
"pg_index" "x", "pg_class" "c", "pg_class" "i" WHERE ("c"."oid" =
"x"."indrelid") AND ("i"."oid" = "x"."indexrelid");
pg_rules |SELECT "c"."relname" AS "tablename", "r"."rulename",
"pg_get_ruledef"("r"."rulename") AS "definition" FROM "pg_rewrite" "r",
"pg_class" "c" WHERE ("r"."rulename" !~ '^_RET'::"text") AND ("c"."oid" =
"r"."ev_class");
! pg_tables |SELECT "c"."relname" AS "tablename",
"pg_get_userbyid"("c"."relowner") AS "tableowner", "c"."relhasindex" AS
"hasindexes", "c"."relhasrules" AS "hasrules", "c"."reltriggers" >
'0'::"int4" AS "hastriggers" FROM "pg_class" "c" WHERE (("c"."relkind" =
'r'::"char") OR ("c"."relkind" = 's'::"char")) AND (NOT (EXISTS (SELECT
"rulename" FROM "pg_rewrite" WHERE ("ev_class" = "c"."oid") AND ("ev_type" =
'1'::"char"))));
pg_user |SELECT "usename", "usesysid", "usecreatedb",
"usetrace", "usesuper", "usecatupd", '********'::"text" AS "passwd",
"valuntil" FROM "pg_shadow";
pg_views |SELECT "c"."relname" AS "viewname",
"pg_get_userbyid"("c"."relowner") AS "viewowner",
"pg_get_viewdef"("c"."relname") AS "definition" FROM "pg_class" "c" WHERE
("c"."relhasrules") AND (EXISTS (SELECT "r"."rulename" FROM "pg_rewrite" "r"
WHERE ("r"."ev_class" = "c"."oid") AND ("r"."ev_type" = '1'::"char")));
rtest_v1 |SELECT "a", "b" FROM "rtest_t1";
--- 1066,1076 ----
QUERY: SELECT viewname, definition FROM pg_views ORDER BY viewname;
viewname |definition
!
------------------+---------------------------------------------------------
----------------------------------------------------------------------------
----------------------------------------------------------------------------
----------------------------------------------------------------------------
----------------------------------------------------------------------------
-------------------------------------
iexit |SELECT "ih"."name", "ih"."thepath",
"interpt_pp"("ih"."thepath", "r"."thepath") AS "exit" FROM "ihighway" "ih",
"ramp" "r" WHERE "ih"."thepath" ## "r"."thepath";
pg_indexes |SELECT "c"."relname" AS "tablename", "i"."relname" AS
"indexname", "pg_get_indexdef"("x"."indexrelid") AS "indexdef" FROM
"pg_index" "x", "pg_class" "c", "pg_class" "i" WHERE ("c"."oid" =
"x"."indrelid") AND ("i"."oid" = "x"."indexrelid");
pg_rules |SELECT "c"."relname" AS "tablename", "r"."rulename",
"pg_get_ruledef"("r"."rulename") AS "definition" FROM "pg_rewrite" "r",
"pg_class" "c" WHERE ("r"."rulename" !~ '^_RET'::"text") AND ("c"."oid" =
"r"."ev_class");
! pg_tables |SELECT "c"."relname" AS "tablename",
"pg_get_userbyid"("c"."relowner"), "c"."relhasindex" AS "hasindexes",
"c"."relhasrules" AS "hasrules", "c"."reltriggers" > '0'::"int4" AS
"hastriggers" FROM "pg_class" "c" WHERE (("c"."relkind" = 'r'::"char") OR
("c"."relkind" = 's'::"char")) AND (NOT (EXISTS (SELECT "rulename" FROM
"pg_rewrite" WHERE ("ev_class" = "c"."oid") AND ("ev_type" =
'1'::"char"))));
pg_user |SELECT "usename", "usesysid", "usecreatedb",
"usetrace", "usesuper", "usecatupd", '********'::"text" AS "passwd",
"valuntil" FROM "pg_shadow";
pg_views |SELECT "c"."relname" AS "viewname",
"pg_get_userbyid"("c"."relowner") AS "viewowner",
"pg_get_viewdef"("c"."relname") AS "definition" FROM "pg_class" "c" WHERE
("c"."relhasrules") AND (EXISTS (SELECT "r"."rulename" FROM "pg_rewrite" "r"
WHERE ("r"."ev_class" = "c"."oid") AND ("r"."ev_type" = '1'::"char")));
rtest_v1 |SELECT "a", "b" FROM "rtest_t1";
***************
*** 1082,1088 ****
rtest_vview5 |SELECT "a", "b", "rtest_viewfunc1"("a") AS "refcount"
FROM "rtest_view1";
shoe |SELECT "sh"."shoename", "sh"."sh_avail",
"sh"."slcolor", "sh"."slminlen", "sh"."slminlen" * "un"."un_fact" AS
"slminlen_cm", "sh"."slmaxlen", "sh"."slmaxlen" * "un"."un_fact" AS
"slmaxlen_cm", "sh"."slunit" FROM "shoe_data" "sh", "unit" "un" WHERE
"sh"."slunit" = "un"."un_name";
shoe_ready |SELECT "rsh"."shoename", "rsh"."sh_avail",
"rsl"."sl_name", "rsl"."sl_avail", "int4smaller"("rsh"."sh_avail",
"rsl"."sl_avail") AS "total_avail" FROM "shoe" "rsh", "shoelace" "rsl" WHERE
(("rsl"."sl_color" = "rsh"."slcolor") AND ("rsl"."sl_len_cm" >=
"rsh"."slminlen_cm")) AND ("rsl"."sl_len_cm" <= "rsh"."slmaxlen_cm");
! shoelace |SELECT "s"."sl_name", "s"."sl_avail", "s"."sl_color",
"s"."sl_len", "s"."sl_unit", "s"."sl_len" * "u"."un_fact" AS "sl_len_cm"
FROM "shoelace_data" "s", "unit" "u" WHERE "s"."sl_unit" = "u"."un_name";
shoelace_candelete|SELECT "sl_name", "sl_avail", "sl_color", "sl_len",
"sl_unit", "sl_len_cm" FROM "shoelace_obsolete" WHERE "sl_avail" =
'0'::"int4";
shoelace_obsolete |SELECT "sl_name", "sl_avail", "sl_color", "sl_len",
"sl_unit", "sl_len_cm" FROM "shoelace" WHERE NOT (EXISTS (SELECT "shoename"
FROM "shoe" WHERE "slcolor" = "sl_color"));
street |SELECT "r"."name", "r"."thepath", "c"."cname" FROM
"road" "r", "real_city" "c" WHERE "c"."outline" ## "r"."thepath";
--- 1082,1088 ----
rtest_vview5 |SELECT "a", "b", "rtest_viewfunc1"("a") AS "refcount"
FROM "rtest_view1";
shoe |SELECT "sh"."shoename", "sh"."sh_avail",
"sh"."slcolor", "sh"."slminlen", "sh"."slminlen" * "un"."un_fact" AS
"slminlen_cm", "sh"."slmaxlen", "sh"."slmaxlen" * "un"."un_fact" AS
"slmaxlen_cm", "sh"."slunit" FROM "shoe_data" "sh", "unit" "un" WHERE
"sh"."slunit" = "un"."un_name";
shoe_ready |SELECT "rsh"."shoename", "rsh"."sh_avail",
"rsl"."sl_name", "rsl"."sl_avail", "int4smaller"("rsh"."sh_avail",
"rsl"."sl_avail") AS "total_avail" FROM "shoe" "rsh", "shoelace" "rsl" WHERE
(("rsl"."sl_color" = "rsh"."slcolor") AND ("rsl"."sl_len_cm" >=
"rsh"."slminlen_cm")) AND ("rsl"."sl_len_cm" <= "rsh"."slmaxlen_cm");
! shoelace |SELECT "s"."sl_name", "s"."sl_avail", "s"."sl_color",
"s"."sl_len", "s"."sl_unit", "s"."sl_len" * "u"."un_fact" FROM
"shoelace_data" "s", "unit" "u" WHERE "s"."sl_unit" = "u"."un_name";
shoelace_candelete|SELECT "sl_name", "sl_avail", "sl_color", "sl_len",
"sl_unit", "sl_len_cm" FROM "shoelace_obsolete" WHERE "sl_avail" =
'0'::"int4";
shoelace_obsolete |SELECT "sl_name", "sl_avail", "sl_color", "sl_len",
"sl_unit", "sl_len_cm" FROM "shoelace" WHERE NOT (EXISTS (SELECT "shoename"
FROM "shoe" WHERE "slcolor" = "sl_color"));
street |SELECT "r"."name", "r"."thepath", "c"."cname" FROM
"road" "r", "real_city" "c" WHERE "c"."outline" ## "r"."thepath";
----------------------
Import Notes
Resolved by subject fallback
It looks like you're missing a couple of column AS column_new_name clauses
in your rules... What could cause this? I'm not sure maybe one of the big
guys could comments... Jan?
-DEJ
Show quoted text
-----Original Message-----
From: Mike Engelhart [SMTP:mengelhart@earthtrip.com]
Sent: Friday, July 09, 1999 4:51 PM
To: pgsql-general@postgreSQL.org
Subject: Re: [GENERAL] rules failedWhat did regression.diff tell you?
I'm sure someone can give you more insight with that diff information.
-DEJwell here is the relevant part from regression.diffs, but I don't
understand
what it's supposed to be telling me...
Thanks,
Mike*** expected/rules.out Thu Jun 3 02:01:21 1999 --- results/rules.out Fri Jul 9 14:04:16 1999 *************** *** 1066,1076 ****! pg_tables |SELECT "c"."relname" AS "tablename","pg_get_userbyid"("c"."relowner") AS "tableowner", "c"."relhasindex" AS"hasindexes", "c"."relhasrules" AS "hasrules", "c"."reltriggers" >'0'::"int4" AS "hastriggers" FROM "pg_class" "c" WHERE (("c"."relkind" ='r'::"char") OR ("c"."relkind" = 's'::"char")) AND (NOT (EXISTS (SELECT"rulename" FROM "pg_rewrite" WHERE ("ev_class" = "c"."oid") AND ("ev_type" = '1'::"char")))); --- 1066,1076 ---- ! pg_tables |SELECT "c"."relname" AS "tablename","pg_get_userbyid"("c"."relowner"), "c"."relhasindex" AS "hasindexes","c"."relhasrules" AS "hasrules", "c"."reltriggers" > '0'::"int4" AS"hastriggers" FROM "pg_class" "c" WHERE (("c"."relkind" = 'r'::"char") OR("c"."relkind" = 's'::"char")) AND (NOT (EXISTS (SELECT "rulename" FROM"pg_rewrite" WHERE ("ev_class" = "c"."oid") AND ("ev_type" ='1'::"char")))); *************** *** 1082,1088 **** ! shoelace |SELECT "s"."sl_name", "s"."sl_avail", "s"."sl_color","s"."sl_len", "s"."sl_unit", "s"."sl_len" * "u"."un_fact" AS "sl_len_cm"FROM "shoelace_data" "s", "unit" "u" WHERE "s"."sl_unit" = "u"."un_name"; --- 1082,1088 ---- ! shoelace |SELECT "s"."sl_name", "s"."sl_avail", "s"."sl_color","s"."sl_len", "s"."sl_unit", "s"."sl_len" * "u"."un_fact" FROM"shoelace_data" "s", "unit" "u" WHERE "s"."sl_unit" = "u"."un_name";----------------------
Import Notes
Resolved by subject fallback
This is what i did in case it makes a difference. I installed LinuxPPC R5
using the latest installer from them, immediately downloaded postgres 6.5,
edited the template linux_ppc to turn off the compiler optimization that I
saw posted in the archives to get rid of the problem where calling
"destroydb" wouldn't work. Then I compiled and installed postgres and ran
the regression test. I've done this on 2 different machines already. One
was a 604e and one was a PPC with a G3 upgrade card in it.
Thanks,
Mike
Show quoted text
It looks like you're missing a couple of column AS column_new_name clauses
in your rules... What could cause this? I'm not sure maybe one of the big
guys could comments... Jan?
-DEJ
Import Notes
Resolved by subject fallback
At 01:34 +0300 on 10/07/1999, Mike Engelhart wrote:
This is what i did in case it makes a difference. I installed LinuxPPC R5
using the latest installer from them, immediately downloaded postgres 6.5,
edited the template linux_ppc to turn off the compiler optimization that I
saw posted in the archives to get rid of the problem where calling
"destroydb" wouldn't work. Then I compiled and installed postgres and ran
the regression test. I've done this on 2 different machines already. One
was a 604e and one was a PPC with a G3 upgrade card in it.
Just to make sure - when you installed R5, did you make sure you are not
installing the Postgres RPMs that came with it? (Assuming you installed
from the same R5 cd as I did) They were 6.5 beta, I don't know which beta.
If you used the X-based installer, these RPMs install themselves as part of
the servers set of packages.
Herouth
--
Herouth Maoz, Internet developer.
Open University of Israel - Telem project
http://telem.openu.ac.il/~herutma
Just to make sure - when you installed R5, did you make sure you are not
installing the Postgres RPMs that came with it? (Assuming you installed
from the same R5 cd as I did) They were 6.5 beta, I don't know which beta.
If you used the X-based installer, these RPMs install themselves as part of
the servers set of packages.
No, I did a very basic install using the RedHat installer and did NOT
install the 6.5 beta (specifically because it was a beta version). I'm
using the 6.5 version that I installed (even though the "rules failed" error
came up) for some simple things but as I am pretty much of a database
neophyte, I can't seem to figure out where "rules" come into play in a RDBMS
like PostgreSQL and whether or not I need to worry about this or more
specifically in what situation would I need to worry about this.
Thanks,
Mike
Import Notes
Resolved by subject fallback