threads
listlengths
1
2.99k
[ { "msg_contents": "> > 2. configure dies (!)\n> > ---------------------\n> > Running configure, dies with the following:\n> > \n> > checking whether time.h and sys/time.h may both be included... yes\n> > checking whether struct tm is in sys/time.h or time.h... time.h\n> > checking for int timezone... yes\n> > checking for union semun... yes\n> > Argument expected\n> \n> \tPlease investigate this one further and let me know what is\n> required to fix it?\n> \n\nI complained about this one a few months back. There is a test condition\nthat needs to be double-quoted. In my generated configure, it's at line\n#3230 in the test whether gcc needs -traditional.\n\nI seem to recall that it was more a bug in autoconf that in the postgres\nconfigure script.\n\ndarrenk\n", "msg_date": "Mon, 23 Feb 1998 10:50:31 -0500", "msg_from": "[email protected] (Darren King)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Snapshot 23Feb98 under Irix5 --- INSTALLATION BROKEN!!!" } ]
[ { "msg_contents": "\nDone - phew\n\n>\n> On Mon, 23 Feb 1998, Jan Wieck wrote:\n>\n> > STOP\n>\n> Damn, a Supreme's song pops into my head *ack*!\n>\n> > I already have my fingers on that :-)\n> >\n> > GRANT/REVOKE works here now for anything except pg_class. But\n> > I know where it is now. So wait a few minutes. Was a real\n> > submarine bug the system cache (old and ugly since this was\n> > never touched by the regression tests).\n>\n> Okay, let me know when fixed and I'll try again :)\n\n The diff looks so simple and easy. But to find it wasn't fun.\n\n It must have been there for a long time. What happened:\n\n When a tuple in one of some central catalogs was updated, the\n referenced relation got flushed, so it would be reopened on\n the next access (to reflect new triggers, rules and table\n structure changes into the relation cache).\n\n Some data (the tupleDescriptor e.g.) is used in the system\n cache too. So when a relation is subject to the system cache,\n this must know too that a cached system relation got flushed\n because the tupleDesc data gets freed during the flush!\n\n For the GRANT/REVOKE on pg_class it was slightly different.\n There is some local data in inval.c that gets initialized on\n the first invalidation of a tuple in some central catalogs.\n This needs a SysCache lookup in pg_class. But when the first\n of all commands is a GRANT on pg_class, exactly the needed\n tuple is the one actually invalidated. So I added little code\n snippets that the initialization of the local variables in\n inval.c will already happen during InitPostgres().\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/include/utils/catcache.h include/utils/catcache.h\n*** /usr/local/pgsql/sup/pgsql/src/include/utils/catcache.h\tWed Feb 4 09:34:32 1998\n--- include/utils/catcache.h\tMon Feb 23 16:12:36 1998\n***************\n*** 66,71 ****\n--- 66,72 ----\n extern void CatalogCacheIdInvalidate(int cacheId, Index hashIndex,\n \t\t\t\t\t\t ItemPointer pointer);\n extern void ResetSystemCache(void);\n+ extern void SystemCacheRelationFlushed(Oid relId);\n extern CatCache * InitSysCache(char *relname, char *indname, int id, int nkeys,\n \t\t\t int key[], HeapTuple (*iScanfuncP) ());\n extern HeapTuple SearchSysCache(struct catcache * cache, Datum v1, Datum v2,\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/include/utils/inval.h include/utils/inval.h\n*** /usr/local/pgsql/sup/pgsql/src/include/utils/inval.h\tMon Sep 8 23:55:08 1997\n--- include/utils/inval.h\tMon Feb 23 16:57:16 1998\n***************\n*** 16,21 ****\n--- 16,23 ----\n #include <access/htup.h>\n #include <utils/rel.h>\n \n+ extern void InitLocalInvalidateData(void);\n+ \n extern void DiscardInvalid(void);\n \n extern void RegisterInvalid(bool send);\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/cache/catcache.c backend/utils/cache/catcache.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/cache/catcache.c\tThu Feb 12 14:36:23 1998\n--- backend/utils/cache/catcache.c\tMon Feb 23 16:14:59 1998\n***************\n*** 621,626 ****\n--- 621,649 ----\n }\n \n /* --------------------------------\n+ *\t\tSystemCacheRelationFlushed\n+ *\n+ *\tRelationFlushRelation() frees some information referenced in the\n+ *\tcache structures. So we get informed when this is done and arrange\n+ *\tfor the next SearchSysCache() call that this information is setup\n+ *\tagain.\n+ * --------------------------------\n+ */\n+ void\n+ SystemCacheRelationFlushed(Oid relId)\n+ {\n+ \tstruct catcache *cache;\n+ \n+ \tfor (cache = Caches; PointerIsValid(cache); cache = cache->cc_next)\n+ \t{\n+ \t\tif (cache->relationId == relId)\n+ \t\t{\n+ \t\t\tcache->relationId = InvalidOid;\n+ \t\t}\n+ \t}\n+ }\n+ \n+ /* --------------------------------\n *\t\tInitIndexedSysCache\n *\n *\tThis allocates and initializes a cache for a system catalog relation.\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/cache/inval.c backend/utils/cache/inval.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/cache/inval.c\tTue Nov 18 11:23:07 1997\n--- backend/utils/cache/inval.c\tMon Feb 23 16:55:28 1998\n***************\n*** 512,517 ****\n--- 512,531 ----\n \t(*function) (relationId, objectId);\n }\n \n+ \n+ /*\n+ *\tInitLocalInvalidateData\n+ *\n+ *\tSetup this before anything could ever get invalid!\n+ *\tCalled by InitPostgres();\n+ */\n+ void\n+ InitLocalInvalidateData()\n+ {\n+ \tValidateHacks();\n+ }\n+ \n+ \n /*\n * DiscardInvalid --\n *\t\tCauses the invalidated cache state to be discarded.\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/cache/relcache.c backend/utils/cache/relcache.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/cache/relcache.c\tWed Feb 4 09:34:06 1998\n--- backend/utils/cache/relcache.c\tMon Feb 23 16:15:20 1998\n***************\n*** 65,70 ****\n--- 65,71 ----\n #include \"utils/relcache.h\"\n #include \"utils/hsearch.h\"\n #include \"utils/relcache.h\"\n+ #include \"utils/catcache.h\"\n \n #include \"catalog/catname.h\"\n #include \"catalog/catalog.h\"\n***************\n*** 1344,1349 ****\n--- 1345,1351 ----\n \t\tRelationCacheDelete(relation);\n \n \t\tFreeTupleDesc(relation->rd_att);\n+ \t\tSystemCacheRelationFlushed(relation->rd_id);\n \n \t\tFreeTriggerDesc(relation);\n \ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/init/postinit.c backend/utils/init/postinit.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/init/postinit.c\tWed Feb 4 09:34:08 1998\n--- backend/utils/init/postinit.c\tMon Feb 23 16:57:05 1998\n***************\n*** 62,67 ****\n--- 62,68 ----\n #include \"utils/elog.h\"\n #include \"utils/palloc.h\"\n #include \"utils/mcxt.h\"\t\t\t/* for EnableMemoryContext, etc. */\n+ #include \"utils/inval.h\"\n \n #include \"catalog/catname.h\"\n #include \"catalog/pg_database.h\"\n***************\n*** 585,590 ****\n--- 586,597 ----\n \t * ----------------\n \t */\n \tInitUserid();\n+ \n+ \t/* ----------------\n+ \t *\t initialize local data in cache invalidation stuff\n+ \t * ----------------\n+ \t */\n+ \tInitLocalInvalidateData();\n \n \t/* ----------------\n \t *\tok, all done, now let's make sure we don't do it again.\n\n", "msg_date": "Mon, 23 Feb 1998 17:19:14 +0100 (MET)", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Here it is - view permissions" } ]
[ { "msg_contents": "The list is shrinking:\n\n---------------------------------------------------------------------------\n\ntest new view permission code, install new pg_user view for use with \\d\nvariable block size patch(Darren)\nSelf-join optimizer performance problem\nGet interfaces fixed for new protocol\nProfiling improvements?\nProblem with tables >2Gb, add elog()?\nDo we want to add timestamps to elog messages?\nScanKeyData missing initializations\nAlpha/64-bit issues, mkoidname() problem\nViews on aggregates fail\nlarge objects memory exhaustion\nCommit sgml document sources(Thomas)\nCommit html documents(Thomas)\nCommit postscript documents(Thomas)\n\n\n-- \nBruce Momjian\[email protected]\n\n", "msg_date": "Mon, 23 Feb 1998 11:58:09 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Open 6.3 issues" } ]
[ { "msg_contents": "> \n> variable block size patch(Darren)\n>\n\nMove to the TODO list please...thanks.\n", "msg_date": "Mon, 23 Feb 1998 12:14:47 -0500", "msg_from": "[email protected] (Darren King)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Open 6.3 issues" } ]
[ { "msg_contents": ">> > > Why does views default to 'select' permission for 'public'?\n>> > > I think most people will never think of the possibility that others\n>> > > will be able to SELECT their data through views.\n>> > > Should not 'create view' at least print a NOTICE about this?\n>> > \n>> > \tConsidering how much security we are putting around everything\n>> > else, is it unreasonably to have both 'create view'/'create table'\ndefault\n>> > to 'revoke all' to public, and 'grant all' to owner?\n>> \n>> Most commercial databases don't do this.\n>\n>\tWell, just checked with Wayne (My Oracle Guru) and in Oracle,\n>everything is private by default, and you open it up as required/desired\n>to other ppl...\n\nHate to say this, but ANSI says the default has to be no rigths for public.\nInformix has a separate config parameter to enforce this. I use this\nparameter. (NODEFDAC=yes)\nI still think this is a non issue, since the paranoid under us (like myself\non sensitive data) will always\nrevoke all on <new table> from public; first thing after the create table\njust to be sure.\n\nAndreas\n", "msg_date": "Mon, 23 Feb 1998 18:23:03 +0100", "msg_from": "Zeugswetter Andreas SARZ <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Here it is - view permissions]" } ]
[ { "msg_contents": "Hi,\n\n the first step on views using aggregate was successful. But\n I don't know enough about GROUP BY, HAVING and all the other\n stuff. So I need someone to assist me in getting the rewrite\n system to handle this kind of views properly.\n\n The patch below is only for hackers ON THIS TODO TOPIC, it\n makes things temporary worse!!!\n\n What works with it:\n\n create table t1 (k int4);\n CREATE\n insert into t1 values (1);\n INSERT 18441 1\n insert into t1 values (2);\n INSERT 18442 1\n insert into t1 values (3);\n INSERT 18443 1\n\n create table t2 (a int4, k int4);\n CREATE\n insert into t2 values (1, 1);\n INSERT 18454 1\n insert into t2 values (2, 1);\n INSERT 18455 1\n insert into t2 values (3, 1);\n INSERT 18456 1\n insert into t2 values (4, 2);\n INSERT 18457 1\n insert into t2 values (5, 2);\n INSERT 18458 1\n\n create view v1 as\n select k, count(t2.a) from t1 where t1.k = t2.k\n group by k;\n CREATE\n\n select * from v1;\n k|count\n -+-----\n 1| 3\n 2| 2\n (2 rows)\n\n I don't know if it's right that no row with k=3 shows up. I\n had expected a row 'k=3 count=0'. But it's exactly what the\n select statement without the view returns. So it's not a\n problem of the rewrite system any more.\n\n But doing\n\n select k from v1;\n\n still crashes the backend (though somewhere completely\n different).\n\n Before going into details and fixing more things I must have\n some different view definitions and table settings (including\n nested views with and without aggregates) and what they are\n expected to output!\n\n And please some complicated select statements building joins\n from tables and the views with GROUP BY etc. too if possible.\n\n As I don't know enough about what GROUP BY really should do I\n cannot work out all these test cases myself.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\ndiff -c -r rewrite.old/rewriteHandler.c rewrite/rewriteHandler.c\n*** rewrite.old/rewriteHandler.c\tMon Feb 23 18:09:44 1998\n--- rewrite/rewriteHandler.c\tMon Feb 23 18:43:30 1998\n***************\n*** 354,359 ****\n--- 354,366 ----\n \tChangeVarNodes(rule_qual, PRS2_CURRENT_VARNO + rt_length, rt_index, 0);\n \tif (relation_level)\n \t{\n+ \t\tOffsetVarNodes((Node *)rule_action->groupClause, rt_length);\n+ \t\tChangeVarNodes((Node *)rule_action->groupClause,\n+ \t\t\t\t PRS2_CURRENT_VARNO + rt_length, rt_index, 0);\n+ \t\tparsetree->groupClause = nconc(parsetree->groupClause,\n+ \t\t\t\t copyObject(rule_action->groupClause));\n+ \t\tparsetree->hasAggs = rule_action->hasAggs;\n+ \t\tparsetree->hasSubLinks = rule_action->hasSubLinks;\n \t\tHandleViewRule(parsetree, rtable, rule_action->targetList, rt_index,\n \t\t\t\t\t modified);\n \t}\nOnly in rewrite: rewriteHandler.c.swp\ndiff -c -r rewrite.old/rewriteManip.c rewrite/rewriteManip.c\n*** rewrite.old/rewriteManip.c\tMon Feb 23 18:09:44 1998\n--- rewrite/rewriteManip.c\tMon Feb 23 18:36:21 1998\n***************\n*** 79,84 ****\n--- 79,91 ----\n \t\t\t\t}\n \t\t\t}\n \t\t\tbreak;\n+ \t\tcase T_GroupClause:\n+ \t\t\t{\n+ \t\t\t\tGroupClause *grp = (GroupClause *) node;\n+ \n+ \t\t\t\tOffsetVarNodes((Node *) grp->entry, offset);\n+ \t\t\t}\n+ \t\t\tbreak;\n \t\tdefault:\n \t\t\t/* ignore the others */\n \t\t\tbreak;\n***************\n*** 140,145 ****\n--- 147,159 ----\n \n \t\t\t\tChangeVarNodes((Node *)query->qual, old_varno, new_varno,\n \t\t\t\t\t\t\t\t\t\tsublevels_up + 1);\n+ \t\t\t}\n+ \t\t\tbreak;\n+ \t\tcase T_GroupClause:\n+ \t\t\t{\n+ \t\t\t\tGroupClause *grp = (GroupClause *) node;\n+ \n+ \t\t\t\tChangeVarNodes((Node *) grp->entry, old_varno, new_varno, sublevels_up);\n \t\t\t}\n \t\t\tbreak;\n \t\tdefault:\n", "msg_date": "Mon, 23 Feb 1998 19:12:23 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": true, "msg_subject": "Views on aggregates - need assistence" }, { "msg_contents": "> \n> Hi,\n> \n> the first step on views using aggregate was successful. But\n> I don't know enough about GROUP BY, HAVING and all the other\n> stuff. So I need someone to assist me in getting the rewrite\n> system to handle this kind of views properly.\n> \n> The patch below is only for hackers ON THIS TODO TOPIC, it\n> makes things temporary worse!!!\n> \n> What works with it:\n> \n> create table t1 (k int4);\n> CREATE\n> insert into t1 values (1);\n> INSERT 18441 1\n> insert into t1 values (2);\n> INSERT 18442 1\n> insert into t1 values (3);\n> INSERT 18443 1\n> \n> create table t2 (a int4, k int4);\n> CREATE\n> insert into t2 values (1, 1);\n> INSERT 18454 1\n> insert into t2 values (2, 1);\n> INSERT 18455 1\n> insert into t2 values (3, 1);\n> INSERT 18456 1\n> insert into t2 values (4, 2);\n> INSERT 18457 1\n> insert into t2 values (5, 2);\n> INSERT 18458 1\n> \n> create view v1 as\n> select k, count(t2.a) from t1 where t1.k = t2.k\n> group by k;\n> CREATE\n> \n> select * from v1;\n> k|count\n> -+-----\n> 1| 3\n> 2| 2\n> (2 rows)\n> \n> I don't know if it's right that no row with k=3 shows up. I\n> had expected a row 'k=3 count=0'. But it's exactly what the\n> select statement without the view returns. So it's not a\n> problem of the rewrite system any more.\n\nI think the join properly eliminates the k=3 row. The aggregate happens\nafter the join.\n\nFor the aggregate gory details, see backend/optimizer/plan/planner.c. \nYou will see how GROUP and Agg nodes are inserted above the tree to then\nbe handled by the executor. Hopefully if the rewrite system works, the\nchange will be transparent to the optimizer, but you have to set the\nquery Aggreg fields properly when doing this. You can also look at\nparser/parse_agg.c to see how a normal aggregate coming in from the\nparser is configured.\n\nOne other cool way of doing testing is to run the backend with -d3 debug\nlevel, and then look at the post-rewrite trees for an aggregate query\nand an aggregate from a view, and see if they are the same. The output\nshows almost all the fields in the query.\n\n> \n> But doing\n> \n> select k from v1;\n> \n> still crashes the backend (though somewhere completely\n> different).\n> \n> Before going into details and fixing more things I must have\n> some different view definitions and table settings (including\n> nested views with and without aggregates) and what they are\n> expected to output!\n> \n> And please some complicated select statements building joins\n> from tables and the views with GROUP BY etc. too if possible.\n> \n> As I don't know enough about what GROUP BY really should do I\n> cannot work out all these test cases myself.\n> \n> \n> Jan\n> \n> --\n> \n> #======================================================================#\n> # It's easier to get forgiveness for being wrong than for being right. #\n> # Let's break this rule - forgive me. #\n> #======================================== [email protected] (Jan Wieck) #\n> \n> \n> diff -c -r rewrite.old/rewriteHandler.c rewrite/rewriteHandler.c\n> *** rewrite.old/rewriteHandler.c\tMon Feb 23 18:09:44 1998\n> --- rewrite/rewriteHandler.c\tMon Feb 23 18:43:30 1998\n> ***************\n> *** 354,359 ****\n> --- 354,366 ----\n> \tChangeVarNodes(rule_qual, PRS2_CURRENT_VARNO + rt_length, rt_index, 0);\n> \tif (relation_level)\n> \t{\n> + \t\tOffsetVarNodes((Node *)rule_action->groupClause, rt_length);\n> + \t\tChangeVarNodes((Node *)rule_action->groupClause,\n> + \t\t\t\t PRS2_CURRENT_VARNO + rt_length, rt_index, 0);\n> + \t\tparsetree->groupClause = nconc(parsetree->groupClause,\n> + \t\t\t\t copyObject(rule_action->groupClause));\n> + \t\tparsetree->hasAggs = rule_action->hasAggs;\n> + \t\tparsetree->hasSubLinks = rule_action->hasSubLinks;\n> \t\tHandleViewRule(parsetree, rtable, rule_action->targetList, rt_index,\n> \t\t\t\t\t modified);\n> \t}\n> Only in rewrite: rewriteHandler.c.swp\n> diff -c -r rewrite.old/rewriteManip.c rewrite/rewriteManip.c\n> *** rewrite.old/rewriteManip.c\tMon Feb 23 18:09:44 1998\n> --- rewrite/rewriteManip.c\tMon Feb 23 18:36:21 1998\n> ***************\n> *** 79,84 ****\n> --- 79,91 ----\n> \t\t\t\t}\n> \t\t\t}\n> \t\t\tbreak;\n> + \t\tcase T_GroupClause:\n> + \t\t\t{\n> + \t\t\t\tGroupClause *grp = (GroupClause *) node;\n> + \n> + \t\t\t\tOffsetVarNodes((Node *) grp->entry, offset);\n> + \t\t\t}\n> + \t\t\tbreak;\n> \t\tdefault:\n> \t\t\t/* ignore the others */\n> \t\t\tbreak;\n> ***************\n> *** 140,145 ****\n> --- 147,159 ----\n> \n> \t\t\t\tChangeVarNodes((Node *)query->qual, old_varno, new_varno,\n> \t\t\t\t\t\t\t\t\t\tsublevels_up + 1);\n> + \t\t\t}\n> + \t\t\tbreak;\n> + \t\tcase T_GroupClause:\n> + \t\t\t{\n> + \t\t\t\tGroupClause *grp = (GroupClause *) node;\n> + \n> + \t\t\t\tChangeVarNodes((Node *) grp->entry, old_varno, new_varno, sublevels_up);\n> \t\t\t}\n> \t\t\tbreak;\n> \t\tdefault:\n> \n> \n\n\n-- \nBruce Momjian\[email protected]\n", "msg_date": "Mon, 23 Feb 1998 13:49:23 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "\nBruce wrote:\n> > create view v1 as\n> > select k, count(t2.a) from t1 where t1.k = t2.k\n> > group by k;\n> > CREATE\n> >\n> > select * from v1;\n> > k|count\n> > -+-----\n> > 1| 3\n> > 2| 2\n> > (2 rows)\n> >\n> > I don't know if it's right that no row with k=3 shows up. I\n> > had expected a row 'k=3 count=0'. But it's exactly what the\n> > select statement without the view returns. So it's not a\n> > problem of the rewrite system any more.\n>\n> I think the join properly eliminates the k=3 row. The aggregate happens\n> after the join.\n\n Then it's OK.\n\n>\n> For the aggregate gory details, see backend/optimizer/plan/planner.c.\n> You will see how GROUP and Agg nodes are inserted above the tree to then\n> be handled by the executor. Hopefully if the rewrite system works, the\n> change will be transparent to the optimizer, but you have to set the\n> query Aggreg fields properly when doing this. You can also look at\n> parser/parse_agg.c to see how a normal aggregate coming in from the\n> parser is configured.\n>\n> One other cool way of doing testing is to run the backend with -d3 debug\n> level, and then look at the post-rewrite trees for an aggregate query\n> and an aggregate from a view, and see if they are the same. The output\n> shows almost all the fields in the query.\n\n That's exactly how I saw that the rewritten parsetree missed\n the groupClause from the views select and the hasAgg flag,\n and what told me that OffsetVarNodes() and ChangeVarNodes()\n didn't handle the T_GroupClause :-)\n\n Anyway - the rewrite system doesn't handle the view queries\n sortClause, havingQual and unionClause either. And I really\n think doing all this in one step is better than groupClause\n now and the others later. But doing all is way too much to be\n done properly for 6.3. So I ask for moving all these issues\n into the 6.4 TODO.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\n", "msg_date": "Mon, 23 Feb 1998 20:41:17 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "> That's exactly how I saw that the rewritten parsetree missed\n> the groupClause from the views select and the hasAgg flag,\n> and what told me that OffsetVarNodes() and ChangeVarNodes()\n> didn't handle the T_GroupClause :-)\n\nYep, the fact the switch defaults to nothing can be a problem. Some\nday, I was going to look at all the switch defaults to make sure\nskipping it is really the proper thing to do, rather than elog out.\n\n\n> Anyway - the rewrite system doesn't handle the view queries\n> sortClause, havingQual and unionClause either. And I really\n> think doing all this in one step is better than groupClause\n> now and the others later. But doing all is way too much to be\n> done properly for 6.3. So I ask for moving all these issues\n> into the 6.4 TODO.\n\nActually, it does handle unions of views, but not views of unions. \nInformix doesn't support it either, and I don't know what the other\ndbms's do, but I think I am going to find out soon from someone. :-)\n\nI will move it to the TODO list.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n\n", "msg_date": "Mon, 23 Feb 1998 14:46:10 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "On Mon, 23 Feb 1998, Bruce Momjian wrote:\n\n> Actually, it does handle unions of views, but not views of unions. \n> Informix doesn't support it either, and I don't know what the other\n> dbms's do, but I think I am going to find out soon from someone. :-)\n\n\tWhat exactly would you like me to try here? *raised eyebrow*\n\n\n", "msg_date": "Mon, 23 Feb 1998 15:02:41 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "> \n> On Mon, 23 Feb 1998, Bruce Momjian wrote:\n> \n> > Actually, it does handle unions of views, but not views of unions. \n> > Informix doesn't support it either, and I don't know what the other\n> > dbms's do, but I think I am going to find out soon from someone. :-)\n> \n> \tWhat exactly would you like me to try here? *raised eyebrow*\n> \n> \n> \n\n\n\tcreate view as\n\t\tselect oid from pg_user union select oid from pg_class\n\nor something like that. That will not work under PostgreSQL. But you\ncan use views as part of a union:\n\n\tselect oid from view1\n\tunion\n\tselect oid from view2\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 23 Feb 1998 15:05:14 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "On Mon, 23 Feb 1998, Bruce Momjian wrote:\n\n> > \n> > On Mon, 23 Feb 1998, Bruce Momjian wrote:\n> > \n> > > Actually, it does handle unions of views, but not views of unions. \n> > > Informix doesn't support it either, and I don't know what the other\n> > > dbms's do, but I think I am going to find out soon from someone. :-)\n> > \n> > \tWhat exactly would you like me to try here? *raised eyebrow*\n> > \n> > \n> > \n> \n> \n> \tcreate view as\n> \t\tselect oid from pg_user union select oid from pg_class\n> \n> or something like that. That will not work under PostgreSQL. But you\n> can use views as part of a union:\n> \n> \tselect oid from view1\n> \tunion\n> \tselect oid from view2\n\nYou mean like:\n\nSQL> select * from one\n 2 ;\n\n A\n----------\n 3\n 4\n 2\n\nSQL> create table two ( B int );\n\nTable created.\n\nSQL> insert into two values ( 1 );\n\n1 row created.\n\nSQL> insert into two values ( 2 ) ;\n\n1 row created.\n\nSQL> insert into two values ( 3 ) ;\n\n1 row created.\n\nSQL> create view v1 as select A from one union select B from two;\n\nView created.\n\nSQL> select * from v1;\n\n A\n----------\n 1\n 2\n 3\n 4\n\n\n\n", "msg_date": "Mon, 23 Feb 1998 15:22:22 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "> > can use views as part of a union:\n> > \n> > \tselect oid from view1\n> > \tunion\n> > \tselect oid from view2\n> \n> You mean like:\n> \n> SQL> select * from one\n> 2 ;\n> \n> A\n> ----------\n> 3\n> 4\n> 2\n> \n> SQL> create table two ( B int );\n> \n> Table created.\n> SQL> create view v1 as select A from one union select B from two;\n> \n> View created.\n> \n> SQL> select * from v1;\n> \n> A\n> ----------\n> 1\n> 2\n> 3\n> 4\n> \n\nYep, we can't currently do that.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 23 Feb 1998 15:25:48 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "Jan Wieck wrote:\n> \n> Hi,\n> \n> the first step on views using aggregate was successful. But\n> I don't know enough about GROUP BY, HAVING and all the other\n> stuff. So I need someone to assist me in getting the rewrite\n> system to handle this kind of views properly.\n\n...\n\n> \n> Before going into details and fixing more things I must have\n> some different view definitions and table settings (including\n> nested views with and without aggregates) and what they are\n> expected to output!\n> \n> And please some complicated select statements building joins\n> from tables and the views with GROUP BY etc. too if possible.\n\ncreate view v as select x, sum(y) as sy from A group by x;\nselect * from B, V where B.z = V.sy;\n\n- how can we handle this (aggregates in WHERE) ?\nIt seems that current VIEW implementation using RULEs has\nunresolvable problems :(\n\nVadim\n", "msg_date": "Tue, 24 Feb 1998 09:29:25 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "\nThank you for addressing this issue! It has been bugging me for a\nwhile. Usually I just select into a new table and select from that\n(but yes, it is multiple queries). Normally I want to do something\nlike:\n\nselect bar,count(a.oid) as c from a,b where a.ab = b.bar and c > 1;\n\nThis actually seems to be a different issue with more complicated\nunresolvable (?) problems, because you want a pre-result (per\ncombination of instances matched) where and a result where (per result\ntuple).. Is this possible to do using subqueries? I'll try to find out.\t\n\nThis might be totally unrelated, actually. I do not know enough about\nview system to understand unresolvable conflicts.\n\n--brett\n\n\nOn Tue, 24 February 1998, at 09:29:25, Vadim B. Mikheev wrote:\n\n> create view v as select x, sum(y) as sy from A group by x;\n> select * from B, V where B.z = V.sy;\n> \n> - how can we handle this (aggregates in WHERE) ?\n> It seems that current VIEW implementation using RULEs has\n> unresolvable problems :(\n> \n> Vadim\n", "msg_date": "Mon, 23 Feb 1998 20:59:10 -0800", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "Brett McCormick wrote:\n> \n> Thank you for addressing this issue! It has been bugging me for a\n> while. Usually I just select into a new table and select from that\n> (but yes, it is multiple queries). Normally I want to do something\n> like:\n> \n> select bar,count(a.oid) as c from a,b where a.ab = b.bar and c > 1;\n ^^^^^\nThis is what HAVING is for (unimplemented, yet).\n\n> \n> This actually seems to be a different issue with more complicated\n> unresolvable (?) problems, because you want a pre-result (per\n> combination of instances matched) where and a result where (per result\n> tuple).. Is this possible to do using subqueries? I'll try to find out.\n\nNo, if you really want to see count in output. If you would be happy\nwith bar only then this could help:\n\nselect bar from b where 1 < (select count(*) from a where a.ab = b.bar);\n\n(Having HAVING would be better, of 'course :)\n\n> This might be totally unrelated, actually. I do not know enough about\n> view system to understand unresolvable conflicts.\n\nYou could CREATE VIEW V as select bar,count(a.oid) as c from a,b \nwhere a.ab = b.bar group by bar;\nand then just select * from v where c > 1.\n\nVadim\n", "msg_date": "Tue, 24 Feb 1998 12:19:53 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "> > Before going into details and fixing more things I must have\n> > some different view definitions and table settings (including\n> > nested views with and without aggregates) and what they are\n> > expected to output!\n> >\n> > And please some complicated select statements building joins\n> > from tables and the views with GROUP BY etc. too if possible.\n>\n> create view v as select x, sum(y) as sy from A group by x;\n> select * from B, V where B.z = V.sy;\n>\n> - how can we handle this (aggregates in WHERE) ?\n> It seems that current VIEW implementation using RULEs has\n> unresolvable problems :(\n\nWell, there may be a subset of the possible cases which could work?\n\n", "msg_date": "Tue, 24 Feb 1998 06:49:56 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "> Anyway - the rewrite system doesn't handle the view queries\n> sortClause, havingQual and unionClause either. And I really\n> think doing all this in one step is better than groupClause\n> now and the others later. But doing all is way too much to be\n> done properly for 6.3. So I ask for moving all these issues\n> into the 6.4 TODO.\n\nMoved to TODO.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 10:36:36 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "Kello!\n\nI have a recusive relation, like this:\n=> create table re( name text, oid parent);\nand needed the name from a tuple, and the name of all parents...\ni tryd some, like:\n=> create function fullname(oid) returns text\n-> as 'select fullname(re.parent) || re.name from re where re.oid=$1;'\n-> language 'sql'; \nthat isn't work. of course ;(\n\n i can get a name, and the parents oid, and the oid of parents parent etc...\n with _MORE_ queries. \n\nfor example: \n=> select oid,* from re;\noid | name | parent\n----+------+--------\n5000|one | (NULL or 0) \n5001|two | 5000\n5002|3d | 5000\n5003|4d | 5002\ni now the oid:5003. i need the name: \"one/two/4d\"\nmust i send thees queries to the backend? (in pseudo code):\n$curr=5003\n$fulln=''\nwhile $curr do\n => SELECT name, parent FROM re WHERE oid=$curr;\n $fulln='$fulln/$name'; $curr=$parent;\nenddo\nso i liked send _ONLY_ 5003, and reveive in a trice the full name.\nthis time i can't this ;(\n\nsprintf (\"`-''-/\").___..--''\"`-._ Error In\n(\"%|s\", `6_ 6 ) `-. ( ).`-.__.`) Loading Object\n\"Petike\" (_Y_.)' ._ ) `._ `. ``-..-' line:3\n/* Neko */ _..`--'_..-_/ /--'_.' ,' Before /*Neko*/\n ); (il),-'' (li),' ((!.-'\t see: http://lsc.kva.hu\n\n", "msg_date": "Mon, 16 Mar 1998 15:37:50 +0100 (NFT)", "msg_from": "\"Vazsonyi Peter[ke]\" <[email protected]>", "msg_from_op": false, "msg_subject": "recursive seek...?" } ]
[ { "msg_contents": "\nOkay...\n\n\tI've modified initdb.sh so that ALL is revoked from pg_user, with\na view being created to look into it for usename and usesysid, which are\nrequired by psql...\n\n\tThis gets it so that psql works for \\d\n\n\tI tried to do a rewrite rule on db_user such that password would\nbecome '*********', but that does't appear to work?\n\n\tReports of any problems associated with any of the pg_ system\ntables, please let me know\n\n\n\n", "msg_date": "Mon, 23 Feb 1998 14:29:00 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "pg_user \"sealed\"" }, { "msg_contents": "On Mon, 23 Feb 1998, Jan Wieck wrote:\n\n> \n> Marc wrote:\n> >\n> >\n> > Okay...\n> >\n> > I've modified initdb.sh so that ALL is revoked from pg_user, with\n> > a view being created to look into it for usename and usesysid, which are\n> > required by psql...\n> >\n> > This gets it so that psql works for \\d\n> >\n> > I tried to do a rewrite rule on db_user such that password would\n> > become '*********', but that does't appear to work?\n> >\n> > Reports of any problems associated with any of the pg_ system\n> > tables, please let me know\n> \n> Since you changed ACL_WORLD_DEFAULT to ACL_NO too, there are\n> now problems on \\d <table> (pg_attribute: Permission denied).\n> And thus I expect more problems. I think users should have\n> SELECT permission on non-critical system catalogs by default.\n\n\tOkay, I've just been adding in appropriate 'GRANT SELECT's inside\nof initdb.sh, for lack of a better idea...\n\n> But I don't think that setting explicit GRANT's on all the\n> system catalogs is a good thing. Due to the ACL parsing I\n> would expect some loss of performance.\n> \n> So if the relname is given to acldefault() in\n> utils/adt/acl.c, it can do a IsSystemRelationName() on it and\n> return ACL_RD instead of ACL_WORLD_DEFAULT.\n\n\t...which this definitely sound like :) Want to make the change\nand send me a patch? \n\n", "msg_date": "Mon, 23 Feb 1998 15:01:12 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] pg_user \"sealed\"" }, { "msg_contents": "\nMarc wrote:\n>\n>\n> Okay...\n>\n> I've modified initdb.sh so that ALL is revoked from pg_user, with\n> a view being created to look into it for usename and usesysid, which are\n> required by psql...\n>\n> This gets it so that psql works for \\d\n>\n> I tried to do a rewrite rule on db_user such that password would\n> become '*********', but that does't appear to work?\n>\n> Reports of any problems associated with any of the pg_ system\n> tables, please let me know\n\n Since you changed ACL_WORLD_DEFAULT to ACL_NO too, there are\n now problems on \\d <table> (pg_attribute: Permission denied).\n And thus I expect more problems. I think users should have\n SELECT permission on non-critical system catalogs by default.\n\n But I don't think that setting explicit GRANT's on all the\n system catalogs is a good thing. Due to the ACL parsing I\n would expect some loss of performance.\n\n So if the relname is given to acldefault() in\n utils/adt/acl.c, it can do a IsSystemRelationName() on it and\n return ACL_RD instead of ACL_WORLD_DEFAULT.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\n", "msg_date": "Mon, 23 Feb 1998 21:01:31 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] pg_user \"sealed\"" }, { "msg_contents": "> Since you changed ACL_WORLD_DEFAULT to ACL_NO too, there are\n> now problems on \\d <table> (pg_attribute: Permission denied).\n> And thus I expect more problems. I think users should have\n> SELECT permission on non-critical system catalogs by default.\n> \n> But I don't think that setting explicit GRANT's on all the\n> system catalogs is a good thing. Due to the ACL parsing I\n> would expect some loss of performance.\n> \n> So if the relname is given to acldefault() in\n> utils/adt/acl.c, it can do a IsSystemRelationName() on it and\n> return ACL_RD instead of ACL_WORLD_DEFAULT.\n\nNice solution.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 23 Feb 1998 15:15:01 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] pg_user \"sealed\"" }, { "msg_contents": "\nSo here it is,\n\n> > So if the relname is given to acldefault() in\n> > utils/adt/acl.c, it can do a IsSystemRelationName() on it and\n> > return ACL_RD instead of ACL_WORLD_DEFAULT.\n>\n> Nice solution.\n\n There might only be one problem left. The acl items output\n regproc too sets up a default entry and uses this if the\n passed in aip is NULL. For types output regproc we cannot\n pass in the relation name because this call happens trough\n the fmgr from somewhere else. I don't know if this could ever\n happen since the system would never produce an empty acl from\n inside or by the aclparse() input function. Might be a good\n thing to change aclitemout() for now to throw an elog() if\n aip is NULL and look if this ever happens.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/catalog/aclchk.c ./backend/catalog/aclchk.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/catalog/aclchk.c\tThu Feb 12 14:35:47 1998\n--- ./backend/catalog/aclchk.c\tMon Feb 23 22:27:24 1998\n***************\n*** 39,45 ****\n #include \"utils/tqual.h\"\n #include \"fmgr.h\"\n \n! static int32 aclcheck(Acl *acl, AclId id, AclIdType idtype, AclMode mode);\n \n /*\n * Enable use of user relations in place of real system catalogs.\n--- 39,45 ----\n #include \"utils/tqual.h\"\n #include \"fmgr.h\"\n \n! static int32 aclcheck(char *relname, Acl *acl, AclId id, AclIdType idtype, AclMode mode);\n \n /*\n * Enable use of user relations in place of real system catalogs.\n***************\n*** 150,156 ****\n \t\telog(DEBUG, \"ChangeAcl: using default ACL\");\n #endif\n /*\t\told_acl = acldefault(((Form_pg_class) GETSTRUCT(htp))->relowner); */\n! \t\told_acl = acldefault();\n \t\tfree_old_acl = 1;\n \t}\n \n--- 150,156 ----\n \t\telog(DEBUG, \"ChangeAcl: using default ACL\");\n #endif\n /*\t\told_acl = acldefault(((Form_pg_class) GETSTRUCT(htp))->relowner); */\n! \t\told_acl = acldefault(relname);\n \t\tfree_old_acl = 1;\n \t}\n \n***************\n*** 281,287 ****\n * any one of the requirements of 'mode'. Returns 0 otherwise.\n */\n static int32\n! aclcheck(Acl *acl, AclId id, AclIdType idtype, AclMode mode)\n {\n \tunsigned i;\n \tAclItem *aip,\n--- 281,287 ----\n * any one of the requirements of 'mode'. Returns 0 otherwise.\n */\n static int32\n! aclcheck(char *relname, Acl *acl, AclId id, AclIdType idtype, AclMode mode)\n {\n \tunsigned i;\n \tAclItem *aip,\n***************\n*** 292,298 ****\n \t/* if no acl is found, use world default */\n \tif (!acl)\n \t{\n! \t\tacl = acldefault();\n \t}\n \n \tnum = ACL_NUM(acl);\n--- 292,298 ----\n \t/* if no acl is found, use world default */\n \tif (!acl)\n \t{\n! \t\tacl = acldefault(relname);\n \t}\n \n \tnum = ACL_NUM(acl);\n***************\n*** 475,481 ****\n \t\t\t\t\t\t\t\t\t Anum_pg_class_relowner,\n \t\t\t\t\t\t\t\t\t RelationGetTupleDescriptor(relation),\n \t\t\t\t\t\t\t\t\t (bool *) NULL);\n! \t\tacl = aclownerdefault(ownerId);\n \t}\n #else\n \t{\t\t\t\t\t\t\t/* This is why the syscache is great... */\n--- 475,481 ----\n \t\t\t\t\t\t\t\t\t Anum_pg_class_relowner,\n \t\t\t\t\t\t\t\t\t RelationGetTupleDescriptor(relation),\n \t\t\t\t\t\t\t\t\t (bool *) NULL);\n! \t\tacl = aclownerdefault(relname, ownerId);\n \t}\n #else\n \t{\t\t\t\t\t\t\t/* This is why the syscache is great... */\n***************\n*** 511,517 ****\n \t\theap_close(relation);\n \t}\n #endif\n! \tresult = aclcheck(acl, id, (AclIdType) ACL_IDTYPE_UID, mode);\n \tif (acl)\n \t\tpfree(acl);\n \treturn (result);\n--- 511,517 ----\n \t\theap_close(relation);\n \t}\n #endif\n! \tresult = aclcheck(relname, acl, id, (AclIdType) ACL_IDTYPE_UID, mode);\n \tif (acl)\n \t\tpfree(acl);\n \treturn (result);\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/adt/acl.c ./backend/utils/adt/acl.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/adt/acl.c\tThu Feb 12 14:36:19 1998\n--- ./backend/utils/adt/acl.c\tMon Feb 23 22:32:56 1998\n***************\n*** 18,23 ****\n--- 18,24 ----\n #include <utils/memutils.h>\n #include \"utils/acl.h\"\n #include \"utils/syscache.h\"\n+ #include \"catalog/catalog.h\"\n #include \"catalog/pg_user.h\"\n #include \"miscadmin.h\"\n \n***************\n*** 342,348 ****\n }\n \n Acl\t\t *\n! aclownerdefault(AclId ownerid)\n {\n \tAcl\t\t *acl;\n \tAclItem *aip;\n--- 343,349 ----\n }\n \n Acl\t\t *\n! aclownerdefault(char *relname, AclId ownerid)\n {\n \tAcl\t\t *acl;\n \tAclItem *aip;\n***************\n*** 351,357 ****\n \taip = ACL_DAT(acl);\n \taip[0].ai_idtype = ACL_IDTYPE_WORLD;\n \taip[0].ai_id = ACL_ID_WORLD;\n! \taip[0].ai_mode = ACL_WORLD_DEFAULT;\n \taip[1].ai_idtype = ACL_IDTYPE_UID;\n \taip[1].ai_id = ownerid;\n \taip[1].ai_mode = ACL_OWNER_DEFAULT;\n--- 352,358 ----\n \taip = ACL_DAT(acl);\n \taip[0].ai_idtype = ACL_IDTYPE_WORLD;\n \taip[0].ai_id = ACL_ID_WORLD;\n! \taip[0].ai_mode = IsSystemRelationName(relname) ? ACL_RD : ACL_WORLD_DEFAULT;\n \taip[1].ai_idtype = ACL_IDTYPE_UID;\n \taip[1].ai_id = ownerid;\n \taip[1].ai_mode = ACL_OWNER_DEFAULT;\n***************\n*** 359,365 ****\n }\n \n Acl\t\t *\n! acldefault(void)\n {\n \tAcl\t\t *acl;\n \tAclItem *aip;\n--- 360,366 ----\n }\n \n Acl\t\t *\n! acldefault(char *relname)\n {\n \tAcl\t\t *acl;\n \tAclItem *aip;\n***************\n*** 368,374 ****\n \taip = ACL_DAT(acl);\n \taip[0].ai_idtype = ACL_IDTYPE_WORLD;\n \taip[0].ai_id = ACL_ID_WORLD;\n! \taip[0].ai_mode = ACL_WORLD_DEFAULT;\n \treturn (acl);\n }\n \n--- 369,375 ----\n \taip = ACL_DAT(acl);\n \taip[0].ai_idtype = ACL_IDTYPE_WORLD;\n \taip[0].ai_id = ACL_ID_WORLD;\n! \taip[0].ai_mode = IsSystemRelationName(relname) ? ACL_RD : ACL_WORLD_DEFAULT;\n \treturn (acl);\n }\n \ndiff -c -r /usr/local/pgsql/sup/pgsql/src/include/utils/acl.h ./include/utils/acl.h\n*** /usr/local/pgsql/sup/pgsql/src/include/utils/acl.h\tMon Feb 23 20:42:08 1998\n--- ./include/utils/acl.h\tMon Feb 23 22:25:47 1998\n***************\n*** 135,142 ****\n /*\n * routines used internally (parser, etc.)\n */\n! extern Acl *aclownerdefault(AclId ownerid);\n! extern Acl *acldefault(void);\n extern Acl *aclinsert3(Acl *old_acl, AclItem *mod_aip, unsigned modechg);\n \n extern char *aclmakepriv(char *old_privlist, char new_priv);\n--- 135,142 ----\n /*\n * routines used internally (parser, etc.)\n */\n! extern Acl *aclownerdefault(char *relname, AclId ownerid);\n! extern Acl *acldefault(char *relname);\n extern Acl *aclinsert3(Acl *old_acl, AclItem *mod_aip, unsigned modechg);\n \n extern char *aclmakepriv(char *old_privlist, char new_priv);\n", "msg_date": "Mon, 23 Feb 1998 23:01:36 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] pg_user \"sealed\"" } ]
[ { "msg_contents": "> \n> Update of /usr/local/cvsroot/pgsql/src/bin/initdb\n> In directory hub.org:/tmp/cvs-serv23999/bin/initdb\n> \n> Modified Files:\n> \tinitdb.sh \n> Log Message:\n> \n> Modify initdb.sh so that it makes pg_user readable through view db_user\n> Modify psql so that it uses db_user instead of pg_user\n> GRANT SELECT on pg_class\n\nI don't know if I like the new name db_user? What do other people\nthink? I thought pg_user_no_pwd would be nice.\n\n\n-- \nBruce Momjian\[email protected]\n", "msg_date": "Mon, 23 Feb 1998 14:41:13 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> > \n> > Update of /usr/local/cvsroot/pgsql/src/bin/initdb\n> > In directory hub.org:/tmp/cvs-serv23999/bin/initdb\n> > \n> > Modified Files:\n> > \tinitdb.sh \n> > Log Message:\n> > \n> > Modify initdb.sh so that it makes pg_user readable through view db_user\n> > Modify psql so that it uses db_user instead of pg_user\n> > GRANT SELECT on pg_class\n> \n> I don't know if I like the new name db_user? What do other people\n> think? I thought pg_user_no_pwd would be nice.\n\n\ncreate view pg_users as ...\nERROR: Illegal class name: pg_users -- pg_ is reserved for system catalogs\n\n> \n> \n> -- \n> Bruce Momjian\n> [email protected]\n> \n> \n\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Mon, 23 Feb 1998 21:13:51 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> > \n> > > \n> > > Update of /usr/local/cvsroot/pgsql/src/bin/initdb\n> > > In directory hub.org:/tmp/cvs-serv23999/bin/initdb\n> > > \n> > > Modified Files:\n> > > \tinitdb.sh \n> > > Log Message:\n> > > \n> > > Modify initdb.sh so that it makes pg_user readable through view db_user\n> > > Modify psql so that it uses db_user instead of pg_user\n> > > GRANT SELECT on pg_class\n> > \n> > I don't know if I like the new name db_user? What do other people\n> > think? I thought pg_user_no_pwd would be nice.\n> \n> \n> create view pg_users as ...\n> ERROR: Illegal class name: pg_users -- pg_ is reserved for system catalogs\n\nOops, yep.\n\nI guess I just liked that the pg_ stuff was all system stuff. Do you\nget this error when creating it from postgres, as initdb does? That\nwould be a solution. Worked here.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 23 Feb 1998 15:17:08 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "On Mon, 23 Feb 1998, Bruce Momjian wrote:\n\n> > \n> > > \n> > > > \n> > > > Update of /usr/local/cvsroot/pgsql/src/bin/initdb\n> > > > In directory hub.org:/tmp/cvs-serv23999/bin/initdb\n> > > > \n> > > > Modified Files:\n> > > > \tinitdb.sh \n> > > > Log Message:\n> > > > \n> > > > Modify initdb.sh so that it makes pg_user readable through view db_user\n> > > > Modify psql so that it uses db_user instead of pg_user\n> > > > GRANT SELECT on pg_class\n> > > \n> > > I don't know if I like the new name db_user? What do other people\n> > > think? I thought pg_user_no_pwd would be nice.\n> > \n> > \n> > create view pg_users as ...\n> > ERROR: Illegal class name: pg_users -- pg_ is reserved for system catalogs\n> \n> Oops, yep.\n> \n> I guess I just liked that the pg_ stuff was all system stuff. Do you\n> get this error when creating it from postgres, as initdb does? That\n> would be a solution. Worked here.\n\n\tMy thought was more splitting the difference between a system\ntable (pg_) vs system view (db_) *shrug* Okay, I was grasping here :)\n\n\n", "msg_date": "Mon, 23 Feb 1998 15:23:54 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> > > \n> > > create view pg_users as ...\n> > > ERROR: Illegal class name: pg_users -- pg_ is reserved for system catalogs\n> > \n> > Oops, yep.\n> > \n> > I guess I just liked that the pg_ stuff was all system stuff. Do you\n> > get this error when creating it from postgres, as initdb does? That\n> > would be a solution. Worked here.\n> \n> \tMy thought was more splitting the difference between a system\n> table (pg_) vs system view (db_) *shrug* Okay, I was grasping here :)\n> \n> \n> \n\nI am afraid the db_user is going to confuse people, and they are going\nto start asking how it got there, or they are going to delete it and ask\nwhy \\d doesn't work.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 23 Feb 1998 15:26:47 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> > > I don't know if I like the new name db_user? What do other people\n> > > think? I thought pg_user_no_pwd would be nice.\n> > \n> > \n> > create view pg_users as ...\n> > ERROR: Illegal class name: pg_users -- pg_ is reserved for system catalogs\n> \n> Oops, yep.\n> \n> I guess I just liked that the pg_ stuff was all system stuff. Do you\n> get this error when creating it from postgres, as initdb does? That\n> would be a solution. Worked here.\n\n even if running postgres directly from pgsql account.\n\n But I think it's right to have views/tables named db_\n or sys_ too. Other RDBMS's have them too (Oracle).\n\n And I don't know if ALL the places where IsSystemRelationName()\n is used are happy with things that in fact aren't really\n hardwired system catalogs.\n\n Just let's choose one prefix for all of them and use\n that then. Maybe we would like to restrict the use of\n this prefix to superusers only. As I think there could\n be more information in the catalogs that we want to\n hide from users in the future, a group of db_ views,\n where all the completely open catalogs are just mapped\n by SELECT * wouldn't be a bad idea.\n\n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Mon, 23 Feb 1998 21:35:21 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> > > > I don't know if I like the new name db_user? What do other people\n> > > > think? I thought pg_user_no_pwd would be nice.\n> > > \n> > > \n> > > create view pg_users as ...\n> > > ERROR: Illegal class name: pg_users -- pg_ is reserved for system catalogs\n> > \n> > Oops, yep.\n> > \n> > I guess I just liked that the pg_ stuff was all system stuff. Do you\n> > get this error when creating it from postgres, as initdb does? That\n> > would be a solution. Worked here.\n> \n> even if running postgres directly from pgsql account.\n\nHere's what I did:\n\necho 'create view pg_x as select * from pg_user' |aspg postgres -F -Q -D\n/u/pg/data template1\n\nI am suggesting we do this in initdb, just like the others.\n> \n> But I think it's right to have views/tables named db_\n> or sys_ too. Other RDBMS's have them too (Oracle).\n> \n> And I don't know if ALL the places where IsSystemRelationName()\n> is used are happy with things that in fact aren't really\n> hardwired system catalogs.\n> \n> Just let's choose one prefix for all of them and use\n> that then. Maybe we would like to restrict the use of\n> this prefix to superusers only. As I think there could\n> be more information in the catalogs that we want to\n> hide from users in the future, a group of db_ views,\n> where all the completely open catalogs are just mapped\n> by SELECT * wouldn't be a bad idea.\n\nCan I suggest pgview_ then? Another problem is that a \\d on an empty\ndatabase, \\d is going to show this view, isn't it. Kind of strange to\nme.\n\nI have a solution. Create the view in initdb as pguser_no_pwd, then\nafter that execute an update statement on pg_class:\n\n\tupdate pg_class \n\tset relname = 'pg_user_no_pwd'\n\twhere relname = 'pguser_no_pwd';\n\nWe are using Jan's cache fix already. I just tried it and it works. \nAnd it means it doesn't show up in \\d, and a user can't accidentally\ndelete it. Sounds like a real winner.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 23 Feb 1998 15:55:12 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "On Mon, 23 Feb 1998, Bruce Momjian wrote:\n\n> \n> Can I suggest pgview_ then? Another problem is that a \\d on an empty\n> database, \\d is going to show this view, isn't it. Kind of strange to\n> me.\n\n\tI modified psql already such that:\n\n\trelname !~ '^[pd][bg]_'\n\n\tis ignored :)\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 23 Feb 1998 23:26:42 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> On Mon, 23 Feb 1998, Bruce Momjian wrote:\n> \n> > \n> > Can I suggest pgview_ then? Another problem is that a \\d on an empty\n> > database, \\d is going to show this view, isn't it. Kind of strange to\n> > me.\n> \n> \tI modified psql already such that:\n> \n> \trelname !~ '^[pd][bg]_'\n> \n> \tis ignored :)\n\nI still disagree. Why not keep the system stuff pg_? This can be done,\nand it keeps things consistent. The above check also finds pb_ and dg_.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 23 Feb 1998 22:51:51 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "The Hermit Hacker wrote:\n> \n> On Mon, 23 Feb 1998, Bruce Momjian wrote:\n> \n> >\n> > Can I suggest pgview_ then? Another problem is that a \\d on an empty\n> > database, \\d is going to show this view, isn't it. Kind of strange to\n> > me.\n> \n> I modified psql already such that:\n> \n> relname !~ '^[pd][bg]_'\n> \n> is ignored :)\n\nAre pb_, db_, dg_ system prefixes now and user can't\n\nCREATE TABLE dg_i_like_this_name...\n\n?\n\nVadim\n", "msg_date": "Tue, 24 Feb 1998 11:01:59 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "On Mon, 23 Feb 1998, Bruce Momjian wrote:\n\n> > \n> > On Mon, 23 Feb 1998, Bruce Momjian wrote:\n> > \n> > > \n> > > Can I suggest pgview_ then? Another problem is that a \\d on an empty\n> > > database, \\d is going to show this view, isn't it. Kind of strange to\n> > > me.\n> > \n> > \tI modified psql already such that:\n> > \n> > \trelname !~ '^[pd][bg]_'\n> > \n> > \tis ignored :)\n> \n> I still disagree. Why not keep the system stuff pg_? This can be done,\n> and it keeps things consistent. The above check also finds pb_ and dg_.\n\n\tActually, I'm not married to db_* for views...it was a \"quick fix\"\nto ensure that things still worked. Whatever we decide on, both Julie and\nPeter, at a minimum, need to know relatively soon. I know in Julie's\ncase, she does do a call to pg_user...I let her know tonight that she\nneeds to change it to db_user, for the *current* code...\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Tue, 24 Feb 1998 00:38:43 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "\nBruce wrote:\n> > And I don't know if ALL the places where IsSystemRelationName()\n> > is used are happy with things that in fact aren't really\n> > hardwired system catalogs.\n>\n> Can I suggest pgview_ then? Another problem is that a \\d on an empty\n> database, \\d is going to show this view, isn't it. Kind of strange to\n> me.\n>\n> I have a solution. Create the view in initdb as pguser_no_pwd, then\n> after that execute an update statement on pg_class:\n>\n> update pg_class\n> set relname = 'pg_user_no_pwd'\n> where relname = 'pguser_no_pwd';\n>\n> We are using Jan's cache fix already. I just tried it and it works.\n> And it means it doesn't show up in \\d, and a user can't accidentally\n> delete it. Sounds like a real winner.\n\n Sounds really good - if we can be sure that the pg_ prefix of\n a view never collides with the IsSystemRelationName() tests\n somewhere (there are many). You got me. Let's leave all\n postgres specific stuff in pg_*.\n\n But as it was done in most UN*X's, could we rename the\n pg_user containing the password into pg_shadow and then\n create a view pg_user that just stars out the password field?\n This way no existing application code (not even the JDBC\n etc.) needs any changes, except for the createuser etc.\n tools that always get installed with the new release.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\n", "msg_date": "Tue, 24 Feb 1998 11:24:59 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "\nI wrote:\n>\n>\n> Bruce wrote:\n> >\n> > I have a solution. Create the view in initdb as pguser_no_pwd, then\n> > after that execute an update statement on pg_class:\n> >\n> > update pg_class\n> > set relname = 'pg_user_no_pwd'\n> > where relname = 'pguser_no_pwd';\n> >\n> > We are using Jan's cache fix already. I just tried it and it works.\n> > And it means it doesn't show up in \\d, and a user can't accidentally\n> > delete it. Sounds like a real winner.\n>\n> Sounds really good - if we can be sure that the pg_ prefix of\n> a view never collides with the IsSystemRelationName() tests\n> somewhere (there are many). You got me. Let's leave all\n> postgres specific stuff in pg_*.\n\n But here it doesn't work. The backend crashes during the\n rewriting since something doesn't match any longer. Here's\n another solution that also asures that the views select rule\n is created with the correct varno names and that the rule\n itself is named as expected:\n\n CREATE TABLE xpg_usr (\n usename name,\n usesysid int4,\n usecreatedb bool,\n usetrace bool,\n usesuper bool,\n usecatupd bool,\n passwd text,\n valuntil abstime);\n\n UPDATE pg_class SET relname = 'pg_usr'\n WHERE relname = 'xpg_usr';\n\n CREATE RULE _RETpg_usr AS ON SELECT TO pg_usr\n DO INSTEAD\n SELECT usename, usesysid, usecreatedb,\n usetrace, usesuper, usecatupd,\n '********'::text as passwd, valuntil\n FROM pg_user;\n\n REVOKE ALL ON pg_user FROM public;\n\n It doesn't look that elegant as creating a view with SELECT *\n and another rule that hides the password. But this seems to\n be the only way to create a view with a pg_ name cleanly.\n\n The GRANT on pg_class in current initdb.sh is obsolete\n (change of acldefault() return value). And if the public\n pg_usr view has the pg_ prefix, there is no need for an\n explicit grant on that too.\n\n A comment in pg_user.h should remind us to update initdb.sh\n when the structure of pg_user is to be changed. But since\n changes to system catalogs require dump/reload releases, I\n expect we will have a beta phase. And during that those\n things will likely show up and can easy get fixed.\n\n>\n> But as it was done in most UN*X's, could we rename the\n> pg_user containing the password into pg_shadow and then\n> create a view pg_user that just stars out the password field?\n> This way no existing application code (not even the JDBC\n> etc.) needs any changes, except for the createuser etc.\n> tools that always get installed with the new release.\n\n Still vote for this. And as soon as we finally choose one\n name for the public pg_user view we must fix createuser.sh,\n createdb.sh and so on to make their checks on the public\n accessible view so they still print the proper error messages\n instead of\n\n ERROR: pg_user: Permission denied.\n createuser: database access failed.\n\n Only createuser/destroyuser need to access the real user\n catalog on the insert/delete.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\n", "msg_date": "Tue, 24 Feb 1998 13:46:06 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "On Tue, 24 Feb 1998, Jan Wieck wrote:\n\n> CREATE TABLE xpg_usr (\n> usename name,\n> usesysid int4,\n> usecreatedb bool,\n> usetrace bool,\n> usesuper bool,\n> usecatupd bool,\n> passwd text,\n> valuntil abstime);\n> \n> UPDATE pg_class SET relname = 'pg_usr'\n> WHERE relname = 'xpg_usr';\n> \n> CREATE RULE _RETpg_usr AS ON SELECT TO pg_usr\n> DO INSTEAD\n> SELECT usename, usesysid, usecreatedb,\n> usetrace, usesuper, usecatupd,\n> '********'::text as passwd, valuntil\n> FROM pg_user;\n> \n> REVOKE ALL ON pg_user FROM public;\n\n\tOkay, just so that I don't mess things up in the translation...do\nyou want to send me an appropriate patch for this?\n\n> > But as it was done in most UN*X's, could we rename the\n> > pg_user containing the password into pg_shadow and then\n> > create a view pg_user that just stars out the password field?\n> > This way no existing application code (not even the JDBC\n> > etc.) needs any changes, except for the createuser etc.\n> > tools that always get installed with the new release.\n> \n> Still vote for this. And as soon as we finally choose one\n> name for the public pg_user view we must fix createuser.sh,\n> createdb.sh and so on to make their checks on the public\n> accessible view so they still print the proper error messages\n> instead of\n\n\tNo arguments here...can you include this as part of your patch\ntoo?\n\n\n\n", "msg_date": "Tue, 24 Feb 1998 08:14:11 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> On Tue, 24 Feb 1998, Jan Wieck wrote:\n> \n> > CREATE TABLE xpg_usr (\n> > usename name,\n> > usesysid int4,\n> > usecreatedb bool,\n> > usetrace bool,\n> > usesuper bool,\n> > usecatupd bool,\n> > passwd text,\n> > valuntil abstime);\n> > \n> > UPDATE pg_class SET relname = 'pg_usr'\n> > WHERE relname = 'xpg_usr';\n> > \n> > CREATE RULE _RETpg_usr AS ON SELECT TO pg_usr\n> > DO INSTEAD\n> > SELECT usename, usesysid, usecreatedb,\n> > usetrace, usesuper, usecatupd,\n> > '********'::text as passwd, valuntil\n> > FROM pg_user;\n> > \n> > REVOKE ALL ON pg_user FROM public;\n> \n> \tOkay, just so that I don't mess things up in the translation...do\n> you want to send me an appropriate patch for this?\n> \n> > > But as it was done in most UN*X's, could we rename the\n> > > pg_user containing the password into pg_shadow and then\n> > > create a view pg_user that just stars out the password field?\n> > > This way no existing application code (not even the JDBC\n> > > etc.) needs any changes, except for the createuser etc.\n> > > tools that always get installed with the new release.\n> > \n> > Still vote for this. And as soon as we finally choose one\n> > name for the public pg_user view we must fix createuser.sh,\n> > createdb.sh and so on to make their checks on the public\n> > accessible view so they still print the proper error messages\n> > instead of\n> \n> \tNo arguments here...can you include this as part of your patch\n> too?\n\n\tWill do so.\n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Tue, 24 Feb 1998 14:23:22 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \tActually, I'm not married to db_* for views...it was a \"quick fix\"\n> to ensure that things still worked. Whatever we decide on, both Julie and\n> Peter, at a minimum, need to know relatively soon. I know in Julie's\n> case, she does do a call to pg_user...I let her know tonight that she\n> needs to change it to db_user, for the *current* code...\n\nGood. I didn't want the db_ namespace pollution. I will call it\npg_user_no_passwd, and make it a view, not a rule. Is that OK with\neveryone?\n\nAre the only things you changed psql.c and initdb.sh?\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 09:59:01 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> > We are using Jan's cache fix already. I just tried it and it works.\n> > And it means it doesn't show up in \\d, and a user can't accidentally\n> > delete it. Sounds like a real winner.\n> \n> Sounds really good - if we can be sure that the pg_ prefix of\n> a view never collides with the IsSystemRelationName() tests\n> somewhere (there are many). You got me. Let's leave all\n> postgres specific stuff in pg_*.\n\nOK, we are basically creating it with a different name, then moving in\ninto the pg_ namespace with UPDATE pg_class.\n\n> But as it was done in most UN*X's, could we rename the\n> pg_user containing the password into pg_shadow and then\n> create a view pg_user that just stars out the password field?\n> This way no existing application code (not even the JDBC\n> etc.) needs any changes, except for the createuser etc.\n> tools that always get installed with the new release.\n\nThe only problem with that is that the database administrator now should\ndeal with pg_shadow, and not pg_user, and pg_user is not a real table\nanymore. Actually, in Unix, this is true too. I don't think we can\nchange the real table to pg_shadow this close to a release, can we?\n\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 10:18:59 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "On Tue, 24 Feb 1998, Bruce Momjian wrote:\n\n> > \tActually, I'm not married to db_* for views...it was a \"quick fix\"\n> > to ensure that things still worked. Whatever we decide on, both Julie and\n> > Peter, at a minimum, need to know relatively soon. I know in Julie's\n> > case, she does do a call to pg_user...I let her know tonight that she\n> > needs to change it to db_user, for the *current* code...\n> \n> Good. I didn't want the db_ namespace pollution. I will call it\n> pg_user_no_passwd, and make it a view, not a rule. Is that OK with\n> everyone?\n\n\tWorks for me...\n\n> Are the only things you changed psql.c and initdb.sh?\n\n\tYes...\n\n\n", "msg_date": "Tue, 24 Feb 1998 10:19:39 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> On Tue, 24 Feb 1998, Bruce Momjian wrote:\n> \n> > > \tActually, I'm not married to db_* for views...it was a \"quick fix\"\n> > > to ensure that things still worked. Whatever we decide on, both Julie and\n> > > Peter, at a minimum, need to know relatively soon. I know in Julie's\n> > > case, she does do a call to pg_user...I let her know tonight that she\n> > > needs to change it to db_user, for the *current* code...\n> > \n> > Good. I didn't want the db_ namespace pollution. I will call it\n> > pg_user_no_passwd, and make it a view, not a rule. Is that OK with\n> > everyone?\n> \n> \tWorks for me...\n\n How? When I create a view the way Bruce explained (update pg_class),\n my backend crashes on SELECT FROM view during the rewrite. For some\n reason the rewrite handler cannot get the rule locks correctly.\n\n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Tue, 24 Feb 1998 16:45:00 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "On Tue, 24 Feb 1998, Jan Wieck wrote:\n\n> > \n> > On Tue, 24 Feb 1998, Bruce Momjian wrote:\n> > \n> > > > \tActually, I'm not married to db_* for views...it was a \"quick fix\"\n> > > > to ensure that things still worked. Whatever we decide on, both Julie and\n> > > > Peter, at a minimum, need to know relatively soon. I know in Julie's\n> > > > case, she does do a call to pg_user...I let her know tonight that she\n> > > > needs to change it to db_user, for the *current* code...\n> > > \n> > > Good. I didn't want the db_ namespace pollution. I will call it\n> > > pg_user_no_passwd, and make it a view, not a rule. Is that OK with\n> > > everyone?\n> > \n> > \tWorks for me...\n> \n> How? When I create a view the way Bruce explained (update pg_class),\n> my backend crashes on SELECT FROM view during the rewrite. For some\n> reason the rewrite handler cannot get the rule locks correctly.\n\n\tPpl are taking me a slight bit too literally :( \"Works for\nme\"...I like the idea...not necessarily implemented it though :)\n\n\n", "msg_date": "Tue, 24 Feb 1998 10:47:45 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> On Tue, 24 Feb 1998, Jan Wieck wrote:\n> \n> > > \n> > > On Tue, 24 Feb 1998, Bruce Momjian wrote:\n> > > \n> > > > > \tActually, I'm not married to db_* for views...it was a \"quick fix\"\n> > > > > to ensure that things still worked. Whatever we decide on, both Julie and\n> > > > > Peter, at a minimum, need to know relatively soon. I know in Julie's\n> > > > > case, she does do a call to pg_user...I let her know tonight that she\n> > > > > needs to change it to db_user, for the *current* code...\n> > > > \n> > > > Good. I didn't want the db_ namespace pollution. I will call it\n> > > > pg_user_no_passwd, and make it a view, not a rule. Is that OK with\n> > > > everyone?\n> > > \n> > > \tWorks for me...\n> > \n> > How? When I create a view the way Bruce explained (update pg_class),\n> > my backend crashes on SELECT FROM view during the rewrite. For some\n> > reason the rewrite handler cannot get the rule locks correctly.\n> \n> \tPpl are taking me a slight bit too literally :( \"Works for\n> me\"...I like the idea...not necessarily implemented it though :)\n\n I already have the pg_shadow + pg_user-view diff ready. Works\n really! Must run a regression test and send it after that\n succeeded. It updates createuser, destroyuser and initdb too.\n\n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Tue, 24 Feb 1998 16:58:07 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "\nBruce wrote:\n>\n> > But as it was done in most UN*X's, could we rename the\n> > pg_user containing the password into pg_shadow and then\n> > create a view pg_user that just stars out the password field?\n> > This way no existing application code (not even the JDBC\n> > etc.) needs any changes, except for the createuser etc.\n> > tools that always get installed with the new release.\n>\n> The only problem with that is that the database administrator now should\n> deal with pg_shadow, and not pg_user, and pg_user is not a real table\n> anymore. Actually, in Unix, this is true too. I don't think we can\n> change the real table to pg_shadow this close to a release, can we?\n\n We can. Here it is. ALL regression tests except for float8\n and geometry (only fp differences - diffs checked) passed\n 'ok'. Checked that createuser and destroyuser work.\n\n This patch changes the catalog pg_user into pg_shadow and\n creates a view pg_user that definitely works. Oridinary user\n cannot access pg_shadow.\n\n Since your greatest need (to stay with all system stuff named\n pg_) is met, you might like it too.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/catalog/Makefile ./backend/catalog/Makefile\n*** /usr/local/pgsql/sup/pgsql/src/backend/catalog/Makefile\tWed Jan 7 13:36:12 1998\n--- ./backend/catalog/Makefile\tTue Feb 24 14:25:33 1998\n***************\n*** 27,33 ****\n GENBKI= ./genbki.sh\n \n GLOBALBKI_SRCS= $(addprefix ../../include/catalog/, \\\n! pg_database.h pg_variable.h pg_user.h \\\n pg_group.h pg_log.h \\\n )\n \n--- 27,33 ----\n GENBKI= ./genbki.sh\n \n GLOBALBKI_SRCS= $(addprefix ../../include/catalog/, \\\n! pg_database.h pg_variable.h pg_shadow.h \\\n pg_group.h pg_log.h \\\n )\n \ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/catalog/aclchk.c ./backend/catalog/aclchk.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/catalog/aclchk.c\tTue Feb 24 10:22:24 1998\n--- ./backend/catalog/aclchk.c\tTue Feb 24 14:54:08 1998\n***************\n*** 32,38 ****\n #include \"catalog/pg_aggregate.h\"\n #include \"catalog/pg_proc.h\"\n #include \"catalog/pg_type.h\"\n! #include \"catalog/pg_user.h\"\n #include \"parser/parse_agg.h\"\n #include \"parser/parse_func.h\"\n #include \"utils/syscache.h\"\n--- 32,38 ----\n #include \"catalog/pg_aggregate.h\"\n #include \"catalog/pg_proc.h\"\n #include \"catalog/pg_type.h\"\n! #include \"catalog/pg_shadow.h\"\n #include \"parser/parse_agg.h\"\n #include \"parser/parse_func.h\"\n #include \"utils/syscache.h\"\n***************\n*** 396,409 ****\n \tif (!HeapTupleIsValid(htp))\n \t\telog(ERROR, \"pg_aclcheck: user \\\"%s\\\" not found\",\n \t\t\t usename);\n! \tid = (AclId) ((Form_pg_user) GETSTRUCT(htp))->usesysid;\n \n \t/*\n \t * for the 'pg_database' relation, check the usecreatedb field before\n \t * checking normal permissions\n \t */\n \tif (strcmp(DatabaseRelationName, relname) == 0 &&\n! \t\t(((Form_pg_user) GETSTRUCT(htp))->usecreatedb))\n \t{\n \n \t\t/*\n--- 396,409 ----\n \tif (!HeapTupleIsValid(htp))\n \t\telog(ERROR, \"pg_aclcheck: user \\\"%s\\\" not found\",\n \t\t\t usename);\n! \tid = (AclId) ((Form_pg_shadow) GETSTRUCT(htp))->usesysid;\n \n \t/*\n \t * for the 'pg_database' relation, check the usecreatedb field before\n \t * checking normal permissions\n \t */\n \tif (strcmp(DatabaseRelationName, relname) == 0 &&\n! \t\t(((Form_pg_shadow) GETSTRUCT(htp))->usecreatedb))\n \t{\n \n \t\t/*\n***************\n*** 417,428 ****\n \n \t/*\n \t * Deny anyone permission to update a system catalog unless\n! \t * pg_user.usecatupd is set. (This is to let superusers protect\n \t * themselves from themselves.)\n \t */\n \tif (((mode & ACL_WR) || (mode & ACL_AP)) &&\n \t\tIsSystemRelationName(relname) &&\n! \t\t!((Form_pg_user) GETSTRUCT(htp))->usecatupd)\n \t{\n \t\telog(DEBUG, \"pg_aclcheck: catalog update to \\\"%s\\\": permission denied\",\n \t\t\t relname);\n--- 417,428 ----\n \n \t/*\n \t * Deny anyone permission to update a system catalog unless\n! \t * pg_shadow.usecatupd is set. (This is to let superusers protect\n \t * themselves from themselves.)\n \t */\n \tif (((mode & ACL_WR) || (mode & ACL_AP)) &&\n \t\tIsSystemRelationName(relname) &&\n! \t\t!((Form_pg_shadow) GETSTRUCT(htp))->usecatupd)\n \t{\n \t\telog(DEBUG, \"pg_aclcheck: catalog update to \\\"%s\\\": permission denied\",\n \t\t\t relname);\n***************\n*** 432,438 ****\n \t/*\n \t * Otherwise, superusers bypass all permission-checking.\n \t */\n! \tif (((Form_pg_user) GETSTRUCT(htp))->usesuper)\n \t{\n #ifdef ACLDEBUG_TRACE\n \t\telog(DEBUG, \"pg_aclcheck: \\\"%s\\\" is superuser\",\n--- 432,438 ----\n \t/*\n \t * Otherwise, superusers bypass all permission-checking.\n \t */\n! \tif (((Form_pg_shadow) GETSTRUCT(htp))->usesuper)\n \t{\n #ifdef ACLDEBUG_TRACE\n \t\telog(DEBUG, \"pg_aclcheck: \\\"%s\\\" is superuser\",\n***************\n*** 531,542 ****\n \tif (!HeapTupleIsValid(htp))\n \t\telog(ERROR, \"pg_ownercheck: user \\\"%s\\\" not found\",\n \t\t\t usename);\n! \tuser_id = (AclId) ((Form_pg_user) GETSTRUCT(htp))->usesysid;\n \n \t/*\n \t * Superusers bypass all permission-checking.\n \t */\n! \tif (((Form_pg_user) GETSTRUCT(htp))->usesuper)\n \t{\n #ifdef ACLDEBUG_TRACE\n \t\telog(DEBUG, \"pg_ownercheck: user \\\"%s\\\" is superuser\",\n--- 531,542 ----\n \tif (!HeapTupleIsValid(htp))\n \t\telog(ERROR, \"pg_ownercheck: user \\\"%s\\\" not found\",\n \t\t\t usename);\n! \tuser_id = (AclId) ((Form_pg_shadow) GETSTRUCT(htp))->usesysid;\n \n \t/*\n \t * Superusers bypass all permission-checking.\n \t */\n! \tif (((Form_pg_shadow) GETSTRUCT(htp))->usesuper)\n \t{\n #ifdef ACLDEBUG_TRACE\n \t\telog(DEBUG, \"pg_ownercheck: user \\\"%s\\\" is superuser\",\n***************\n*** 597,608 ****\n \tif (!HeapTupleIsValid(htp))\n \t\telog(ERROR, \"pg_func_ownercheck: user \\\"%s\\\" not found\",\n \t\t\t usename);\n! \tuser_id = (AclId) ((Form_pg_user) GETSTRUCT(htp))->usesysid;\n \n \t/*\n \t * Superusers bypass all permission-checking.\n \t */\n! \tif (((Form_pg_user) GETSTRUCT(htp))->usesuper)\n \t{\n #ifdef ACLDEBUG_TRACE\n \t\telog(DEBUG, \"pg_ownercheck: user \\\"%s\\\" is superuser\",\n--- 597,608 ----\n \tif (!HeapTupleIsValid(htp))\n \t\telog(ERROR, \"pg_func_ownercheck: user \\\"%s\\\" not found\",\n \t\t\t usename);\n! \tuser_id = (AclId) ((Form_pg_shadow) GETSTRUCT(htp))->usesysid;\n \n \t/*\n \t * Superusers bypass all permission-checking.\n \t */\n! \tif (((Form_pg_shadow) GETSTRUCT(htp))->usesuper)\n \t{\n #ifdef ACLDEBUG_TRACE\n \t\telog(DEBUG, \"pg_ownercheck: user \\\"%s\\\" is superuser\",\n***************\n*** 638,649 ****\n \tif (!HeapTupleIsValid(htp))\n \t\telog(ERROR, \"pg_aggr_ownercheck: user \\\"%s\\\" not found\",\n \t\t\t usename);\n! \tuser_id = (AclId) ((Form_pg_user) GETSTRUCT(htp))->usesysid;\n \n \t/*\n \t * Superusers bypass all permission-checking.\n \t */\n! \tif (((Form_pg_user) GETSTRUCT(htp))->usesuper)\n \t{\n #ifdef ACLDEBUG_TRACE\n \t\telog(DEBUG, \"pg_aggr_ownercheck: user \\\"%s\\\" is superuser\",\n--- 638,649 ----\n \tif (!HeapTupleIsValid(htp))\n \t\telog(ERROR, \"pg_aggr_ownercheck: user \\\"%s\\\" not found\",\n \t\t\t usename);\n! \tuser_id = (AclId) ((Form_pg_shadow) GETSTRUCT(htp))->usesysid;\n \n \t/*\n \t * Superusers bypass all permission-checking.\n \t */\n! \tif (((Form_pg_shadow) GETSTRUCT(htp))->usesuper)\n \t{\n #ifdef ACLDEBUG_TRACE\n \t\telog(DEBUG, \"pg_aggr_ownercheck: user \\\"%s\\\" is superuser\",\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/commands/copy.c ./backend/commands/copy.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/commands/copy.c\tThu Feb 19 13:05:25 1998\n--- ./backend/commands/copy.c\tTue Feb 24 14:39:35 1998\n***************\n*** 32,38 ****\n #include <access/genam.h>\n #include <catalog/pg_type.h>\n #include <catalog/catname.h>\n! #include <catalog/pg_user.h>\n #include <commands/copy.h>\n #include \"commands/trigger.h\"\n #include <storage/fd.h>\n--- 32,38 ----\n #include <access/genam.h>\n #include <catalog/pg_type.h>\n #include <catalog/catname.h>\n! #include <catalog/pg_shadow.h>\n #include <commands/copy.h>\n #include \"commands/trigger.h\"\n #include <storage/fd.h>\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/commands/dbcommands.c ./backend/commands/dbcommands.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/commands/dbcommands.c\tWed Feb 4 09:33:29 1998\n--- ./backend/commands/dbcommands.c\tTue Feb 24 14:45:45 1998\n***************\n*** 25,31 ****\n #include \"utils/elog.h\"\n #include \"catalog/catname.h\"\n #include \"catalog/pg_proc.h\"\n! #include \"catalog/pg_user.h\"\n #include \"catalog/pg_database.h\"\n #include \"utils/syscache.h\"\n #include \"commands/dbcommands.h\"\n--- 25,31 ----\n #include \"utils/elog.h\"\n #include \"catalog/catname.h\"\n #include \"catalog/pg_proc.h\"\n! #include \"catalog/pg_shadow.h\"\n #include \"catalog/pg_database.h\"\n #include \"utils/syscache.h\"\n #include \"commands/dbcommands.h\"\n***************\n*** 211,219 ****\n \tuserName = GetPgUserName();\n \tutup = SearchSysCacheTuple(USENAME, PointerGetDatum(userName),\n \t\t\t\t\t\t\t 0, 0, 0);\n! \t*userIdP = ((Form_pg_user) GETSTRUCT(utup))->usesysid;\n! \tuse_super = ((Form_pg_user) GETSTRUCT(utup))->usesuper;\n! \tuse_createdb = ((Form_pg_user) GETSTRUCT(utup))->usecreatedb;\n \n \t/* Check to make sure user has permission to use createdb */\n \tif (!use_createdb)\n--- 211,219 ----\n \tuserName = GetPgUserName();\n \tutup = SearchSysCacheTuple(USENAME, PointerGetDatum(userName),\n \t\t\t\t\t\t\t 0, 0, 0);\n! \t*userIdP = ((Form_pg_shadow) GETSTRUCT(utup))->usesysid;\n! \tuse_super = ((Form_pg_shadow) GETSTRUCT(utup))->usesuper;\n! \tuse_createdb = ((Form_pg_shadow) GETSTRUCT(utup))->usecreatedb;\n \n \t/* Check to make sure user has permission to use createdb */\n \tif (!use_createdb)\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/commands/define.c ./backend/commands/define.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/commands/define.c\tFri Feb 13 18:28:37 1998\n--- ./backend/commands/define.c\tTue Feb 24 14:39:46 1998\n***************\n*** 52,58 ****\n #include <commands/defrem.h>\n #include <optimizer/xfunc.h>\n #include <tcop/dest.h>\n! #include <catalog/pg_user.h>\n \n static char *defGetString(DefElem *def);\n static int\tdefGetTypeLength(DefElem *def);\n--- 52,58 ----\n #include <commands/defrem.h>\n #include <optimizer/xfunc.h>\n #include <tcop/dest.h>\n! #include <catalog/pg_shadow.h>\n \n static char *defGetString(DefElem *def);\n static int\tdefGetTypeLength(DefElem *def);\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/commands/proclang.c ./backend/commands/proclang.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/commands/proclang.c\tWed Jan 7 13:36:17 1998\n--- ./backend/commands/proclang.c\tTue Feb 24 14:39:49 1998\n***************\n*** 11,17 ****\n \n #include \"access/heapam.h\"\n #include \"catalog/catname.h\"\n! #include \"catalog/pg_user.h\"\n #include \"catalog/pg_proc.h\"\n #include \"catalog/pg_language.h\"\n #include \"utils/syscache.h\"\n--- 11,17 ----\n \n #include \"access/heapam.h\"\n #include \"catalog/catname.h\"\n! #include \"catalog/pg_shadow.h\"\n #include \"catalog/pg_proc.h\"\n #include \"catalog/pg_language.h\"\n #include \"utils/syscache.h\"\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/commands/user.c ./backend/commands/user.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/commands/user.c\tThu Feb 19 22:31:39 1998\n--- ./backend/commands/user.c\tTue Feb 24 14:52:21 1998\n***************\n*** 21,27 ****\n #include <miscadmin.h>\n #include <catalog/catname.h>\n #include <catalog/pg_database.h>\n! #include <catalog/pg_user.h>\n #include <libpq/crypt.h>\n #include <access/heapam.h>\n #include <access/xact.h>\n--- 21,27 ----\n #include <miscadmin.h>\n #include <catalog/catname.h>\n #include <catalog/pg_database.h>\n! #include <catalog/pg_shadow.h>\n #include <libpq/crypt.h>\n #include <access/heapam.h>\n #include <access/xact.h>\n***************\n*** 38,44 ****\n /*---------------------------------------------------------------------\n * UpdatePgPwdFile\n *\n! * copy the modified contents of pg_user to a file used by the postmaster\n * for user authentication. The file is stored as $PGDATA/pg_pwd.\n *---------------------------------------------------------------------\n */\n--- 38,44 ----\n /*---------------------------------------------------------------------\n * UpdatePgPwdFile\n *\n! * copy the modified contents of pg_shadow to a file used by the postmaster\n * for user authentication. The file is stored as $PGDATA/pg_pwd.\n *---------------------------------------------------------------------\n */\n***************\n*** 56,66 ****\n tempname = (char*)malloc(strlen(filename) + 12);\n sprintf(tempname, \"%s.%d\", filename, MyProcPid);\n \n! /* Copy the contents of pg_user to the pg_pwd ASCII file using a the SEPCHAR\n * character as the delimiter between fields. Then rename the file to its\n * final name.\n */\n! sprintf(sql, \"copy %s to '%s' using delimiters %s\", UserRelationName, tempname, CRYPT_PWD_FILE_SEPCHAR);\n pg_exec_query(sql, (char**)NULL, (Oid*)NULL, 0);\n rename(tempname, filename);\n free((void*)tempname);\n--- 56,66 ----\n tempname = (char*)malloc(strlen(filename) + 12);\n sprintf(tempname, \"%s.%d\", filename, MyProcPid);\n \n! /* Copy the contents of pg_shadow to the pg_pwd ASCII file using a the SEPCHAR\n * character as the delimiter between fields. Then rename the file to its\n * final name.\n */\n! sprintf(sql, \"copy %s to '%s' using delimiters %s\", ShadowRelationName, tempname, CRYPT_PWD_FILE_SEPCHAR);\n pg_exec_query(sql, (char**)NULL, (Oid*)NULL, 0);\n rename(tempname, filename);\n free((void*)tempname);\n***************\n*** 76,90 ****\n /*---------------------------------------------------------------------\n * DefineUser\n *\n! * Add the user to the pg_user relation, and if specified make sure the\n * user is specified in the desired groups of defined in pg_group.\n *---------------------------------------------------------------------\n */\n void DefineUser(CreateUserStmt *stmt) {\n \n char* pg_user;\n! Relation pg_user_rel;\n! TupleDesc pg_user_dsc;\n HeapScanDesc scan;\n HeapTuple tuple;\n Datum datum;\n--- 76,90 ----\n /*---------------------------------------------------------------------\n * DefineUser\n *\n! * Add the user to the pg_shadow relation, and if specified make sure the\n * user is specified in the desired groups of defined in pg_group.\n *---------------------------------------------------------------------\n */\n void DefineUser(CreateUserStmt *stmt) {\n \n char* pg_user;\n! Relation pg_shadow_rel;\n! TupleDesc pg_shadow_dsc;\n HeapScanDesc scan;\n HeapTuple tuple;\n Datum datum;\n***************\n*** 101,134 ****\n if (!(inblock = IsTransactionBlock()))\n BeginTransactionBlock();\n \n! /* Make sure the user attempting to create a user can insert into the pg_user\n * relation.\n */\n pg_user = GetPgUserName();\n! if (pg_aclcheck(UserRelationName, pg_user, ACL_RD | ACL_WR | ACL_AP) != ACLCHECK_OK) {\n UserAbortTransactionBlock();\n elog(ERROR, \"defineUser: user \\\"%s\\\" does not have SELECT and INSERT privilege for \\\"%s\\\"\",\n! pg_user, UserRelationName);\n return;\n }\n \n! /* Scan the pg_user relation to be certain the user doesn't already exist.\n */\n! pg_user_rel = heap_openr(UserRelationName);\n! pg_user_dsc = RelationGetTupleDescriptor(pg_user_rel);\n! /* Secure a write lock on pg_user so we can be sure of what the next usesysid\n * should be.\n */\n! RelationSetLockForWrite(pg_user_rel);\n \n! scan = heap_beginscan(pg_user_rel, false, false, 0, NULL);\n while (HeapTupleIsValid(tuple = heap_getnext(scan, 0, &buffer))) {\n! datum = heap_getattr(tuple, Anum_pg_user_usename, pg_user_dsc, &n);\n \n if (!exists && !strncmp((char*)datum, stmt->user, strlen(stmt->user)))\n exists = true;\n \n! datum = heap_getattr(tuple, Anum_pg_user_usesysid, pg_user_dsc, &n);\n if ((int)datum > max_id)\n max_id = (int)datum;\n \n--- 101,134 ----\n if (!(inblock = IsTransactionBlock()))\n BeginTransactionBlock();\n \n! /* Make sure the user attempting to create a user can insert into the pg_shadow\n * relation.\n */\n pg_user = GetPgUserName();\n! if (pg_aclcheck(ShadowRelationName, pg_user, ACL_RD | ACL_WR | ACL_AP) != ACLCHECK_OK) {\n UserAbortTransactionBlock();\n elog(ERROR, \"defineUser: user \\\"%s\\\" does not have SELECT and INSERT privilege for \\\"%s\\\"\",\n! pg_user, ShadowRelationName);\n return;\n }\n \n! /* Scan the pg_shadow relation to be certain the user doesn't already exist.\n */\n! pg_shadow_rel = heap_openr(ShadowRelationName);\n! pg_shadow_dsc = RelationGetTupleDescriptor(pg_shadow_rel);\n! /* Secure a write lock on pg_shadow so we can be sure of what the next usesysid\n * should be.\n */\n! RelationSetLockForWrite(pg_shadow_rel);\n \n! scan = heap_beginscan(pg_shadow_rel, false, false, 0, NULL);\n while (HeapTupleIsValid(tuple = heap_getnext(scan, 0, &buffer))) {\n! datum = heap_getattr(tuple, Anum_pg_shadow_usename, pg_shadow_dsc, &n);\n \n if (!exists && !strncmp((char*)datum, stmt->user, strlen(stmt->user)))\n exists = true;\n \n! datum = heap_getattr(tuple, Anum_pg_shadow_usesysid, pg_shadow_dsc, &n);\n if ((int)datum > max_id)\n max_id = (int)datum;\n \n***************\n*** 137,144 ****\n heap_endscan(scan);\n \n if (exists) {\n! RelationUnsetLockForWrite(pg_user_rel);\n! heap_close(pg_user_rel);\n UserAbortTransactionBlock();\n elog(ERROR, \"defineUser: user \\\"%s\\\" has already been created\", stmt->user);\n return;\n--- 137,144 ----\n heap_endscan(scan);\n \n if (exists) {\n! RelationUnsetLockForWrite(pg_shadow_rel);\n! heap_close(pg_shadow_rel);\n UserAbortTransactionBlock();\n elog(ERROR, \"defineUser: user \\\"%s\\\" has already been created\", stmt->user);\n return;\n***************\n*** 146,152 ****\n \n /* Build the insert statment to be executed.\n */\n! sprintf(sql, \"insert into %s(usename,usesysid,usecreatedb,usetrace,usesuper,usecatupd,passwd\", UserRelationName);\n /* if (stmt->password)\n strcat(sql, \",passwd\"); -- removed so that insert empty string when no password */\n if (stmt->validUntil)\n--- 146,152 ----\n \n /* Build the insert statment to be executed.\n */\n! sprintf(sql, \"insert into %s(usename,usesysid,usecreatedb,usetrace,usesuper,usecatupd,passwd\", ShadowRelationName);\n /* if (stmt->password)\n strcat(sql, \",passwd\"); -- removed so that insert empty string when no password */\n if (stmt->validUntil)\n***************\n*** 186,193 ****\n /* This goes after the UpdatePgPwdFile to be certain that two backends to not\n * attempt to write to the pg_pwd file at the same time.\n */\n! RelationUnsetLockForWrite(pg_user_rel);\n! heap_close(pg_user_rel);\n \n if (IsTransactionBlock() && !inblock)\n EndTransactionBlock();\n--- 186,193 ----\n /* This goes after the UpdatePgPwdFile to be certain that two backends to not\n * attempt to write to the pg_pwd file at the same time.\n */\n! RelationUnsetLockForWrite(pg_shadow_rel);\n! heap_close(pg_shadow_rel);\n \n if (IsTransactionBlock() && !inblock)\n EndTransactionBlock();\n***************\n*** 197,204 ****\n extern void AlterUser(AlterUserStmt *stmt) {\n \n char* pg_user;\n! Relation pg_user_rel;\n! TupleDesc pg_user_dsc;\n HeapScanDesc scan;\n HeapTuple tuple;\n Datum datum;\n--- 197,204 ----\n extern void AlterUser(AlterUserStmt *stmt) {\n \n char* pg_user;\n! Relation pg_shadow_rel;\n! TupleDesc pg_shadow_dsc;\n HeapScanDesc scan;\n HeapTuple tuple;\n Datum datum;\n***************\n*** 214,242 ****\n if (!(inblock = IsTransactionBlock()))\n BeginTransactionBlock();\n \n! /* Make sure the user attempting to create a user can insert into the pg_user\n * relation.\n */\n pg_user = GetPgUserName();\n! if (pg_aclcheck(UserRelationName, pg_user, ACL_RD | ACL_WR) != ACLCHECK_OK) {\n UserAbortTransactionBlock();\n elog(ERROR, \"alterUser: user \\\"%s\\\" does not have SELECT and UPDATE privilege for \\\"%s\\\"\",\n! pg_user, UserRelationName);\n return;\n }\n \n! /* Scan the pg_user relation to be certain the user exists.\n */\n! pg_user_rel = heap_openr(UserRelationName);\n! pg_user_dsc = RelationGetTupleDescriptor(pg_user_rel);\n! /* Secure a write lock on pg_user so we can be sure that when the dump of\n * the pg_pwd file is done, there is not another backend doing the same.\n */\n! RelationSetLockForWrite(pg_user_rel);\n \n! scan = heap_beginscan(pg_user_rel, false, false, 0, NULL);\n while (HeapTupleIsValid(tuple = heap_getnext(scan, 0, &buffer))) {\n! datum = heap_getattr(tuple, Anum_pg_user_usename, pg_user_dsc, &n);\n \n if (!strncmp((char*)datum, stmt->user, strlen(stmt->user))) {\n exists = true;\n--- 214,242 ----\n if (!(inblock = IsTransactionBlock()))\n BeginTransactionBlock();\n \n! /* Make sure the user attempting to create a user can insert into the pg_shadow\n * relation.\n */\n pg_user = GetPgUserName();\n! if (pg_aclcheck(ShadowRelationName, pg_user, ACL_RD | ACL_WR) != ACLCHECK_OK) {\n UserAbortTransactionBlock();\n elog(ERROR, \"alterUser: user \\\"%s\\\" does not have SELECT and UPDATE privilege for \\\"%s\\\"\",\n! pg_user, ShadowRelationName);\n return;\n }\n \n! /* Scan the pg_shadow relation to be certain the user exists.\n */\n! pg_shadow_rel = heap_openr(ShadowRelationName);\n! pg_shadow_dsc = RelationGetTupleDescriptor(pg_shadow_rel);\n! /* Secure a write lock on pg_shadow so we can be sure that when the dump of\n * the pg_pwd file is done, there is not another backend doing the same.\n */\n! RelationSetLockForWrite(pg_shadow_rel);\n \n! scan = heap_beginscan(pg_shadow_rel, false, false, 0, NULL);\n while (HeapTupleIsValid(tuple = heap_getnext(scan, 0, &buffer))) {\n! datum = heap_getattr(tuple, Anum_pg_shadow_usename, pg_shadow_dsc, &n);\n \n if (!strncmp((char*)datum, stmt->user, strlen(stmt->user))) {\n exists = true;\n***************\n*** 247,254 ****\n heap_endscan(scan);\n \n if (!exists) {\n! RelationUnsetLockForWrite(pg_user_rel);\n! heap_close(pg_user_rel);\n UserAbortTransactionBlock();\n elog(ERROR, \"alterUser: user \\\"%s\\\" does not exist\", stmt->user);\n return;\n--- 247,254 ----\n heap_endscan(scan);\n \n if (!exists) {\n! RelationUnsetLockForWrite(pg_shadow_rel);\n! heap_close(pg_shadow_rel);\n UserAbortTransactionBlock();\n elog(ERROR, \"alterUser: user \\\"%s\\\" does not exist\", stmt->user);\n return;\n***************\n*** 256,262 ****\n \n /* Create the update statement to modify the user.\n */\n! sprintf(sql, \"update %s set\", UserRelationName);\n sql_end = sql;\n if (stmt->password) {\n sql_end += strlen(sql_end);\n--- 256,262 ----\n \n /* Create the update statement to modify the user.\n */\n! sprintf(sql, \"update %s set\", ShadowRelationName);\n sql_end = sql;\n if (stmt->password) {\n sql_end += strlen(sql_end);\n***************\n*** 296,303 ****\n \n UpdatePgPwdFile(sql);\n \n! RelationUnsetLockForWrite(pg_user_rel);\n! heap_close(pg_user_rel);\n \n if (IsTransactionBlock() && !inblock)\n EndTransactionBlock();\n--- 296,303 ----\n \n UpdatePgPwdFile(sql);\n \n! RelationUnsetLockForWrite(pg_shadow_rel);\n! heap_close(pg_shadow_rel);\n \n if (IsTransactionBlock() && !inblock)\n EndTransactionBlock();\n***************\n*** 307,313 ****\n extern void RemoveUser(char* user) {\n \n char* pg_user;\n! Relation pg_user_rel,\n pg_rel;\n TupleDesc pg_dsc;\n HeapScanDesc scan;\n--- 307,313 ----\n extern void RemoveUser(char* user) {\n \n char* pg_user;\n! Relation pg_shadow_rel,\n pg_rel;\n TupleDesc pg_dsc;\n HeapScanDesc scan;\n***************\n*** 324,356 ****\n if (!(inblock = IsTransactionBlock()))\n BeginTransactionBlock();\n \n! /* Make sure the user attempting to create a user can delete from the pg_user\n * relation.\n */\n pg_user = GetPgUserName();\n! if (pg_aclcheck(UserRelationName, pg_user, ACL_RD | ACL_WR) != ACLCHECK_OK) {\n UserAbortTransactionBlock();\n elog(ERROR, \"removeUser: user \\\"%s\\\" does not have SELECT and DELETE privilege for \\\"%s\\\"\",\n! pg_user, UserRelationName);\n return;\n }\n \n! /* Perform a scan of the pg_user relation to find the usesysid of the user to\n * be deleted. If it is not found, then return a warning message.\n */\n! pg_user_rel = heap_openr(UserRelationName);\n! pg_dsc = RelationGetTupleDescriptor(pg_user_rel);\n! /* Secure a write lock on pg_user so we can be sure that when the dump of\n * the pg_pwd file is done, there is not another backend doing the same.\n */\n! RelationSetLockForWrite(pg_user_rel);\n \n! scan = heap_beginscan(pg_user_rel, false, false, 0, NULL);\n while (HeapTupleIsValid(tuple = heap_getnext(scan, 0, &buffer))) {\n! datum = heap_getattr(tuple, Anum_pg_user_usename, pg_dsc, &n);\n \n if (!strncmp((char*)datum, user, strlen(user))) {\n! usesysid = (int)heap_getattr(tuple, Anum_pg_user_usesysid, pg_dsc, &n);\n ReleaseBuffer(buffer);\n break;\n }\n--- 324,356 ----\n if (!(inblock = IsTransactionBlock()))\n BeginTransactionBlock();\n \n! /* Make sure the user attempting to create a user can delete from the pg_shadow\n * relation.\n */\n pg_user = GetPgUserName();\n! if (pg_aclcheck(ShadowRelationName, pg_user, ACL_RD | ACL_WR) != ACLCHECK_OK) {\n UserAbortTransactionBlock();\n elog(ERROR, \"removeUser: user \\\"%s\\\" does not have SELECT and DELETE privilege for \\\"%s\\\"\",\n! pg_user, ShadowRelationName);\n return;\n }\n \n! /* Perform a scan of the pg_shadow relation to find the usesysid of the user to\n * be deleted. If it is not found, then return a warning message.\n */\n! pg_shadow_rel = heap_openr(ShadowRelationName);\n! pg_dsc = RelationGetTupleDescriptor(pg_shadow_rel);\n! /* Secure a write lock on pg_shadow so we can be sure that when the dump of\n * the pg_pwd file is done, there is not another backend doing the same.\n */\n! RelationSetLockForWrite(pg_shadow_rel);\n \n! scan = heap_beginscan(pg_shadow_rel, false, false, 0, NULL);\n while (HeapTupleIsValid(tuple = heap_getnext(scan, 0, &buffer))) {\n! datum = heap_getattr(tuple, Anum_pg_shadow_usename, pg_dsc, &n);\n \n if (!strncmp((char*)datum, user, strlen(user))) {\n! usesysid = (int)heap_getattr(tuple, Anum_pg_shadow_usesysid, pg_dsc, &n);\n ReleaseBuffer(buffer);\n break;\n }\n***************\n*** 359,366 ****\n heap_endscan(scan);\n \n if (usesysid == -1) {\n! RelationUnsetLockForWrite(pg_user_rel);\n! heap_close(pg_user_rel);\n UserAbortTransactionBlock();\n elog(ERROR, \"removeUser: user \\\"%s\\\" does not exist\", user);\n return;\n--- 359,366 ----\n heap_endscan(scan);\n \n if (usesysid == -1) {\n! RelationUnsetLockForWrite(pg_shadow_rel);\n! heap_close(pg_shadow_rel);\n UserAbortTransactionBlock();\n elog(ERROR, \"removeUser: user \\\"%s\\\" does not exist\", user);\n return;\n***************\n*** 399,406 ****\n if (dbase)\n free((void*)dbase);\n \n! /* Since pg_user is global over all databases, one of two things must be done\n! * to insure complete consistency. First, pg_user could be made non-global.\n * This would elminate the code above for deleting database and would require\n * the addition of code to delete tables, views, etc owned by the user.\n *\n--- 399,406 ----\n if (dbase)\n free((void*)dbase);\n \n! /* Since pg_shadow is global over all databases, one of two things must be done\n! * to insure complete consistency. First, pg_shadow could be made non-global.\n * This would elminate the code above for deleting database and would require\n * the addition of code to delete tables, views, etc owned by the user.\n *\n***************\n*** 414,428 ****\n *\n */\n \n! /* Remove the user from the pg_user table\n */\n! sprintf(sql, \"delete from %s where usename = '%s'\", UserRelationName, user);\n pg_exec_query(sql, (char**)NULL, (Oid*)NULL, 0);\n \n UpdatePgPwdFile(sql);\n \n! RelationUnsetLockForWrite(pg_user_rel);\n! heap_close(pg_user_rel);\n \n if (IsTransactionBlock() && !inblock)\n EndTransactionBlock();\n--- 414,428 ----\n *\n */\n \n! /* Remove the user from the pg_shadow table\n */\n! sprintf(sql, \"delete from %s where usename = '%s'\", ShadowRelationName, user);\n pg_exec_query(sql, (char**)NULL, (Oid*)NULL, 0);\n \n UpdatePgPwdFile(sql);\n \n! RelationUnsetLockForWrite(pg_shadow_rel);\n! heap_close(pg_shadow_rel);\n \n if (IsTransactionBlock() && !inblock)\n EndTransactionBlock();\n***************\n*** 431,455 ****\n /*\n * CheckPgUserAclNotNull\n *\n! * check to see if there is an ACL on pg_user\n */\n static void CheckPgUserAclNotNull()\n {\n HeapTuple htp;\n \n! \thtp = SearchSysCacheTuple(RELNAME, PointerGetDatum(UserRelationName),\n \t\t\t\t\t\t\t 0, 0, 0);\n \tif (!HeapTupleIsValid(htp))\n \t{\n \t\telog(ERROR, \"IsPgUserAclNull: class \\\"%s\\\" not found\",\n! \t\t\t UserRelationName);\n \t}\n \n \tif (heap_attisnull(htp, Anum_pg_class_relacl))\n \t{\n! \t\telog(NOTICE, \"To use passwords, you have to revoke permissions on pg_user\");\n \t\telog(NOTICE, \"so normal users can not read the passwords.\");\n! \t\telog(ERROR, \"Try 'REVOKE ALL ON pg_user FROM PUBLIC'\");\n \t}\n \t\n \treturn;\n--- 431,455 ----\n /*\n * CheckPgUserAclNotNull\n *\n! * check to see if there is an ACL on pg_shadow\n */\n static void CheckPgUserAclNotNull()\n {\n HeapTuple htp;\n \n! \thtp = SearchSysCacheTuple(RELNAME, PointerGetDatum(ShadowRelationName),\n \t\t\t\t\t\t\t 0, 0, 0);\n \tif (!HeapTupleIsValid(htp))\n \t{\n \t\telog(ERROR, \"IsPgUserAclNull: class \\\"%s\\\" not found\",\n! \t\t\t ShadowRelationName);\n \t}\n \n \tif (heap_attisnull(htp, Anum_pg_class_relacl))\n \t{\n! \t\telog(NOTICE, \"To use passwords, you have to revoke permissions on pg_shadow\");\n \t\telog(NOTICE, \"so normal users can not read the passwords.\");\n! \t\telog(ERROR, \"Try 'REVOKE ALL ON pg_shadow FROM PUBLIC'\");\n \t}\n \t\n \treturn;\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/libpq/auth.c ./backend/libpq/auth.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/libpq/auth.c\tWed Feb 4 09:33:38 1998\n--- ./backend/libpq/auth.c\tTue Feb 24 14:52:50 1998\n***************\n*** 605,611 ****\n \n /*\n * Use the local flat password file if clear passwords are used and the file is\n! * specified. Otherwise use the password in the pg_user table, encrypted or\n * not.\n */\n \n--- 605,611 ----\n \n /*\n * Use the local flat password file if clear passwords are used and the file is\n! * specified. Otherwise use the password in the pg_shadow table, encrypted or\n * not.\n */\n \ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/libpq/crypt.c ./backend/libpq/crypt.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/libpq/crypt.c\tWed Feb 4 09:33:39 1998\n--- ./backend/libpq/crypt.c\tTue Feb 24 14:53:38 1998\n***************\n*** 1,7 ****\n /*-------------------------------------------------------------------------\n *\n * crypt.c--\n! * Look into pg_user and check the encrypted password with the one\n * passed in from the frontend.\n *\n * Modification History\n--- 1,7 ----\n /*-------------------------------------------------------------------------\n *\n * crypt.c--\n! * Look into pg_shadow and check the encrypted password with the one\n * passed in from the frontend.\n *\n * Modification History\n***************\n*** 119,125 ****\n \n /* We want to delete the flag file before reading the contents of the pg_pwd\n * file. If result == 0 then the unlink of the reload file was successful.\n! * This means that a backend performed a COPY of the pg_user file to\n * pg_pwd. Therefore we must now do a reload.\n */\n if (!pwd_cache || !result) {\n--- 119,125 ----\n \n /* We want to delete the flag file before reading the contents of the pg_pwd\n * file. If result == 0 then the unlink of the reload file was successful.\n! * This means that a backend performed a COPY of the pg_shadow file to\n * pg_pwd. Therefore we must now do a reload.\n */\n if (!pwd_cache || !result) {\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/parser/gram.y ./backend/parser/gram.y\n*** /usr/local/pgsql/sup/pgsql/src/backend/parser/gram.y\tThu Feb 19 13:05:45 1998\n--- ./backend/parser/gram.y\tTue Feb 24 14:57:11 1998\n***************\n*** 88,94 ****\n \tchar\t\t\t\tchr;\n \tchar\t\t\t\t*str;\n \tbool\t\t\t\tboolean;\n! \tbool*\t\t\t\tpboolean;\t/* for pg_user privileges */\n \tList\t\t\t\t*list;\n \tNode\t\t\t\t*node;\n \tValue\t\t\t\t*value;\n--- 88,94 ----\n \tchar\t\t\t\tchr;\n \tchar\t\t\t\t*str;\n \tbool\t\t\t\tboolean;\n! \tbool*\t\t\t\tpboolean;\t/* for pg_shadow privileges */\n \tList\t\t\t\t*list;\n \tNode\t\t\t\t*node;\n \tValue\t\t\t\t*value;\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/rewrite/rewriteHandler.c ./backend/rewrite/rewriteHandler.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/rewrite/rewriteHandler.c\tMon Feb 23 14:21:42 1998\n--- ./backend/rewrite/rewriteHandler.c\tTue Feb 24 14:45:52 1998\n***************\n*** 32,38 ****\n \n #include \"utils/syscache.h\"\n #include \"utils/acl.h\"\n! #include \"catalog/pg_user.h\"\n \n static void ApplyRetrieveRule(Query *parsetree, RewriteRule *rule,\n \t\t\t\t int rt_index, int relation_level,\n--- 32,38 ----\n \n #include \"utils/syscache.h\"\n #include \"utils/acl.h\"\n! #include \"catalog/pg_shadow.h\"\n \n static void ApplyRetrieveRule(Query *parsetree, RewriteRule *rule,\n \t\t\t\t int rt_index, int relation_level,\n***************\n*** 827,833 ****\n \t\t\t\t\t\tview->rd_rel->relowner);\n \t}\n \tStrNCpy(uname.data,\n! \t\t\t((Form_pg_user) GETSTRUCT(utup))->usename.data,\n \t\t\tNAMEDATALEN);\n \n \t/*\n--- 827,833 ----\n \t\t\t\t\t\tview->rd_rel->relowner);\n \t}\n \tStrNCpy(uname.data,\n! \t\t\t((Form_pg_shadow) GETSTRUCT(utup))->usename.data,\n \t\t\tNAMEDATALEN);\n \n \t/*\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/adt/acl.c ./backend/utils/adt/acl.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/adt/acl.c\tTue Feb 24 10:22:34 1998\n--- ./backend/utils/adt/acl.c\tTue Feb 24 14:46:02 1998\n***************\n*** 19,25 ****\n #include \"utils/acl.h\"\n #include \"utils/syscache.h\"\n #include \"catalog/catalog.h\"\n! #include \"catalog/pg_user.h\"\n #include \"miscadmin.h\"\n \n static char *getid(char *s, char *n);\n--- 19,25 ----\n #include \"utils/acl.h\"\n #include \"utils/syscache.h\"\n #include \"catalog/catalog.h\"\n! #include \"catalog/pg_shadow.h\"\n #include \"miscadmin.h\"\n \n static char *getid(char *s, char *n);\n***************\n*** 158,164 ****\n \t\t\t\t\t\t\t\t\t 0, 0, 0);\n \t\t\tif (!HeapTupleIsValid(htp))\n \t\t\t\telog(ERROR, \"aclparse: non-existent user \\\"%s\\\"\", name);\n! \t\t\taip->ai_id = ((Form_pg_user) GETSTRUCT(htp))->usesysid;\n \t\t\tbreak;\n \t\tcase ACL_IDTYPE_GID:\n \t\t\taip->ai_id = get_grosysid(name);\n--- 158,164 ----\n \t\t\t\t\t\t\t\t\t 0, 0, 0);\n \t\t\tif (!HeapTupleIsValid(htp))\n \t\t\t\telog(ERROR, \"aclparse: non-existent user \\\"%s\\\"\", name);\n! \t\t\taip->ai_id = ((Form_pg_shadow) GETSTRUCT(htp))->usesysid;\n \t\t\tbreak;\n \t\tcase ACL_IDTYPE_GID:\n \t\t\taip->ai_id = get_grosysid(name);\n***************\n*** 285,291 ****\n \t\t\t\tpfree(tmp);\n \t\t\t}\n \t\t\telse\n! \t\t\t\tstrncat(p, (char *) &((Form_pg_user)\n \t\t\t\t\t\t\t\t\t GETSTRUCT(htp))->usename,\n \t\t\t\t\t\tsizeof(NameData));\n \t\t\tbreak;\n--- 285,291 ----\n \t\t\t\tpfree(tmp);\n \t\t\t}\n \t\t\telse\n! \t\t\t\tstrncat(p, (char *) &((Form_pg_shadow)\n \t\t\t\t\t\t\t\t\t GETSTRUCT(htp))->usename,\n \t\t\t\t\t\tsizeof(NameData));\n \t\t\tbreak;\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/cache/syscache.c ./backend/utils/cache/syscache.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/cache/syscache.c\tThu Feb 12 14:36:23 1998\n--- ./backend/utils/cache/syscache.c\tTue Feb 24 14:48:38 1998\n***************\n*** 48,54 ****\n #include \"catalog/pg_type.h\"\n #include \"catalog/pg_rewrite.h\"\n #include \"catalog/pg_aggregate.h\"\n! #include \"catalog/pg_user.h\"\n #include \"storage/large_object.h\"\n #include \"catalog/pg_listener.h\"\n \n--- 48,54 ----\n #include \"catalog/pg_type.h\"\n #include \"catalog/pg_rewrite.h\"\n #include \"catalog/pg_aggregate.h\"\n! #include \"catalog/pg_shadow.h\"\n #include \"storage/large_object.h\"\n #include \"catalog/pg_listener.h\"\n \n***************\n*** 254,275 ****\n \t\tsizeof(FormData_pg_listener),\n \t\tNULL,\n \t(ScanFunc) NULL},\n! \t{UserRelationName,\t\t\t/* USENAME */\n \t\t1,\n! \t\t{Anum_pg_user_usename,\n \t\t\t0,\n \t\t\t0,\n \t\t0},\n! \t\tsizeof(FormData_pg_user),\n \t\tNULL,\n \t(ScanFunc) NULL},\n! \t{UserRelationName,\t\t\t/* USESYSID */\n \t\t1,\n! \t\t{Anum_pg_user_usesysid,\n \t\t\t0,\n \t\t\t0,\n \t\t0},\n! \t\tsizeof(FormData_pg_user),\n \t\tNULL,\n \t(ScanFunc) NULL},\n \t{GroupRelationName,\t\t\t/* GRONAME */\n--- 254,275 ----\n \t\tsizeof(FormData_pg_listener),\n \t\tNULL,\n \t(ScanFunc) NULL},\n! \t{ShadowRelationName,\t\t\t/* USENAME */\n \t\t1,\n! \t\t{Anum_pg_shadow_usename,\n \t\t\t0,\n \t\t\t0,\n \t\t0},\n! \t\tsizeof(FormData_pg_shadow),\n \t\tNULL,\n \t(ScanFunc) NULL},\n! \t{ShadowRelationName,\t\t\t/* USESYSID */\n \t\t1,\n! \t\t{Anum_pg_shadow_usesysid,\n \t\t\t0,\n \t\t\t0,\n \t\t0},\n! \t\tsizeof(FormData_pg_shadow),\n \t\tNULL,\n \t(ScanFunc) NULL},\n \t{GroupRelationName,\t\t\t/* GRONAME */\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/init/globals.c ./backend/utils/init/globals.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/init/globals.c\tWed Feb 4 09:34:08 1998\n--- ./backend/utils/init/globals.c\tTue Feb 24 14:44:00 1998\n***************\n*** 110,116 ****\n \tDatabaseRelationName,\n \tGroupRelationName,\n \tLogRelationName,\n! \tUserRelationName,\n \tVariableRelationName,\n \t0\n };\n--- 110,116 ----\n \tDatabaseRelationName,\n \tGroupRelationName,\n \tLogRelationName,\n! \tShadowRelationName,\n \tVariableRelationName,\n \t0\n };\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/init/miscinit.c ./backend/utils/init/miscinit.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/init/miscinit.c\tWed Feb 4 09:34:08 1998\n--- ./backend/utils/init/miscinit.c\tTue Feb 24 14:46:07 1998\n***************\n*** 32,38 ****\n #include \"miscadmin.h\"\t\t\t/* where the declarations go */\n \n #include \"catalog/catname.h\"\n! #include \"catalog/pg_user.h\"\n #include \"catalog/pg_proc.h\"\n #include \"utils/syscache.h\"\n \n--- 32,38 ----\n #include \"miscadmin.h\"\t\t\t/* where the declarations go */\n \n #include \"catalog/catname.h\"\n! #include \"catalog/pg_shadow.h\"\n #include \"catalog/pg_proc.h\"\n #include \"utils/syscache.h\"\n \n***************\n*** 339,344 ****\n \tif (!HeapTupleIsValid(userTup))\n \t\telog(FATAL, \"SetUserId: user \\\"%s\\\" is not in \\\"%s\\\"\",\n \t\t\t userName,\n! \t\t\t UserRelationName);\n! \tUserId = (Oid) ((Form_pg_user) GETSTRUCT(userTup))->usesysid;\n }\n--- 339,344 ----\n \tif (!HeapTupleIsValid(userTup))\n \t\telog(FATAL, \"SetUserId: user \\\"%s\\\" is not in \\\"%s\\\"\",\n \t\t\t userName,\n! \t\t\t ShadowRelationName);\n! \tUserId = (Oid) ((Form_pg_shadow) GETSTRUCT(userTup))->usesysid;\n }\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/backend/utils/misc/superuser.c ./backend/utils/misc/superuser.c\n*** /usr/local/pgsql/sup/pgsql/src/backend/utils/misc/superuser.c\tMon Sep 8 04:32:00 1997\n--- ./backend/utils/misc/superuser.c\tTue Feb 24 14:46:13 1998\n***************\n*** 17,23 ****\n \n #include <postgres.h>\n #include <utils/syscache.h>\n! #include <catalog/pg_user.h>\n \n bool\n superuser(void)\n--- 17,23 ----\n \n #include <postgres.h>\n #include <utils/syscache.h>\n! #include <catalog/pg_shadow.h>\n \n bool\n superuser(void)\n***************\n*** 33,37 ****\n \tutup = SearchSysCacheTuple(USENAME, PointerGetDatum(UserName),\n \t\t\t\t\t\t\t 0, 0, 0);\n \tAssert(utup != NULL);\n! \treturn ((Form_pg_user) GETSTRUCT(utup))->usesuper;\n }\n--- 33,37 ----\n \tutup = SearchSysCacheTuple(USENAME, PointerGetDatum(UserName),\n \t\t\t\t\t\t\t 0, 0, 0);\n \tAssert(utup != NULL);\n! \treturn ((Form_pg_shadow) GETSTRUCT(utup))->usesuper;\n }\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/bin/createuser/createuser.sh ./bin/createuser/createuser.sh\n*** /usr/local/pgsql/sup/pgsql/src/bin/createuser/createuser.sh\tWed May 7 04:59:46 1997\n--- ./bin/createuser/createuser.sh\tTue Feb 24 15:01:24 1998\n***************\n*** 203,209 ****\n CANADDUSER=f\n fi\n \n! QUERY=\"insert into pg_user \\\n (usename, usesysid, usecreatedb, usetrace, usesuper, usecatupd) \\\n values \\\n ('$NEWUSER', $SYSID, '$CANCREATE', 't', '$CANADDUSER','t')\"\n--- 203,209 ----\n CANADDUSER=f\n fi\n \n! QUERY=\"insert into pg_shadow \\\n (usename, usesysid, usecreatedb, usetrace, usesuper, usecatupd) \\\n values \\\n ('$NEWUSER', $SYSID, '$CANCREATE', 't', '$CANADDUSER','t')\"\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/bin/destroyuser/destroyuser.sh ./bin/destroyuser/destroyuser.sh\n*** /usr/local/pgsql/sup/pgsql/src/bin/destroyuser/destroyuser.sh\tWed May 7 04:59:52 1997\n--- ./bin/destroyuser/destroyuser.sh\tTue Feb 24 15:01:58 1998\n***************\n*** 182,188 ****\n done\n fi\n \n! QUERY=\"delete from pg_user where usename = '$DELUSER'\"\n \n $PSQL -c \"$QUERY\" template1\n if [ $? -ne 0 ]\n--- 182,188 ----\n done\n fi\n \n! QUERY=\"delete from pg_shadow where usename = '$DELUSER'\"\n \n $PSQL -c \"$QUERY\" template1\n if [ $? -ne 0 ]\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/bin/initdb/initdb.sh ./bin/initdb/initdb.sh\n*** /usr/local/pgsql/sup/pgsql/src/bin/initdb/initdb.sh\tTue Feb 24 10:22:35 1998\n--- ./bin/initdb/initdb.sh\tTue Feb 24 16:42:13 1998\n***************\n*** 351,371 ****\n echo \"vacuum\" | postgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"^DEBUG:\"\n \n! echo \"COPY pg_user TO '$PGDATA/pg_pwd' USING DELIMITERS '\\\\t'\" |\\\n \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"'DEBUG:\"\n \n! echo \"GRANT SELECT ON pg_class TO PUBLIC\" |\\\n! \t postgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n! \n! echo \"CREATE RULE pg_user_hide_pw as on SELECT to pg_user.passwd DO INSTEAD SELECT '********' as passwd;\" | \\\n \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"'DEBUG:\"\n! \n! echo \"create view db_user as select * from pg_user;\" |\\\n \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"'DEBUG:\"\n! echo \"grant select on db_user to public\" |\\\n \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"'DEBUG:\"\n \n--- 351,382 ----\n echo \"vacuum\" | postgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"^DEBUG:\"\n \n! echo \"COPY pg_shadow TO '$PGDATA/pg_pwd' USING DELIMITERS '\\\\t'\" |\\\n \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"'DEBUG:\"\n \n! echo \"creating public pg_user view\"\n! echo \"CREATE TABLE xpg_user (\t\t\\\n! \t usename\tname,\t\t\\\n! \t usesysid\tint4,\t\t\\\n! \t usecreatedb\tbool,\t\t\\\n! \t usetrace\tbool,\t\t\\\n! \t usesuper\tbool,\t\t\\\n! \t usecatupd\tbool,\t\t\\\n! \t passwd\t\ttext,\t\t\\\n! \t valuntil\tabstime);\" |\\\n \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"'DEBUG:\"\n! echo \"UPDATE pg_class SET relname = 'pg_user' WHERE relname = 'xpg_user';\" |\\\n! \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n! \tgrep -v \"'DEBUG:\"\n! echo \"CREATE RULE _RETpg_user AS ON SELECT TO pg_user DO INSTEAD\t\\\n! \t SELECT usename, usesysid, usecreatedb, usetrace,\t\t\\\n! \t usesuper, usecatupd, '********'::text as passwd,\t\\\n! \t\t valuntil FROM pg_shadow;\" |\\\n \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"'DEBUG:\"\n! echo \"REVOKE ALL on pg_shadow FROM public\" |\\\n \tpostgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\\\n \tgrep -v \"'DEBUG:\"\n \ndiff -c -r /usr/local/pgsql/sup/pgsql/src/include/catalog/catname.h ./include/catalog/catname.h\n*** /usr/local/pgsql/sup/pgsql/src/include/catalog/catname.h\tTue Nov 18 11:23:10 1997\n--- ./include/catalog/catname.h\tTue Feb 24 14:35:39 1998\n***************\n*** 35,43 ****\n #define ProcedureRelationName \"pg_proc\"\n #define RelationRelationName \"pg_class\"\n #define RewriteRelationName \"pg_rewrite\"\n #define StatisticRelationName \"pg_statistic\"\n #define TypeRelationName \"pg_type\"\n- #define UserRelationName \"pg_user\"\n #define VariableRelationName \"pg_variable\"\n #define VersionRelationName \"pg_version\"\n #define AttrDefaultRelationName \"pg_attrdef\"\n--- 35,43 ----\n #define ProcedureRelationName \"pg_proc\"\n #define RelationRelationName \"pg_class\"\n #define RewriteRelationName \"pg_rewrite\"\n+ #define ShadowRelationName \"pg_shadow\"\n #define StatisticRelationName \"pg_statistic\"\n #define TypeRelationName \"pg_type\"\n #define VariableRelationName \"pg_variable\"\n #define VersionRelationName \"pg_version\"\n #define AttrDefaultRelationName \"pg_attrdef\"\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/include/catalog/pg_attribute.h ./include/catalog/pg_attribute.h\n*** /usr/local/pgsql/sup/pgsql/src/include/catalog/pg_attribute.h\tThu Feb 19 13:05:54 1998\n--- ./include/catalog/pg_attribute.h\tTue Feb 24 14:30:35 1998\n***************\n*** 275,281 ****\n DATA(insert OID = 0 ( 1255 cmax\t\t\t\t29 0 4 -6 0 -1 -1 t f i f f));\n \n /* ----------------\n! *\t\tpg_user\n * ----------------\n */\n DATA(insert OID = 0 ( 1260 usename\t\t19 0 NAMEDATALEN 1 0 -1 -1 f f i f f));\n--- 275,281 ----\n DATA(insert OID = 0 ( 1255 cmax\t\t\t\t29 0 4 -6 0 -1 -1 t f i f f));\n \n /* ----------------\n! *\t\tpg_shadow\n * ----------------\n */\n DATA(insert OID = 0 ( 1260 usename\t\t19 0 NAMEDATALEN 1 0 -1 -1 f f i f f));\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/include/catalog/pg_class.h ./include/catalog/pg_class.h\n*** /usr/local/pgsql/sup/pgsql/src/include/catalog/pg_class.h\tMon Jan 19 09:36:11 1998\n--- ./include/catalog/pg_class.h\tTue Feb 24 14:31:23 1998\n***************\n*** 125,131 ****\n DESCR(\"\");\n DATA(insert OID = 1259 ( pg_class 83\t\t PGUID 0 0 0 f f r 14 0 0 f _null_ ));\n DESCR(\"\");\n! DATA(insert OID = 1260 ( pg_user 86\t\t PGUID 0 0 0 f t r 8 0 0 f _null_ ));\n DESCR(\"\");\n DATA(insert OID = 1261 ( pg_group 87\t\t PGUID 0 0 0 f t s 3 0 0 f _null_ ));\n DESCR(\"\");\n--- 125,131 ----\n DESCR(\"\");\n DATA(insert OID = 1259 ( pg_class 83\t\t PGUID 0 0 0 f f r 14 0 0 f _null_ ));\n DESCR(\"\");\n! DATA(insert OID = 1260 ( pg_shadow 86\t\t PGUID 0 0 0 f t r 8 0 0 f _null_ ));\n DESCR(\"\");\n DATA(insert OID = 1261 ( pg_group 87\t\t PGUID 0 0 0 f t s 3 0 0 f _null_ ));\n DESCR(\"\");\n***************\n*** 146,152 ****\n #define RelOid_pg_attribute\t\t1249\n #define RelOid_pg_proc\t\t\t1255\n #define RelOid_pg_class\t\t\t1259\n! #define RelOid_pg_user\t\t\t1260\n #define RelOid_pg_group\t\t\t1261\n #define RelOid_pg_database\t\t1262\n #define RelOid_pg_variable\t\t1264\n--- 146,152 ----\n #define RelOid_pg_attribute\t\t1249\n #define RelOid_pg_proc\t\t\t1255\n #define RelOid_pg_class\t\t\t1259\n! #define RelOid_pg_shadow\t\t1260\n #define RelOid_pg_group\t\t\t1261\n #define RelOid_pg_database\t\t1262\n #define RelOid_pg_variable\t\t1264\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/include/catalog/pg_type.h ./include/catalog/pg_type.h\n*** /usr/local/pgsql/sup/pgsql/src/include/catalog/pg_type.h\tWed Feb 11 15:25:43 1998\n--- ./include/catalog/pg_type.h\tTue Feb 24 14:31:53 1998\n***************\n*** 212,218 ****\n DATA(insert OID = 75 (\tpg_attribute PGUID 1 1 t b t \\054 1249 0 foo bar foo bar c _null_));\n DATA(insert OID = 81 (\tpg_proc\t\t PGUID 1 1 t b t \\054 1255 0 foo bar foo bar c _null_));\n DATA(insert OID = 83 (\tpg_class\t PGUID 1 1 t b t \\054 1259 0 foo bar foo bar c _null_));\n! DATA(insert OID = 86 (\tpg_user\t\t PGUID 1 1 t b t \\054 1260 0 foo bar foo bar c _null_));\n DATA(insert OID = 87 (\tpg_group\t PGUID 1 1 t b t \\054 1261 0 foo bar foo bar c _null_));\n DATA(insert OID = 88 (\tpg_database PGUID 1 1 t b t \\054 1262 0 foo bar foo bar c _null_));\n DATA(insert OID = 90 (\tpg_variable PGUID 1 1 t b t \\054 1264 0 foo bar foo bar c _null_));\n--- 212,218 ----\n DATA(insert OID = 75 (\tpg_attribute PGUID 1 1 t b t \\054 1249 0 foo bar foo bar c _null_));\n DATA(insert OID = 81 (\tpg_proc\t\t PGUID 1 1 t b t \\054 1255 0 foo bar foo bar c _null_));\n DATA(insert OID = 83 (\tpg_class\t PGUID 1 1 t b t \\054 1259 0 foo bar foo bar c _null_));\n! DATA(insert OID = 86 (\tpg_shadow\t PGUID 1 1 t b t \\054 1260 0 foo bar foo bar c _null_));\n DATA(insert OID = 87 (\tpg_group\t PGUID 1 1 t b t \\054 1261 0 foo bar foo bar c _null_));\n DATA(insert OID = 88 (\tpg_database PGUID 1 1 t b t \\054 1262 0 foo bar foo bar c _null_));\n DATA(insert OID = 90 (\tpg_variable PGUID 1 1 t b t \\054 1264 0 foo bar foo bar c _null_));\ndiff -c -r /usr/local/pgsql/sup/pgsql/src/include/utils/acl.h ./include/utils/acl.h\n*** /usr/local/pgsql/sup/pgsql/src/include/utils/acl.h\tTue Feb 24 10:22:45 1998\n--- ./include/utils/acl.h\tTue Feb 24 14:58:30 1998\n***************\n*** 39,45 ****\n typedef uint8 AclIdType;\n \n #define ACL_IDTYPE_WORLD\t\t0x00\n! #define ACL_IDTYPE_UID\t\t\t0x01\t/* user id - from pg_user */\n #define ACL_IDTYPE_GID\t\t\t0x02\t/* group id - from pg_group */\n \n /*\n--- 39,45 ----\n typedef uint8 AclIdType;\n \n #define ACL_IDTYPE_WORLD\t\t0x00\n! #define ACL_IDTYPE_UID\t\t\t0x01\t/* user id - from pg_shadow */\n #define ACL_IDTYPE_GID\t\t\t0x02\t/* group id - from pg_group */\n \n /*\n", "msg_date": "Tue, 24 Feb 1998 17:19:07 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> > \n> > On Tue, 24 Feb 1998, Jan Wieck wrote:\n> > \n> > > CREATE TABLE xpg_usr (\n> > > usename name,\n> > > usesysid int4,\n> > > usecreatedb bool,\n> > > usetrace bool,\n> > > usesuper bool,\n> > > usecatupd bool,\n> > > passwd text,\n> > > valuntil abstime);\n> > > \n> > > UPDATE pg_class SET relname = 'pg_usr'\n> > > WHERE relname = 'xpg_usr';\n> > > \n> > > CREATE RULE _RETpg_usr AS ON SELECT TO pg_usr\n> > > DO INSTEAD\n> > > SELECT usename, usesysid, usecreatedb,\n> > > usetrace, usesuper, usecatupd,\n> > > '********'::text as passwd, valuntil\n> > > FROM pg_user;\n> > > \n> > > REVOKE ALL ON pg_user FROM public;\n> > \n> > \tOkay, just so that I don't mess things up in the translation...do\n> > you want to send me an appropriate patch for this?\n> > \n> > > > But as it was done in most UN*X's, could we rename the\n> > > > pg_user containing the password into pg_shadow and then\n> > > > create a view pg_user that just stars out the password field?\n> > > > This way no existing application code (not even the JDBC\n> > > > etc.) needs any changes, except for the createuser etc.\n> > > > tools that always get installed with the new release.\n> > > \n> > > Still vote for this. And as soon as we finally choose one\n> > > name for the public pg_user view we must fix createuser.sh,\n> > > createdb.sh and so on to make their checks on the public\n> > > accessible view so they still print the proper error messages\n> > > instead of\n> > \n> > \tNo arguments here...can you include this as part of your patch\n> > too?\n> \n> \tWill do so.\n\nThe more I think about it, the more I like pg_shadow. Maybe we can do\nthat in enough time for testing. No one's code has to change then, and\nthis is a big win.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 13:49:36 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> > > my backend crashes on SELECT FROM view during the rewrite. For some\n> > > reason the rewrite handler cannot get the rule locks correctly.\n> > \n> > \tPpl are taking me a slight bit too literally :( \"Works for\n> > me\"...I like the idea...not necessarily implemented it though :)\n> \n> I already have the pg_shadow + pg_user-view diff ready. Works\n> really! Must run a regression test and send it after that\n> succeeded. It updates createuser, destroyuser and initdb too.\n\nGreat news. Go for it. Please back out the psql db_ changes and any\ninitdb stuff we don't need anymore.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 14:20:45 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "On Tue, 24 Feb 1998, The Hermit Hacker wrote:\n\n> \tActually, I'm not married to db_* for views...it was a \"quick fix\"\n> to ensure that things still worked. Whatever we decide on, both Julie and\n> Peter, at a minimum, need to know relatively soon. I know in Julie's\n> case, she does do a call to pg_user...I let her know tonight that she\n> needs to change it to db_user, for the *current* code...\n\nIt's only one or two lines to change (and the queries involved are similar\nto those in psql), so as soon as we decide on what the view is to be\ncalled, I'll make the changes.\n\n-- \nPeter T Mount [email protected] or [email protected]\nMain Homepage: http://www.demon.co.uk/finder\nWork Homepage: http://www.maidstone.gov.uk Work EMail: [email protected]\n\n", "msg_date": "Tue, 24 Feb 1998 19:22:19 +0000 (GMT)", "msg_from": "Peter T Mount <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "On Tue, 24 Feb 1998, Bruce Momjian wrote:\n\n> The only problem with that is that the database administrator now should\n> deal with pg_shadow, and not pg_user, and pg_user is not a real table\n> anymore. Actually, in Unix, this is true too. I don't think we can\n> change the real table to pg_shadow this close to a release, can we?\n\nI like the pg_shadow idea.\n\nOne thing though, although the v6.3 driver is not backward compatible with\npre 6.3 backends (because of the network protocol changes), it should be\nforward compatible. However, if we change the real table to pg_shadow\nafter 6.3, it would break the DatabaseMetaData class.\n\nIf we change the table's name now, we won't have this problem, and\nexisting code won't break either.\n\n-- \nPeter T Mount [email protected] or [email protected]\nMain Homepage: http://www.demon.co.uk/finder\nWork Homepage: http://www.maidstone.gov.uk Work EMail: [email protected]\n\n", "msg_date": "Tue, 24 Feb 1998 19:31:44 +0000 (GMT)", "msg_from": "Peter T Mount <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" }, { "msg_contents": "> \n> > > > my backend crashes on SELECT FROM view during the rewrite. For some\n> > > > reason the rewrite handler cannot get the rule locks correctly.\n> > > \n> > > \tPpl are taking me a slight bit too literally :( \"Works for\n> > > me\"...I like the idea...not necessarily implemented it though :)\n> > \n> > I already have the pg_shadow + pg_user-view diff ready. Works\n> > really! Must run a regression test and send it after that\n> > succeeded. It updates createuser, destroyuser and initdb too.\n> \n> Great news. Go for it. Please back out the psql db_ changes and any\n> initdb stuff we don't need anymore.\n\nAgain, this is very good. I had not thought of making pg_user a\ndifferent name, but that is the perfect solution. Here is a case where\nmany heads get a nice solution. PostgreSQL is full of those areas where\npeople get good ideas for certain areas, and the whole project gets\nbetter.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 14:52:37 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" } ]
[ { "msg_contents": "> \n> > Let me add that I have found GNU sed version 1.* to be often 2-3 times\n> > faster then BSD sed, so it may not be sed itself, but the BSD\n> > implementation.\n> \n> That one's probably my fault. BSD's regex(3) routines, which I think its\n> sed uses, are the ones I did for 4.4BSD... and they're an alpha release\n> and are a trifle slow. :-) There is hope for a better set in the near\n> future, however.\n> \n> Henry Spencer\n> [email protected]\n\nHenry, I am CC'ing this to the PostgreSQL group. (See\nwww.postgresql.org for more info.) Hey folks, guess who wrote our regex\nstuff. \n\n\tCopyright 1992, 1993, 1994 Henry Spencer. All rights reserved.\n\nHenry, will the new code you write be in the public domain, or only part\nof BSDI? Would you recommend we replace our regex stuff with something\nelse? Do you have any patches you would like us to test?\n\n-- \nBruce Momjian\[email protected]\n", "msg_date": "Mon, 23 Feb 1998 14:44:26 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Appended a string of text to each line in a file" }, { "msg_contents": "> Henry, will the new code you write be in the public domain, or only part\n> of BSDI?\n\nThe new regex code will be under essentially the same redistribution terms\nas the old stuff (in fact, slightly more generous). BSDI didn't end up\ncontributing to this particular project, and the folks who did were all \nhappy with open redistribution.\n\nI should clarify that this code isn't \"to be written\" -- it already exists,\nalthough I'm not entirely happy with it yet and want to limit distribution\nuntil it's tidied up somewhat.\n\n> Would you recommend we replace our regex stuff with something else?\n\nMy only real competitor :-) right now appears to be the GNU rx package,\nand I have heard enough grumbling about it that I hesitate to recommend\nit for general use. It's faster but it has problems, is my impression;\nI have not examined it closely.\n\n> Do you have any patches you would like us to test?\n\nNothing quite yet. Incidentally, the new code is a from-scratch\nreimplementation, not just patches to the 4.4 one.\n\n Henry Spencer\n [email protected]\n\n", "msg_date": "Mon, 23 Feb 1998 15:42:27 -0500 (EST)", "msg_from": "Henry Spencer <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Appended a string of text to each line in a file" }, { "msg_contents": "On Mon, 23 Feb 1998, Henry Spencer wrote:\n\n> My only real competitor :-) right now appears to be the GNU rx package,\n> and I have heard enough grumbling about it that I hesitate to recommend\n> it for general use. It's faster but it has problems, is my impression;\n> I have not examined it closely.\n\n\tAnd...we wouldn't sully our code with a GNU license anyway :) We\nare being very very careful about that...\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 23 Feb 1998 23:25:09 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: Appended a string of text to each line in a file" }, { "msg_contents": "> > My only real competitor :-) right now appears to be the GNU rx package,\n> > and I have heard enough grumbling about it that I hesitate...\n> \n> \tAnd...we wouldn't sully our code with a GNU license anyway :) We\n> are being very very careful about that...\n\nAh yes, there's that... As one of my friends calls it, the \"GNU Public\nVirus\"...\n\n Henry Spencer\n [email protected]\n\n", "msg_date": "Mon, 23 Feb 1998 23:01:49 -0500 (EST)", "msg_from": "Henry Spencer <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: Appended a string of text to each line in a file" } ]
[ { "msg_contents": "Based on today's snapshot, the symbol _pgresStatus is still undefined\nin interfaces/libpgtcl/libpgtcl.a (actually from pgtclCmds.o). The\noffending statement in pgtclCmds.c is:\n\n\tif (strcmp(opt, \"-status\") == 0)\n\t{\n\t\tTcl_AppendResult(interp, pgresStatus[PQresultStatus(result)], 0);\n\t\treturn TCL_OK;\n\t}\n\nIt seems like this symbol should refer to an array that is defined in\ninterfaces/libpq/fe-exec.c (the symbol is declared extern in\ninterfaces/libpq/libpq-fe.h which is included by pgtclCmds.c):\n\n /* keep this in same order as ExecStatusType in pgtclCmds.h */\n const char *pgresStatus[] = {\n\t \"PGRES_EMPTY_QUERY\",\n\t \"PGRES_COMMAND_OK\",\n\t \"PGRES_TUPLES_OK\",\n\t \"PGRES_BAD_RESPONSE\",\n\t \"PGRES_NONFATAL_ERROR\",\n\t \"PGRES_FATAL_ERROR\"\n };\n\nOne solution is to place this segment of fe-exec.c into a distinct *.c\nfile that is included by both interfaces/libpq/fe-exec.c and\ninterfaces/libpgtcl/pgtclCmds.c. Then the symbol would be included in\nthe libraries as intended.\n\nHowever, the comment preceding the array definition suggests that\nperhaps something should be taken from pgtclCmds.h and the whole thing\norganized for sharing between the two directories.\n\nOther solutions may be obvious to those more enlightened on matters of\nthe organization of this code. As it stands, pgaccess is unusable\nbecause of the undefined symbol.\n\nCan anyone comment on the correct way to solve this problem? I'll\nmake the patch if that would help.\n\nCheers,\nBrook\n", "msg_date": "Mon, 23 Feb 1998 14:30:36 -0700 (MST)", "msg_from": "Brook Milligan <[email protected]>", "msg_from_op": true, "msg_subject": "pgresStatus undefined in interfaces/libpgtcl/libpgtcl.a" } ]
[ { "msg_contents": "\"Vadim B. Mikheev\" <[email protected]>\n> \n> Bruce Momjian wrote:\n> > \n> > This is a partial fix. In make_unique(), if Query->uniqueAttr is '*',\n> > Unique->uniqueAttr gets null. However, with this fix, I get:\n> > \n> > test=> select usesysid from pg_user where usesysid in (select \ndistinct\n> > usesysid from pg_user);\n> > ERROR: ExecReScan: node type 24 not supported\n> > \n> > I have not installed this patch yet until Vadim comments and perhaps has\n> > an idea on the ExecReScan message:\n> \n> Patch is Ok. DISTINCT is yet another node without re-scan support.\n> Hope to add it in 1-2 days.\n> \n\nLooks like you've done your usual magic Vadim/Bruce.\n\nGrabbed a cvsup this morning, built and tested fine.\n\nThanks,\nKeith.\n\n", "msg_date": "Mon, 23 Feb 1998 21:57:26 +0000 (GMT)", "msg_from": "Keith Parks <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] SIGSEGV in sebselect." } ]
[ { "msg_contents": "Here is what I get from initdb:\n\nloading pg_description\nNOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE\nSAME AS HEAP' (44)\nNOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE\nSAME AS HEAP' (44)\n\nLooks strange to me.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 23 Feb 1998 23:23:41 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "initdb problem" }, { "msg_contents": ">Here is what I get from initdb:\n>\n>loading pg_description\n>NOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE\n>SAME AS HEAP' (44)\n>NOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE\n>SAME AS HEAP' (44)\n>\n>Looks strange to me.\n\nI saw this on SunOS but not on FreeBSD and Solaris 2.6.\nreally strange...\n---\nTatsuo Ishii\[email protected]\n", "msg_date": "Wed, 25 Feb 1998 11:48:52 +0900", "msg_from": "[email protected]", "msg_from_op": false, "msg_subject": "Re: [HACKERS] initdb problem " }, { "msg_contents": "> \n> >Here is what I get from initdb:\n> >\n> >loading pg_description\n> >NOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE\n> >SAME AS HEAP' (44)\n> >NOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE\n> >SAME AS HEAP' (44)\n> >\n> >Looks strange to me.\n> \n> I saw this on SunOS but not on FreeBSD and Solaris 2.6.\n> really strange...\n\nI am waiting for Jan's pg_user/pg_shadow fix and changes to initdb for a\npossible fix.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 22:06:27 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] initdb problem" }, { "msg_contents": "> From: [email protected]\n> cc: [email protected] (PostgreSQL-development)\n\n> >Here is what I get from initdb:\n> >\n> >loading pg_description\n> >NOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE\n> >SAME AS HEAP' (44)\n> >NOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE\n> >SAME AS HEAP' (44)\n> >\n> >Looks strange to me.\n> \n> I saw this on SunOS but not on FreeBSD and Solaris 2.6.\n> really strange...\n\nI saw it on a totally new install (no previous PostgreSQL bits on that\nhost) to FreeBSD-2.2.5-STABLE with yesterday's snapshot.\n\n", "msg_date": "Wed, 25 Feb 1998 11:12:26 -0600 (CST)", "msg_from": "Hal Snyder <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] initdb problem" }, { "msg_contents": "> > I saw this on SunOS but not on FreeBSD and Solaris 2.6.\n> > really strange...\n> \n> I saw it on a totally new install (no previous PostgreSQL bits on that\n> host) to FreeBSD-2.2.5-STABLE with yesterday's snapshot.\n> \n\nFixed today.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 14:08:26 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] initdb problem" } ]
[ { "msg_contents": "-----Original Message-----\nFrom: Vadim B. Mikheev <[email protected]>\nTo: Maurice Gittens <[email protected]>\nCc: [email protected] <[email protected]>\nDate: dinsdag 24 februari 1998 10:01\nSubject: Re: [HACKERS] How To free resources used by large object Relations?\n\n\n>I'm sorry, Maurice, but I haven't time to deal with this now.\n>Let's 6.3 be out first...\n>\n>Vadim\n\nNo problem. Let's make a stable 6.3.\n\nRegards,\nMaurice\n\n\n", "msg_date": "Tue, 24 Feb 1998 08:10:19 +0100", "msg_from": "\"Maurice Gittens\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] How To free resources used by large object Relations?" } ]
[ { "msg_contents": "> I don't know if I like the new name db_user? What do other people\n> think? I thought pg_user_no_pwd would be nice.\n\nSame with me. I think the name should definitely be in the restricted name\nspace starting with\npg_ !! How about pg_user beeing the view and having a restricted\npg_user_security ?\nI still think we should hash out the password in both versions, since most\nusers will use\nthe same passwords as everywhere else. This is just to help superusers who\nwant to stay honest.\n\nAndreas\n", "msg_date": "Tue, 24 Feb 1998 09:45:28 +0100", "msg_from": "Zeugswetter Andreas SARZ <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [COMMITTERS] 'pgsql/src/bin/initdb initdb.sh'" } ]
[ { "msg_contents": "On Mon, 23 Feb 1998, Bruce Momjian wrote:\n\n> Actually, it does handle unions of views, but not views of unions. \n> Informix doesn't support it either, and I don't know what the other\n> dbms's do, but I think I am going to find out soon from someone. :-)\n\ncreate view testv as\nselect * from dual\nunion all\nselect * from dual;\n\nWorks in Oracle, I think this is great, I have been missing this feature in\nInformix.\nIt can for example solve the large table problem (create several tables and\na union view). \nBut it is definitely a goody that could wait a little on the TODO list.\n\nAndreas\n", "msg_date": "Tue, 24 Feb 1998 09:56:24 +0100", "msg_from": "Zeugswetter Andreas SARZ <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" }, { "msg_contents": "> Works in Oracle, I think this is great, I have been missing this feature in\n> Informix.\n> It can for example solve the large table problem (create several tables and\n> a union view). \n> But it is definitely a goody that could wait a little on the TODO list.\n\nAdded to TODO.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 10:07:57 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Views on aggregates - need assistence" } ]
[ { "msg_contents": ">> the table or even discover that it exists!\n> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n> Not in 6.3, or maybe ever. Too much OO stuff for that, I think.\n\nI vote for not ever. No commercial DBMS has it. It is a standard\nthat is of very restricted practicability. You can always split into\ndifferent \ndatabases whatever needs turbo security.\n\nAndreas \n", "msg_date": "Tue, 24 Feb 1998 10:21:57 +0100", "msg_from": "Zeugswetter Andreas SARZ <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Here it is - view permissions" }, { "msg_contents": "Andreas wrote:\n>\n> >> the table or even discover that it exists!\n> > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n> > Not in 6.3, or maybe ever. Too much OO stuff for that, I think.\n>\n> I vote for not ever. No commercial DBMS has it. It is a standard\n> that is of very restricted practicability. You can always split into\n> different\n> databases whatever needs turbo security.\n\n I'm not quite sure if any commercial RDMBS does it. But since\n we don't have the ability to create multiple tables/views of\n the same name as long as the owner differs, I think it's\n better to stay as we are. As long as PostgreSQL cannot\n distinguish tables of the same name by a <user>.tablename\n syntax, it's better to let them know what tables already\n exist.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\n", "msg_date": "Tue, 24 Feb 1998 11:09:32 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Here it is - view permissions" }, { "msg_contents": "> \n> Andreas wrote:\n> >\n> > >> the table or even discover that it exists!\n> > > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n> > > Not in 6.3, or maybe ever. Too much OO stuff for that, I think.\n> >\n> > I vote for not ever. No commercial DBMS has it. It is a standard\n> > that is of very restricted practicability. You can always split into\n> > different\n> > databases whatever needs turbo security.\n> \n> I'm not quite sure if any commercial RDMBS does it. But since\n> we don't have the ability to create multiple tables/views of\n> the same name as long as the owner differs, I think it's\n> better to stay as we are. As long as PostgreSQL cannot\n> distinguish tables of the same name by a <user>.tablename\n> syntax, it's better to let them know what tables already\n> exist.\n\nI have NOT added this to the TODO list.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 10:09:30 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Here it is - view permissions" } ]
[ { "msg_contents": "I'm sorry, but what exactly is the problem with GPL?\n\nMichael\n\n--\nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n\n> -----Original Message-----\n> From:\tThe Hermit Hacker [SMTP:[email protected]]\n> Sent:\tTuesday, February 24, 1998 4:25 AM\n> To:\tHenry Spencer\n> Cc:\tBruce Momjian; PostgreSQL-development\n> Subject:\tRe: [HACKERS] Re: Appended a string of text to each line\n> in a file\n> \n> On Mon, 23 Feb 1998, Henry Spencer wrote:\n> \n> > My only real competitor :-) right now appears to be the GNU rx\n> package,\n> > and I have heard enough grumbling about it that I hesitate to\n> recommend\n> > it for general use. It's faster but it has problems, is my\n> impression;\n> > I have not examined it closely.\n> \n> \tAnd...we wouldn't sully our code with a GNU license anyway :)\n> We\n> are being very very careful about that...\n> \n> Marc G. Fournier \n> Systems Administrator @ hub.org \n> primary: [email protected] secondary:\n> scrappy@{freebsd|postgresql}.org \n> \n", "msg_date": "Tue, 24 Feb 1998 10:57:46 +0100", "msg_from": "\"Meskes, Michael\" <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Re: Appended a string of text to each line in a fil\n\te" }, { "msg_contents": "> I'm sorry, but what exactly is the problem with GPL?\n\nI can't speak for the PostgreSQL folks, who may have their own reasons,\nbut my take on it is simple: it creates complex legal obligations which\nlimit use of the software by their very existence. (Even if you consider\nthose obligations perfectly reasonable and are willing to abide by them,\nyour boss may disagree. Or the company lawyers may insist that you keep\ndetailed records of everything you do with the software, in case they ever\nhave to defend the company against a lawsuit alleging violation of the\nGPL. Or upper management may decide that the expense of paying the\ncompany lawyers to read the GPL and investigate its implications isn't \nworthwhile, but you can't use the software without their okay, which they\naren't going to give without investigation.)\n\nThe GPL is a tool for people with an axe to grind. If all you want to do\nis distribute software for free, a simpler licence (or even just placing\nthe software in the public domain) is preferable.\n\n Henry Spencer\n [email protected]\n\n", "msg_date": "Tue, 24 Feb 1998 11:14:15 -0500 (EST)", "msg_from": "Henry Spencer <[email protected]>", "msg_from_op": false, "msg_subject": "RE: [HACKERS] Re: Appended a string of text to each line in a fil e" }, { "msg_contents": "On Tue, 24 Feb 1998, Henry Spencer wrote:\n\n> > I'm sorry, but what exactly is the problem with GPL?\n> \n> I can't speak for the PostgreSQL folks, who may have their own reasons,\n> but my take on it is simple: it creates complex legal obligations which\n> limit use of the software by their very existence. \n\n\tExactly!\n\n> The GPL is a tool for people with an axe to grind. If all you want to do\n> is distribute software for free, a simpler licence (or even just placing\n> the software in the public domain) is preferable.\n\n\tI believe, one thing further, that since we started off under the\nBerkeley license, we can't change anyway (not that I would consider it\n*looks around*):\n\n/*\n * Copyright (c) 1990, 1993\n * The Regents of the University of California. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions\n * are met:\n * 1. Redistributions of source code must retain the above copyright\n * notice, this list of conditions and the following disclaimer.\n * 2. Redistributions in binary form must reproduce the above copyright\n * notice, this list of conditions and the following disclaimer in the\n * documentation and/or other materials provided with the distribution.\n * 3. All advertising materials mentioning features or use of this\nsoftware\n * must display the following acknowledgement:\n * This product includes software developed by the University of\n * California, Berkeley and its contributors.\n\n\n\n", "msg_date": "Tue, 24 Feb 1998 12:01:28 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "RE: [HACKERS] Re: Appended a string of text to each line in a fil e" }, { "msg_contents": "> I believe, one thing further, that since we started off under the\n> Berkeley license, we can't change anyway (not that I would consider it\n> *looks around*)...\n\nWell, the way I read it one could take and use the source code for any purpose\n(including developing another product or set of source code with other\nconditions) as long as the Berkeley conditions are met. Those conditions seem\nto cover giving UCB some credit for having done the work, and protecting UCB\nfrom liability resulting from use of software which they had once developed.\n\nbtw, the license terms in the Postgres95 docs are slightly different, but with\nthe same intent. As you point out, that license seems to suit us just fine :)\n\n - Tom\n\n> /*\n> * Copyright (c) 1990, 1993\n> * The Regents of the University of California. All rights reserved.\n> *\n> * Redistribution and use in source and binary forms, with or without\n> * modification, are permitted provided that the following conditions\n> * are met:\n> * 1. Redistributions of source code must retain the above copyright\n> * notice, this list of conditions and the following disclaimer.\n> * 2. Redistributions in binary form must reproduce the above copyright\n> * notice, this list of conditions and the following disclaimer in the\n> * documentation and/or other materials provided with the distribution.\n> * 3. All advertising materials mentioning features or use of this\n> software\n> * must display the following acknowledgement:\n> * This product includes software developed by the University of\n> * California, Berkeley and its contributors.\n\n", "msg_date": "Wed, 25 Feb 1998 02:30:20 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: Appended a string of text to each line in a fil e" } ]
[ { "msg_contents": "I'm back to having a working 6.3 installation since saturday night. It\nappears Jan's patches fixed my problem.\n\nAnyway, I've just submitted a patch that fixes all bugs I could reproduce.\nHowever, I cannot reproduce the problem with the varchar entry in a struct\nin test2.pgc. So if this still exists we have to dig into it in more detail.\n\nAlso, I'm not sure about what the standard says for the whenever command.\nI'm pretty sure I already saw a 'exec whenever sqlerror break;' command\nmaybe on Ingres. Oracle does not know about this. I tried implementing it\nregardless, but found that this is almost impossible since break obviously\ncannot be issued outside a loop resp. switch statement. Shall I just remove\nit?\n\nAnd the continue statement? Currently ecpg adds a continue command, but it\nappears to be better to do nothing in case the user wants to continue. This\nis btw what Oracle does too.\n\nFinally, here's a list of open bugs that I won't be able to tackle before\n6.3 is released:\n\n- The return code is alway -1 in case of an error. You cannot see which error\n occured by examining the return code.\n- The cursor is opened when the declare statement is issued.\n- ecpg does not understand enum datatypes.\n- There is no exec sql prepare statement.\n- The complete structure definition has to be listed inside the declare\n section for ecpg to be able to understand it.\n- Each variable has to be defined on a line on its own.\n- There is no way yet to fill a complete array with one call except arrays of\n [unsigned] char which are considered strings.\n- ecpg cannot use pointer variables except [unsigned] char *\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Tue, 24 Feb 1998 13:26:52 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "ecpg news" }, { "msg_contents": "> Also, I'm not sure about what the standard says for the whenever command.\n> I'm pretty sure I already saw a 'exec whenever sqlerror break;' command\n> maybe on Ingres. Oracle does not know about this. I tried implementing it\n> regardless, but found that this is almost impossible since break obviously\n> cannot be issued outside a loop resp. switch statement. Shall I just remove\n> it?\n\nThe CA-Ingres parameters on \"whenever\" are only \"continue\", \"stop\", \"goto\n<label>\", and \"call <procedure>\". I suspect that part of the problem is that\nembedded SQL is available for several host languages, and some don't map the\nsame way as C would. How about disabling it for now?\n\n> And the continue statement? Currently ecpg adds a continue command, but it\n> appears to be better to do nothing in case the user wants to continue. This\n> is btw what Oracle does too.\n\nCA-Ingres sez:continue: continues execution with the next executable statement.\nIf a fatal error occurs, an error message is printed and the program aborts.\n\nI think this means that errors are ignored, as in Oracle, rather than doing a\nC-style \"continue\". Then, the program can check the sqlcode variable to decide\nwhat to do...\n\n> Finally, here's a list of open bugs that I won't be able to tackle before\n> 6.3 is released:\n\nThe embedded SQL is a great capability which was one of the most visible\nomissions in the Postgres features. Thanks for being so aggressive and\npersistent about getting it solid for its first release. But, we've got to have\na few things to work on later :)\n\n - Tom\n\n", "msg_date": "Tue, 24 Feb 1998 13:45:05 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] ecpg news" }, { "msg_contents": "Thomas G. Lockhart writes:\n> The CA-Ingres parameters on \"whenever\" are only \"continue\", \"stop\", \"goto\n> <label>\", and \"call <procedure>\". I suspect that part of the problem is that\n> embedded SQL is available for several host languages, and some don't map the\n> same way as C would. How about disabling it for now?\n\nOkay, I will do that as soon as I find time.\n\n> CA-Ingres sez:continue: continues execution with the next executable statement.\n> If a fatal error occurs, an error message is printed and the program aborts.\n> \n> I think this means that errors are ignored, as in Oracle, rather than doing a\n> C-style \"continue\". Then, the program can check the sqlcode variable to decide\n> what to do...\n\nOkay, will change that, too. In fact I like this approach much more than the\ncontinue statement.\n\n> The embedded SQL is a great capability which was one of the most visible\n> omissions in the Postgres features. Thanks for being so aggressive and\n> persistent about getting it solid for its first release. But, we've got to have\n> a few things to work on later :)\n\nMy pleasure.\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Tue, 24 Feb 1998 17:05:34 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] ecpg news" } ]
[ { "msg_contents": "> End users hate uneccessaries or non sense messages like the following\n> when he/she writes a sentence like this:\n> \n> UPDATE my_table SET my_int=my_small;\n> \n> and PostgreSQL show him/her this message ?\n> ---------------------------------------------------------------------\n> WARN: type of my_small does not match target column my_int\n> ---------------------------------------------------------------------\n> - What message is this ? If PostgreSQL understand that I want to do:\n> UPDATE my_table SET my_int=my_small::int4;\n> why it doesn't do that for me?\n> \n> SELECT my_small * my_float FROM my_table;\n> ---------------------------------------------------------------------\n> NOTICE:there is no operator * for types int2 and float8\n> NOTICE:You will either have to retype this query using an\n> NOTICE:explicit cast, or you will have to define the operator\n> WARN:* for int2 and float8 using CREATE OPERATOR\n> ---------------------------------------------------------------------\n> \n> - Well, if PostgreSQL know what I want why it doesn't do it for me ?\n> I know that conversion is more expensive than warnning but it's more\n> friendly. What do you think? ;-)\n\nYes, this is very annoying. If I do:\n psql=> select my_small * my_float from my_table;\n\nthen my_small should be promoted to float automagically.\n\nPostgreSQL should rewrite this as \"select my_small::float * my_float from\nmy_table\"\nso that numeric expressions always returns the \"biggest\" type involved.\nIn most programmig languages, this is done automatically, and should be\ndone\nin PostgreSQL for all calculations.\n\n\n/* m */\n\n", "msg_date": "Tue, 24 Feb 1998 14:32:35 +0100", "msg_from": "\"Mattias Kregert\" <[email protected]>", "msg_from_op": true, "msg_subject": "SV: [HACKERS] Re: [BUGS] agregate function sum error" } ]
[ { "msg_contents": "Hi,\n\nhas somebody tried to replace the -c switch with the -u switch\n(available with GNU diffutils) in the script regess.sh?\n\nWell, I did it and I find the resulting output much easier on the eye\nto compare the current and the expected results. \n\nThis change might be worth a little hint in the regress/README file. \n\n--\n\tFrank\n", "msg_date": "Tue, 24 Feb 1998 13:39:40 GMT", "msg_from": "Frank Ridderbusch <[email protected]>", "msg_from_op": true, "msg_subject": "Using the -u switch for diff in regress.sh" }, { "msg_contents": "> \n> Hi,\n> \n> has somebody tried to replace the -c switch with the -u switch\n> (available with GNU diffutils) in the script regess.sh?\n> \n> Well, I did it and I find the resulting output much easier on the eye\n> to compare the current and the expected results. \n> \n> This change might be worth a little hint in the regress/README file. \n\nregress/checkresults has those new flags.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 13:51:16 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Using the -u switch for diff in regress.sh" } ]
[ { "msg_contents": "I created simple table (just single int4 attr) with index on it\nand tried to reproduce reported problems with BTP_CHAIN flag\n(without success, unfortunately ?) by inserting data by 3-4 psql-s \nsimultaneously. No problems with 2 clients. But when 3rd psql\nstarts one of psql-s becomes blocked for long time (a minutes). \nAfter some time blocked process may continue insertion but \nanother process is sleeping instead of wake-uped proc. The same\nwith 4 psql-s: one of process is always sleeping!\n\nIt's very easy to reproduce - just create a file with >~ 100\nINSERTs...\n\nI also run 2 insertion procs + 2 selecting procs - result is\nthe same, one is always sleeping.\n\nVadim\nP.S. Nevertheless, I really like new deadlock recognition code,\nthanks!\n", "msg_date": "Tue, 24 Feb 1998 21:56:12 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "some problems with new locking code" }, { "msg_contents": "> \n> I created simple table (just single int4 attr) with index on it\n> and tried to reproduce reported problems with BTP_CHAIN flag\n> (without success, unfortunately ?) by inserting data by 3-4 psql-s \n> simultaneously. No problems with 2 clients. But when 3rd psql\n> starts one of psql-s becomes blocked for long time (a minutes). \n> After some time blocked process may continue insertion but \n> another process is sleeping instead of wake-uped proc. The same\n> with 4 psql-s: one of process is always sleeping!\n\nThanks for finding this, Vadim. I had meant to re-run my locking tests\non the new code before the 6.3 final, but had not done it yet. I ran\nthem now, and they didn't work as they should. It is fixed now.\n\nThe problem was that I was incrementing a counter in a while conditional\ntest, even though I was not executing the loop, and the counter was used\nin the next loop.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 14:56:58 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] some problems with new locking code" } ]
[ { "msg_contents": "Henry Spencer <[email protected]> wrote:\n\n> > Would you recommend we replace our regex stuff with something else?\n>\n> My only real competitor :-) right now appears to be the GNU rx package,\n>\nActually there is a very nice regular expression package (re) inside the\npython 1.5 (http://www.python.org/)\ndistribution (it does the perl-style regular expressions, with some\nminor differences to fit the python programming model)\n\nThere is also an older version (regex) that does\nemacs/grep/awk/xxx-style regex (selectable by set_syntax)\n\nThey all fall under the python license which seems to me very compatible\nwith postgresql ona.\n\n---------------\nHannu Krosing\n\n", "msg_date": "Tue, 24 Feb 1998 18:08:06 +0200", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": true, "msg_subject": "Possible replacement regex" } ]
[ { "msg_contents": "Are you guys going to make an RPM for Redhat 5.0 when 6.3 is \nreleased? I'd like that very much. \n\nThanks!\n\nDante\n\n.------------------------------------------.-----------------------.\n| _ [email protected] - D. Dante Lorenso | Network Administrator |\n| | | ___ _ _ ___ __ _ ___ ___ | |\n| | |__ / o \\| '_|/ o_\\| \\ |\\_ _\\/ o \\ | Accounting Firms |\n| |____|\\___/|_| \\___/|_|\\_|\\___|\\___/ | Associated, inc. |\n| http://www.afai.com/~dlorenso | http://www.afai.com/ |\n'------------------------------------------'-----------------------'\n\n", "msg_date": "Tue, 24 Feb 1998 11:40:04 -0500", "msg_from": "\"D. Dante Lorenso\" <[email protected]>", "msg_from_op": true, "msg_subject": "Redhat 5.0 RPMS request" }, { "msg_contents": "> Are you guys going to make an RPM for Redhat 5.0 when 6.3 is\n> released? I'd like that very much.\n\nI don't know who packages the \"official\" RedHat RPM for this. It would\nbe nice to coordinate it with the Postgres project so we can make sure\nbug fixes and workarounds for Linux are incorporated.\n\nThe current RPM for RH5.0 is compiled with USE_LOCALE turned on. I\nhaven't been able to figure out how to get proper locale support since\npre-RH4.2, though I did have it working at one time. My little test\nprogram which used to work does not now, and I don't know if it is\nbecause I forgot something about how to set up the environment or if\nsomething in the configuration changed.\n\nDoes anyone want to track this down and make it work for RH5.0? That\nwould ensure that v6.3 can operate cleanly. btw, a test for the locale\nsupport is to try \"select '$1.00'::money;\". Works fine on my RH4.2 box\nwith locale support disabled (the default for a clean install from\nsource), and fails on both RH4.2 and on my RH5.0 box when locale support\nis compiled in...\n\n - Tom\n\n", "msg_date": "Tue, 24 Feb 1998 16:53:01 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Redhat 5.0 RPMS request" }, { "msg_contents": "Thomas G. Lockhart writes:\n> I don't know who packages the \"official\" RedHat RPM for this. It would\n> be nice to coordinate it with the Postgres project so we can make sure\n> bug fixes and workarounds for Linux are incorporated.\n\nThis brings me to the question: Is the RedHat maintainer listening on this\nlist? I think he definitely should be. Anyway, I know Oliver (the Debian\nmaintainer) is. :-)\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Wed, 25 Feb 1998 15:14:34 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Redhat 5.0 RPMS request" } ]
[ { "msg_contents": "On Thu, 19 Feb 1998, Bruce Momjian wrote:\n> I have been working with many of you for over a hear, and would like to\n> know more details about you.\n\nI'm 44 and live with my wife near old city KAMAKURA in Japan.\nI love to take a walk around beach and small mountains.\n(my house is located at 10 minutes walk from the seashore)\nAnother way I spend my spare time is listening to the music through\nmy old TANNOY speakers driven by an even older tube amplifier.\n\nThe first encounter with postgres was back to 1991 while I was\nin Hawaii. I joined in a research project at University of Hawaii\nto make a repository system to keep complex information. I choosed\npostgres (v2.0 at that time) as a database engine for it.\nAlthough it was not so fast compared wih commercial RDBMSs, \nI was impressed by its extensibility.\nAfter coming back to Japan I started to run a mailing list to\ndiscuss postgres in Japanese. Until now the list has over\n700 members.\n\nMy \"real\" job is designing and making software for customers\non Unix boxes. I'm using various kind of platfoms including\nSunOS, Solairs, FreeBSD, Linux ,MkLinux and they\nare very convenient for testing PostgreSQL:-)\n---\nTatsuo Ishii\[email protected]\n\n", "msg_date": "Wed, 25 Feb 1998 07:46:56 +0900", "msg_from": "[email protected] (Tatsuo Ishii)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Who is everyone?" }, { "msg_contents": "> On Thu, 19 Feb 1998, Bruce Momjian wrote:\n> > I have been working with many of you for over a hear, and would like to\n> > know more details about you.\n> \n> I'm 44 and live with my wife near old city KAMAKURA in Japan.\n> I love to take a walk around beach and small mountains.\n> (my house is located at 10 minutes walk from the seashore)\n> Another way I spend my spare time is listening to the music through\n> my old TANNOY speakers driven by an even older tube amplifier.\n\nMr. Webmaster, can we have a web page set up with a collection of these\nrecently posted descriptions? The are in the hackers maillist archive,\nand there are probably 15-20 of them.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 20:52:05 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Who is everyone?" } ]
[ { "msg_contents": "Hi All,\n\nI'm getting the following error when running initdb after a fresh compile\nof the 24th Feb development tree. (cvsup'd)\n\nvacuuming template1\nloading pg_description\nNOTICE: Ind pg_class_relname_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE \nSAME AS HEAP' (44)\nNOTICE: Ind pg_class_relname_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE \nSAME AS HEAP' (44)\nNOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE SAME AS \nHEAP' (44)\nNOTICE: Ind pg_class_oid_index: NUMBER OF INDEX' TUPLES (45) IS NOT THE SAME AS \nHEAP' (44)\n\nYesterday's gave a similar problem but only pg_class_oid_index.\n\nThis somehow seems to be related to the recent jiggery-pokery we've\nbeen doing on the classes to hide them.\n\nIt looks like the index is getting out of step with the class?\n\nKeith.\n\n", "msg_date": "Wed, 25 Feb 1998 00:09:30 +0000 (GMT)", "msg_from": "Keith Parks <[email protected]>", "msg_from_op": true, "msg_subject": "initdb error on 24th Feb (PM) cvsup." } ]
[ { "msg_contents": "I am trying to install the Feb 24 snapshot under Solaris 2.4. I have\nfigured out how to get it to use lex rather than flex (we have the\nwrong version of flex), but I'm still having some problems. Is there\nanyone on this list who is compiling on Solaris? Perhaps we could\nexchange notes.\n\nI'm just about ready to begin contributing to the project in earnest,\nbut I must make it compile on its own before I add my own \"magic\" :^)\n\nOcie\n", "msg_date": "Tue, 24 Feb 1998 16:44:21 -0800 (PST)", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "Compiling under Solaris" }, { "msg_contents": "On Tue, 24 Feb 1998 [email protected] wrote:\n\n> I am trying to install the Feb 24 snapshot under Solaris 2.4. I have\n> figured out how to get it to use lex rather than flex (we have the\n> wrong version of flex), but I'm still having some problems. Is there\n> anyone on this list who is compiling on Solaris? Perhaps we could\n> exchange notes.\n> \n> I'm just about ready to begin contributing to the project in earnest,\n> but I must make it compile on its own before I add my own \"magic\" :^)\n\n\tI wasn't able to do a compile today (lack of time), but have both\nSolaris/Sparc and Solaris/i386...what sorts of problems are you seeing?\n\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Tue, 24 Feb 1998 22:29:10 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Compiling under Solaris" } ]
[ { "msg_contents": "> Is anyone aware that the last 2 or 3 days of snapshots will not\n> compile?\n>\n> The problem is in the ecpq stuff. There is a duplicate def of S_SIGNED.\n> Cab we fix this, so I can test the compile on HPUX?\n\nMy cvs tree from 980223 03:00 UTC (about 24 hours ago) compiled to completion, but\nI do see a duplicate definition of S_SIGNED in preproc.y. Remove that symbol from\nline 234 of that file and try again.\n\n - Tom\n\n", "msg_date": "Wed, 25 Feb 1998 02:39:21 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] Snapshot has not compiled in a couple of days" }, { "msg_contents": "> > The problem is in the ecpq stuff. There is a duplicate def of S_SIGNED.\n> > Cab we fix this, so I can test the compile on HPUX?\n>\n> My cvs tree from 980223 03:00 UTC (about 24 hours ago) compiled to completion, but\n> I do see a duplicate definition of S_SIGNED in preproc.y. Remove that symbol from\n> line 234 of that file and try again.\n\n/usr/bin/bison -y -d preproc.y\nconflicts: 5 shift/reduce\ngcc -I../include -O2 -g -Wall -DMAJOR_VERSION=1 -DMINOR_VERSION=0 -DPATCHLEVEL=0 -c\ny.tab.c -o y.tab.o\n...\npreproc.y:289: warning: passing arg 1 of `free' discards `const' from pointer target\ntype\ngcc -g -O2 -Wall -o ecpg y.tab.o pgc.o type.o ecpg.o ../lib/typename.o\n\nI removed the duplicate S_SIGNED from my source code and noticed these remaining\nmessages. Can we get rid of the shift/reduce conflicts? I haven't looked at the code,\nbut there is a debugging flag on yacc/bison (\"-v\") which will write a log file\nidentifying the conflicting statements. I have some experience debugging this on the\nmain parser, but need to work on docs so shouldn't do this at the moment :(\n\n - Tom\n\n", "msg_date": "Wed, 25 Feb 1998 03:27:42 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [QUESTIONS] Snapshot has not compiled in a couple\n\tof days" }, { "msg_contents": "On Wed, 25 Feb 1998, Thomas G. Lockhart wrote:\n\n> > > The problem is in the ecpq stuff. There is a duplicate def of S_SIGNED.\n> > > Cab we fix this, so I can test the compile on HPUX?\n> >\n> > My cvs tree from 980223 03:00 UTC (about 24 hours ago) compiled to completion, but\n> > I do see a duplicate definition of S_SIGNED in preproc.y. Remove that symbol from\n> > line 234 of that file and try again.\n> \n> /usr/bin/bison -y -d preproc.y\n> conflicts: 5 shift/reduce\n> gcc -I../include -O2 -g -Wall -DMAJOR_VERSION=1 -DMINOR_VERSION=0 -DPATCHLEVEL=0 -c\n> y.tab.c -o y.tab.o\n> ...\n> preproc.y:289: warning: passing arg 1 of `free' discards `const' from pointer target\n> type\n> gcc -g -O2 -Wall -o ecpg y.tab.o pgc.o type.o ecpg.o ../lib/typename.o\n> \n> I removed the duplicate S_SIGNED from my source code and noticed these\n> remaining messages. Can we get rid of the shift/reduce conflicts? I\n> haven't looked at the code, but there is a debugging flag on yacc/bison\n> (\"-v\") which will write a log file identifying the conflicting\n> statements. I have some experience debugging this on the main parser,\n> but need to work on docs so shouldn't do this at the moment :(\n\n\tIf I can figure out bison, I'll try and work these out...one way\nto learn, I guess :)\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 25 Feb 1998 00:29:07 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [QUESTIONS] Snapshot has not compiled in a couple\n\tof days" }, { "msg_contents": "> > remaining messages. Can we get rid of the shift/reduce conflicts? I\n> > haven't looked at the code, but there is a debugging flag on yacc/bison\n> > (\"-v\") which will write a log file identifying the conflicting\n> > statements. I have some experience debugging this on the main parser,\n> > but need to work on docs so shouldn't do this at the moment :(\n> \n> \tIf I can figure out bison, I'll try and work these out...one way\n> to learn, I guess :)\n\nThis ecps is hot, but it seems it is still 'in process' as we approach\nrelease date. Can we do what we did with pgaccess, and get a web site\nthat has the most recent version, and just ship a current version with\n6.3, and people can go to the web site to get the newest copy? We put a\nnice README in the pgaccess directory pointing people to a web site\nhaving the most recent version. Seemed to work well.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 24 Feb 1998 23:50:55 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [QUESTIONS] Snapshot has not compiled in a couple\n\tof days" }, { "msg_contents": "On Tue, 24 Feb 1998, Bruce Momjian wrote:\n\n> > > remaining messages. Can we get rid of the shift/reduce conflicts? I\n> > > haven't looked at the code, but there is a debugging flag on yacc/bison\n> > > (\"-v\") which will write a log file identifying the conflicting\n> > > statements. I have some experience debugging this on the main parser,\n> > > but need to work on docs so shouldn't do this at the moment :(\n> > \n> > \tIf I can figure out bison, I'll try and work these out...one way\n> > to learn, I guess :)\n> \n> This ecps is hot, but it seems it is still 'in process' as we approach\n> release date. Can we do what we did with pgaccess, and get a web site\n> that has the most recent version, and just ship a current version with\n> 6.3, and people can go to the web site to get the newest copy? We put a\n> nice README in the pgaccess directory pointing people to a web site\n> having the most recent version. Seemed to work well.\n\n\tecpg isn't a seperate package, so this isn't really an alternative\nin this case :( \n\n\tThe above problem is more an annoyance then anything, and, quite\nfrankly, I don't understand enough about yacc/bison to work out where.\nWell, I understand more now then when I started, but still have a long way\nto go. Next Nutshell book, I fear :)\n\n\tI'm going to do a run through of the code again tomorrow at work,\non the two Solaris boxes, and check for compiler problems...\n\n\tJan, how goes the pg_shadow stuff? I believe we still have\nbreakage in initdb, but Bruce is waiting for that patch before\ninvestigating further?\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 25 Feb 1998 01:30:13 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [QUESTIONS] Snapshot has not compiled in a couple\n\tof days" }, { "msg_contents": "Thomas G. Lockhart writes:\n> /usr/bin/bison -y -d preproc.y\n> conflicts: 5 shift/reduce\n> gcc -I../include -O2 -g -Wall -DMAJOR_VERSION=1 -DMINOR_VERSION=0 -DPATCHLEVEL=0 -c\n> y.tab.c -o y.tab.o\n> ...\n> preproc.y:289: warning: passing arg 1 of `free' discards `const' from pointer target\n> type\n> gcc -g -O2 -Wall -o ecpg y.tab.o pgc.o type.o ecpg.o ../lib/typename.o\n> \n> I removed the duplicate S_SIGNED from my source code and noticed these remaining\n> messages. Can we get rid of the shift/reduce conflicts? I haven't looked at the code,\n> but there is a debugging flag on yacc/bison (\"-v\") which will write a log file\n> identifying the conflicting statements. I have some experience debugging this on the\n> main parser, but need to work on docs so shouldn't do this at the moment :(\n\nI see what I can do. Unfortunately I'm not really a bison expert either.\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Wed, 25 Feb 1998 15:29:27 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [QUESTIONS] Snapshot has not compiled in a couple\n\tof days" } ]
[ { "msg_contents": "Included are patches for SunOS port based on the Feb 24 snapshot.\nRemaining problems are some minor compiling errors of ecpg and strange\nNOTICE messages from initdb (known bug?). I have tested the patches\non FreeBSD and Solairs2.6 to make sure they do not break other ports.\n\no added SunOS support to template/.similar\n\no changed UNIXSOCK_PATH macro in include/libpq/pqcomm.h. The macro\nsupposes sprintf() return the length of the result\nstring. Unfortunately on some platforms such as SunOS sprintf() never\nreturns value (I guess that behavior was inherited from BSD4.2). So I\nchanged in more portable way using strlen().\n\no changed backend/libpq/pqcomm.c. It uses atexit() to unlink an Unix\ndomain socket when postmaster exits. Again unfortunately SunOS does\nnot have it. Looking for an alternative, I found a general exiting\ncallback manager called on_exitpg() has already existed in PostgreSQL!\nSo I replaced atexit() with on_exitpg().\n\nTatsuo Ishii\[email protected]\n----------------------------------------------------------------\n*** template/.similar.orig\tWed Feb 25 10:00:55 1998\n--- template/.similar\tWed Feb 25 10:03:02 1998\n***************\n*** 20,22 ****\n--- 20,26 ----\n powerpc-unknown-linux-gnu=linux-elf\n sparc-sun-solaris=sparc_solaris-gcc\n sparc-unknown-linux-gnu=linux-elf-sparc\n+ sparc-sun-sunos4.1.3=sunos4-gcc\n+ sparc-sun-sunos4.1.3_JL=sunos4-gcc\n+ sparc-sun-sunos4.1.4=sunos4-gcc\n+ sparc-sun-sunos4.1.4_JL=sunos4-gcc\n*** backend/libpq/pqcomm.c.orig\tWed Feb 25 10:04:28 1998\n--- backend/libpq/pqcomm.c\tWed Feb 25 10:05:57 1998\n***************\n*** 645,651 ****\n \tif (family == AF_UNIX)\n \t {\n \t chmod(sock_path, 0777);\n! \t atexit(do_unlink);\n \t }\n \treturn (STATUS_OK);\n }\n--- 645,651 ----\n \tif (family == AF_UNIX)\n \t {\n \t chmod(sock_path, 0777);\n! \t on_exitpg(do_unlink,0);\n \t }\n \treturn (STATUS_OK);\n }\n*** include/libpq/pqcomm.h.orig\tWed Feb 25 10:07:25 1998\n--- include/libpq/pqcomm.h\tWed Feb 25 10:07:41 1998\n***************\n*** 34,41 ****\n /* Configure the UNIX socket address for the well known port. */\n \n #define\tUNIXSOCK_PATH(sun,port) \\\n! \t(sprintf((sun).sun_path, \"/tmp/.s.PGSQL.%d\", (port)) + \\\n! \t\toffsetof(struct sockaddr_un, sun_path))\n /*\n *\t\tWe do this because sun_len is in BSD's struct, while others don't.\n *\t\tWe never actually set BSD's sun_len, and I can't think of a\n--- 34,41 ----\n /* Configure the UNIX socket address for the well known port. */\n \n #define\tUNIXSOCK_PATH(sun,port) \\\n! \t(sprintf((sun).sun_path, \"/tmp/.s.PGSQL.%d\", (port)), \\\n! \t strlen((sun).sun_path)+ offsetof(struct sockaddr_un, sun_path))\n /*\n *\t\tWe do this because sun_len is in BSD's struct, while others don't.\n *\t\tWe never actually set BSD's sun_len, and I can't think of a\n", "msg_date": "Wed, 25 Feb 1998 11:51:52 +0900", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "SunOS patches" }, { "msg_contents": ">o changed backend/libpq/pqcomm.c. It uses atexit() to unlink an Unix\n>domain socket when postmaster exits. Again unfortunately SunOS does\n>not have it. Looking for an alternative, I found a general exiting\n>callback manager called on_exitpg() has already existed in PostgreSQL!\n>So I replaced atexit() with on_exitpg().\n\nI found my previous patches for backend/libpq/pqcomm.c did not work if\nbackend crashed accidentaly (yes, I found yet another SQL commands to\ncrash the backend, but it's an another story). If the backend dies\nabnormally (SEGFALUT etc.) postmaster calls functions registered by\non_exitpg(). This is ok. Problem is postmaster does not exits in that\ncase and leaves the socket file with link counter 0! Too bad. It seems\nthe only solution that would work with both SunOS and other platforms\nis let exitpg() call do_unlink() in backend/libpq/pqcomm.c (note that\nexitpg() is the only function calling exit()).\n\nincluded are patches for Feb 26 snapshot. I hope these are the last\npatches for SunOS port:-)\n\nP.S. I didn't see my patches to tempalte/.similar in Mar 1\nsnapshot. Should I repost the patches?\n---\nTatsuo Ishii\[email protected]\n----------------------------------------------------------------------\n*** backend/libpq/pqcomm.c.orig\tFri Feb 27 14:07:52 1998\n--- backend/libpq/pqcomm.c\tFri Feb 27 14:08:50 1998\n***************\n*** 564,571 ****\n * Shutdown routine for backend connection\n * If a Unix socket is used for communication, explicitly close it.\n */\n! static void\n! do_unlink()\n {\n \tif (sock_path[0])\n \t\tunlink(sock_path);\n--- 564,571 ----\n * Shutdown routine for backend connection\n * If a Unix socket is used for communication, explicitly close it.\n */\n! void\n! StreamDoUnlink()\n {\n \tif (sock_path[0])\n \t\tunlink(sock_path);\n***************\n*** 645,651 ****\n \tif (family == AF_UNIX)\n \t{\n \t\tchmod(sock_path, 0777);\n- \t\tatexit(do_unlink);\n \t}\n \treturn (STATUS_OK);\n }\n--- 645,650 ----\n*** backend/storage/ipc/ipc.c.orig\tFri Feb 27 14:09:12 1998\n--- backend/storage/ipc/ipc.c\tFri Feb 27 14:09:26 1998\n***************\n*** 136,141 ****\n--- 136,142 ----\n \tfor (i = onexit_index - 1; i >= 0; --i)\n \t\t(*onexit_list[i].function) (code, onexit_list[i].arg);\n \n+ \tStreamDoUnlink();\n \texit(code);\n }\n \n", "msg_date": "Mon, 02 Mar 1998 11:16:48 +0900", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "Re: [HACKERS] SunOS patches " }, { "msg_contents": "On Mon, 2 Mar 1998 [email protected] wrote:\n\n> \n> included are patches for Feb 26 snapshot. I hope these are the last\n> patches for SunOS port:-)\n\n\tAck!\n\n> P.S. I didn't see my patches to tempalte/.similar in Mar 1\n> snapshot. Should I repost the patches?\n> ---\n> Tatsuo Ishii\n> [email protected]\n> ----------------------------------------------------------------------\n> *** backend/libpq/pqcomm.c.orig\tFri Feb 27 14:07:52 1998\n> --- backend/libpq/pqcomm.c\tFri Feb 27 14:08:50 1998\n> ***************\n> *** 564,571 ****\n> * Shutdown routine for backend connection\n> * If a Unix socket is used for communication, explicitly close it.\n> */\n> ! static void\n> ! do_unlink()\n> {\n> \tif (sock_path[0])\n> \t\tunlink(sock_path);\n> --- 564,571 ----\n> * Shutdown routine for backend connection\n> * If a Unix socket is used for communication, explicitly close it.\n> */\n> ! void\n> ! StreamDoUnlink()\n\n\n\tWhat breaks by renaming this function?? :(\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sun, 1 Mar 1998 23:05:56 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] SunOS patches " }, { "msg_contents": ">> ----------------------------------------------------------------------\n>> *** backend/libpq/pqcomm.c.orig\tFri Feb 27 14:07:52 1998\n>> --- backend/libpq/pqcomm.c\tFri Feb 27 14:08:50 1998\n>> ***************\n>> *** 564,571 ****\n>> * Shutdown routine for backend connection\n>> * If a Unix socket is used for communication, explicitly close it.\n>> */\n>> ! static void\n>> ! do_unlink()\n>> {\n>> \tif (sock_path[0])\n>> \t\tunlink(sock_path);\n>> --- 564,571 ----\n>> * Shutdown routine for backend connection\n>> * If a Unix socket is used for communication, explicitly close it.\n>> */\n>> ! void\n>> ! StreamDoUnlink()\n>\n>\n>\tWhat breaks by renaming this function?? :(\n\nNothing. do_unlink() is called only from line 648 and the line was\ndeleted by my patches.\nJust removing \"static\" from the declaration of do_unlink might be ok.\nHowever function name \"do_unlink\" would be too general IMHO.\n--\nTatsuo Ishii\[email protected]\n", "msg_date": "Mon, 02 Mar 1998 12:21:26 +0900", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "Re: [HACKERS] SunOS patches " }, { "msg_contents": "The Hermit Hacker wrote:\n\n> On Mon, 2 Mar 1998 [email protected] wrote:\n>\n> >\n> > included are patches for Feb 26 snapshot. I hope these are the last\n> > patches for SunOS port:-)\n>\n> Ack!\n>\n> > P.S. I didn't see my patches to tempalte/.similar in Mar 1\n> > snapshot. Should I repost the patches?\n> > ---\n> > Tatsuo Ishii\n> > [email protected]\n> > ----------------------------------------------------------------------\n> > *** backend/libpq/pqcomm.c.orig Fri Feb 27 14:07:52 1998\n> > --- backend/libpq/pqcomm.c Fri Feb 27 14:08:50 1998\n> > ***************\n> > *** 564,571 ****\n> > * Shutdown routine for backend connection\n> > * If a Unix socket is used for communication, explicitly close it.\n> > */\n> > ! static void\n> > ! do_unlink()\n> > {\n> > if (sock_path[0])\n> > unlink(sock_path);\n> > --- 564,571 ----\n> > * Shutdown routine for backend connection\n> > * If a Unix socket is used for communication, explicitly close it.\n> > */\n> > ! void\n> > ! StreamDoUnlink()\n>\n> What breaks by renaming this function?? :(\n\nOn my linux box:\n\n...\ngcc -I../../include -I../../backend -I/usr/include/ncurses\n-I/usr/include/readline -O2 -m486 -Wall -Wmissing-prototypes -I.. -c\npqcomm.c -o pqcomm.o\npqcomm.c:569: warning: no previous prototype for `StreamDoUnlink'\n...\nipc.c: In function `exitpg':\nipc.c:139: warning: implicit declaration of function `StreamDoUnlink'\n\nSeems to run OK though. Would like to get the warnings out of there for a\nrelease. I didn't pay attention to Tatsuo's earlier patches since they didn't\ndirectly affect my platform; where would these things be declared? Can Tatsuo\ncome up with a few more patches to fix this up? It would be worth waiting a few\nhours on the release to get SunOS in there (the docs claim it is supported :)\n\n - Tom\n\n", "msg_date": "Mon, 02 Mar 1998 03:23:51 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] SunOS patches" }, { "msg_contents": "On Mon, 2 Mar 1998, Thomas G. Lockhart wrote:\n\n> gcc -I../../include -I../../backend -I/usr/include/ncurses\n> -I/usr/include/readline -O2 -m486 -Wall -Wmissing-prototypes -I.. -c\n> pqcomm.c -o pqcomm.o\n> pqcomm.c:569: warning: no previous prototype for `StreamDoUnlink'\n> ...\n> ipc.c: In function `exitpg':\n> ipc.c:139: warning: implicit declaration of function `StreamDoUnlink'\n> \n> Seems to run OK though. Would like to get the warnings out of there for a\n> release. I didn't pay attention to Tatsuo's earlier patches since they didn't\n> directly affect my platform; where would these things be declared? Can Tatsuo\n> come up with a few more patches to fix this up? It would be worth waiting a few\n> hours on the release to get SunOS in there (the docs claim it is supported :)\n\n\tWhat he said... :)\n\n\tTatsuo...could you send me a clean patch that fixes the above and\nincludes the last patch? I'll end up scrutinizing it in the morning, most\nlikely, before applying it, but it would be nice to get it in before I\nbundle things...\n\n\tAs long as I'm confident that it won't affect anything or anyone\nelse :)\n\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 2 Mar 1998 00:01:43 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] SunOS patches" }, { "msg_contents": ">On Mon, 2 Mar 1998, Thomas G. Lockhart wrote:\n>\n>> gcc -I../../include -I../../backend -I/usr/include/ncurses\n>> -I/usr/include/readline -O2 -m486 -Wall -Wmissing-prototypes -I.. -c\n>> pqcomm.c -o pqcomm.o\n>> pqcomm.c:569: warning: no previous prototype for `StreamDoUnlink'\n>> ...\n>> ipc.c: In function `exitpg':\n>> ipc.c:139: warning: implicit declaration of function `StreamDoUnlink'\n>> \n>> Seems to run OK though. Would like to get the warnings out of there for a\n>> release. I didn't pay attention to Tatsuo's earlier patches since they didn't\n>> directly affect my platform; where would these things be declared? Can Tatsuo\n>> come up with a few more patches to fix this up? It would be worth waiting a few\n>> hours on the release to get SunOS in there (the docs claim it is supported :)\n>\n>\tWhat he said... :)\n>\n>\tTatsuo...could you send me a clean patch that fixes the above and\n>includes the last patch? I'll end up scrutinizing it in the morning, most\n>likely, before applying it, but it would be nice to get it in before I\n>bundle things...\n>\n>\tAs long as I'm confident that it won't affect anything or anyone\n>else :)\n\nPlease give me an hour. I will work on this now.\n--\nTatsuo Ishii\[email protected]\n", "msg_date": "Mon, 02 Mar 1998 13:05:49 +0900", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "Re: [HACKERS] SunOS patches " }, { "msg_contents": ">>On Mon, 2 Mar 1998, Thomas G. Lockhart wrote:\n>>\n>>> gcc -I../../include -I../../backend -I/usr/include/ncurses\n>>> -I/usr/include/readline -O2 -m486 -Wall -Wmissing-prototypes -I.. -c\n>>> pqcomm.c -o pqcomm.o\n>>> pqcomm.c:569: warning: no previous prototype for `StreamDoUnlink'\n>>> ...\n>>> ipc.c: In function `exitpg':\n>>> ipc.c:139: warning: implicit declaration of function `StreamDoUnlink'\n>>> \n>>> Seems to run OK though. Would like to get the warnings out of there for a\n>>> release. I didn't pay attention to Tatsuo's earlier patches since they didn't\n>>> directly affect my platform; where would these things be declared? Can Tatsuo\n>>> come up with a few more patches to fix this up? It would be worth waiting a few\n>>> hours on the release to get SunOS in there (the docs claim it is supported :)\n>>\n>>\tWhat he said... :)\n>>\n>>\tTatsuo...could you send me a clean patch that fixes the above and\n>>includes the last patch? I'll end up scrutinizing it in the morning, most\n>>likely, before applying it, but it would be nice to get it in before I\n>>bundle things...\n>>\n>>\tAs long as I'm confident that it won't affect anything or anyone\n>>else :)\n>\n>Please give me an hour. I will work on this now.\n\nHere it is.\n(Mar 1 snapshot seems to lack the pacthes to include/libpq/pqcomm.h. so \nI included that also.)\n\n----------------------------- cut here -----------------------------\n*** include/libpq/libpq.h.orig\tThu Feb 26 17:02:21 1998\n--- include/libpq/libpq.h\tMon Mar 2 13:16:06 1998\n***************\n*** 282,286 ****\n--- 282,287 ----\n extern int\tStreamServerPort(char *hostName, short portName, int *fdP);\n extern int\tStreamConnection(int server_fd, Port *port);\n extern void StreamClose(int sock);\n+ extern void StreamDoUnlink(void);\n \n #endif\t\t\t\t\t\t\t/* LIBPQ_H */\n*** include/libpq/pqcomm.h.orig\tMon Mar 2 13:55:19 1998\n--- include/libpq/pqcomm.h\tMon Mar 2 13:57:10 1998\n***************\n*** 35,42 ****\n /* Configure the UNIX socket address for the well known port. */\n \n #define UNIXSOCK_PATH(sun,port) \\\n! \t(sprintf((sun).sun_path, \"/tmp/.s.PGSQL.%d\", (port)) + \\\n! \t\toffsetof(struct sockaddr_un, sun_path))\n /*\n *\t\tWe do this because sun_len is in BSD's struct, while others don't.\n *\t\tWe never actually set BSD's sun_len, and I can't think of a\n--- 35,43 ----\n /* Configure the UNIX socket address for the well known port. */\n \n #define UNIXSOCK_PATH(sun,port) \\\n! \t(sprintf((sun).sun_path, \"/tmp/.s.PGSQL.%d\", (port)), \\\n! \t strlen((sun).sun_path)+ offsetof(struct sockaddr_un, sun_path))\n! \n /*\n *\t\tWe do this because sun_len is in BSD's struct, while others don't.\n *\t\tWe never actually set BSD's sun_len, and I can't think of a\n*** backend/libpq/pqcomm.c.orig\tThu Feb 26 17:01:05 1998\n--- backend/libpq/pqcomm.c\tMon Mar 2 13:16:06 1998\n***************\n*** 564,571 ****\n * Shutdown routine for backend connection\n * If a Unix socket is used for communication, explicitly close it.\n */\n! static void\n! do_unlink()\n {\n \tif (sock_path[0])\n \t\tunlink(sock_path);\n--- 564,571 ----\n * Shutdown routine for backend connection\n * If a Unix socket is used for communication, explicitly close it.\n */\n! void\n! StreamDoUnlink()\n {\n \tif (sock_path[0])\n \t\tunlink(sock_path);\n***************\n*** 645,651 ****\n \tif (family == AF_UNIX)\n \t{\n \t\tchmod(sock_path, 0777);\n- \t\tatexit(do_unlink);\n \t}\n \treturn (STATUS_OK);\n }\n--- 645,650 ----\n*** backend/storage/ipc/ipc.c.orig\tThu Feb 26 17:01:36 1998\n--- backend/storage/ipc/ipc.c\tMon Mar 2 13:16:06 1998\n***************\n*** 38,43 ****\n--- 38,44 ----\n #include <sys/sem.h>\n #include <sys/shm.h>\n #include \"utils/memutils.h\"\n+ #include \"libpq/libpq.h\"\n \n #if defined(sparc_solaris)\n #include <string.h>\n***************\n*** 136,141 ****\n--- 137,143 ----\n \tfor (i = onexit_index - 1; i >= 0; --i)\n \t\t(*onexit_list[i].function) (code, onexit_list[i].arg);\n \n+ \tStreamDoUnlink();\n \texit(code);\n }\n \n", "msg_date": "Mon, 02 Mar 1998 14:24:02 +0900", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "Re: [HACKERS] SunOS patches " }, { "msg_contents": "On Mon, 2 Mar 1998 [email protected] wrote:\n\n> Here it is.\n> (Mar 1 snapshot seems to lack the pacthes to include/libpq/pqcomm.h. so \n> I included that also.)\n\n\tOkay, applied...I'll test it under solaris tomorrow before I\npackage things up, and FreeBSD tonight...everyone else should do a run\nthough quickly also...\n\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 2 Mar 1998 01:42:51 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] SunOS patches " } ]
[ { "msg_contents": "This is from AA van Raalte ([email protected]) and shows that\nwe have some problems when dumping tables with LO:\n> \n> 3/ The following script causes pg_dump to fail with a Segmentation fault. On my \n> system pg_dump tries to generate an index on a large object. The SELECT statement \n> in pg_dump that obtains the list of objects to be dumped explicitly rejects large \n> objects. This SELECT statement is returning an incorrect value!.\n> \n> --------cut-------------\n> db=testdump\n> a=1\n> \n> destroydb $db\n> createdb $db\n> psql -c \"create table hobs_log1 (id text, obj oid);\" $db\n> \n> while [ $a -lt 100 ]; do\n> psql -c \"insert into hobs_log1 (id, obj) values ('$a', lo_import('/home/alvin/pg2'));\" $db\n> pg_dump $db || exit $?\n> a=`expr $a + 1`\n> done\n> \n> echo success\n> -------cut---------------\n> \n> The following is the output of the above script on my system. \n> Note the rather garbled line containing xinv18337, this is a CREATE INDEX \n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n> command and should never have been generated.\n> \n> --------cut--------------\n> CREATE\n> INSERT 18351 1\n> \\connect - alvin\n> CREATE TABLE hobs_log1 (id text, obj oid);\n> COPY hobs_log1 FROM stdin;\n> 1 18337\n> \\.\n> @\" int4_ops );xinx18337 on xinv18337 using btree ( \"qdR\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n> INSERT 18383 1\n> \\connect - alvin\n> CREATE TABLE hobs_log1 (id text, obj oid);\n> COPY hobs_log1 FROM stdin;\n> 1 18337\n> 2 18369\n> \\.\n> ------------cut-------------\n\nVadim\n", "msg_date": "Wed, 25 Feb 1998 11:01:04 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "pg_dump and large objects" } ]
[ { "msg_contents": ">> has somebody tried to replace the -c switch with the -u switch\n>> (available with GNU diffutils) in the script regess.sh?\n>> \n>> Well, I did it and I find the resulting output much easier on the eye\n>> to compare the current and the expected results. \n>> \n>> This change might be worth a little hint in the regress/README file. \n>\n> regress/checkresults has those new flags.\n\nUnfortunately, not all diff's have the -u option (AIX 4.1 :-( so I have to\nget a gnu diff)\nbut it looks like diff -wC3 will produce similar results. Actually\nsince the diff is so large I prefer diff -wC1 which only gives one line of\ncontext\nusually the sql statement.\n\nAndreas\n", "msg_date": "Wed, 25 Feb 1998 09:32:08 +0100", "msg_from": "Zeugswetter Andreas SARZ <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Using the -u switch for diff in regress.sh" } ]
[ { "msg_contents": "Hi,\n\n seems that my last post didn't make it through. That's good\n since the diff itself didn't covered the renaming of\n pg_user.h to pg_shadow.h and it's new content.\n\n Here it's again. The complete regression test passwd with\n only some float diffs. createuser and destroyuser work.\n pg_shadow cannot be read by ordinary user.\n\n And Bruce, your'e right. Sometimes the nice solutions are\n that simple but we tend to think complicated first and waste\n too much time with complex solutions.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\nbegin 644 pg_shadow.tgz\nM'XL(`.7@\\S0\"`^P]:U/;R++YROZ*@;,)-D>`WX\"SV2H\"),M=`AP;3FJKMHJ2\nMK;&M&UGR2G((9T_^^^WNF=%S;&QCB,.-B\\2RYJ%^37=/SZAGU+\\)!J;EW>Y8\nM=J_WXE$^Y5*I4:NQ%PP^U1)]EROB&ZZJ]7*IP5BCME>K-_8:U3*55AHO6.G%\nM$WS&06CZC+T8]8._G\"GUK([YXAE^D.MLN\\NV?;8[#OQ=Q^N:SBX18S<8C]25\nMW]WMF-U/W+5VNV9H.EY_]X/YB?=LA[.=B44_;6UM+=KMVD=NL?\\Q7<;V0$::\nMU4:S7&'E@X/]G[:WMZ<\\<^UJS-D[WF&5&BO7FI5ZLUH5[;;2'P*NLF=`,?UD\nM[/W)^=O?3]]`YWWN=C[9.\\$`[F+!V<7;PS,HNVFWCMIOV,\\%T[)&/CSO\"]O9\nMV84_V^TZ8XM'T!CLSY_66?XSZM]84*5C!GQG@+\\^F[YM=ASY:QQP'Z[^_(GI\nMV_9];SP25>$IDVH6$6JDDL`.KK97`CNI:):#W^*\":W:=[N#33E<C1*IH$<%5\nM;5,\"6&I6*DV\\F\"RXVG:U9KW6+.U/%MQJQ:CN*\\']AV00VU\"=`@'-?M_G?3,$\nMXF],JC/RO>Z4XO!N1*W7]<5\"6M.M1Z8/=W?I\"T&86MX;N[G'CT/;\"7:#NZ!K\nM=@?T=\"2;0%=*\\C=\"5XGOHR.LY?=!PZB5#A3'U^P>*ZS_QLW1U7CD\\-/@WZ9C\nM6X5!.\"KBZ%A;XP!TX:35NF@9``.0!Z6,=S\\U&7*-_;GQ,OAS@[E>R'K>V+4V\nM#&JUAJ6N.>3%UT\"%-=MB;UCAL.N<6D56*+SS_.&-Y'L1],E5^ZIU?70EGKK]\nM*]P&+&SKM5`K:[L$*-N\")_@L''\"VF=`/F\\SGCAG:GFLP`HQJ0!==GP,3K0[K\nMV=RQ6(=#:RX[HHJVVP>X_:'IL!'WAW800\">!J+&K2!.$?G<X*AS+I[7DL\\X!\nM-0.?3#BR-V]8B;UZA:BN%6;!3P$GB/RW1!0Q)2&5/))B^DUY)(3U.7-I&H:3\nM^:0;6[7RGE&K1-HT195C[MXQT[WS7)Y`A(4>&X^`2IR9#,@9\\B&3FH*-78<'\nM`4(+S9661)C,$)HP.V`!#W<8*UP-X!K^H\"^'APRL\"_>Q<L!`3X6\\&[email protected]#\nM@#N?><!ZOC=,_-XI9@A:*`P]T\"FOV.'1V<W'5I']][\\L>>OPLEA$4B(Q3H,V\nM`9ZD>B$BNJ3W^DRC@C\"+2\"T%^_CD[?7[K&!'1!+$`]2%E#>3Q+6X:_-8W!5,\nMKVF0*6;)0;9D9DD=_PS8-75X/!7#M*,-;'DM]EUB[ET`I?Q;.X\"QGR!NYVYD\nM!@$SG:0BV58Z9D=1=%U1=`8CA9U'R/_#[EF\\A^0F_&^N6H=')_<016IFE`T%\nM*\"!/TBF14R;@D9\";JMT?\"3T=+^O5LE&O51;V2KQ;E_OSVSRL>K,DYZ2]BJ(V\nMB2X:B5,L6-3I>`06S.][M%=S2,S(!NW(.-@S&J7]A4<&SA1^#(\\E#`_)AT6'\nMQV/QX<<8V6*-ZK[1J#U@3@M3_A]C9)(YGT8<S4!1S%AX\\OI(S'@V`V4>ABP0\nMW/2&0].U`K@8W:5CF^F2N4*;Z:9K5X,Q12C+!QB2+]6;E;HVLIEME@IL5@^:\nMU?J\\@<U?S&X7)FH8NC:'.X-?4V6Y$)Z^&+Y1Y+!X7=]:!#0SK5/(I`LWHL+0\nMM_O]7#3TER#T?+//=WL6MIP<R'P:]%0`\\]$0?(#86AUUJ1?>9/E\"(ISL@-:6\nM4\")9C95`'*O-RL%404XU3HMSK0Y_4Q:8ZD:UG(_3BZ`OIT4.?3PZ8N>]T>PY\nMHO.)XGBAYKYPM%8>$A21(7J!:2Y$_P28Z@/SCX6KELOELE$IQYX,TAX#-&#1\nMWO/PLG\\M?Q>*KZDX'(^@J,U-L`7MN^`('T]VMG#=/CD__'!BL$O/=D/N0_-C\nM,QP/\"ZK+HK2@^&&,E0SZ$W9T\"RN=6I=H2\">Z%OCPM/T4%OB&#-#,3;%RU#0*\nM!\\_86M6/;3<[$N%ECPW-3QR,H<^%@1R803:6%W`6/3`.IJTG`2D*D91L43[-\nM*K$E[V+,P9CIC>]GS=3V3\\\"<AQ@*WK-=/L%(R++%#(1LO/;.MX674V7E_69E\nMOUG=FVX<5,.<GU-K3#8,]8I1U_@YR5Y]GO,%O%%H#^W_<'_WBUA+3!>'8,.A\nM91#.Y.3`7Q\":H=UEW8'ILRUX),AU&TR]\"YXK[YTX?$AW:7C(JB#^:Z+B%3@C\nM9]SMAX-L99IX$WXY1^?Q\\4MZ.8^&X0,$&(V98\\+L0RO\"<>E\"0APWU^R?F2[&\nMB:9Y03Z8+,B@8Z'G>.TL-J#2J1W`)!*]VGNM_V*.S#V+^HC2&%S4V?89\"&3B\nMM:6E(W.OK[(T=!X@HD1QK7B*DH5$4S1-SB$KE6:U#.(U52Q5L_3FF$JS4I[B\nM=(/9W\\OK5C!37=,:VNX,4Z@)$[#8DYQK$NG8G=%?NUW_;A1FBS)RI2W\\8G9#\nM-8$4N.7TZM/@II]!+@D[;31@WZC5%\"=WM[:7\\<$M95OLFA8T+_N7M]8[W*J(\nM-W%3VQ;#>3#M<QAZ,(9L4*-=#WP^-PR8UU,K^NCKF(SV/\\)/BW5$DY$7A$,S\nM``]1/`4W55!U<PS%+I@76KS=8>P*:E-S#/W`+!KZ`&?JY\\OWQX=7AZ0(;JT=\nMZF1Y2.^*$`315-Y<%9H*R?I.J:KU[QI&HZ$DE[&0#T>NF'H4T!?9*@Y-![0G\nM[H%QN%M`H,52_C]9N4+N\"#@D(W!4PEY!-3;8QLM@YZ6U83!5WV`?[B[!9%S:\nM%C6B?9GHL2N\"3Y!=(BN1@QVVCTY/%=%QWXY)I>V3RZ/?#EMB`^86.5`P4)'H\nM`95;W`%7#6]T>'C+N2OV`@6\"\"R[S\"3ZJ2GW#0^TP4-V!RVPZC#22O+5+H\"N4\nMP8P8.`4'+%[2GHO-E\\&FA\"]Z<@!E0`N<QJ7W#L4$.VK]<7EU<_GQ^.;=Z=G)\nMC41*TA<(P+_P[LU?8^[?B4<*YFP5SZ_/SN#7A6VIZY)L)/!*\\\"1BG2@'MY87\nM\"I\\];*DJ*9^89$()SLK(1#SVGI-4M`FKE9<+G>[8:Q@'I4>Q>L<T5\\4!DU#.\nMAY:E]O4E=0/]C/?_@3?&8\"H?C'A7:/`X%@`-1/?4!%5O5,EVI5@$-BICVN!-\nM<B=FS50AVOB]=,7,&-([@77AB&(0>-D.AR';`L,2%IG<(<A(GK<RF](1J=<D\nMADJ8LJ4W0\"51@Z)%QSSH9FM805>(`2ZIM;NF&U4\"O\\V-BZ@#U3C$'Z*,HDU)\nMP\"R\\(=2*$)?',.CSB(O4(C\\$YAZ!$72:+C*RSF,)C78:7X*I;[46>RP4MBO8\nM;@<LTB<P4:?!E6^Z`6A[0.@MWBP4:2T8/V]YWW;SY4GK\\R')?>F^A:@(0]3>\nM($<B/`AVALH`06`U7(48D$DI)64ME*C%MB+!`%V,=UVBE=CM5L@[#[(#@[9@\nMMH[9?^7V3'EQ>%EDZV_P\\NBWDZ/?;RY^%^*`'^SLL./YH9X4^$FMFUN1G*67\nM@RV/![1H/C`_H\\T].SFZHO%T>MX^:5TQ,(>?P;KT.;G\"HM&&D7\\G)T(EBV4$\nMCL_#L2]%Z6N\"6RAM6D.`G.J`\"P&,,>58I7($V=T,F>D`&ZT[QK_809BVX@EM\nM\"=S!.>&--^*N7]!`MY[6G5!?5<\"XG!HROCT\")[^0Z%@V10QX%X7-9+<^>`6,\nMI-AS(WP\"C]URDK*.%$O0,;<#,R247/XE9\"H0K^0M&'ACVNR>1DL!UN;A&3SD\nMG>=_Q\"=FH)*DQ8&KD._@H,$;R:K@-Y@.;A.57R6#H9\\A&78[0*>ID-N708->\nM]=OG(<)?P*ZI@U>=<:_'?1BN(*GKL29(-(\"AZ(M>0.[=<;2`<R,W:AA);D\"/\nM;O&U4H%251##`_;J%5L'_]7%C?W2JZ5G&0PU)RTP^'A-'FY\\*U8EC,F>WK#0\nM'_.(<O/!3(S3`ZT@!MT6\"MC8KV\";OMS85@R#^(V>>53KM7JM3JG*R)%?354I\nMC,A2E:7.IWZ.ZC*/YUP*,^,*/4QEQOY\"6FEJ85S/^@_W*LZX^UE4I\\3L291G\nM\"K+[U&=<>844J`0JJ4)CSJRP$HWACM6H!O`'*5*M#UK=,\\JUA`]*0'+7(B[C\nM?S'!\\,$\"[email protected]\\6B-G7>=;P@;ZJ7J9QPC5R-\\`X&1.0R^$:2F3GU\nM0G9&DB.R,\\LD1V[<9PF2&7[?GB1:B:DUC'*]DEA^)`7V=FP[8I(J[2(N[0ZY\nM&TI5C-&=,3QP6I0I:5%?!@4UB*-!D=@I@=>A;W9%*6Z_,**WK`S<@7IK;4SP\nMP0%8)EZ%1+RIKN='PP=?D#1#\"9#JJ?@:)`*H,O0^PW0X0'MOA@I1=!+NL!UZ\nM\"K<8<7,]IKI55C]^X&=4?M=N:#MBQXRB9[P\"NKKTG&\"D5XBB6HG=!PH?5&,=\nM!_#2JX5]=&+,'H9.D=\"9M92<#X&V]A;NB?52\"H:\"!Z2LK707\\:ZPX>G@+H5>\nMI;4.*!YK#R<8YEETZ11-&E%'YQ.3G9-NLV+0B6OIM`L)IR1=I`^_1]+E].Y4\nMK;LL\\FDE\\6#/J)0B:PL.#_==$?\\Z=.\":PE_1U?,)ERJ\\I1@]#=XK&O6KE&M&\nM)7Z!\\T?4+S>-7=[LU50B->/D]?KR^/#J9!5C?<+1_*Z\">Z3UR7K3ZL)X.((I\nMJQ*IK'H'DV)Y+JX7#KA//Y$_)OPWP(5-83>@\"HFPM`,_8H*:Z>QB<]AHA.5F\nML6(#E%!9/Z)OSTMM/4W,;8+J^CZ\";*NCQ/X_QN:6K<RT_E@-?-/Z[!&P]94*\nM@=VG*@C8^^->B@BSQKW65R[PM01\"Z%\\F;!B51B[:);8H\"!TGTO1@>(:K^`QM\nMN;R+5.\"T&(UL_I*2'FU,=\"6A,K(#)!FN7F<\"(%'$)9)\\5?V?;Z(1(N[(>;U\"\nM*Q-T>CRT)IJ:)2*FY=]!PZB6JBG^98(5V$.L4E<P\"*-P2#)K<1Q6)QI2+>T9\nMU7)5%PUI46\"0P@)BXB_>;%Q\"%,30)D+%&A0H8!,\"!?=%\"&B7M\\1'$^58/CX)\nM\"_\\X&.DS!=2,:KVQ4K$+BSL<[JC$;\\\\F=N%'(C/C+.`8+I\\D>'')?>AZB*G]\nMD`%>;V(DHV>[T<9%6G)0E>5&1L6D#I=LM'88.^TQ.U3.,Z4P(8?:E?\"@^V[Z\nM+LK#D`<!OICUT*C(CX#(]QT0F6_ZD)HXQ%,&-4`B497KY_-M?<HNUA,;N!GP\nMMX1J06(<%W=`H7U2/[_*A\"5\"RZY2N$6C99]-N.7)-.T\"\\9:)NE83?/E&VG:1\nM0,Z/\",YSB>!\\,]VKVS'U4.VK]7GK!T8U^5[A/:&1&(<W;+N\\(F&B>U6<\"H],\nMC!`I,LP:(5J(#$\\1*'H8*?0'!1P8M5)F5F3A>]W*)B=?1!,%27/<MMUN[#_C\nMY@K'ZY@.`S!]2J2G7A,/#(9YME&KW^*J!VBA@`W'04@J'8H$S;;H%3^7M%_7\nM&X[(<G<]-P\"\\N-N]`ZW_SO:#,+*M4\"@VBK*A:7$@@KLM0%\"J3>SYN*5:W!G:\nMKHH2=3%SMMD!2,D&DEFA-P,EQ&0N13N?_S6V*6-]I'E-R[+)>`%&U!/`+1V-\nM$,\\P`7P_V_P6OGC899C(+WH_.1E_DB<!\"\":DG*9%F\"`-R1.S03[U.V>$/M5_\nM+9GJG^K%+J(BOPB0Q-Y*=CHOX)@2<$PZJ\"\\#-/@B8Y)\\VQ??6M6^MYP8Y0N\\\nM@_I=QA,51Z*A,C='U.O+2^&)SNG_IEQ9G0AIK5HV:O5Z_%ZR>(63<H.)V=1A\nMUSGWPO.QXR13/ZC<80'G\"%KDS(*O\"3.F1)0B>@=3)F*B8*6V^P*\"CS.L>!_4\nM(!Q)@J[!Y80T;JV3,WT:MUPX)I7.+<[F=G]BW+_SV7%/@QA^`+[)N@YFI=7D\nMQEVGW+C:&-C:5YF.#9]/,@!^J!VX2`UX>.R*4N<H$#\"152\"M*Y#.+ZY.CP#_\nMC2N1JDVM:8`RO?/&8FX)K/+Y9^]3\\@R-(,&F#0%/IL/`4^>]B-2[.)5`U'\"7\nMMQBIZE$[&R(M7II(5_X=VVR=_/OB]Q-V>';&+LXC;?NN=?&!75Z_/3L]VMR(\nMB;&&_Y)>H1+0Z$WH90IH'&#X1B*JF<%^2R&=$#Y8#3$5S'I*095&:!91G3\\Q\nMETBPA,EN4EFYDK?G2<F5;)=/A5O=U^7C2K7))>.JER8GXVJ4ZD:C7$XL>JJ!\nM\">)&!\">(60\\D*=Y7+P(@X`#\"C-F/6<),7Z8&,F5X249*Q%\".T@B`.QN=N$(2\nME&2LRC&0\\N;`FW0IA17T[<D\\0R`6.]&(%UG2)3+QZN<*(9-TA.Y'9U$Q%'F^\nM\\G(H[\\\\OB+*A1A(/)DNB:I01Q5A\\M3O>C;TE9U6)4D<(\"DNHX!YQ4'[./.^3\nMV!NH)`[Y'9^G%G,J8NJM'0ZH#\"=P+-$7UA!),\"(7&\"XPG8_,:R5J?Z`T6R(M\nM%OO-QE18=V+SN[&WY$PA\\Y-`RNFW(8(^A>6!4:[4L_MJ/G)V:XK-)FK^B4]R\nMS+X8J.+4.S(<*@2;S*P4AW/C]$8.%U%NGP=C)Q1'VX4J'#QV'=O]I)J\":?1,\nMJ3MN33P?@-+E]<8P_UY/S+^''-QW$5@VHZ#P2$3J4;6PHXO+/[+KHC+WD@),\nM)D:C'$V^P.J6BRB\"\"YRR,\"N;@\">]HD)N!K2\\H:R3>'S9NL`,0VPBGZ:@;&9K\nMS_.DK)3KIZ#M_,I;GD/:]\\WASEU\"G:;NSZ.\\4PWS1T/4M$=#9!JEE?=>LSPE\nMJ>?^OG$0;8Q<PTDW^KW=@?\\Z^7LK\",6-CN<Y>`._.6XA61?WMO#F2-W%Y-88\nMHE+C(EI%\"V3RZC-0&]2O`Q?4\\;EG<;KCP@7=`>=Z+&Y]QBLQ&1'@JLSCRP=7\nM\"MMR`)Y?G'Q.BU[J^S=0YDXF:>RD*O,(V:0^UCZ`2B?1J=(IW^5F37LZ^,3V\nMN4,<ZI49SR29XP0!40H3G)FR&V=FE8>CD7/7XJ%O\\\\^\\-8:IX;\\PZ,2V:`R%\nM/@<?KR70PE*VY</_:D;(T-@R/[RQ78M_,<0O.5>[<:!#Q\\@?1[)DS)*ICI\\:\nM-ZT\"J>P9^_%I[V+>C)'D[5]]\"V>B\\`UZ&$_H2<S<VJ%_?C2Z*XPI*R%&L.4,\nM>*:##A*-Z(DXM<=4I&<GY\\7$P46D,\"1X2F4L#;RIR?YG!'!^!2$EQ`I)2I)Z\nM(5,RCSK(-,T?M5[5'K4^K1D,_D:S-&7P@P<3NX831L`<AXK$Z9A->2;*'&G/\nM$UF>-S3I[?L\\M*V\"N`X,>=-5;T\\3'A/.9WE$//09SQ?%1,NA^KY1;M32`SL?\nM$UN[]TRS3*0'B$+ZJ$EK7[02BWO/$^NT&P:+3S%;6S/MT?:OIBWSG<QSGAQ:\nM?K7Z#UX\"KI'AQJ+3XZL_+D]NWI\\>-T6EU!.`2)@'D3HI)-+,*GJD-,D*T6.F\nM(]V61A'M1OS]NE$Y*\"<E9D0KLN%PI(CS57QQ)^`\"FS7:16*&A9%<]&%;1?8J\nMP^8TO748TF:5J%I@_X=[O0+&3_$8]&(QC3OMN)?`)MCY<&`E#Y8,[J)F@E1,\nMK&ORUB);87ZCD>TAGK%4Z)\"+1A-=R4FV(]\\Z;4+VI\\:=:OM&_$Z75DF*@]TF\nMGOH@W=<I-?!T0=XWPWD/TE`'N#FFW^<W7N=_.2;CGWS\\!(WYR&.E51=\"+F=7\nMGAHYO9EY&'KZ=[!J1F6O'JL..21P8.&0N$ET(Q=H:#48KPKX9L.[L=LMTJ:Y\nMK^2J_9W;!@#C\">9Y\\L@I.:U;*PN_[F_MOF,Q\"$OI[Y+H7P<@J:H'`M?^HWUZ\nM?!]T8C?<XX\"'2T;O,0VP!K[WK0M%//&&F6!:I$(?S#3-/H&9V);9M#@O9:3:\nM?C\"(4YF7W<SX6$#.R,!%C8KMVN&NV+$4:$Q*NGA^@Y)NGUV]J#5+^Y/-2:9M\nMQIA`V]*T\\Y9*1KD<;?!;.Y:;JE)$Q((\\:2D^Y/73]X\")N4$N@D2^C2M)N8(2\nM_/=5>IH2%C6NE@\"+1FIG@>9!0H*3$;R8)\"5Q^8)B$G>P@)PD&N<GKGOSGJ2;\nMFGF)L2:V0HFLZUVPE$1@S*HE5PJ?[-@NW91SRJFY3X;*0H=V:9'1\\JEZ8%3C\nMK)<39F5(SJMQZO3M=QBG@7E9FX?7=,)D[DQIW-=@N_';(-'9VWXTWO3[C:12\nM.*6)VX4]]7CT\"++T!$Z^/B21FWZL^\",B-^'%C\\GH:<)EDQ!<[email protected]&YWUK\nMM$ZVPOQJ)]L#!<S;?,38/BO!=*<B;<R>5N_D6N<43[DZQ4+M&96J+ES^\"Q[D\nM!*Y\\D#T)+#M69CN\\$E=%,'\"DX*3MU#*/)8&@B6L_'(3,^9(3@-`/=*.Z%Y\\1\nMO,!IL]?WG38+=P\\#S$5$,5Y\\*4V^G;.N]A_-=;QO/(H1\\N@8W6\\.^2SGW\\XY\nM0&UW5[QHB%1)7.X$`QP>4XIG&IQ3VI-+\\,&\\PY,Z86C6U;FQT=\"<UC8Y,.O-\nM4KE9J4TY%[%4-2JE@\\3N=W9T>'YX?`QL:[W!]]!ZMMB@^*_KD]8?;U(Y6]42\nMZ9^)-_RC+*XL?O,IF<>518E<693)E46I7(O)OF@E,DCUS@J;/Y^??$3@-@WV\nM,\\U9#+;Y,\\!\\U#HYO#J!NYOAIKPET=@TX%91'DDN\\?V_]HZUJ7$<.5^=7Z')\nM4@?,\\;`=VWE0M5=ADLMPRQ(V\"3<?;NXH)W'`2X@IQV'@;O>_;[<>CAS;\"7B!\nMG;U2SU#,6*V6U&JU6E*KM?0M?UY[^1GKGZ3%SQ-V?$4W#!ZI2$G_7HI[/L)3\nM!3Z?0EKDV?&K+/)K<J>$WE[G]%4S]XR:?.6#78M)=;Y\\04`(>^J6P%:K?4J9\nMSD\\MML[[/YTBU\\M;E$R9OC$&QH9GE*@/Q[_(UM_(_LPC.ODWCV++ZB,)Y9/J\nMPX7QA6OT/*'!9<AXR'\\M167U\\U,%9#5?QGE>THMD4QZG89EK39.*;<!,%F_\\\nM>Z/K@)3OW=%B<5LFOQ!A')#]OY/]G\\A^B[\\<N60A,;__BT&^)R\"2]X?HU4Q^\nMP0&L0:X[LG]/RO]IM8\\O.HTRZTI6`/43$B(UZ$*?)1ZDW\"87_9.S#M[D/OGQ\nM9-#N]<GVER_1=IG3?H%:;6?4JM-KG@W$37+FQ<Q\\OJ&&S(695@#FWZ)\\>2^Q\nM@*HOTKLX;<=!,:[]L0?MQZ<#T3AE%5G.-`<L.C=I=?$=CT&[V1(XVZ)/MS$O\nM0SO\"_GMQ=DDMX&$(\\$2>C(?<CQ,C2DV]480N:)+>.'J-KA,5N0K1=8Z7\"XP3\nME4'.+893?_1*<L,NWL+XJ<6ANMYX_'`5^,V,(\"H2Z*#(^!X/<921\\JKH#YK'\nM(/L/`F='T]C88C?-49MK,[;_*7^G)H8&!HFUDB`L#NHEMI)&#9\"L!&J/9\"4P\nM\\R25PH:6ID7>0R1_1],%0]QK[G\".\\<]W7U7@1411H9_Z[0$Z_(@)D'-TFWS^\nMU.ZUY13![.TCH<D**[(UU9-5VV6O/1`]W.RC5N4J\"V16?%_JLR5#.=:3C4NI\nM+Z1H!2O6YIZD*!L-[,.ENMQC!#2I,]GEE7B8O6J72O=G$A$S6!5>4XL]W>#A\nMB__#U#XA6\"*Y:4\\Q?7(S4UOF++@'&Y$8L)2K-(S$)LWZC,O]F8H=WYW(-H+V\nMK'A_YCOV2`LA^&*P-UZ$B2UV4N:[FV4956\"D,.GX7$%E7GRKF/S0-X';1P\\@\nMT\">C%/9<I\"3P!X]W:<)XV`RKOR76ZNXFQ:+W&&5:6><+%/.>)R2QO7\">U?Y[\nM]CV!VXRBL.5-W,4T2N%C*!'`*_.Y%;M%;'+_P=WR5ZE;4CNHK$_8';M7ZL!O\nMIVN**PQ.Q1\\NHFRMD40HHCJ2%-)>^';\"'W)3[J02T>/55^9>4M7>,VOQ2@HU\nM\\@[?/NF>M`A>O]@AAFG;9'3K/N!VGUF';\\0B9-^!?^P;^#<B$^+#SV17>)L>\nM?B\"IVT5XDTC3Y%OB)/?]WKR*.'IL9FG`'O@JN;I\"9B.NTT2N$]U&XDWEY;Q-\nM4Z7[QF_6V-\\EZE3)Y(DY3RPHXCPW/</XASM#\\<:S4R>^+Y(KWB+GBF@;L;-7\nMYHZ1:>\\9E:5HM_L?>SME=ITWS7'`K@/3E^9IK8)FU7GG`I)U^@>9'$+!_#^7\nM:*-<$B8'$O7WF=0=G5.GQF/-21./@'B-;\"\">777'X,3I>]JD5LVB/B>53=3I\nMQA9GFQ@FWPC;N&7YC3+N\"8_:B>D*IJBN/[Z4E3:,;M.J9^*@=:!ANFUGIE.F\nM,X0Z'G6E$%#<:+JC9Q*@#6<(1B:\"B/9#4<Q,%#&#4Q0KZP6Z/ZCQ3&C>MO6_\nM2_LR'\\ML)<C2\"NI>ECEV6T&-:S=,NV%5-JA>GC&E>>TUFM<TS#W3J.4;%56;\nM[&BR$/`Q![6\"\\3:$GR\\ZVCP@&#CL`GSE+8Q_C_@PW,T9UC#'4^I,?/)(PSQ?\nM@'2%D6:2ETMZ4ZVS=%W-8:39@,TC[>A%:EUEI)FTYY(VBI\"N,=)Q3+!<ZF8!\nMZG6=41=#+)^ZM8$Z>W*(B66N`:C$,E\\LN2I5<OFR<OG\\V4*ZZ25I;.GK<V8(\nM*5OZU\"YY]WM3%JMAUV\"UN6:_JKYGQ0[W.*W`3$H6_BRJD>9H>C+&;02^I!*3\nMK'15Z'.W=]K2-/U!UZ6I7D(`_FLTW4`/0A;V<DSVDP?!=+F5D;DC,IN8F1F#\nMB=SLD_`^/!3Q(;%%7)V\\?8NX2?QR;7JGX$\\*DD/;JY5AZ+IC6>0='E/`.,??\nMALE^(S@V3%W$L:I6U='QE@88F17#>$?TMV#`8AZ!9B7OJ(I;@S<>NO^/_?^B\nM08!`/W\\@DD31;[`NIBHFCNE*0Y4_SB/OEI3Y)O(R<OR.?#<1\\\\)R`M_=%J&`\nM!.+VG%\"2[C2.#'-0DB($+>,78Y`55YS0NC32BX\\S+SW(EP^?#E@#D,K'X.XQ\nM]*^N([(SVL6)R<)X!%=R_)F+F4^WE*-'_/+1G?J3()SY+J>PA0[+L</JWCTQ\nM#MB)S*%N'N+V;+5AU!NV06Z#VY]]=T;:#W=DBV<^ZP[:?=9\\+`K*'=[XZ&[#\nM(M+3N#@8F`9:QYZCGHT1R0O=R)N3`T!FF?T9AJIAC(TC)5&C9'?YEM:<MUNP\nM[O.G]EG[G^T>]Z*/>RX9=V1T[<ZN,!0O8$F9*5/9L3CK;-$1(B(QRT=C-\\4N\nM/.]9!5Y2$`]+W_F3&<ZJYYW+_J=FJ_OY\\E-)S'7RMU()'S8(@RC`>5C$(Q[3\nMYBZ=>G<9_V2?;2BCQ**VK/C^'E&2&962]G4EQAX0,KJ[(^CAROL4W0\\INK`,\nMYE&X&$4D?<>JE+DY##7[B%N]W8XTFLAQMXO.LLWSTO]*FKC`J_%MXJ,2]3'0\nMM*6#.P])(YT_R]_H,;3\\@7O=2KGH&31\\P8-G:#KSTA'EB$/GH]*O&>U:P\\*D\nM\"S`,_C#TYG<!?\\<=!CIS/&;_8>\\.H/)@_+RF`:EA1'#17'FWXB\"7GZ(GTE4E\nM'Y(U6E-UC+L-PS6D<;<C%Y5)8E#EEB[D]@S6EW-Y>TK3:G%B]@U#W*):@\\+<\nM2S3-7(,3>YIHE358S.=$TZQUI5'W$TVSUY7&/%$T)P]'^*1HU3R,V#L%V9/;\nM&ZO31T(D<KLB^\\0E]E%@J[F(_^&;OJ9A.#\"%6+I.]W]+QS^<7!ZW.R=GJ*10\nMJIJGIZ\"+0\"MU>MV+<YK>/FN5<@J[]6\\\\4JW7-Q23D]D-B%'3G4*9K[WI%$.F\nM&GJM6.D_!]XCL=$ENUCNZ12R6U:E4/;Y`GK<17.S6/%W[L,<)K6*;A9E?3B\"\nM!6_%+M9X,!*NOBZ(8\\\":N0@!-[CQB5EQ]&*Y[WU2@7XOEOLFQ,/_&1CV9K&^\nM`PLG!,O\"-@OR?A8,%S<!R$Z]6/G7;AC]%Z2?.$ZUV-@9>_>HJIQJP>X;!L!#\nMXE3JQ8J?WTR#KS#U5&RKL/!Z4Q`!6)L5(G#E@]T'Y3MULU#^KT$P#A>3\"4JA\nM69`'],(2'J+BUN#3E;0W&_L3?F<)9I.DML9)(5;8JZB2H8EX:KM!@0(%\"A0H\nJ4*!`@0(%\"A0H4*!`@0(%\"A0H4*!`@0(%\"A0H4*!`P0O#;\\-M\"]H`\\```\n`\nend\n", "msg_date": "Wed, 25 Feb 1998 10:24:28 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": true, "msg_subject": "pg_shadow" }, { "msg_contents": "On Wed, 25 Feb 1998, Jan Wieck wrote:\n\n> Hi,\n> \n> seems that my last post didn't make it through. That's good\n> since the diff itself didn't covered the renaming of\n> pg_user.h to pg_shadow.h and it's new content.\n> \n> Here it's again. The complete regression test passwd with\n> only some float diffs. createuser and destroyuser work.\n> pg_shadow cannot be read by ordinary user.\n> \n> And Bruce, your'e right. Sometimes the nice solutions are\n> that simple but we tend to think complicated first and waste\n> too much time with complex solutions.\n\n\tApplied, and committed...this is the *last* non-bug-fix bug to be\ninserted, time to now debug the hell out of this and get it stable...\n\n\tGreat work Jan :)\n\n\n", "msg_date": "Wed, 25 Feb 1998 08:06:46 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [PATCHES] pg_shadow" }, { "msg_contents": "> \n> On Wed, 25 Feb 1998, Jan Wieck wrote:\n> \n> > Hi,\n> > \n> > seems that my last post didn't make it through. That's good\n> > since the diff itself didn't covered the renaming of\n> > pg_user.h to pg_shadow.h and it's new content.\n> > \n> > Here it's again. The complete regression test passwd with\n> > only some float diffs. createuser and destroyuser work.\n> > pg_shadow cannot be read by ordinary user.\n> > \n> > And Bruce, your'e right. Sometimes the nice solutions are\n> > that simple but we tend to think complicated first and waste\n> > too much time with complex solutions.\n> \n> \tApplied, and committed...this is the *last* non-bug-fix bug to be\n> inserted, time to now debug the hell out of this and get it stable...\n> \n> \tGreat work Jan :)\n\n Thanks.\n\n Please remove the now obsolete include/catalog/pg_user.h\n\n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Wed, 25 Feb 1998 15:28:26 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: [PATCHES] pg_shadow" }, { "msg_contents": "On Wed, 25 Feb 1998, Jan Wieck wrote:\n\n> Thanks.\n> \n> Please remove the now obsolete include/catalog/pg_user.h\n\nDone...\n\nThe current source tree compiled cleanly on Solaris/i386, and am now\nworking on the regression tests, which also appear to have its \"normal\"\nfailures...\n\n\n", "msg_date": "Wed, 25 Feb 1998 09:55:39 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [PATCHES] pg_shadow" } ]
[ { "msg_contents": "System : RedHat Linux i386 4.2\nHardware : Pentium 200 MMX\nPg 6.3 Snapshot : Dated on February 23\n\nAfter ./configure and gmake all I am getting this error :\n\ngcc -I../../include -I../../backend -I/usr/include/ncurses\n-I/usr/include/readline -O2 -Wall -Wmissing-prototypes -I.. \n-Wno-error -c bootstrap.c -o bootstrap.o\nbootstrap.c:160: `F_BOOLIN' undeclared here (not in a function)\nbootstrap.c:160: initializer element for `Procid[0].inproc' is not\nconstant\nbootstrap.c:160: `F_BOOLOUT' undeclared here (not in a function)\nbootstrap.c:160: initializer element for `Procid[0].outproc' is not\nconstant\nbootstrap.c:161: `F_BYTEAIN' undeclared here (not in a function)\nbootstrap.c:161: initializer element for `Procid[1].inproc' is not\nconstant\nbootstrap.c:161: `F_BYTEAOUT' undeclared here (not in a function)\nbootstrap.c:161: initializer element for `Procid[1].outproc' is not\nconstant\nbootstrap.c:162: `F_CHARIN' undeclared here (not in a function)\nbootstrap.c:162: initializer element for `Procid[2].inproc' is not\nconstant \n...\nthere are a lot more, and compiling is stopping.\n\nPlease cc me because I am not on the [email protected] list\n!\n\n-- \nConstantin Teodorescu\nFLEX Consulting Braila, ROMANIA\n-- \nConstantin Teodorescu\nFLEX Consulting Braila, ROMANIA\n", "msg_date": "Wed, 25 Feb 1998 11:48:15 +0200", "msg_from": "Constantin Teodorescu <[email protected]>", "msg_from_op": true, "msg_subject": "Cannot compile postgresql 6.3" }, { "msg_contents": "> -I/usr/include/readline -O2 -Wall -Wmissing-prototypes -I.. \n> -Wno-error -c bootstrap.c -o bootstrap.o\n> bootstrap.c:160: `F_BOOLIN' undeclared here (not in a function)\n> bootstrap.c:160: initializer element for `Procid[0].inproc' is not\n> constant\n> bootstrap.c:160: `F_BOOLOUT' undeclared here (not in a function)\n> bootstrap.c:160: initializer element for `Procid[0].outproc' is not\n> constant\n> bootstrap.c:161: `F_BYTEAIN' undeclared here (not in a function)\n> bootstrap.c:161: initializer element for `Procid[1].inproc' is not\n> constant\n> bootstrap.c:161: `F_BYTEAOUT' undeclared here (not in a function)\n> bootstrap.c:161: initializer element for `Procid[1].outproc' is not\n> constant\n> bootstrap.c:162: `F_CHARIN' undeclared here (not in a function)\n> bootstrap.c:162: initializer element for `Procid[2].inproc' is not\n> constant \n> ...\n> there are a lot more, and compiling is stopping.\n\nMy guess is that the backend/fmgr.h file is not being created properly\nby utils/Gen_fmgrtab.sh file. Can you check on this? Look for errors\nearlier in the compile. I assume you did a make clean first.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 09:24:13 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Cannot compile postgresql 6.3" }, { "msg_contents": "Bruce Momjian wrote:\n> \n> > -I/usr/include/readline -O2 -Wall -Wmissing-prototypes -I..\n> > -Wno-error -c bootstrap.c -o bootstrap.o\n> > bootstrap.c:160: `F_BOOLIN' undeclared here (not in a function)\n> > bootstrap.c:160: initializer element for `Procid[0].inproc' is not\n> > constant\n\n\n> My guess is that the backend/fmgr.h file is not being created properly\n> by utils/Gen_fmgrtab.sh file. Can you check on this? Look for errors\n> earlier in the compile. I assume you did a make clean first.\n\nYes. someone told me that he had the same problem due to 'cpp' missing\nin path.\nI have found 'cpp' , put it into the path, re-make all the compilation\nand everything is ok now.\n\nBut \"configure\" (that is executing Gen_fmgrtab.sh) didn't detect that\ncpp wasn't found.\nI presume that \"configure\" must check if 'cpp' is available and report\nthe error.\nIn my case, he didn't report any error !!! \n\n-- \nConstantin Teodorescu\nFLEX Consulting Braila, ROMANIA\n", "msg_date": "Wed, 25 Feb 1998 17:08:28 +0200", "msg_from": "Constantin Teodorescu <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Cannot compile postgresql 6.3" } ]
[ { "msg_contents": "Hi,\n\n while playing around with the new view permissions I\n discovered a security hole. It's an old one (checked under\n 6.2.1 and it was already there - so it's not from new code).\n It's a trojan horse.\n\n Now I know why commercial RDBMS execute PL procedures under\n the permissions of their owner. We must switch to that model\n too in the future.\n\n Having a table revoked from public like pg_shadow now a user\n creates some functions.\n\n create function f1 () returns bool as '\n select nameeq(getpgusername(), ''pgsql'') as ret;\n ' language 'sql';\n\n create function f2 () returns bool as '\n insert into mypwd select usename, passwd from pg_shadow;\n select ''f''::bool as ret;\n ' language 'sql';\n\n create function overpaid (EMP) returns bool as '\n select 1 as x where f1() and f2();\n select $1.salary > 17000 as ret;\n ' language 'sql';\n\n Since f1() only returns true if the current user is 'pgsql',\n f2() will never get evaluated if a non superuser calls\n overpaid(). So overpaid() will work as expected for users\n and superusers. But if ever called by 'pgsql', it will\n silently copy the user names and plain passwords into mypwd.\n\n If we ever open the rule system or views to ordinary users,\n they could arrange that such a function construct would be\n executed on a simple SELECT from one of their tables. And\n f1() could be smarter and return true if any superuser or the\n table owner is the current user.\n\n All this can also be done with triggers. So there cannot be a\n trusted procedural language as long as we don't have a\n uid/euid model where functions, trigger procedures and rule\n actions get checked against their owner. The skipAcl\n implemented now for views is a step forward but it isn't\n enough.\n\n I think this is far too much for 6.3. But I would like to\n work on it for 6.4 so we can grant rule creation (including\n views) to users someday.\n\n\nUntil later, Jan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\n", "msg_date": "Wed, 25 Feb 1998 11:04:20 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": true, "msg_subject": "Security again" }, { "msg_contents": "On Wed, 25 Feb 1998, Jan Wieck wrote:\n\n> I think this is far too much for 6.3. But I would like to\n\n\tYou can say that again :) \n\n\n", "msg_date": "Wed, 25 Feb 1998 08:02:53 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Security again" } ]
[ { "msg_contents": "\n-----Original Message-----\nFrom: Constantin Teodorescu <[email protected]>\nTo: [email protected] <[email protected]>\nDate: woensdag 25 februari 1998 16:50\nSubject: [HACKERS] Cannot compile postgresql 6.3\n\n\nHi,\nIn my case it was because cpp can not be found.\nI fixed this and it worked.\n\nRegards,\nMaurice\n\n>System : RedHat Linux i386 4.2\n>Hardware : Pentium 200 MMX\n>Pg 6.3 Snapshot : Dated on February 23\n>\n>After ./configure and gmake all I am getting this error :\n>\n>gcc -I../../include -I../../backend -I/usr/include/ncurses\n>-I/usr/include/readline -O2 -Wall -Wmissing-prototypes -I..\n>-Wno-error -c bootstrap.c -o bootstrap.o\n>bootstrap.c:160: `F_BOOLIN' undeclared here (not in a function)\n>bootstrap.c:160: initializer element for `Procid[0].inproc' is not\n>constant\n>bootstrap.c:160: `F_BOOLOUT' undeclared here (not in a function)\n>bootstrap.c:160: initializer element for `Procid[0].outproc' is not\n>constant\n>bootstrap.c:161: `F_BYTEAIN' undeclared here (not in a function)\n>bootstrap.c:161: initializer element for `Procid[1].inproc' is not\n>constant\n>bootstrap.c:161: `F_BYTEAOUT' undeclared here (not in a function)\n>bootstrap.c:161: initializer element for `Procid[1].outproc' is not\n>constant\n>bootstrap.c:162: `F_CHARIN' undeclared here (not in a function)\n>bootstrap.c:162: initializer element for `Procid[2].inproc' is not\n>constant\n>...\n>there are a lot more, and compiling is stopping.\n>\n>Please cc me because I am not on the [email protected] list\n>!\n>\n>--\n>Constantin Teodorescu\n>FLEX Consulting Braila, ROMANIA\n>--\n>Constantin Teodorescu\n>FLEX Consulting Braila, ROMANIA\n\nPS: It is my understanding that messages like this should go to the PORTS\nlist.\n\n\n\n", "msg_date": "Wed, 25 Feb 1998 11:52:17 +0100", "msg_from": "\"Maurice Gittens\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Cannot compile postgresql 6.3" } ]
[ { "msg_contents": "> > 2. configure dies (!)\n> > ---------------------\n> > Running configure, dies with the following:\n> > \n> > checking whether time.h and sys/time.h may both be included... yes\n> > checking whether struct tm is in sys/time.h or time.h... time.h\n> > checking for int timezone... yes\n> > checking for union semun... yes\n> > Argument expected\n> \n> \tPlease investigate this one further and let me know what is\n> required to fix it?\nI understand nothing about how autoconf works...\nAll I can say from hacking the configure script itself is that it's\nduring the test for whether gcc needs --traditional which is being\nrun even when the compiler is not gcc\n\n> \n> > 3. My expected output files for Irix have not been incorporated in \n> > .../src/test/regress/expected/ :-(\n> > ------------------------------------------------------------------\n> \n> \tErk...resend it to me privately?\nI hope I still have it:-) If not, I'll regenerate on the next snapshot\nI try - probably tomorrow\n\n\nBets wishes,\n\nAndrew\n\n----------------------------------------------------------------------------\nDr. Andrew C.R. Martin University College London\nEMAIL: (Work) [email protected] (Home) [email protected]\nURL: http://www.biochem.ucl.ac.uk/~martin\nTel: (Work) +44(0)171 419 3890 (Home) +44(0)1372 275775\n", "msg_date": "Wed, 25 Feb 1998 10:53:20 GMT", "msg_from": "Andrew Martin <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Snapshot 23Feb98 under Irix5 --- INSTALLATION BROKEN!!!" } ]
[ { "msg_contents": "> \n> First, this list is not right place to ask about 6.3 features :)\n> 2nd, subselects within UPDATE are supported.\n\nThey are? I thought he wanted to do:\n\n\tupdate test set x = (select y from taby)\n\nI didn't think we supported that. Can you confirm that?\n \n> 3rd, there will be separate select (better say - separate re-scan of\n> subquery' plan) for each parent row (I assume that you talk about \n> correlated subqueries) but this will be more efficient than using \n> SQL-funcs which do _initialization_, scannig, _closing_ of query' plan\n> for each parent row. When using subqueries performance will be\n> near the same as for performing Nestloop join.\n\nGood.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 09:28:10 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] How fully will subselects be implemented?" }, { "msg_contents": "> \n> Herouth Maoz wrote:\n> > \n> > I'm developing a new app, and I constantly run into the need of updating\n> > things by data in related columns.\n> > \n> > Since UPDATE doesn't syntatctically support joins, this means that\n> > subselects in UPDATE are a real must.\n\nOK, now I see he only wants the subquery in the where clause. That\nclearly does work.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 09:29:03 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] How fully will subselects be implemented?" }, { "msg_contents": "Bruce Momjian wrote:\n> \n> >\n> > First, this list is not right place to ask about 6.3 features :)\n> > 2nd, subselects within UPDATE are supported.\n> \n> They are? I thought he wanted to do:\n> \n> update test set x = (select y from taby)\n> \n> I didn't think we supported that. Can you confirm that?\n\nOh, this is not supported, sorry.\nAnd select a, (select b from tab2) from tab1 and so on...\n\nVadim\n", "msg_date": "Wed, 25 Feb 1998 22:59:35 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [QUESTIONS] How fully will subselects be implemented?" } ]
[ { "msg_contents": ">From what I understand, there are at least two platforms which are\nhaving trouble with the macro inlining in v6.3. The alpha ports have\ntrouble inlining the slock assembler code, and the SCO port has trouble\ninlining the cache lookup code.\n\nSince these macros were inlined only for performance reasons, would it\nbe possible to revert to non-inline function calls for these platforms?\nIt would seem that substituting a macro expansion for a compiled routine\ncould be done with a compiler switch (e.g. USE_INLINING) so it could be\nturned on and off at will.\n\nFor most of us, the performance gains are fantastic, but for those ports\nwhich broke performance has degraded to zero :(\n\n - Tom\n\n", "msg_date": "Wed, 25 Feb 1998 14:28:37 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": true, "msg_subject": "Platforms with v6.3 trouble" }, { "msg_contents": "> \n> >From what I understand, there are at least two platforms which are\n> having trouble with the macro inlining in v6.3. The alpha ports have\n> trouble inlining the slock assembler code, and the SCO port has trouble\n> inlining the cache lookup code.\n> \n> Since these macros were inlined only for performance reasons, would it\n> be possible to revert to non-inline function calls for these platforms?\n> It would seem that substituting a macro expansion for a compiled routine\n> could be done with a compiler switch (e.g. USE_INLINING) so it could be\n> turned on and off at will.\n> \n> For most of us, the performance gains are fantastic, but for those ports\n> which broke performance has degraded to zero :(\n\nYes, how do we do that? Do we have inlined-versions of these files? \nSounds messy. Can people run cpp separately on the files, then compile\nthem? I wonder. I think this is an SCO-only problem, and seeing as\ntheir native compilers are notoriously buggy (Microsoft/SVr4 code), it\nis no wonder.\n\nThe alpha problem has been solved by having a s_lock.c file, that only\ncontains the alpha/linux locking code. They don't have local asm\nlabels, and hence the workaround. I believe this is not a problem issue\nfor 6.3. Anyone? Of course, we still have the initdb problem, or do\nwe?\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 10:19:55 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Platforms with v6.3 trouble" }, { "msg_contents": "> > Since these macros were inlined only for performance reasons, would it\n> > be possible to revert to non-inline function calls for these platforms?\n> > It would seem that substituting a macro expansion for a compiled routine\n> > could be done with a compiler switch (e.g. USE_INLINING) so it could be\n> > turned on and off at will.\n> >\n> > For most of us, the performance gains are fantastic, but for those ports\n> > which broke performance has degraded to zero :(\n>\n> Yes, how do we do that? Do we have inlined-versions of these files?\n> Sounds messy. Can people run cpp separately on the files, then compile\n> them? I wonder. I think this is an SCO-only problem, and seeing as\n> their native compilers are notoriously buggy (Microsoft/SVr4 code), it\n> is no wonder.\n\nWell, those macros used to be a function call, right? So surround the macro\nwith#ifdef USE_INLINING\n#define ...\n#endif\n\nand surround the old subroutine code with\n\n#ifndef USE_INLINING\n...\n#endif\n\nOr are the macros of a different nature and not just a subroutine inlining?\nIf there still needs to be a little macro expansion, then that could be done\nalso...\n\n> The alpha problem has been solved by having a s_lock.c file, that only\n> contains the alpha/linux locking code. They don't have local asm\n> labels, and hence the workaround. I believe this is not a problem issue\n> for 6.3. Anyone? Of course, we still have the initdb problem, or do\n> we?\n\nDon't know...\n\n", "msg_date": "Wed, 25 Feb 1998 17:36:26 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Platforms with v6.3 trouble" }, { "msg_contents": "> Well, those macros used to be a function call, right? So surround the macro\n> with#ifdef USE_INLINING\n> #define ...\n> #endif\n> \n> and surround the old subroutine code with\n> \n> #ifndef USE_INLINING\n> ...\n> #endif\n> \n\nI was trying to avoid having the code in two places, and you can't just\ncopy the macro. You have to replace the parameters in each instance for\nthe huge conditional to work.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 14:10:52 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Platforms with v6.3 trouble" }, { "msg_contents": "On the SCO UNIXWARE (UNIVEL) port, it is only necessary to replace the macro \ndefinition of fastgetattr with a static function in heapam.h in order to get \nthe code to compile. I guess the people who wrote the compile could not \nconcieve of anyone nesting the trinary operator (?:) to such a depth :-). The \nUNIXWARE compiler does an excellent job of in-lining the function on it's own \nwithout the macro. The patch for the version of heapam.h I am using follows \n(I am currently using USE_UNIVEL_CC_ASM as the trigger, but that can be \nchanged).\n\nBruce, will this change work? I am not as familiar with this section of code \nas I would like to be.\n\n----\n*** src/include/access/heapam.h.orig Fri Feb 13 20:18:33 1998\n--- src/include/access/heapam.h Sat Feb 14 09:03:40 1998\n***************\n*** 88,93 ****\n--- 88,142 ----\n *\n * ----------------\n */\n+ #if defined(USE_UNIVEL_CC_ASM)\n+ extern Datum nocachegetattr(HeapTuple tup, int attnum,\n+ TupleDesc att, bool *isnull);\n+\n+ static Datum fastgetattr(HeapTuple tup, int attnum, TupleDesc tupleDesc,\n+ bool *isnull)\n+ {\n+ return (\n+ (attnum) > 0 ?\n+ (\n+ ((isnull) ? (*(isnull) = false) : (dummyret)NULL),\n+ HeapTupleNoNulls(tup) ?\n+ (\n+ ((tupleDesc)->attrs[(attnum)-1]->attcacheoff != -1 ||\n+ (attnum) == 1) ?\n+ (\n+ (Datum)fetchatt(&((tupleDesc)->attrs[(attnum)-1]),\n+ (char *) (tup) + (tup)->t_hoff +\n+ (\n+ ((attnum) != 1) ?\n+ (tupleDesc)->attrs[(attnum)-1]->attcacheoff\n+ :\n+ 0\n+ )\n+ )\n+ )\n+ :\n+ nocachegetattr((tup), (attnum), (tupleDesc), (isnull))\n+ )\n+ :\n+ (\n+ att_isnull((attnum)-1, (tup)->t_bits) ?\n+ (\n+ ((isnull) ? (*(isnull) = true) : (dummyret)NULL),\n+ (Datum)NULL\n+ )\n+ :\n+ (\n+ nocachegetattr((tup), (attnum), (tupleDesc), (isnull))\n+ )\n+ )\n+ )\n+ :\n+ (\n+ (Datum)NULL\n+ )\n+ );\n+ }\n+ #else\n #define fastgetattr(tup, attnum, tupleDesc, isnull) \\\n ( \\\n AssertMacro((attnum) > 0) ? \\\n***************\n*** 129,136 ****\n (Datum)NULL \\\n ) \\\n )\n!\n!\n\n /* ----------------\n * heap_getattr\n--- 178,184 ----\n (Datum)NULL \\\n ) \\\n )\n! #endif\n\n /* ----------------\n * heap_getattr\n\n-- \n____ | Billy G. Allie | Domain....: [email protected]\n| /| | 7436 Hartwell | Compuserve: 76337,2061\n|-/-|----- | Dearborn, MI 48126| MSN.......: [email protected]\n|/ |LLIE | (313) 582-1540 | \n\n\n", "msg_date": "Thu, 26 Feb 1998 23:46:47 -0500", "msg_from": "\"Billy G. Allie\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Platforms with v6.3 trouble " }, { "msg_contents": "> \n> On the SCO UNIXWARE (UNIVEL) port, it is only necessary to replace the macro \n> definition of fastgetattr with a static function in heapam.h in order to get \n> the code to compile. I guess the people who wrote the compile could not \n> concieve of anyone nesting the trinary operator (?:) to such a depth :-). The \n> UNIXWARE compiler does an excellent job of in-lining the function on it's own \n> without the macro. The patch for the version of heapam.h I am using follows \n> (I am currently using USE_UNIVEL_CC_ASM as the trigger, but that can be \n> changed).\n> \n> Bruce, will this change work? I am not as familiar with this section of code \n> as I would like to be.\n\nThis is fine, and a good place to put it, though the port-specific\nchange should go AFTER the standard #define, not before it, so you do:\n\n#if !defined(SCO)\n#define\n#else\nstatic ...\n#endif\n\nAs far as them never suspecting such a macro, well, I never suspected I\nwould ever write such a macro either. But I did, and it works. I\ndidn't inline this in the first pass of inlining because it looked so\nhard, but when I realized how many times it was called, and that I could\ninline just the beginning of the function to get more speed when the\ncache offset was active, I did it. The new macro formatting style is my\nidea too, and it makes things much simpler. Look at the ugly\nheap_getattr() macros in 6.2.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 00:14:05 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Platforms with v6.3 trouble" }, { "msg_contents": "> This is fine, and a good place to put it, though the port-specific\n> change should go AFTER the standard #define, not before it, so you do:\n> \n> #if !defined(SCO)\n> #define\n> #else\n> static ...\n> #endif\n\nI'll make this change before submitting the patch.\n\n> [...] The new macro formatting style is my \n> idea too, and it makes things much simpler. Look at the ugly\n> heap_getattr() macros in 6.2.\n\nAgreed, and I have.\n-- \n____ | Billy G. Allie | Domain....: [email protected]\n| /| | 7436 Hartwell | Compuserve: 76337,2061\n|-/-|----- | Dearborn, MI 48126| MSN.......: [email protected]\n|/ |LLIE | (313) 582-1540 | \n\n\n", "msg_date": "Fri, 27 Feb 1998 00:52:53 -0500", "msg_from": "\"Billy G. Allie\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Platforms with v6.3 trouble " } ]
[ { "msg_contents": "> \n> At 15:15 +0200 on 25/2/98, The Hermit Hacker wrote:\n> \n> \n> > \tYou don't have to be contributing to the effort to be on the\n> > hackers list...it is where implementation details are discussed and\n> > suggested, that is all. It is also where \"under development\" issues are\n> > talked about. subselects, until the release are \"under development\"...\n> \n> What I'm trying to get across is that I am subscribed to three mailing\n> lists, and still, I have to wait for over two hundred messages to load\n> after weekend. This means that I try to keep the number of lists to which\n> I'm subscribed down to the minimum I need for my uses.\n\nThe basic problem is that the volume on these lists is huge. Marc has\nproperly broken them down as much as humanly possible, but people can\nonly keep a few lists and their purposes in their heads. There is just\ntoo much volume and I think that is what you are complaining about.\n\nIt used to be quieter, but I don't read for one day, I have 50-100\nmessages to read. No way around it. People have questions/issues, and\nwe have to address them.\n\nThe only solution for people who occasionally want questions answered\nbut don't want the volume is to ALWAYS reply to the poster and to the\nlist. That way, people can ask questions to a list without having to be\non the list. I always do that.\n\n\n> If they do, will the person who asked the question know he was answered? Is\n> he subscribed to the other list? Should you cross-post to both and raise\n> the anger of those subscribed to both?\n\nIf we CC them on replies, yes.\n\n> I appreciate Bruce's work, but you have to admit that the TODO list is\n> cryptic, at best. Sometimes the actual developers are frustrated by a TODO\n> item (Like the famous \"Large Objects are broken\"), which is not specific\n> enough. I wouldn't have known what half the TODO items mean, if they\n> weren't previously discussed on the Questions list.\n\nFunny you should mention that item. I was complaining for quite a while\nthat we had the item marked as broken, but no one reported any bugs, and\nno one could tell us an example of the bug. I proposed removing the\nitem, and then Peter Mount reported a reproducable bug, and later fixed\nit for the 6.3 release.\n\nIf there are any other cryptic bug items, please let me know. I try to\ngive an example SQL statement, or explain it in one line as best I can. \nA few of them require knowledge of the source code, which can't be\nconveyed in one line.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 09:46:08 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] This mailing list and others (was re subselects)" }, { "msg_contents": "On Wed, 25 Feb 1998, Bruce Momjian wrote:\n\n> The only solution for people who occasionally want questions answered\n> but don't want the volume is to ALWAYS reply to the poster and to the\n> list. That way, people can ask questions to a list without having to be\n> on the list. I always do that.\n\n\tAnd, of course, there are the \"RTFM\" questions that can be\nanswered by a quick search of the mhonarc archives before asking on the\nlists...\n\n\tIts more a matter of educating ppl to use all the resources at\nhand, instead of the \"easy\" route :(\n\n\n", "msg_date": "Wed, 25 Feb 1998 10:09:19 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [QUESTIONS] This mailing list and others (was re subselects)" } ]
[ { "msg_contents": "Should/Will ecpg be added to the HISTORY, FAQ, etc. files?\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Wed, 25 Feb 1998 15:59:02 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "ecpg in docs" }, { "msg_contents": "On Wed, 25 Feb 1998, Michael Meskes wrote:\n\n> Should/Will ecpg be added to the HISTORY, FAQ, etc. files?\n\n\tYes\n\n\n", "msg_date": "Wed, 25 Feb 1998 10:03:50 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] ecpg in docs" }, { "msg_contents": "> \n> Should/Will ecpg be added to the HISTORY, FAQ, etc. files?\n> \n> Michael\n> \n\nWow, that FAQ needs updating. Doing it now.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 14:02:19 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] ecpg in docs" }, { "msg_contents": "> \n> On Wed, 25 Feb 1998, Michael Meskes wrote:\n> \n> > Should/Will ecpg be added to the HISTORY, FAQ, etc. files?\n> \n> \tYes\n> \n\necpg is in the TODO list, and will be added to the HISTORY just before\nthe release.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 14:03:06 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] ecpg in docs" } ]
[ { "msg_contents": "\nWith all the recent changes, I just did a clean compile, install and\nregression test for the above port...most impressive.\n\nI'm not sure if it is changing the diff flags, but my 'regression.diffs'\nwent from ~930k down to 37k *head spins*\n\nSolaris/Sparc next...\n\n\n", "msg_date": "Wed, 25 Feb 1998 10:05:56 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Solaris/i386 - Confirmed" } ]
[ { "msg_contents": "First, with Jan's fix, initdb works fine now.\n\nHere are the open issues. IMHO, none of these are show-stoppers.\n\n---------------------------------------------------------------------------\n\nSelf-join optimizer performance problem\nGet interfaces fixed for new protocol\nProfiling improvements?\nProblem with tables >2Gb, add elog()?\nDo we want to add timestamps to elog messages?\nScanKeyData missing initializations\nAlpha/64-bit issues, mkoidname() problem\nlarge objects memory exhaustion\nCommit sgml document sources(Thomas)\nCommit html documents(Thomas)\nCommit postscript documents(Thomas)\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 10:22:45 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Open 6.3 issues" }, { "msg_contents": "> \n> First, with Jan's fix, initdb works fine now.\n> \n> Here are the open issues. IMHO, none of these are show-stoppers.\n> \n> ---------------------------------------------------------------------------\n> \n> Self-join optimizer performance problem\n> Get interfaces fixed for new protocol\n> Profiling improvements?\n> Problem with tables >2Gb, add elog()?\n> Do we want to add timestamps to elog messages?\n> ScanKeyData missing initializations\n\n More details on missing initializations of ScanKeyData pleas.\n Might have some time now since the other permission and setuid\n things are delayed for 6.4.\n\n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Wed, 25 Feb 1998 16:43:45 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Open 6.3 issues" }, { "msg_contents": "Jan Wieck wrote:\n> \n> > ScanKeyData missing initializations\n> \n> More details on missing initializations of ScanKeyData pleas.\n> Might have some time now since the other permission and setuid\n> things are delayed for 6.4.\n\nThere was one place in selfuncs.c where scan key was initialized\ndirectly by assignment values to structure' fields \n(without ScanKeyEntryInitialize) and so new 6.3 fields were\nnot initialized at all. One should check all code...\n\nVadim\n", "msg_date": "Wed, 25 Feb 1998 23:32:13 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Open 6.3 issues" }, { "msg_contents": "> \n> Jan Wieck wrote:\n> > \n> > > ScanKeyData missing initializations\n> > \n> > More details on missing initializations of ScanKeyData pleas.\n> > Might have some time now since the other permission and setuid\n> > things are delayed for 6.4.\n> \n> There was one place in selfuncs.c where scan key was initialized\n> directly by assignment values to structure' fields \n> (without ScanKeyEntryInitialize) and so new 6.3 fields were\n> not initialized at all. One should check all code...\n\n Haven't found any more places where sk_attno is assigned a\n value and where no previous ScanKeyEntryInitialize() is\n done. Think it's already fixed then.\n\n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Wed, 25 Feb 1998 18:22:48 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Open 6.3 issues" }, { "msg_contents": "> Here are the open issues. IMHO, none of these are show-stoppers.\n>\n> ---------------------------------------------------------------------------\n>\n> Self-join optimizer performance problem\n> Get interfaces fixed for new protocol\n> Profiling improvements?\n> Problem with tables >2Gb, add elog()?\n> Do we want to add timestamps to elog messages?\n> ScanKeyData missing initializations\n> Alpha/64-bit issues, mkoidname() problem\n> large objects memory exhaustion\n> Commit sgml document sources(Thomas)\n> Commit html documents(Thomas)\n> Commit postscript documents(Thomas)\n\nI would like the new docs to be considered \"show stoppers\", but expect that\nthey will be committed before March. That is 3 days away and I have completed\nthe tutorial and user's guide packages. Just need to redraw one of the other\nfigures (1 hour?) and then massage the programmer's guide and administrator's\nguide (1-2 hours each), and then commit.\n\nHmm, I think that I will go ahead and put some of the products into the cvs\ntree soon so folks can work out any installation problems. OK?\n\n - Tom\n\n", "msg_date": "Wed, 25 Feb 1998 17:25:06 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Open 6.3 issues" }, { "msg_contents": "Jan Wieck wrote:\n> \n> >\n> > Jan Wieck wrote:\n> > >\n> > > > ScanKeyData missing initializations\n> > >\n> > > More details on missing initializations of ScanKeyData pleas.\n> > > Might have some time now since the other permission and setuid\n> > > things are delayed for 6.4.\n> >\n> > There was one place in selfuncs.c where scan key was initialized\n> > directly by assignment values to structure' fields\n> > (without ScanKeyEntryInitialize) and so new 6.3 fields were\n> > not initialized at all. One should check all code...\n> \n> Haven't found any more places where sk_attno is assigned a\n> value and where no previous ScanKeyEntryInitialize() is\n> done. Think it's already fixed then.\n\nOk, but the problem was in un-initialized sk_func->fn_oid (sorry)...\n\nVadim\n", "msg_date": "Thu, 26 Feb 1998 06:00:41 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Open 6.3 issues" } ]
[ { "msg_contents": "Ok,\n\nI decided to learn more about postgresql.\n\nMy challenge:\nGiven an oid, efficiently determine the most derived class the instance\nbelongs to.\n\nMy intended solution is to add an extra attribute to each tuple\nwhich contains the oid of the most derived class it belongs to.\n\nOn inserting a tuple I set this field to the value of the table/class used\nfor the\ninsert.\n\nUsing with a negative index I can allways retreive the oid of\nthe most derived class.\n\nHow to proceed?\nStep: 1\nAdd the new field to the HeapTupleData struct in htup.h.\n\nStep: 2\nModify inserting function to add the oid of the class into which\nthe insertion takes place.\n\nStep 3\n???\n\nStep 4\n\nCan anyone give clues as whatelse I will have to do to get this to work?\n\nThanks,\nMaurice\n\n", "msg_date": "Wed, 25 Feb 1998 16:27:38 +0100", "msg_from": "\"Maurice Gittens\" <[email protected]>", "msg_from_op": true, "msg_subject": "Adding a field to each tuple" }, { "msg_contents": "> \n> Ok,\n> \n> I decided to learn more about postgresql.\n> \n> My challenge:\n> Given an oid, efficiently determine the most derived class the instance\n> belongs to.\n> \n> My intended solution is to add an extra attribute to each tuple\n> which contains the oid of the most derived class it belongs to.\n\nThis is a lot of overhead for places it is not needed.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 14:04:42 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Adding a field to each tuple" } ]
[ { "msg_contents": "Even more up to date:\n\n---------------------------------------------------------------------------\n\nSelf-join optimizer performance problem\nGet interfaces fixed for new protocol\nProfiling improvements?\nProblem with tables >2Gb, add elog()?\nDo we want to add timestamps to elog messages?\nScanKeyData missing initializations\nAlpha/64-bit issues, mkoidname() problem\nlarge objects memory exhaustion\nCommit sgml document sources(Thomas)\nCommit html documents(Thomas)\nCommit postscript documents(Thomas)\nSunOS4 problems\nlibpgtcl undefined symbol?\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 10:39:31 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Open 6.3 issues" } ]
[ { "msg_contents": "Even more up to date:\n\n---------------------------------------------------------------------------\n\nSelf-join optimizer performance problem\nGet interfaces fixed for new protocol\nProfiling improvements?\nProblem with tables >2Gb, add elog()?\nDo we want to add timestamps to elog messages?\nScanKeyData missing initializations\nAlpha/64-bit issues, mkoidname() problem\nlarge objects memory exhaustion\nCommit sgml document sources(Thomas)\nCommit html documents(Thomas)\nCommit postscript documents(Thomas)\nSunOS4 problems\nlibpgtcl undefined symbol?\nlarge objects and pg_dump poblem\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 10:40:29 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Open 6.3 issues" } ]
[ { "msg_contents": "\nHello\n\nI like the added security of 6.3 however how do you grant access to \nSELECT currval('SEQ') AS id\nI get a permission error on seq.currval?\n\nI figured out how to use CVSUP so I am grabbing the latest version.\n\nIf this is fixed in it then great otherwise any ideas?\n\nMichael\n\n* Michael J. Rogan, Network Administrator, 905-624-3020 *\n* Mark IV Industries, F-P Electronics & I.V.H.S. Divisions *\n* [email protected] [email protected] *\n", "msg_date": "Wed, 25 Feb 1998 17:01:24 +0000", "msg_from": "\"Michael J. Rogan\" <[email protected]>", "msg_from_op": true, "msg_subject": "SELECT currval('SEQ') broken?" }, { "msg_contents": "\nCompiles, installs and tests cleanly...regression test results are in\nsrc/test/regress/regression.Solaris-Sparc for anyone wanting to look at\nthe variances...\n\n\n\n", "msg_date": "Wed, 25 Feb 1998 15:55:46 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Very nice... Solaris/Sparc works..." }, { "msg_contents": "Michael J. Rogan wrote:\n> \n> Hello\n> \n> I like the added security of 6.3 however how do you grant access to\n> SELECT currval('SEQ') AS id\n> I get a permission error on seq.currval?\n> \n> I figured out how to use CVSUP so I am grabbing the latest version.\n> \n> If this is fixed in it then great otherwise any ideas?\n\nI don't remember - did we NO_ACCESS to a table for public\nas default or not ?\nIf yes then you have to GRANT permissions on sequences...\n\nVadim\n", "msg_date": "Thu, 26 Feb 1998 06:21:15 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] SELECT currval('SEQ') broken?" }, { "msg_contents": "> \n> Michael J. Rogan wrote:\n> > \n> > Hello\n> > \n> > I like the added security of 6.3 however how do you grant access to\n> > SELECT currval('SEQ') AS id\n> > I get a permission error on seq.currval?\n> > \n> > I figured out how to use CVSUP so I am grabbing the latest version.\n> > \n> > If this is fixed in it then great otherwise any ideas?\n> \n> I don't remember - did we NO_ACCESS to a table for public\n> as default or not ?\n\n We did so. Default is now NO_ACCESS for public but SELECT\n granted for public on IsSystemRelationName() where no\n explicit ACL is set. So all tables and views prefixed pg_\n are readable by default and must still be revoked if you\n don't want them public readable. All other tables and\n views are private.\n \n\n> If yes then you have to GRANT permissions on sequences...\n\n Checked that and it works. The creator of the sequence is\n the owner and can do anything by default (superuser too). \n\n GRANT SELECT ON seq permitts to get currval() from sequence.\n\n GRANT SELECT, UPDATE ON seq permitts to get nextval().\n\n\n Great to see that new security code works also for an area\n that we didn't thought about.\n\n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Thu, 26 Feb 1998 07:55:20 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] SELECT currval('SEQ') broken?" }, { "msg_contents": "On Thu, 26 Feb 1998, Vadim B. Mikheev wrote:\n\n> Michael J. Rogan wrote:\n> > \n> > Hello\n> > \n> > I like the added security of 6.3 however how do you grant access to\n> > SELECT currval('SEQ') AS id\n> > I get a permission error on seq.currval?\n> > \n> > I figured out how to use CVSUP so I am grabbing the latest version.\n> > \n> > If this is fixed in it then great otherwise any ideas?\n> \n> I don't remember - did we NO_ACCESS to a table for public\n> as default or not ?\n\n\tYes...\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 26 Feb 1998 17:38:27 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] SELECT currval('SEQ') broken?" } ]
[ { "msg_contents": "We need the help of a postgres GURU. This would probably be a couple\nweeks worth of work. We are in Portland OR, our worst problem is\ncurrently in Indoniesia. The work might be able to be done remotely.\n\nAnybody interested in the work, send me email. We need help today!\n\nBrian Beattie\nAtlas PrePaid Services\[email protected]\n503.228.1400x4355\n\n", "msg_date": "Wed, 25 Feb 1998 09:23:48 -0800 (PST)", "msg_from": "Brian Beattie <[email protected]>", "msg_from_op": true, "msg_subject": "Help Wanted: Postgres GURU" } ]
[ { "msg_contents": "On October 27, 1997 I wrote:\n> \n> Hi,\n> \n> while playing around with PL/Tcl I encountered a general\n> memory allocation problem. Every transaction abort via\n> elog(WARN, ...) leaves some allocated memory laying around.\n> \n> Just do some \"select * from non_existing_table;\" and you'll\n> see the backend growing.\n> \n> One place where this happens is tcop. The querytree isn't\n> freed on the restart. But there must be other places too\n> since I've hacked out that one and the backend is still\n> growing.\n> \n> This all didn't matter until we have triggers and constraints\n> now. One normal action of a trigger or constraint is to fire\n> a transaction abort. Thus, a really long running database\n> backend can grow and grow.\n> \n> Please add this to TODO as I don't have the time right now to\n> dive into.\n\n Never got onto the TODO :-(\n\n It still happens. Seems like approx 1K isn't freed per elog(ERROR).\n \n\nJan\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Wed, 25 Feb 1998 18:54:56 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Memory not freed at WARN" }, { "msg_contents": "> > This all didn't matter until we have triggers and constraints\n> > now. One normal action of a trigger or constraint is to fire\n> > a transaction abort. Thus, a really long running database\n> > backend can grow and grow.\n> > \n> > Please add this to TODO as I don't have the time right now to\n> > dive into.\n> \n> Never got onto the TODO :-(\n> \n> It still happens. Seems like approx 1K isn't freed per elog(ERROR).\n\nAdded:\n\n* elog() does not free all its memory(Jan)\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 14:16:44 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Memory not freed at WARN" } ]
[ { "msg_contents": "I have updated the FAQ on the WWW page. Many changes for the new\nrelease. Many limitations removed.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 14:38:05 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Updated FAQ" } ]
[ { "msg_contents": "On Wed, 25 Feb 1998, Ronald Cole wrote:\n\n> The Hermit Hacker writes:\n> >\tWhat version? Postgres95, as a name, died *months* ago, and\n> >several releases back...\n> \n> And since you've practically removed what made it a postgres database,\n> I would recommend you change the name yet again. I was quite familiar\n> with the innovative feature set of postgres, and was quite suprised to\n> discover that you've practically removed most of them. How about\n> calling your current project \"gnubase\"?\n\n\tFor starters, there is nothing GNU about this, other then the fact\nthat we have now included the ODBC drivers that fall under LGPL...\n\n\tSecond, over the past two years, we have revisited this, I\nbelieve, twice, with you being the second one. Discussing this between\nyou and I would be useless, as there is alot that *I* don't know about the\nsystem, so I'm CC'ng this to [email protected]...\n\n\tI'm curious as to what, from the 'innovative feature set of\npostgres' has disappeared? The only major thing that *I* know of that has\ndisappeared (since we took over development from Jolly/Andrew) is the\nremoval of time travel, and there is a README in the contrib/spi directory\nthat details how to recreate this using triggers, as required, so instead\nof overall database overhead suffering because *everything* used time\ntravel, only the individual tables use it...\n\n\tAgain, I am interested in knowing how much we have removed, and by\ndiscussing it in pgsql-hackers, I imagine that there will be a much\nbroader knowledge base of ppl that can explain the whys (and work arounds)\nof each...\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 25 Feb 1998 17:43:51 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] Installation Postgresql95 on linux slackware" }, { "msg_contents": "> > And since you've practically removed what made it a postgres database,\n> > I would recommend you change the name yet again. I was quite familiar\n> > with the innovative feature set of postgres, and was quite suprised to\n> > discover that you've practically removed most of them.\n\nHmm. You should be specific, since many of us are familiar with the feature set\nand your blanket statement doesn't make much sense to me at least. Not intending\nto escalate this, but please remember that without the PostgreSQL team you would\nhave a choice of Postgres95/v1.0 or nothing with \"Post\" in the name. Join us and\nhelp, or enjoy what is available, or find another tool.\n\nFrankly, I'm quite pleased with the direction PostgreSQL has taken, but then I've\nworked hard to help take it there ;-)\n\n - Tom\n\n", "msg_date": "Thu, 26 Feb 1998 03:12:40 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [QUESTIONS] Installation Postgresql95 on linux\n\tslackware" } ]
[ { "msg_contents": "I got assertion in my 6.2.1 production data base today.\nPatch for 6.2.1 follows and is on ftp site too.\n\nVadim", "msg_date": "Thu, 26 Feb 1998 05:55:49 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "6.X vacuum bug found & fixed" } ]
[ { "msg_contents": "Is this Ok ?\n\n/home/postgres/lib > ls -l\ntotal 711\n-r--r--r-- 1 postgres users 605 26 ��� 07:57 global1.bki.source\n-r--r--r-- 1 postgres users 0 26 ��� 07:57 global1.description\n-r--r--r-- 1 postgres users 8994 26 ��� 07:57 libecpg.a\nlrwxrwxrwx 1 postgres users 14 26 ��� 07:57 libecpg.so -> libecpg.so.1.0\n ^ ^\n-r--r--r-- 1 postgres users 16743 26 ��� 07:57 libecpg.so.1.0\n-rw-rw-r-- 1 postgres users 82184 26 ��� 07:57 libpgtcl.a\n ^\nlrwxrwxrwx 1 postgres users 15 26 ��� 07:57 libpgtcl.so -> libpgtcl.so.1.0\n ^ ^\n-rw-rw-r-- 1 postgres users 81925 26 ��� 07:57 libpgtcl.so.1.0\n ^\n-rw-rw-r-- 1 postgres users 157494 26 ��� 07:57 libpq.a\n ^\nlrwxrwxrwx 1 postgres users 12 26 ��� 07:57 libpq.so -> libpq.so.1.1\n ^ ^\n-rw-rw-r-- 1 postgres users 152325 26 ��� 07:57 libpq.so.1.1\n ^\n\nVadim\n", "msg_date": "Thu, 26 Feb 1998 08:02:31 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "mode of libs" }, { "msg_contents": "> \n> Is this Ok ?\n> \n> /home/postgres/lib > ls -l\n> total 711\n> -r--r--r-- 1 postgres users 605 26 ��������� 07:57 global1.bki.source\n> -r--r--r-- 1 postgres users 0 26 ��������� 07:57 global1.description\n> -r--r--r-- 1 postgres users 8994 26 ��������� 07:57 libecpg.a\n> lrwxrwxrwx 1 postgres users 14 26 ��������� 07:57 libecpg.so -> libecpg.so.1.0\n> ^ ^\n\nGood eye. Fixed. Was in configure.in as 664 not 644. No reason to\ngive group write permission, right?\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 21:16:51 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] mode of libs" }, { "msg_contents": "Bruce Momjian wrote:\n> \n> >\n> > Is this Ok ?\n> >\n> > /home/postgres/lib > ls -l\n> > total 711\n> > -r--r--r-- 1 postgres users 605 26 ��� 07:57 global1.bki.source\n> > -r--r--r-- 1 postgres users 0 26 ��� 07:57 global1.description\n> > -r--r--r-- 1 postgres users 8994 26 ��� 07:57 libecpg.a\n> > lrwxrwxrwx 1 postgres users 14 26 ��� 07:57 libecpg.so -> libecpg.so.1.0\n> > ^ ^\n> \n> Good eye. Fixed. Was in configure.in as 664 not 644. No reason to\n> give group write permission, right?\n\nYes. And \"others\" too...\n\nVadim\n", "msg_date": "Thu, 26 Feb 1998 10:06:40 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] mode of libs" }, { "msg_contents": "> \n> Bruce Momjian wrote:\n> > \n> > >\n> > > Is this Ok ?\n> > >\n> > > /home/postgres/lib > ls -l\n> > > total 711\n> > > -r--r--r-- 1 postgres users 605 26 ��������� 07:57 global1.bki.source\n> > > -r--r--r-- 1 postgres users 0 26 ��������� 07:57 global1.description\n> > > -r--r--r-- 1 postgres users 8994 26 ��������� 07:57 libecpg.a\n> > > lrwxrwxrwx 1 postgres users 14 26 ��������� 07:57 libecpg.so -> libecpg.so.1.0\n> > > ^ ^\n> > \n> > Good eye. Fixed. Was in configure.in as 664 not 644. No reason to\n> > give group write permission, right?\n> \n> Yes. And \"others\" too...\n\nNow there is a bigger problem. pg_pwd is mode rw-rw-rw- because a COPY\nis used to create it. Any ideas how to fix this? Copy sets the\npermissions to this before it creates the file. It temporarily changes\nthe umask to create the file. If pg_pwd ever has data in it and it is\nworld-readable, it is unsecure.\n\nAnyone have a brilliant idea on a fix?\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 22:17:57 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] mode of libs" }, { "msg_contents": "> Now there is a bigger problem. pg_pwd is mode rw-rw-rw- because a COPY\n> is used to create it. Any ideas how to fix this? Copy sets the\n> permissions to this before it creates the file. It temporarily changes\n> the umask to create the file. If pg_pwd ever has data in it and it is\n> world-readable, it is unsecure.\n>\n> Anyone have a brilliant idea on a fix?\n\nWell, the data directory itself is protected from anyone other than the postgres\naccount, so it may not matter as much if an individual file is not right. My (former)\nIngres installation had the directory protected, and then permissions of 777 on all the\ndirectories and files within it as I recall...\n\nWe should fix it up to match the protections on other files though...\n\n - Tom\n\n", "msg_date": "Thu, 26 Feb 1998 04:05:01 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] mode of libs" }, { "msg_contents": "> Well, the data directory itself is protected from anyone other than the postgres\n> account, so it may not matter as much if an individual file is not right. My (former)\n> Ingres installation had the directory protected, and then permissions of 777 on all the\n> directories and files within it as I recall...\n> \n> We should fix it up to match the protections on other files though...\n\nNot true. As long as someone has read or execute permission on a\ndirectory, they can read/write any file in that directory they have\npermission for. What they can't do is add or delete file based on the\ndirectory permission.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 23:13:18 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] mode of libs" }, { "msg_contents": "> > Well, the data directory itself is protected from anyone other than the postgres\n> > account, so it may not matter as much if an individual file is not right. My (former)\n> > Ingres installation had the directory protected, and then permissions of 777 on all the\n> > directories and files within it as I recall...\n> >\n> > We should fix it up to match the protections on other files though...\n>\n> Not true. As long as someone has read or execute permission on a\n> directory, they can read/write any file in that directory they have\n> permission for. What they can't do is add or delete file based on the\n> directory permission.\n\nSure. I must be missing the point (as usual :), because my directory protections look like:\n\n golem> dir\n...\n 142 drwx------ 3 postgres postgres 1024 Feb 24 03:38 data/\n...\ngolem> dir data\nls: data: Permission denied\ngolem> dir data/pg_pwd\nls: data/pg_pwd: Permission denied\ngolem> cat data/pg_pwd\ncat: data/pg_pwd: Permission denied\n\n??\n\n - Tom\n\n", "msg_date": "Thu, 26 Feb 1998 05:39:10 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] mode of libs" }, { "msg_contents": "> > Not true. As long as someone has read or execute permission on a\n> > directory, they can read/write any file in that directory they have\n> > permission for. What they can't do is add or delete file based on the\n> > directory permission.\n> \n> Sure. I must be missing the point (as usual :), because my directory protections look like:\n\nSorry, count me an idiot. I see what you mean now. The pgsql/data\ndirectory is rw-------, which makes all files underneath unreadable by\nanyone but the superuser. There is no problem. Sorry.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Thu, 26 Feb 1998 09:27:22 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] mode of libs" }, { "msg_contents": "On Wed, 25 Feb 1998, Bruce Momjian wrote:\n\n> Now there is a bigger problem. pg_pwd is mode rw-rw-rw- because a COPY\n> is used to create it. Any ideas how to fix this? Copy sets the\n> permissions to this before it creates the file. It temporarily changes\n> the umask to create the file. If pg_pwd ever has data in it and it is\n> world-readable, it is unsecure.\n> \n> Anyone have a brilliant idea on a fix?\n\n\tWhy, again, is COPY creating files 666? 600, IMHO, sounds more\nappropriate, but I imagine there has to be a reason why it is 666...\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 26 Feb 1998 17:43:40 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] mode of libs" }, { "msg_contents": "> \n> On Wed, 25 Feb 1998, Bruce Momjian wrote:\n> \n> > Now there is a bigger problem. pg_pwd is mode rw-rw-rw- because a COPY\n> > is used to create it. Any ideas how to fix this? Copy sets the\n> > permissions to this before it creates the file. It temporarily changes\n> > the umask to create the file. If pg_pwd ever has data in it and it is\n> > world-readable, it is unsecure.\n> > \n> > Anyone have a brilliant idea on a fix?\n> \n> \tWhy, again, is COPY creating files 666? 600, IMHO, sounds more\n> appropriate, but I imagine there has to be a reason why it is 666...\n\nBecause the owner is postgres, not the user running the psql copy\ncommand.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Thu, 26 Feb 1998 17:01:38 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] mode of libs" } ]
[ { "msg_contents": "\nAre there any plans to implement oid-style functionality for\nsequences, such as returning the nextval in the result tuple somehow?\n\nIs it at all possible to implement? That is one very nice thing about\nusing oid instead, is that it comes back in PQoidStatus. I probably\nwon't stop using oids until this is possible (i've got my own restore\nwhich \"preserves\" (i.e. renumbers) oid references)\n\n--brett\n", "msg_date": "Wed, 25 Feb 1998 18:56:36 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": true, "msg_subject": "sequences" }, { "msg_contents": "Brett McCormick wrote:\n> \n> Are there any plans to implement oid-style functionality for\n> sequences, such as returning the nextval in the result tuple somehow?\n> \n> Is it at all possible to implement? That is one very nice thing about\n> using oid instead, is that it comes back in PQoidStatus. I probably\n> won't stop using oids until this is possible (i've got my own restore\n> which \"preserves\" (i.e. renumbers) oid references)\n\nNot possible - sequences are just \"a gear\", user can use more than\none sequences in inserts, etc...\n\nBut we could return PRIMARY KEY of affected tuple if it exists!\nI kept this feature in mind when thought about removing OID...\n\nComments ?\n\nVadim\n", "msg_date": "Thu, 26 Feb 1998 10:40:23 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] sequences" }, { "msg_contents": "\n> Brett McCormick wrote:\n> > \n> > Are there any plans to implement oid-style functionality for\n> > sequences, such as returning the nextval in the result tuple somehow?\n> > \n> > Is it at all possible to implement? That is one very nice thing about\n> > using oid instead, is that it comes back in PQoidStatus. I probably\n> > won't stop using oids until this is possible (i've got my own restore\n> > which \"preserves\" (i.e. renumbers) oid references)\n> \n> Not possible - sequences are just \"a gear\", user can use more than\n> one sequences in inserts, etc...\n> \n> But we could return PRIMARY KEY of affected tuple if it exists!\n> I kept this feature in mind when thought about removing OID...\n> \n> Comments ?\n\nThis would be very useful. I never did like the idea of using OID as \nreference so a way to get the PIMARY KEY would be A GOOD THING(tm).\n\nMichael\n\nBTW: I could have sworn the first thing I tried was to grant select on the \nsequence I was using when it complianed about access.\n\n> \n> Vadim\n> \n> \n\n* Michael J. Rogan, Network Administrator, 905-624-3020 *\n* Mark IV Industries, F-P Electronics & I.V.H.S. Divisions *\n* [email protected] [email protected] *\n", "msg_date": "Thu, 26 Feb 1998 17:37:50 +0000", "msg_from": "\"Michael J. Rogan\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] sequences" }, { "msg_contents": "Michael J. Rogan wrote:\n> \n> >\n> > But we could return PRIMARY KEY of affected tuple if it exists!\n> > I kept this feature in mind when thought about removing OID...\n> >\n> > Comments ?\n> \n> This would be very useful. I never did like the idea of using OID as\n> reference so a way to get the PIMARY KEY would be A GOOD THING(tm).\n\nBut we will have to decide how to deal with multi-key PK...\n\nVadim\n", "msg_date": "Fri, 27 Feb 1998 10:27:07 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] sequences" }, { "msg_contents": "\nOn Fri, 27 February 1998, at 10:27:07, Vadim B. Mikheev wrote:\n> Michael J. Rogan wrote:\n> > \n> > >\n> > > But we could return PRIMARY KEY of affected tuple if it exists!\n> > > I kept this feature in mind when thought about removing OID...\n> > >\n> > > Comments ?\n> > \n> > This would be very useful. I never did like the idea of using OID as\n> > reference so a way to get the PIMARY KEY would be A GOOD THING(tm).\n> \n> But we will have to decide how to deal with multi-key PK...\n> \n> Vadim\n\nHow is this implemented?\n", "msg_date": "Sun, 1 Mar 1998 13:51:09 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] sequences" }, { "msg_contents": "Brett McCormick wrote:\n> \n> On Fri, 27 February 1998, at 10:27:07, Vadim B. Mikheev wrote:\n> > Michael J. Rogan wrote:\n> > >\n> > > >\n> > > > But we could return PRIMARY KEY of affected tuple if it exists!\n> > > > I kept this feature in mind when thought about removing OID...\n> > > >\n> > > > Comments ?\n> > >\n> > > This would be very useful. I never did like the idea of using OID as\n> > > reference so a way to get the PIMARY KEY would be A GOOD THING(tm).\n> >\n> > But we will have to decide how to deal with multi-key PK...\n> >\n> > Vadim\n> \n> How is this implemented?\n\nUsing multi-key unique btree indices. \n\nVadim\n", "msg_date": "Mon, 02 Mar 1998 10:31:03 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] sequences" } ]
[ { "msg_contents": "OK, so when I asked earlier about documentation directory structure,\nMarc indicated that we should put things into a separate area, not just\nplop them into the usual src/ tree. I agree, but am not sure _where_ to\nactually put them.\n\nI am thinking of making a directory doc/src/sgml (under the existing doc\ndirectory) which would contain the sgml source code. doc/src would\ncontain that and a Makefile which would know how to invoke the Makefile\nin doc/src/sgml. A \"make install\" from doc/src would copy gzip packaged\nfiles up to doc/, where they would be for a distribution.\n\nA Makefile in doc/ would unpack the gzip tar files of html into\ndirectories right under doc/, such as doc/tutorial, doc/userguide, etc.\n\nIs this OK? Some questions:\n\n1) Should all html be isolated into subdirectories under a doc/html/\ndirectory?\n\n2) Should documentation source be somewhere other than doc/src/?\nRemember that the doc directory is at the same level as the src/\ndirectory for the executable source code distribution, not underneath\nit.\n\n3) The top level Makefile will be very simple at first (I won't have\ntime for more), and will just install directly into the doc/ directory\ntree. Is this OK? If not, does someone want to volunteer to do more??\n\nOpinions/comments?\n\n - Tom\n\n", "msg_date": "Thu, 26 Feb 1998 03:01:20 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": true, "msg_subject": "Documentation tree (again)" }, { "msg_contents": "On Thu, 26 Feb 1998, Thomas G. Lockhart wrote:\n\n> OK, so when I asked earlier about documentation directory structure,\n> Marc indicated that we should put things into a separate area, not just\n> plop them into the usual src/ tree. I agree, but am not sure _where_ to\n> actually put them.\n> \n> I am thinking of making a directory doc/src/sgml (under the existing doc\n> directory) which would contain the sgml source code. doc/src would\n> contain that and a Makefile which would know how to invoke the Makefile\n> in doc/src/sgml. A \"make install\" from doc/src would copy gzip packaged\n> files up to doc/, where they would be for a distribution.\n> \n> A Makefile in doc/ would unpack the gzip tar files of html into\n> directories right under doc/, such as doc/tutorial, doc/userguide, etc.\n> \n> Is this OK? Some questions:\n\n\tSounds good to me...\n\n> 1) Should all html be isolated into subdirectories under a doc/html/\n> directory?\n\n\tI'd say that all html should be installed in $prefix/html when a\n'make install' is issued. You should be able to remove the package after\ninstalling...\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 26 Feb 1998 17:41:14 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Documentation tree (again)" }, { "msg_contents": "> I'd say that all html should be installed in $prefix/html when a\n> 'make install' is issued. You should be able to remove the package after\n> installing...\n\nWhich \"the package\": the source distribution tar files or the $prefix/html target\narea?\n\n - Tom\n\n", "msg_date": "Fri, 27 Feb 1998 03:30:58 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Documentation tree (again)" }, { "msg_contents": "On Fri, 27 Feb 1998, Thomas G. Lockhart wrote:\n\n> > I'd say that all html should be installed in $prefix/html when a\n> > 'make install' is issued. You should be able to remove the package after\n> > installing...\n> \n> Which \"the package\": the source distribution tar files or the\n> $prefix/html target area? \n\n\tThe source distribution...\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 26 Feb 1998 23:45:49 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Documentation tree (again)" } ]
[ { "msg_contents": "\nI'm willing to throw some time towards this -- is there anyone who is\ncurrently investigating this? please drop me an e-mail. also, if I\ncould be informed of progress to date/underlying issues that we know\nabout that would be great.\n\nthanks in advance,\n--brett\n", "msg_date": "Wed, 25 Feb 1998 19:34:12 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": true, "msg_subject": "alpha/64bit & mkoidname problem" }, { "msg_contents": "> \n> \n> I'm willing to throw some time towards this -- is there anyone who is\n> currently investigating this? please drop me an e-mail. also, if I\n> could be informed of progress to date/underlying issues that we know\n> about that would be great.\n\nI have no idea where we stand on the alpha issues, alpha/linux and\nalpha/dec unix.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Wed, 25 Feb 1998 22:43:48 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [PORTS] alpha/64bit & mkoidname problem" } ]
[ { "msg_contents": "\ntransaction needs to be put in that big ol thing with user et al in\nthe grammer for ColId..\n", "msg_date": "Wed, 25 Feb 1998 20:07:38 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": true, "msg_subject": "transaction not valid ColID" } ]
[ { "msg_contents": "\nwell, by putting TRANSACTION and ORDER in the ColID grammer, I seem to\nhave introduced some shift/reduce and reduce/reduce conflicts.. will\nthe grammer work? What are your thoughts on using these as column\nidentifiers? If they aren't going to end up usable I certainly won't\nuse them as table/field names.. (order sounds like a really bad idea)\n", "msg_date": "Wed, 25 Feb 1998 20:14:43 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": true, "msg_subject": "grammer/keywords/shift/reduce conflicts" }, { "msg_contents": "> well, by putting TRANSACTION and ORDER in the ColID grammer, I seem to\n> have introduced some shift/reduce and reduce/reduce conflicts.. will\n> the grammer work? What are your thoughts on using these as column\n> identifiers? If they aren't going to end up usable I certainly won't\n> use them as table/field names.. (order sounds like a really bad idea)\n\nYup. I think that the conflicts mean that there now would be ambiguous\ngrammar. So, if you stumble across just the right statement and order of\nwords, you may not get what you expected, and not be able to get what you\nwant. Both \"transaction\" and \"order\" are pretty clearly SQL-ish words, so\nI wouldn't bother trying to make them work in other contexts...\n\n - Tom\n\n", "msg_date": "Thu, 26 Feb 1998 05:45:01 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] grammer/keywords/shift/reduce conflicts" } ]
[ { "msg_contents": "-----Original Message-----\nFrom: Bruce Momjian <[email protected]>\nTo: Maurice Gittens <[email protected]>\nCc: [email protected] <[email protected]>\nDate: donderdag 26 februari 1998 2:09\nSubject: Re: [HACKERS] Adding a field to each tuple\n\n\n>> My challenge:\n>> Given an oid, efficiently determine the most derived class the instance\n>> belongs to.\n>>\n>> My intended solution is to add an extra attribute to each tuple\n>> which contains the oid of the most derived class it belongs to.\n>\n\n\nI expect it will also introduce me to quite a few aspects of the postgresql\nsystem.\nIf I'm going to learn about the system then I might as well get a good\noverall\nview of how things are organized.\nSure I've read parts of the developers manual but I think this little\nproject will let\nme see (in the source) how information travels from diskstorage all the\nway to the client.\nAlso valuable information on how to debug the backend etc. will be\nlearned in this way I think.\n\nWhile trying to fix a large_object memory leak I noticed\nthat without an understanding of how the many components interrelate\nit's almost impossible to fix anything because you don't know who is\nresponsible for what.\n\nI certainly do appreciate any help I can get.\n>\n> This is a lot of overhead for places it is not needed.\n>\n\nAny suggestions for solving the general given problem with less overhead?-:)\n\nBest regards,\nMaurice\n\n\n", "msg_date": "Thu, 26 Feb 1998 10:45:28 +0100", "msg_from": "\"Maurice Gittens\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Adding a field to each tuple" }, { "msg_contents": "> I certainly do appreciate any help I can get.\n> >\n> > This is a lot of overhead for places it is not needed.\n> >\n> \n> Any suggestions for solving the general given problem with less overhead?-:)\n\nYes, this is a natural use for a trigger. Create the column in the base\ntable, and have it stuff the value on insert. You have to make the\ntrigger on each derived table, but you may be able to use the same\ntrigger on all tables. This is how we are implementing time travel.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Thu, 26 Feb 1998 09:31:48 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Adding a field to each tuple" } ]
[ { "msg_contents": "AA van Raalte wrote:\n> \n> >>\n> >> Summary: Indexes are broken\n> >\n> >Could you post me your data to give me way to reproduce bug locally ?\n> >\n> >Vadim\n> \n> OK. There are three scripts attatched, s1 generates the data, s2 creates the\n> indexes, s3 performs a query on the data.\n> If you perform the following query:\n> \n> cat s1 s3 | psql db\n> \n> the last query returns a count of 8.\n> If you use indexes by performing the following, identical query:\n> \n> cat s1 s2 s3 | psql db\n> \n> the last query returns a count of 4!.\n\nWell, fortunately, btree are not broken and two old bugs fixed. I suppose\nthat your server compiled without CASSERT. Having CASSERT I got core from\nthe next s3' query when tested using indices:\n\nupdate temp_bankbaln \n set prev_baln = b.baln \n from temp_bankbaln b \n where temp_bankbaln.prev_date = b.date and \n temp_bankbaln.accno = b.accno; \n\nEXPLAIN:\n\nMerge Join (cost=53.85 size=24556 width=62)\n -> Index Scan on b (cost=19.40 size=228 width=24)\n -> Index Scan on temp_bankbaln (cost=19.40 size=228 width=38)\n\nWithout index baln_i4 on temp_bankbaln(accno):\n\nMerge Join (cost=71.18 size=24556 width=60)\n -> Index Scan on b (cost=18.40 size=228 width=24)\n -> Seq Scan (cost=18.40 size=0 width=0)\n -> Sort (cost=10.52 size=0 width=0)\n -> Seq Scan on temp_bankbaln (cost=10.52 size=228 width=36)\n\n- no probs.\n\nFirst bug was in execScan.c when \"bad\" tuple table slot was returned in\nthe end of index' scan and the second was in nodeIndexscan.c where \n\"tooo\" general and dummy IndexScanMarkPosition()/ExecIndexRestrPos() \nwere used instead of index_markpos()/index_restrpos().\n\nNote, that ONLY MergeJoin was affected by these two bugs because\nthis join method is only one using ExecMarkPos() and ExecRestrPos()\n(and for inner child plan onle).\nBTW, SELECT with second plan above is 13 times faster than with \nthe first one! Sorting by using indices is not always fastest way...\n\nThanks Alvin for given simple way to reproduce bug!\n\nBTW, elog(FATAL) from vacuum and btree were reported by 2-3\nanother ppl - shouldn't we ask users to re-compile server with\nCASSERT in all \"FATAL\" cases ? \nCASSERT assisted me very much to find real sources of this problem\nand recently fixed vacuum bug.\n\nVadim\nP.S. Unfortunately, I still didn't add permissions check to subselect\ncode and didn't implement ReScan of MergeJoin node - hope to do this\ntomorrow... Bye.\n", "msg_date": "Thu, 26 Feb 1998 18:55:14 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "MergeJoin and Mark/Restr scan positions (Re: [PORTS] Port Bug Report)" }, { "msg_contents": "> BTW, elog(FATAL) from vacuum and btree were reported by 2-3\n> another ppl - shouldn't we ask users to re-compile server with\n> CASSERT in all \"FATAL\" cases ? \n> CASSERT assisted me very much to find real sources of this problem\n> and recently fixed vacuum bug.\n\nI am a little confused on when we should have them use this. In most\ncases, turning on CASSERT doesn't help. Should we suggest it in certain\ncases as we see it applies, or is there a rule we can give them to tell\nthem when to try it?\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Thu, 26 Feb 1998 09:44:34 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] MergeJoin and Mark/Restr scan positions (Re: [PORTS]\n\tPort Bug Report)" }, { "msg_contents": "Bruce Momjian wrote:\n> \n> > BTW, elog(FATAL) from vacuum and btree were reported by 2-3\n> > another ppl - shouldn't we ask users to re-compile server with\n> > CASSERT in all \"FATAL\" cases ?\n> > CASSERT assisted me very much to find real sources of this problem\n> > and recently fixed vacuum bug.\n> \n> I am a little confused on when we should have them use this. In most\n> cases, turning on CASSERT doesn't help. Should we suggest it in certain\n> cases as we see it applies, or is there a rule we can give them to tell\n> them when to try it?\n\nFor me, CASSERT is last chance to put me in right direction when\nI can't reproduce reported bug (user can't provide test data etc).\nBut you're right - we shouldn't suggest anything generaly.\n\nBTW, Alvin got ASSERTion for real data! We'll try to fix this...\n\nVadim\n", "msg_date": "Fri, 27 Feb 1998 10:05:12 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] MergeJoin and Mark/Restr scan positions (Re: [PORTS]\n\tPort Bug Report)" } ]
[ { "msg_contents": "Karl, Doug - could you try new vacuum code (should be in current snapshot\nalready) ?\nDid you use CASSERT in compilation ?\nPlease try re-compile with this if not.\nAlso, Doug, could you post me EXPLAIN output of your UPDATE query (below) ?\n\nTIA,\n\tVadim\n\nKarl Denninger wrote:\n> \n> That's the same problem, but I don't get it during use - only during the\n> vacuum.\n> \n> I've got a LOT of large tables - the only one which is doing this to me is\n> the one which has a compound unique index - the problem may lie there.\n> \n> \n> On Mon, Feb 09, 1998 at 11:59:47AM -0800, Doug Mitchell wrote:\n> >\n> > I have a 200-300 MB table that also seems to be having index corruption\n> > problems. It also has a four-field unique index. I removed the old\n> > database, did an initdb and a reload. Everything works fine until I let\n> > several clients update the table at the same time. Once I let several\n> > clients work concurrently, the index seems to get \"corrupted\".\n> > If I had to guess, I'd say that something was not getting locked correctly.\n> > Were you running vacuum while the table was being accessed?\n> >\n> > mybase=> UPDATE sometable SET lasttime = now () WHERE ... ;\n> > FATAL 1: btree: BTP_CHAIN flag was expected\n> >\n> > I'm running a fairly recent snapshot:\n> > 2916657 Feb 2 00:02 postgresql.snapshot.tar.gz\n> >\n> > Has anyone else seen this problem with big tables or under heavy concurrent\n> > access?\n> >\n> > Thanks,\n> > Doug\n> >\n> > ----------------------------------------------------\n> >\n> > At 02:10 PM 2/8/98 -0600, Karl Denninger wrote:\n> > >Hi folks,\n> > >\n> > >I'm running into Btree index corruption problems with large (~500MB)\n> > >databases.\n> > >\n> > >There is no indication of trouble until I run vacuum - then the system comes\n> > >back with a fatal error indicating that a chain in the Btree is invalid, and\n> > >stops.\n> > >\n> > >The index in question is a compound index with 4 fields, and is unique as\n> > >well.\n> > >\n> > >Any ideas? The scuttlebutt is that hash indices are broken, and besides, in\n> > >this case it wouldn't work anyway since I need a unique index on this (which\n> > >is restricted to btrees).\n> > >\n> > >This is V6.2.1.\n> > >\n", "msg_date": "Thu, 26 Feb 1998 19:26:46 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] Index corruption problmes?!" } ]
[ { "msg_contents": "-----Original Message-----\nFrom: Bruce Momjian <[email protected]>\nTo: Maurice Gittens <[email protected]>\nCc: [email protected] <[email protected]>\nDate: donderdag 26 februari 1998 21:36\nSubject: Re: [HACKERS] Adding a field to each tuple\n\n\n>\n>Yes, this is a natural use for a trigger. Create the column in the base\n>table, and have it stuff the value on insert. You have to make the\n>trigger on each derived table, but you may be able to use the same\n>trigger on all tables. This is how we are implementing time travel.\n>\n\n\nAgreed. This was my first try. But doesn't solve the general problem, of\nmapping an arbitrary valid (within the system) OID to the OID of it's class\ndoes it ?!.\n\nSo I've started hacking and I'm now encountering my first problems -:).\n(I do realize that I going to run into more trouble for large objects.)\n\nLearning new stuff is so much fun -:).\n\nThanks,\nMaurice (who's enjoying himself today.)\n\n\n\n\n", "msg_date": "Thu, 26 Feb 1998 15:42:42 +0100", "msg_from": "\"Maurice Gittens\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Adding a field to each tuple" } ]
[ { "msg_contents": "Just tried the 26Feb98 Snapshot under Irix 5.3.\n\nIf you request a compiler other than gcc, configure still dies.\n\nAfter looking at Darren's comment: \n> \n> I complained about this one a few months back. There is a test condition\n> that needs to be double-quoted. In my generated configure, it's at line\n> #3230 in the test whether gcc needs -traditional.\n> \n> I seem to recall that it was more a bug in autoconf that in the postgres\n> configure script.\n> \n> darrenk\n> \n\nI took another look and fixed the problem by hacking configure.\nIt clearly is a bug in the routine:\nAC_PROG_GCC_TRADITIONAL\n\nThe only work around seems to be to hack configure after running autoconf\n(or to fix autoconf...).\n\nHere's a patch to configure which fixes the problem:\n\n*** configure.orig Thu Feb 26 08:02:06 1998\n--- configure Thu Feb 26 15:42:30 1998\n***************\n*** 3275,3281 ****\n fi\n rm -f conftest*\n \n! if test $ac_cv_prog_gcc = yes; then\n echo $ac_n \"checking whether ${CC-cc} needs -traditional\"\"... $ac_c\" 1>&6\n echo \"configure:3281: checking whether ${CC-cc} needs -traditional\" >&5\n if eval \"test \\\"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\\\" = set\"; then\n--- 3275,3281 ----\n fi\n rm -f conftest*\n \n! if test \"$ac_cv_prog_gcc\" = yes; then\n echo $ac_n \"checking whether ${CC-cc} needs -traditional\"\"... $ac_c\" 1>&6\n echo \"configure:3281: checking whether ${CC-cc} needs -traditional\" >&5\n if eval \"test \\\"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\\\" = set\"; then\n\n\n\n\nAndrew\n\n----------------------------------------------------------------------------\nDr. Andrew C.R. Martin University College London\nEMAIL: (Work) [email protected] (Home) [email protected]\nURL: http://www.biochem.ucl.ac.uk/~martin\nTel: (Work) +44(0)171 419 3890 (Home) +44(0)1372 275775\n", "msg_date": "Thu, 26 Feb 1998 15:46:37 GMT", "msg_from": "Andrew Martin <[email protected]>", "msg_from_op": true, "msg_subject": "Snapshot 26Feb98 - configure still broken" }, { "msg_contents": "On Thu, 26 Feb 1998, Andrew Martin wrote:\n\n> Just tried the 26Feb98 Snapshot under Irix 5.3.\n> \n> If you request a compiler other than gcc, configure still dies.\n> \n> After looking at Darren's comment: \n> > \n> > I complained about this one a few months back. There is a test condition\n> > that needs to be double-quoted. In my generated configure, it's at line\n> > #3230 in the test whether gcc needs -traditional.\n> > \n> > I seem to recall that it was more a bug in autoconf that in the postgres\n> > configure script.\n> > \n> > darrenk\n> > \n> \n> I took another look and fixed the problem by hacking configure.\n> It clearly is a bug in the routine:\n> AC_PROG_GCC_TRADITIONAL\n> \n> The only work around seems to be to hack configure after running autoconf\n> (or to fix autoconf...).\n> \n> Here's a patch to configure which fixes the problem:\n\n\tThis patch will only fix the problem until the next time I happen\nto run autoconf, at which time it will disappear again. What I did once\nalready for another area was to actually modify the autoconf source code\n*before* reinstalling it so that autoconf itself has the fix...\n\n\tWith that in mind, and assuming that you have autoconf laying\naround, can you look at what it would take in autoconf 2.12 to get this to\nwork consistently and supply a patch? If you don't have it, let me know\nand I'll try and dig into it later tonight...right now, I'm stretching in\nabout a dozen directions :(\n\n> \n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 26 Feb 1998 17:49:10 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Snapshot 26Feb98 - configure still broken" } ]
[ { "msg_contents": "\nThe Makefile in .../src/interfaces/ecpg/lib/ uses a gcc specific flag\n(-Wall) instead of COPTS.\n\nThe following patch is for Makefile.in in that directory\n\n*** Makefile.in.orig Tue Feb 24 08:00:41 1998\n--- Makefile.in Thu Feb 26 16:27:16 1998\n***************\n*** 61,66 ****\n libecpg.a : libecpg.a(ecpglib.o) libecpg.a(typename.o)\n\n ecpglib.o : ecpglib.c ../include/ecpglib.h ../include/ecpgtype.h\n! $(CC) -Wall -I../include $(PQ_INCLUDE) -c ecpglib.c\n typename.o : typename.c ../include/ecpgtype.h\n! $(CC) -Wall -I../include $(PQ_INCLUDE) -c typename.c\n--- 61,66 ----\n libecpg.a : libecpg.a(ecpglib.o) libecpg.a(typename.o)\n\n ecpglib.o : ecpglib.c ../include/ecpglib.h ../include/ecpgtype.h\n! $(CC) $(CFLAGS) -I../include $(PQ_INCLUDE) -c ecpglib.c\n typename.o : typename.c ../include/ecpgtype.h\n! $(CC) $(CFLAGS) -I../include $(PQ_INCLUDE) -c typename.c\n\n\n\n\n\nI guess (I haven't had time to check) that the actual Makefile is built\nfrom Makefile.in. If not, then an equivalent patch needs to be applied\nto Makefile\n\n\n\nAndrew\n\n----------------------------------------------------------------------------\nDr. Andrew C.R. Martin University College London\nEMAIL: (Work) [email protected] (Home) [email protected]\nURL: http://www.biochem.ucl.ac.uk/~martin\nTel: (Work) +44(0)171 419 3890 (Home) +44(0)1372 275775\n", "msg_date": "Thu, 26 Feb 1998 16:31:55 GMT", "msg_from": "Andrew Martin <[email protected]>", "msg_from_op": true, "msg_subject": "Snapshot 26Feb98 - another minor showstopper" } ]
[ { "msg_contents": "> But someone will have to do it. Red Hat 5.0 is too important a\n> distribution and postgresql is too important an application.\n\nI agree. Can someone track down the RH5.0 rpm packager so we can start a dialog?\n\nAlso, is there anyone running RH5.0 who can do some debugging (and who already\nhas some familiarity with Postgres :)?\n\nI believe that the locale support is broken (I'm developing on RH4.2 at home and\nhave a non-development RH5.0 machine at work, both with the same symptoms). And\nthere is this possible problem with date/time...\n\nPostgreSQL-6.3 will be released in a few days, and it would be nice to resolve\nthese issues.\n\n - Tom\n\n", "msg_date": "Thu, 26 Feb 1998 17:03:27 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] Re: RH5.0/PostgreSQL Regression Test Failures" } ]
[ { "msg_contents": "\nThe Makefile in .../src/interfaces/ecpg/preproc also has -Wall as a\nCFLAGS option.\n\n\nHere's a patch:\n\n\n*** Makefile.orig Wed Feb 25 08:00:39 1998\n--- Makefile Thu Feb 26 16:51:43 1998\n***************\n*** 5,11 ****\n MINOR_VERSION=0\n PATCHLEVEL=0\n \n! CFLAGS+=-I$(SRCDIR)/include -I../include -Wall -DMAJOR_VERSION=$(MAJOR_VERSION) -DMINOR_VERSION=$(MINOR_VERSION) -DPATCHLEVEL=$(PATCHLEVEL)\n \n all:: ecpg\n \n--- 5,11 ----\n MINOR_VERSION=0\n PATCHLEVEL=0\n \n! CFLAGS+=-I$(SRCDIR)/include -I../include -DMAJOR_VERSION=$(MAJOR_VERSION) -DMINOR_VERSION=$(MINOR_VERSION) -DPATCHLEVEL=$(PATCHLEVEL)\n \n all:: ecpg\n \n\n\n\n\nAndrew\n----------------------------------------------------------------------------\nDr. Andrew C.R. Martin University College London\nEMAIL: (Work) [email protected] (Home) [email protected]\nURL: http://www.biochem.ucl.ac.uk/~martin\nTel: (Work) +44(0)171 419 3890 (Home) +44(0)1372 275775\n", "msg_date": "Thu, 26 Feb 1998 17:12:06 GMT", "msg_from": "Andrew Martin <[email protected]>", "msg_from_op": true, "msg_subject": "Snapshot 26Feb98 - minor showstoppers part 2" } ]
[ { "msg_contents": "\n\nJust seen that Darren has supplied more extensive patches which\nalso fix the problems with -Wall in ecpg\n\n\nSo, ignore my versions (though the patch to configure is still\nneeded).\n\n\nAndrew\n----------------------------------------------------------------------------\nDr. Andrew C.R. Martin University College London\nEMAIL: (Work) [email protected] (Home) [email protected]\nURL: http://www.biochem.ucl.ac.uk/~martin\nTel: (Work) +44(0)171 419 3890 (Home) +44(0)1372 275775\n", "msg_date": "Thu, 26 Feb 1998 17:15:28 GMT", "msg_from": "Andrew Martin <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Snapshot 26Feb98 - another minor showstopper" }, { "msg_contents": "On Thu, Feb 26, 1998 at 05:15:28PM +0000, Andrew Martin wrote:\n\n> Just seen that Darren has supplied more extensive patches which\n> also fix the problems with -Wall in ecpg\n> \n> So, ignore my versions (though the patch to configure is still\n> needed).\n\nNot entirely. His version didn't introduce \"$(CFLAGS)\" into the cc\ncommand lines, which is needed for many systems -- while yours did.\nSpecifically, this causes building to fail on systems that do shared\nlibraries. For the \"bsd\" port, the shared library setup should also\nbe modified as has been done everywhere else, to ignore it on those\nBSD systems that don't have shared libraries.\n\nHere's a slightly expanded version of your patch -- this is what I'm\nusing here now:\n\n*** interfaces/ecpg/lib/Makefile.in.orig\tTue Feb 24 09:00:41 1998\n--- interfaces/ecpg/lib/Makefile.in\tThu Feb 26 18:29:03 1998\n***************\n*** 8,13 ****\n--- 8,17 ----\n \n PORTNAME=@PORTNAME@\n \n+ ifdef KRBVERS\n+ CFLAGS+= $(KRBFLAGS)\n+ endif\n+ \n # Shared library stuff\n shlib := \n install-shlib-dep :=\n***************\n*** 20,29 ****\n endif\n endif\n ifeq ($(PORTNAME), bsd)\n! install-shlib-dep := install-shlib\n! shlib := libecpg.so.$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)\n! LDFLAGS_SL = -x -Bshareable -Bforcearchive\n! CFLAGS += $(CFLAGS_SL)\n endif\n #ifeq ($(PORTNAME), i386_solaris)\n # install-shlib-dep := install-shlib\n--- 24,35 ----\n endif\n endif\n ifeq ($(PORTNAME), bsd)\n! ifdef BSD_SHLIB\n! install-shlib-dep := install-shlib\n! shlib := libecpg.so.$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)\n! LDFLAGS_SL = -x -Bshareable -Bforcearchive\n! CFLAGS += $(CFLAGS_SL)\n! endif\n endif\n #ifeq ($(PORTNAME), i386_solaris)\n # install-shlib-dep := install-shlib\n***************\n*** 61,66 ****\n libecpg.a : libecpg.a(ecpglib.o) libecpg.a(typename.o)\n \n ecpglib.o : ecpglib.c ../include/ecpglib.h ../include/ecpgtype.h\n! \t$(CC) -Wall -I../include $(PQ_INCLUDE) -c ecpglib.c\n typename.o : typename.c ../include/ecpgtype.h\n! \t$(CC) -Wall -I../include $(PQ_INCLUDE) -c typename.c\n--- 67,72 ----\n libecpg.a : libecpg.a(ecpglib.o) libecpg.a(typename.o)\n \n ecpglib.o : ecpglib.c ../include/ecpglib.h ../include/ecpgtype.h\n! \t$(CC) $(CFLAGS) -I../include $(PQ_INCLUDE) -c ecpglib.c\n typename.o : typename.c ../include/ecpgtype.h\n! \t$(CC) $(CFLAGS) -I../include $(PQ_INCLUDE) -c typename.c\n\n-tih\n-- \nPopularity is the hallmark of mediocrity. --Niles Crane, \"Frasier\"\n", "msg_date": "Thu, 26 Feb 1998 22:26:56 +0100", "msg_from": "Tom I Helbekkmo <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Snapshot 26Feb98 - another minor showstopper" }, { "msg_contents": "Tom I Helbekkmo writes:\n> Not entirely. His version didn't introduce \"$(CFLAGS)\" into the cc\n> command lines, which is needed for many systems -- while yours did.\n> Specifically, this causes building to fail on systems that do shared\n> libraries. For the \"bsd\" port, the shared library setup should also\n> be modified as has been done everywhere else, to ignore it on those\n> BSD systems that don't have shared libraries.\n> \n> Here's a slightly expanded version of your patch -- this is what I'm\n> using here now:\n\nOkay, will be included with my next patch set.\n\nMichael\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Fri, 27 Feb 1998 11:05:22 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Snapshot 26Feb98 - another minor showstopper" } ]
[ { "msg_contents": "Now that we have subselects, I would like to mention that without\nsubselects, SQL is a very limited language.\n\nWith commercial Ingres, you could do aggregates with their own WHERE and\nBY clauses for restriction and correlation, but SQL doesn't allow this. \nSubselects are a major feature, and you should review your code for\nplaces where subselects provide a better solution for your queries. I\nthink you will find that there are more uses for subselects than you may\nthink.\n\nVadim has put us on the big SQL map with subselects, and fully\nfunctional ones too.\n\nI will post something like this with 6.3 is released.\n\n[Let's see, how do I send this to the questions group too? :-) ]\n\n--\nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Thu, 26 Feb 1998 13:30:09 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "subselects" } ]
[ { "msg_contents": "On Thu, 26 Feb 1998, Dwight Johnson wrote:\n\n> I agree. Can someone track down the RH5.0 rpm packager so we can start a dialog?\n\nHello,\n\nI am the packager for the RH 5.0 postgres RPM. What's wrong with it ?\n\n> PostgreSQL-6.3 will be released in a few days, and it would be nice to resolve\n> these issues.\n\nLooking forward for this release...\n\nBest wishes,\n\nCristian\n--\n----------------------------------------------------------------------\nCristian Gafton -- [email protected] -- Red Hat Software, Inc.\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n UNIX is user friendly. It's just selective about who its friends are.\n\n", "msg_date": "Thu, 26 Feb 1998 13:51:45 -0500 (EST)", "msg_from": "Cristian Gafton <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Postgresql broken" }, { "msg_contents": "On Thu, 26 Feb 1998, Cristian Gafton wrote:\n\n> On Thu, 26 Feb 1998, Dwight Johnson wrote:\n> \n> > I agree. Can someone track down the RH5.0 rpm packager so we can start a dialog?\n> \n> Hello,\n> \n> I am the packager for the RH 5.0 postgres RPM. What's wrong with it ?\n\nHi Christian...\n\n\tI don't currently deal with Linux, so don't know what problems\nexist with the RPM, but would be possible for you to take the current\nsnapshot, and build an RPM for that? Then upload it to our bindist\ndirectory so that ppl can take alook at it before the release, to check\nfor any problems?\n\n\n", "msg_date": "Thu, 26 Feb 1998 14:20:56 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: Postgresql broken" }, { "msg_contents": "On Thu, 26 Feb 1998, The Hermit Hacker wrote:\n\n> \tI don't currently deal with Linux, so don't know what problems\n> exist with the RPM, but would be possible for you to take the current\n> snapshot, and build an RPM for that? Then upload it to our bindist\n\nSure. I am downloading the snapshot now, and I will build RPMs and upload\nthem to ftp://ftp.redhat.com/home/gafton/pgsql, if you want to point out\nppl to a kind-of-official RH rpm.\n\nBest wishes,\n\nCristian\n--\n----------------------------------------------------------------------\nCristian Gafton -- [email protected] -- Red Hat Software, Inc.\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n UNIX is user friendly. It's just selective about who its friends are.\n\n", "msg_date": "Thu, 26 Feb 1998 14:25:00 -0500 (EST)", "msg_from": "Cristian Gafton <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: Postgresql broken" }, { "msg_contents": "> I am the packager for the RH 5.0 postgres RPM. What's wrong with it ?\n\nHi Cristian. I'm developing Postgres on RH4.2 at home, and have RH5.0 running at\nwork. There are three known problems with the Postgres packages (some of which are\nlikely not directly related to the packaging itself):\n\n1) You have compiled the package with USE_LOCALE enabled. However, neither of my\nmachines behaves properly with that (including a clean build from source on RH4.2).\nThe test is to start up psql and try\n\n select '$1.00'::money;\n\nwhich fails. I believe this works on other platforms, and I distinctly recall getting\nthis to work on my development machine (in fact I helped implement it), but afaik\nthat was pre-RH4.2. My small test program which exercises the locale support in libc\nalso no longer works under RH4.2, though by now that may be from my mucking with it\ntrying to get it to work.\n\n2) pre-glibc2.0.7 has rounding bugs which cause odd results in some date/time\nroutines. The test is to try\n\n select '4 hours'::timespan;\n\nwhich will return '3 hours 59 mins 60 secs' on a machine with problems. We have\nreports from someone running Debian that glibc2.0.7-pre1 (?) fixes the problem. Any\nidea on when glibc2.0.7 might be available?\n\n3) the ownership of the data area is incorrect as shipped (I assume this is\nrpm-specific). On my RH5.0 machine, which is a VAResearch system with Linux/Postgres\npreinstalled, the data area was owned by root, and the backend cannot start up. If\nthe ownership is changed to the postgres account then the backend starts.\n\n> > PostgreSQL-6.3 will be released in a few days, and it would be nice to resolve\n> > these issues.\n\nThanks for building a new RPM. I'll try it at work on my production machine tomorrow.\nAlso, we will have new documentation in v6.3, including html and hardcopy, and you\nwill want to repackage that too. Look in the doc directory (in a day or two; I'm\nstill building the docs and haven't committed anything yet to the source tree).\n\nBest regards.\n\n - Tom\n\n", "msg_date": "Fri, 27 Feb 1998 03:13:34 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: Postgresql broken" }, { "msg_contents": "On Fri, 27 Feb 1998, Thomas G. Lockhart wrote:\n\n> The test is to start up psql and try\n> \n> select '$1.00'::money;\n> \n> which fails. I believe this works on other platforms, and I distinctly recall getting\n\nThat is true, it fails. However, if you could point to me where exactly\nsomething is going wrong I could try and have a look at it. I don't really\nfeel like digging into postgresql source to see which functions are at\nfault. A small C test program will be nice.\n\n> 2) pre-glibc2.0.7 has rounding bugs which cause odd results in some date/time\n> routines. The test is to try\n> \n> select '4 hours'::timespan;\n\nYepp, it fails.\n\n> which will return '3 hours 59 mins 60 secs' on a machine with problems. We have\n> reports from someone running Debian that glibc2.0.7-pre1 (?) fixes the problem. Any\n> idea on when glibc2.0.7 might be available?\n\nthe 2.0.7pre1 is available. However, if the debian folks fixed this\nproblem, I can tell you that their patch didn't made it so far in the\nglibc source tree. Again, a small C test program that shows what exactly\nfails will be nice.\n\n> 3) the ownership of the data area is incorrect as shipped (I assume this is\n> rpm-specific). On my RH5.0 machine, which is a VAResearch system with Linux/Postgres\n> preinstalled, the data area was owned by root, and the backend cannot start up. If\n> the ownership is changed to the postgres account then the backend starts.\n\nI think that is a VAResearch thing. The package definitely installs the\n/var/lib/pgsql directory owned by postgres account.\n\n> Thanks for building a new RPM. I'll try it at work on my production machine tomorrow.\n> Also, we will have new documentation in v6.3, including html and hardcopy, and you\n> will want to repackage that too. Look in the doc directory (in a day or two; I'm\n> still building the docs and haven't committed anything yet to the source tree).\n\nI am still waiting to find out a way to get cvs read-only access to the\npostgres sources. Downloading a full snapshot evey other day is not my\nfavorite game. Especially when a nice shell script can take care of\nautomatically generating new rpms every day... :-)\n\nBest wishes,\n\nCristian\n--\n----------------------------------------------------------------------\nCristian Gafton -- [email protected] -- Red Hat Software, Inc.\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n UNIX is user friendly. It's just selective about who its friends are.\n\n\n\n", "msg_date": "Sun, 1 Mar 1998 04:32:53 -0500 (EST)", "msg_from": "Cristian Gafton <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Re: Postgresql broken" }, { "msg_contents": "> > The test is to start up psql and try\n> >\n> > select '$1.00'::money;\n> >\n> > which fails. I believe this works on other platforms, and I distinctly recall getting\n>\n> That is true, it fails. However, if you could point to me where exactly\n> something is going wrong I could try and have a look at it. I don't really\n> feel like digging into postgresql source to see which functions are at\n> fault. A small C test program will be nice.\n\nDid you receive my mail dated 1998-02-28 03:02UTC? It contained a very small test program\nwhich (I believe) illustrates the problem. I've now modified it by dropping the relevant\nPostgres \"money\" support code straight into it; the new version is enclosed below. Just do\n\n golem> make testlocale\n cc testlocale.c -o testlocale\n\nTo try it out. It _may_ just be illustrating my lack of understanding of the locale\nsupport code in Unix, but I'm pretty sure this works on other platforms (and used to work\non an older - 3.03? 4.0? 4.1? - RH installation).\n\n> > 2) pre-glibc2.0.7 has rounding bugs which cause odd results in some date/time\n> > routines. The test is to try\n> >\n> > select '4 hours'::timespan;\n>\n> Yepp, it fails.\n\nDwight reported success when upgrading to a newer glibc but I didn't see a change when\ntrying the glibc in your home directory area. Oliver (I think??) reported success with\nDebian with a newer glibc, so perhaps things are fixed and I just didn't do the right\nthings to have the machine use the new library.\n\n> > which will return '3 hours 59 mins 60 secs' on a machine with problems. We have\n> > reports from someone running Debian that glibc2.0.7-pre1 (?) fixes the problem. Any\n> > idea on when glibc2.0.7 might be available?\n>\n> the 2.0.7pre1 is available. However, if the debian folks fixed this\n> problem, I can tell you that their patch didn't made it so far in the\n> glibc source tree. Again, a small C test program that shows what exactly\n> fails will be nice.\n\nOK. I'll work on it and try getting it to you soon. As I recall, it is problems with\nrounding behavior in one of the math functions (maybe modf()??). Anyway, will let you\nknow.\n\n> > 3) the ownership of the data area is incorrect as shipped (I assume this is\n> > rpm-specific). On my RH5.0 machine, which is a VAResearch system with Linux/Postgres\n> > preinstalled, the data area was owned by root, and the backend cannot start up. If\n> > the ownership is changed to the postgres account then the backend starts.\n>\n> I think that is a VAResearch thing. The package definitely installs the\n> /var/lib/pgsql directory owned by postgres account.\n\nOK.\n\n> > Thanks for building a new RPM. I'll try it at work on my production machine tomorrow.\n> > Also, we will have new documentation in v6.3, including html and hardcopy, and you\n> > will want to repackage that too. Look in the doc directory (in a day or two; I'm\n> > still building the docs and haven't committed anything yet to the source tree).\n>\n> I am still waiting to find out a way to get cvs read-only access to the\n> postgres sources. Downloading a full snapshot evey other day is not my\n> favorite game. Especially when a nice shell script can take care of\n> automatically generating new rpms every day... :-)\n\nWe are using CVSup. I built a static version on RH4.2 and placed it on\n\n ftp://postgresql.org/pub/CVSup/cvsup-15.2-client-linux-static.tar.gz\n\nThere is a non-static image also, but it probably requires some Modula-3 libraries. Hey,\nthat brings up something: would you be interested in a Modula-3 rpm? It would make\ninstalling CVSup much easier, since I wouldn't have to do the static library thing.\n\nActually, I'd be willing to build the rpm (or at least the source rpm) or even better help\nset up someone at RH, but I don't know much about rpm building and have been working so\nmuch on Postgres that I really don't want to start from scratch on figuring it out.\n\nI found that it built fairly easily, but it takes 200MB (!!) to do the build. The\ninstallation footprint is much smaller. It's a nice environment, and apparently let John\nPolstra, the CVSup developer, do his project fairly easily.\n\nTalk to you soon...\n\n - Tom", "msg_date": "Sun, 01 Mar 1998 16:09:56 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: Postgresql broken" } ]
[ { "msg_contents": "unsubscribe\n\n", "msg_date": "Thu, 26 Feb 1998 23:00:33 -0500", "msg_from": "Joao Leao <[email protected]>", "msg_from_op": true, "msg_subject": "(no subject)" } ]
[ { "msg_contents": "I am enhancing my PyGreSQL 2.0 package and I wanted to determine the\ntypes of returned fields. I tried using the manifest constans\nINT2OID, INT4OID, FLOAT4OID, etc but these are defined in the\nfile src/include/catalog/pg_type.h which doesn't get installed\ninto the public include directory. Am I right in assuming that\nexternal programs shouldn't use these values? Is there another\nway to get what I want? Is it considered acceptable for interface\nprograms to use this header file? Inquiring minds want to know.\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 424 2871 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Thu, 26 Feb 1998 23:32:45 -0500 (EST)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": true, "msg_subject": "INT2OID, etc." }, { "msg_contents": "> \n> I am enhancing my PyGreSQL 2.0 package and I wanted to determine the\n> types of returned fields. I tried using the manifest constans\n> INT2OID, INT4OID, FLOAT4OID, etc but these are defined in the\n> file src/include/catalog/pg_type.h which doesn't get installed\n> into the public include directory. Am I right in assuming that\n> external programs shouldn't use these values? Is there another\n> way to get what I want? Is it considered acceptable for interface\n> programs to use this header file? Inquiring minds want to know.\n\nI will say that pg_dump does use it, but it is not really a 3rd party\nlibrary.\n\nI recommend you use the file, and make them supply the pgsql source\ndirectory as part of the compile, that way, you can access the files you\nneed directly. You can do a lookup in pg_type for the names of the\ntypes you want. Maybe you can even write a little psql script to\nextract the oid's you need from pg_type, convert the output to #defines,\nand #include that in your compile.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Thu, 26 Feb 1998 23:45:24 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] INT2OID, etc." }, { "msg_contents": "D'Arcy J.M. Cain wrote:\n> \n> I am enhancing my PyGreSQL 2.0 package and I wanted to determine the\n> types of returned fields. I tried using the manifest constans\n> INT2OID, INT4OID, FLOAT4OID, etc but these are defined in the\n> file src/include/catalog/pg_type.h which doesn't get installed\n> into the public include directory. Am I right in assuming that\n> external programs shouldn't use these values? Is there another\n> way to get what I want? Is it considered acceptable for interface\n> programs to use this header file? Inquiring minds want to know.\n\nOn the one hand, client applications/interfaces shouldn't use\nserver internal constants like these but query database to get\ntype' name using type OIDs (like pg_dump does for \\d-s).\n\nOn the other hand - performance! And ability to use constants\nfor built-in types is good thing.\n\nI like second way (and so - we should copy pg_type to ~pgsql/include or\nsomething like this) but it would be nice if you support more\ngeneral 1st way too.\n\nVadim\n", "msg_date": "Fri, 27 Feb 1998 12:15:21 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] INT2OID, etc." }, { "msg_contents": "\nCan we have all the constants put in pg_type? In the implementation\nof my perl PL language, some types I care about aren't defined so I\nmust define them myself, which seems dangerous (should they ever\nchange)\n\nOn Fri, 27 February 1998, at 12:15:21, Vadim B. Mikheev wrote:\n\n> I like second way (and so - we should copy pg_type to ~pgsql/include or\n> something like this) but it would be nice if you support more\n> general 1st way too.\n> \n> Vadim\n", "msg_date": "Thu, 26 Feb 1998 22:20:20 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] INT2OID, etc." }, { "msg_contents": "Brett McCormick wrote:\n> \n> Can we have all the constants put in pg_type? In the implementation\n> of my perl PL language, some types I care about aren't defined so I\n> must define them myself, which seems dangerous (should they ever\n> change)\n> \n> On Fri, 27 February 1998, at 12:15:21, Vadim B. Mikheev wrote:\n> \n> > I like second way (and so - we should copy pg_type to ~pgsql/include or\n> > something like this) but it would be nice if you support more\n> > general 1st way too.\n\nWe should do this.\n\nVadim\n", "msg_date": "Fri, 27 Feb 1998 14:13:08 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] INT2OID, etc." }, { "msg_contents": "Thus spake Bruce Momjian\n> I will say that pg_dump does use it, but it is not really a 3rd party\n> library.\n\nMaybe everything in src/interfaces should be considered the same way.\n\n> I recommend you use the file, and make them supply the pgsql source\n> directory as part of the compile, that way, you can access the files you\n> need directly. You can do a lookup in pg_type for the names of the\n> types you want. Maybe you can even write a little psql script to\n> extract the oid's you need from pg_type, convert the output to #defines,\n> and #include that in your compile.\n\nThat's a thought. I just pulled the defines I needed out with many\ncomments about what a bad boy I was for doing that. I'll look at\nsomething like that.\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 424 2871 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Fri, 27 Feb 1998 07:54:32 -0500 (EST)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] INT2OID, etc." }, { "msg_contents": "Thus spake Vadim B. Mikheev\n> On the one hand, client applications/interfaces shouldn't use\n> server internal constants like these but query database to get\n> type' name using type OIDs (like pg_dump does for \\d-s).\n> \n> On the other hand - performance! And ability to use constants\n> for built-in types is good thing.\n> \n> I like second way (and so - we should copy pg_type to ~pgsql/include or\n> something like this) but it would be nice if you support more\n> general 1st way too.\n\nI think I'll write a program to extract this info and create a header\nfile. Perhaps that program can be dropped into the distribution.\nThe only problem is that it has to be run after the system has been\nbuilt, installed and initialized so it has to be run separately.\nStill, it's better than reinventing it for every package that needs it.\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 424 2871 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Fri, 27 Feb 1998 08:05:23 -0500 (EST)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] INT2OID, etc." }, { "msg_contents": "> \n> \n> Can we have all the constants put in pg_type? In the implementation\n> of my perl PL language, some types I care about aren't defined so I\n> must define them myself, which seems dangerous (should they ever\n> change)\n> \n\nPlease submit a patch to pg_type to add the ones you need. Maybe\ngenerating a separate file via a shell script with the oids would be\nnice. Gen_fmgr.sh does this, I think.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 10:00:43 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] INT2OID, etc." } ]
[ { "msg_contents": "\nselect money_words_out('$50');\n\ndoes not work under the latest snapshot.. also, you can't index an\narray without the table name (and a .) prepended?\n", "msg_date": "Thu, 26 Feb 1998 22:18:11 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": true, "msg_subject": "money_words_out segfaults" } ]
[ { "msg_contents": "Tables INS (x int) and SEL (y int) are owned by dbadm, for another\nuser SELECT granted on SEL, INSERT - on INS.\n\nShould another user be able to do\n\ninsert into ins select y from sel where x = y;\n\nor not ? \nCurrently, PG allows this. Backend tries to check \n(in execMain.c:ExecCheckPerms()) is READ access to\ntable being changed granted to user or not, but this check\nseems to be quite stupid:\n\n qvars = pull_varnos(parseTree->qual);\n tvars = pull_varnos((Node *) parseTree->targetList);\n if (intMember(resultRelation, qvars) ||\n intMember(resultRelation, tvars))\n\n: pull_varnos is very simple and just skips expressions in\nqual & target list.\n\nWe have to either get rid of this check or change it.\n\nWhat do you think ?\nHow \"big boys\" handle this ?\n\nVadim\n", "msg_date": "Fri, 27 Feb 1998 14:30:08 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": true, "msg_subject": "permission issue" }, { "msg_contents": "\nVadim wrote:\n\n>\n> Tables INS (x int) and SEL (y int) are owned by dbadm, for another\n> user SELECT granted on SEL, INSERT - on INS.\n>\n> Should another user be able to do\n>\n> insert into ins select y from sel where x = y;\n>\n> or not ?\n> Currently, PG allows this. Backend tries to check\n> (in execMain.c:ExecCheckPerms()) is READ access to\n> table being changed granted to user or not, but this check\n> seems to be quite stupid:\n>\n> qvars = pull_varnos(parseTree->qual);\n> tvars = pull_varnos((Node *) parseTree->targetList);\n> if (intMember(resultRelation, qvars) ||\n> intMember(resultRelation, tvars))\n>\n> : pull_varnos is very simple and just skips expressions in\n> qual & target list.\n>\n> We have to either get rid of this check or change it.\n>\n> What do you think ?\n> How \"big boys\" handle this ?\n>\n> Vadim\n>\n>\n\n As I wrote we must change more on the permission checking\n than currently done. I plan to implement something like an\n effective user which is used instead of the current user in\n the checks and switch the effective user on function calls to\n the owner of the function (triggers are implemented as\n functions and thus also covered). And we need that effective\n user too for the checks in views instead of what we did now\n with skipAcl in the RTE.\n\n I'll keep the above words in mind when doing so. But first\n let's release 6.3.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\n", "msg_date": "Fri, 27 Feb 1998 11:14:27 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] permission issue" }, { "msg_contents": "> \n> Tables INS (x int) and SEL (y int) are owned by dbadm, for another\n> user SELECT granted on SEL, INSERT - on INS.\n> \n> Should another user be able to do\n> \n> insert into ins select y from sel where x = y;\n\nMy guess is that the other user doesn't have SELECT permissions on\nINS.y, so this should fail, no?\n\n> \n> or not ? \n> Currently, PG allows this. Backend tries to check \n> (in execMain.c:ExecCheckPerms()) is READ access to\n> table being changed granted to user or not, but this check\n> seems to be quite stupid:\n> \n> qvars = pull_varnos(parseTree->qual);\n> tvars = pull_varnos((Node *) parseTree->targetList);\n> if (intMember(resultRelation, qvars) ||\n> intMember(resultRelation, tvars))\n> \n> : pull_varnos is very simple and just skips expressions in\n> qual & target list.\n> \n> We have to either get rid of this check or change it.\n> \n> What do you think ?\n> How \"big boys\" handle this ?\n> \n> Vadim\n> \n> \n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 10:06:31 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] permission issue" } ]
[ { "msg_contents": "Ok,\n\nAs part of my \"learning postgresql project\" I've been hacking yesterday\nand I've found out how to add a system attribute to each tuple in\npostgresql.\n\nI added a system attribute which maintains the relation between the\noid of a heaptuple and the oid of the relation to which the tuple\nbelongs.\n\nIn OO speak each instance now knows to which class it belongs.\n(Like runtime type idenfication in C++ and other languages).\n\nThe operation required the following changes.\n\n* in htup.h\n- add the new attribute to the HeapTupleData structure. Remember to\n add a symbolic constant with the index of the system attribute.\n also remember to Adjust the FirstLowInvalidHeapAttribute constant\n accordingly.\n\n* in heaptuple.c\n- add offsetof new fields to the heap_sysoffset table\n- update the functions heap_attisnull, heap_sysattrlen, heap_sysattrbyval,\n heap_getsysattr to support the new system attribute\n\n* in heapam.c\n- for example in the function heap_insert initialize the new field.\n In my case I want the field to carry the oid of the relation into which\n the tuple is being inserted.\n\n* in heap.c\n- update the static array of AttributeTupleForms called HeapAtt with\n information about the new systemattribute.\n Make sure the name of your systemattribute isn't a postgresql\n reserve word -:).\n\n* in index.c\n- update the static array of FormData_pg_attribute called sysatts with\n information about the new systemattribute\n\nAfter making these modifcations the system passes all regression tests\nand seems to give the expected results.\nOf course it was tested using inheritance (since this is the only context\nin which the functionality offered makes any sense).\n\nNow my next goal is polymorphism.\nI want triggers to be more like polymorphic functions in OO languages.\nSo that the definition of the trigger used only depend on the relation\nbut also on the context which it is used.\nSo it more closely follows the semantics of polymorphic methods.\n\nDon't worry I will try to ensure that poeple who don't like OO will not\nnotice any difference in the semantics of the postgresql system.\n\nThanks for your patience,\nMaurice\n\n\n", "msg_date": "Fri, 27 Feb 1998 09:57:11 +0100", "msg_from": "\"Maurice Gittens\" <[email protected]>", "msg_from_op": true, "msg_subject": "Howto add a field to each postgresql tuple" } ]
[ { "msg_contents": "It seems we need something like that too. I've just run the new perftest\nprogram against PostgreSQL and Oracle. It does:\n\n1) insert 1407 tuples into two tables\n2) select one attribute from one table\n3) select one attribute from the join og both tables\n4) updates one attribute in one table.\n\nHere are the results:\n\nOracle:\nI needed 24 seconds and 1937 microseconds for the insert test.\nI needed 1 seconds and 600641 microseconds for the selection&projection test.\nI needed 1 seconds and 703673 microseconds for the join test.\nI needed 2 seconds and 404709 microseconds for the update test.\n\nPostgreSQL with -F:\nI needed 10 seconds and 297716 microseconds for the insert test.\nI needed 28 seconds and 964208 microseconds for the selection&projection test.\nI needed 83 seconds and 931762 microseconds for the join test.\nI needed 0 seconds and 588390 microseconds for the update test.\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Fri, 27 Feb 1998 10:48:42 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "common area" }, { "msg_contents": "Tables, queries ?\nAlso, did you look @ src/test/performance ?\nIt would be nice to add support for Oracle there and new tests.\n\nMichael Meskes wrote:\n> \n> It seems we need something like that too. I've just run the new perftest\n> program against PostgreSQL and Oracle. It does:\n> \n> 1) insert 1407 tuples into two tables\n> 2) select one attribute from one table\n> 3) select one attribute from the join og both tables\n> 4) updates one attribute in one table.\n> \n> Here are the results:\n> \n> Oracle:\n> I needed 24 seconds and 1937 microseconds for the insert test.\n\nAll inserts in single transaction ?\n\n> I needed 1 seconds and 600641 microseconds for the selection&projection test.\n> I needed 1 seconds and 703673 microseconds for the join test.\n> I needed 2 seconds and 404709 microseconds for the update test.\n> \n> PostgreSQL with -F:\n> I needed 10 seconds and 297716 microseconds for the insert test.\n> I needed 28 seconds and 964208 microseconds for the selection&projection test.\n> I needed 83 seconds and 931762 microseconds for the join test.\n> I needed 0 seconds and 588390 microseconds for the update test.\n\nVadim\n", "msg_date": "Fri, 27 Feb 1998 18:05:19 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] common area" }, { "msg_contents": "Vadim B. Mikheev writes:\n> Tables, queries ?\n\nIt's just a very simple test program I use mainly to debug ecpg. I include\nit below.\n\n> Also, did you look @ src/test/performance ?\n> It would be nice to add support for Oracle there and new tests.\n\nYes, that's what I'm going to do once I have ecpg completed for 6.3. I'd\nlike to run some of mysql benchmarks too. In particular I'd like to see a\ncomparison between as many DB systems as possible using e.g. the Wisconsin\nbenchmark.\n\nMichael\n\n#include <stdio.h>\n#include <sys/time.h>\n#include <unistd.h>\n\nexec sql include sqlca;\n\nexec sql whenever sqlerror sqlprint;\nexec sql whenever not found sqlprint;\n\nstatic void\nprint_result(long sec, long usec, char *text)\n{\n\tif (usec < 0)\n\t{\n\t\tsec--;\n\t\tusec+=1000000;\n\t}\n\tprintf(\"I needed %ld seconds and %ld microseconds for the %s test.\\n\", sec, usec, text);\n}\n\nint\nmain ()\n{\nexec sql begin declare section;\n\tlong i;\nexec sql end declare section;\n\tstruct timeval tvs, tve;\n\n\texec sql connect 'mm';\n\n\texec sql create table perftest1(number int4, ascii char16);\n\n\texec sql create unique index number1 on perftest1(number);\n\n\texec sql create table perftest2(number int4, next_number int4);\n\n\texec sql create unique index number2 on perftest2(number);\n\n\tgettimeofday(&tvs, NULL);\n\n\tfor (i = 0;i < 1407; i++)\n\t{\n\t\texec sql begin declare section;\n\t\t\tchar text[16];\n\t\texec sql end declare section;\n\n\t\tsprintf(text, \"%ld\", i);\n\t\texec sql insert into perftest1(number, ascii) values (:i, :text);\n\t\texec sql insert into perftest2(number, next_number) values (:i, :i+1);\n\n\t\texec sql commit;\n\t}\n\n\tgettimeofday(&tve, NULL);\n\n\tprint_result(tve.tv_sec - tvs.tv_sec, tve.tv_usec - tvs.tv_usec, \"insert\");\n\n\tgettimeofday(&tvs, NULL);\n\n\tfor (i = 0;i < 1407; i++)\n\t{\n\t\texec sql begin declare section;\n\t\t\tchar text[16];\n\t\texec sql end declare section;\n\n\t\texec sql select ascii into :text from perftest1 where number = :i;\n\n\t\texec sql commit;\n\t}\n\n\tgettimeofday(&tve, NULL);\n\n\tprint_result(tve.tv_sec - tvs.tv_sec, tve.tv_usec - tvs.tv_usec, \"selection&projection\");\n\n\tgettimeofday(&tvs, NULL);\n\n\tfor (i = 0;i < 1407; i++)\n\t{\n\t\texec sql begin declare section;\n\t\t\tchar text[16];\n\t\texec sql end declare section;\n\n\t\texec sql select perftest1.ascii into :text from perftest1, perftest2 where perftest1.number = perftest2.number and perftest2.number = :i;\n\n\t\texec sql commit;\n\t}\n\n\tgettimeofday(&tve, NULL);\n\n\tprint_result(tve.tv_sec - tvs.tv_sec, tve.tv_usec - tvs.tv_usec, \"join\");\n\n\tgettimeofday(&tvs, NULL);\n\n\texec sql update perftest2 set next_number = next_number + 1;\n\n\texec sql commit;\n\n\tgettimeofday(&tve, NULL);\n\n\tprint_result(tve.tv_sec - tvs.tv_sec, tve.tv_usec - tvs.tv_usec, \"update\");\n\n\texec sql drop index number2;\n\n\texec sql drop table perftest2;\n\n\texec sql drop index number1;\n\n\texec sql drop table perftest1;\n\n\texec sql commit;\n\n\treturn (0);\n}\n\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Fri, 27 Feb 1998 12:13:29 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] common area" }, { "msg_contents": "> \n> It seems we need something like that too. I've just run the new perftest\n> program against PostgreSQL and Oracle. It does:\n> \n> 1) insert 1407 tuples into two tables\n> 2) select one attribute from one table\n> 3) select one attribute from the join og both tables\n> 4) updates one attribute in one table.\n> \n> Here are the results:\n> \n> Oracle:\n> I needed 24 seconds and 1937 microseconds for the insert test.\n> I needed 1 seconds and 600641 microseconds for the selection&projection test.\n> I needed 1 seconds and 703673 microseconds for the join test.\n> I needed 2 seconds and 404709 microseconds for the update test.\n> \n> PostgreSQL with -F:\n> I needed 10 seconds and 297716 microseconds for the insert test.\n> I needed 28 seconds and 964208 microseconds for the selection&projection test.\n> I needed 83 seconds and 931762 microseconds for the join test.\n> I needed 0 seconds and 588390 microseconds for the update test.\n\nThis seems strange. Is a vacuum being done so the optimizer knows how\nlarge each table is?\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 10:11:28 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] common area" }, { "msg_contents": "Bruce Momjian writes:\n> This seems strange. Is a vacuum being done so the optimizer knows how\n> large each table is?\n\nNo. The problem is how to send a vacuum from ecpg. I do not know enough\nabout libpq to know the command. And just sending it via PQexec doesn't\nwork.\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Fri, 27 Feb 1998 16:42:46 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] common area" }, { "msg_contents": "Michael Meskes writes:\n> Bruce Momjian writes:\n> > This seems strange. Is a vacuum being done so the optimizer knows how\n> > large each table is?\n> \n> No. The problem is how to send a vacuum from ecpg. I do not know enough\n> about libpq to know the command. And just sending it via PQexec doesn't\n> work.\n\nOops, it seems that one is a bug in ecpg. I found a way to execute it but\nthat doesn't change much:\n\nI needed 9 seconds and 903642 microseconds for the insert test.\nI needed 26 seconds and 882004 microseconds for the selection&projection test.\nI needed 75 seconds and 983778 microseconds for the join test.\nI needed 0 seconds and 550797 microseconds for the update test.\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Fri, 27 Feb 1998 16:54:52 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] common area" }, { "msg_contents": "Bruce Momjian wrote:\n> \n> >\n> > Oracle:\n> > I needed 24 seconds and 1937 microseconds for the insert test.\n> > I needed 1 seconds and 600641 microseconds for the selection&projection test.\n> > I needed 1 seconds and 703673 microseconds for the join test.\n> > I needed 2 seconds and 404709 microseconds for the update test.\n> >\n> > PostgreSQL with -F:\n> > I needed 10 seconds and 297716 microseconds for the insert test.\n> > I needed 28 seconds and 964208 microseconds for the selection&projection test.\n> > I needed 83 seconds and 931762 microseconds for the join test.\n> > I needed 0 seconds and 588390 microseconds for the update test.\n> \n> This seems strange. Is a vacuum being done so the optimizer knows how\n> large each table is?\n\nYou're right, Bruce. I don't see VACUUM in Michael' programm.\nThis also affects the second test (selection&projection): during\nselect backend updates data pages to set commit/abort statuses\nfor tuples' xactions.\n\nVadim\n", "msg_date": "Fri, 27 Feb 1998 23:02:02 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] common area" }, { "msg_contents": "Michael Meskes wrote:\n> \n> Bruce Momjian writes:\n> > This seems strange. Is a vacuum being done so the optimizer knows how\n> > large each table is?\n> \n> No. The problem is how to send a vacuum from ecpg. I do not know enough\n> about libpq to know the command. And just sending it via PQexec doesn't work.\n ^^^^^^^^^^^^^^^^^^^\nShould work! \n\nVadim\n", "msg_date": "Fri, 27 Feb 1998 23:11:10 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] common area" } ]
[ { "msg_contents": "[email protected] writes:\n> >Does it help to add #include <sys/types.h> to pgc.l? I'm not sure which\n> >file I should include to be correct. \n> \n> Yes.\n\nIs already in CVS.\n\n> BTW, line 32 of preproc/main.c has:\n> \n> \tchar\t\tc,\n> \n> 'char c' should be 'int c' I think. Otherwise\n> \n> \twhile ((c = getopt(argc, argv, \"vdo:\")) != EOF)\n> \n> will not work on some platforms.\n\nThanks. Changed in my source tree. Will be submitted later.\n\n> Another problem is SunOS does not have getopt(). Possible solutions\n> might be:\n> \n> a. steal getopt(3) source from FreeBSD\n> b. rewrite main.c so that it does not use getopt().\n> \n> I would prefer (a) since it would be easier:-) How do you think?\n\nEhem, how do we solve this in the backend? It does use getopt, too.\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Fri, 27 Feb 1998 11:27:40 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Current 6.3 issues" } ]
[ { "msg_contents": "At 11:27 AM 98.2.27 +0100, Michael Meskes wrote:\n>> Another problem is SunOS does not have getopt(). Possible solutions\n>> might be:\n>> \n>> a. steal getopt(3) source from FreeBSD\n>> b. rewrite main.c so that it does not use getopt().\n>> \n>> I would prefer (a) since it would be easier:-) How do you think?\n>\n>Ehem, how do we solve this in the backend? It does use getopt, too.\n\nSorry, I was wrong. Maybe I saw a dream:-)\nThe truth is SunOS does *have* getopt() but does not have getopt.h.\nSo we need to declare followings somewhere in ecpg.c.\n\nextern char *optarg;\nextern int optind;\n---\nTatsuo Ishii\[email protected]\n\n", "msg_date": "Fri, 27 Feb 1998 22:30:13 +0900", "msg_from": "[email protected] (Tatsuo Ishii)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Current 6.3 issues" } ]
[ { "msg_contents": "I wonder if I didn't make a mistake in the money type. As a C library\nfunction it made sense to add the \"$\" to the display because it was\neasy to add one to the return value if it wasn't required. I'm finding\nit to be a bit of a problem with my Python interface. I was just\ngoing to strip it in my module but I thought I would see if others\nfelt that it should simply be dropped from the PostgreSQL output.\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 424 2871 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Fri, 27 Feb 1998 08:45:09 -0500 (EST)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": true, "msg_subject": "Money type display" }, { "msg_contents": "\nI say remove it. It has only caused problems for me. Also, what\nabout the convention of only having a $ in the first & last rows\ninstead of all in between. there should at least be a handy function\nfor converting the output (other than string manipulation) should the\n$ be left on..\n\nOn Fri, 27 February 1998, at 08:45:09, D'Arcy J.M. Cain wrote:\n\n> I wonder if I didn't make a mistake in the money type. As a C library\n> function it made sense to add the \"$\" to the display because it was\n> easy to add one to the return value if it wasn't required. I'm finding\n> it to be a bit of a problem with my Python interface. I was just\n> going to strip it in my module but I thought I would see if others\n> felt that it should simply be dropped from the PostgreSQL output.\n> \n> -- \n> D'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\n> http://www.druid.net/darcy/ | and a sheep voting on\n> +1 416 424 2871 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Fri, 27 Feb 1998 07:06:46 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Money type display" }, { "msg_contents": "On Fri, 27 Feb 1998, D'Arcy J.M. Cain wrote:\n\n> I wonder if I didn't make a mistake in the money type. As a C library\n> function it made sense to add the \"$\" to the display because it was\n> easy to add one to the return value if it wasn't required. I'm finding\n> it to be a bit of a problem with my Python interface. I was just\n> going to strip it in my module but I thought I would see if others\n> felt that it should simply be dropped from the PostgreSQL output.\n\nA while back, (nine months, actually) I wrote that there were a number of\nproblems with the money type. I got several messages asking what I\nthought was wrong. I've been meaning to write that message, but I've\nnever found the time. (The fact that I deleted my code for a currency \ntype when I saw that the money type was included with the distribution is\na major contributing factor, here.)\n\nIn a nutshell, there were two problems: it didn't handle the case where\nlocales were defined for the build, but not for the run. Also, the\noutput didn't make use of all of the features of the locale, though I\ndon't recall the details of that complaint.\n\nI also thought that there should be some way of formatting the output for\ndifferent locales and that there should be some canonical format to be\nused for dumps and such to avoid the problem of dumping in one locale and\nattempting a reload in a different locale. This is kind of related to\nyour question.\n\nLately, I've been thinking of building some Python classes to support\ncertain Web-based operations on databases. (I do lots of active Web pages\nbased upon Postgres databases.) I was going to have a class for money\nfields, but I wasn't going to use the Postgres currency class. This was\nbecause the fact that I wanted Postgres to handle the value, with the\nPython handling the formatting of the output. It seems like such a waste\nto have the Postgres back end do all this formatting only to have some\nother code parse it so that I could manipulate the value and then reformat\nit. I don't particularly want to do all the arithmetic in SQL.\n\nHTH.\n\n-- \nJonathan Guthrie ([email protected])\nInformation Broker Systems +281-895-8101 http://www.brokersys.com/\n12703 Veterans Memorial #106, Houston, TX 77014, USA\n\nWe sell Internet access and commercial Web space. We also are general\nnetwork consultants in the greater Houston area.\n\n\n", "msg_date": "Fri, 27 Feb 1998 21:40:43 -0600 (CST)", "msg_from": "Jonathan Guthrie <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Money type display" } ]
[ { "msg_contents": "But this isn't declared in postmaster.c either. ecpg.c does include\nunistd.h if getopt.h does not exist and I think unistd.h is the one that\nputs the getopt stuff into postmaster.\n\nMichael\n\n--\nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n\n> -----Original Message-----\n> From:\[email protected] [SMTP:[email protected]]\n> Sent:\tFriday, February 27, 1998 2:30 PM\n> To:\tMichael Meskes\n> Cc:\[email protected]\n> Subject:\tRe: [HACKERS] Current 6.3 issues\n> \n> Sorry, I was wrong. Maybe I saw a dream:-)\n> The truth is SunOS does *have* getopt() but does not have getopt.h.\n> So we need to declare followings somewhere in ecpg.c.\n> \n> extern char *optarg;\n> extern int optind;\n> ---\n> Tatsuo Ishii\n> [email protected]\n", "msg_date": "Fri, 27 Feb 1998 14:52:26 +0100", "msg_from": "\"Meskes, Michael\" <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Current 6.3 issues" } ]
[ { "msg_contents": "> Brett McCormick wrote:\n> > \n> > Can we have all the constants put in pg_type? In the implementation\n> > of my perl PL language, some types I care about aren't defined so I\n> > must define them myself, which seems dangerous (should they ever\n> > change)\n> > \n> > On Fri, 27 February 1998, at 12:15:21, Vadim B. Mikheev wrote:\n> > \n> > > I like second way (and so - we should copy pg_type to ~pgsql/include or\n> > > something like this) but it would be nice if you support more\n> > > general 1st way too.\n> \n> We should do this.\n\nIs there anything to prevent someone from deleting that function and\nthen recreating it? If that happens, it will then have a different oid.\n\ndarrenk\n", "msg_date": "Fri, 27 Feb 1998 09:45:24 -0500", "msg_from": "[email protected] (Darren King)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] INT2OID, etc." } ]
[ { "msg_contents": "Here it is. Any changes? I will have a paragraph or two highlighting\nsome of the major changes.\n\n---------------------------------------------------------------------------\n\nCHANGES IN THE 6.3 RELEASE\n--------------------------\n\nDevelopers who have claimed items are:\n-------------------------------------\n\t* Billy is Billy G. Allie <[email protected]>\n\t* Brook is Brook Milligan\n\t* Bruce is Bruce Momjian <[email protected]>\n\t* D'Arcy is D'Arcy J.M. Cain <[email protected]>\n\t* Dan is Dan McGuirk <[email protected]>\n\t* Darren is Darren King <[email protected]>\n\t* Goran is Goran Thyni <[email protected]>\n\t* Henry is Henry B. Hotz <[email protected]>\n\t* James is James Hughes <[email protected]>\n\t* Jan is Jan Wieck <[email protected]>\n\t* Jeroen is Jeroen van Vianen <[email protected]>\n\t* Marc is Marc Fournier <[email protected]>\n\t* Martin is Martin S. Utesch <[email protected]>\n\t* Matt is Matt Maycock <[email protected]>\n\t* Peter is Peter T Mount <[email protected]>\n\t* Phil is Phil Thompson <[email protected]>\n\t* Ryan is Ryan Kirkpatrick <[email protected]>\n\t* Tatsuo is Tatsuo Ishii <[email protected]>\n\t* Thomas is Thomas Lockhart <[email protected]>\n\t* TomH is Tom I Helbekkmo <[email protected]>\n\t* TomS is Tom Szybist\n\t* Todd is Todd Brandys is <[email protected]>\n\t* Travis is Travis Melhiser <[email protected]>\n\t* Vadim is \"Vadim B. Mikheev\" <[email protected]>\n\nBug Fixes\n---------\nFix binary cursors broken by MOVE implementation(Vadim)\nFix for tcl library crash(Jan)\nFix for array handling, from Gerhard Hintermayer\nFix acl error, and remove duplicate pqtrace(Bruce)\nFix psql \\e for empty file(Bruce)\nFix for textcat on varchar() fields(Bruce)\nFix for DBT Sendproc (Zeugswetter Andres)\nFix vacuum analyze syntax problem(Bruce)\nFix for international identifiers(Tatsuo)\nFix aggregates on inherited tables(Bruce)\nFix substr() for out-of-bounds data\nFix for select 1=1 or 2=2, select 1=1 and 2=2, and select sum(2+2)(Bruce)\nFix notty output to show status result. -q option still turns it off(Bruce)\nFix for count(*), aggs with views and multiple tables and sum(3)(Bruce)\nFix cluster(Bruce)\nFix for PQtrace start/stop several times(Bruce)\nFix a variety of locking problems like newer lock waiters getting\n\tlock before older waiters, and having readlock people not share\n\tlocks if a writer is waiting for a lock, and waiting writers not\n\tgetting priority over waiting readers(Bruce)\nFix crashes in psql when executing queries from external files(James)\nFix problem with multiple order by columns, with the first one having\n\tNULL values(Jeroen)\nUse correct hash table support functions for float8 and int4(Thomas)\nRe-enable JOIN= option in CREATE OPERATOR statement (Thomas)\nChange precedence for boolean operators to match expected behavior(Thomas)\nGenerate elog(ERROR) on over-large integer(Bruce)\nAllow multiple-argument functions in constraint clauses(Thomas)\nCheck boolean input literals for 'true','false','yes','no','1','0'\n\tand throw elog(ERROR) if unrecognized(Thomas)\nMajor large objects fix\n\nEnhancements\n------------\nNew User Manual(Thomas, others)\nReal deadlock detection, no more timeouts(Bruce)\nSubselects with EXISTS, IN, ALL, ANY keywords (Vadim, Bruce, Thomas)\nAdd SQL92 \"constants\" CURRENT_DATE, CURRENT_TIME, CURRENT_TIMESTAMP, \n\tCURRENT_USER(Thomas)\nSpeedup by inlining some frequently-called functions\nModify constraint syntax to be SQL92-compliant(Thomas)\nImplement SQL92 PRIMARY KEY and UNIQUE clauses using indices(Thomas)\nRecognize SQL92 syntax for FOREIGN KEY. Throw elog notice(Thomas)\nAllow NOT NULL UNIQUE constraint clause (each allowed separately before)(Thomas)\nAllow Postgres-style casting (\"::\") of non-constants(Thomas)\nAdd support for SQL3 TRUE and FALSE boolean constants(Thomas)\nSupport SQL92 syntax for IS TRUE/IS FALSE/IS NOT TRUE/IS NOT FALSE(Thomas)\nAllow shorter strings for boolean literals (e.g. \"t\", \"tr\", \"tru\")(Thomas)\nAllow SQL92 delimited identifiers(Thomas)\nImplement SQL92 binary and hexadecimal string decoding (b'10' and x'1F')(Thomas)\nSupport SQL92 syntax for type coercion of literal strings\n\t(e.g. \"DATETIME 'now'\")(Thomas)\nAdd conversions for int2, int4, and OID types to and from text(Thomas)\nUse shared lock when building indices(Vadim)\nFree memory allocated for an user query inside transaction block after\n\tthis query is done, was turned off in <= 6.2.1(Vadim)\nNew SQL statement CREATE PROCEDURAL LANGUAGE(Jan)\nNew PostgreSQL Procedural Language (PL) backend interface(Jan)\nRename pg_dump -H option to -h(Bruce)\nAdd Java support for passwords, European dates(Peter)\nUse indices for LIKE and ~, !~ operations(Bruce)\nAdd hash functions for datetime and timespan(Thomas)\nTime Travel removed(Vadim, Bruce)\nAdd paging for \\d and \\z, and fix \\i(Bruce)\nAdd Unix domain socket support to backend and to frontend library(Goran)\nImplement CREATE DATABASE/WITH LOCATION and initlocation utility(Thomas)\nAllow more SQL92 and/or Postgres reserved words as column identifiers(Thomas)\nAugment support for SQL92 SET TIME ZONE...(Thomas)\nSET/SHOW/RESET TIME ZONE uses TZ backend environment variable(Thomas)\nImplement SET keyword = DEFAULT and SET TIME ZONE DEFAULT(Thomas)\nEnable SET TIME ZONE using TZ environment variable(Thomas)\nAdd PGDATESTYLE environment variable to frontend and backend initialization(Thomas)\nAdd PGTZ, PGCOSTHEAP, PGCOSTINDEX, PGRPLANS, PGGEQO\n\tfrontend library initialization environment variables(Thomas)\nRegression tests time zone automatically set with \"setenv PGTZ PST8PDT\"(Thomas)\nAdd pg_description table for info on tables, columns, operators, types, and\n\taggregates(Bruce)\nIncrease 16 char limit on system table/index names to 32 characters(Bruce)\nRename system indices(Bruce)\nAdd 'GERMAN' option to SET DATESTYLE(Thomas)\nDefine an \"ISO-style\" timespan output format with \"hh:mm:ss\" fields(Thomas)\nAllow fractional values for delta times (e.g. '2.5 days')(Thomas)\nValidate numeric input more carefully for delta times(Thomas)\nImplement day of year as possible input to date_part()(Thomas)\nDefine timespan_finite() and text_timespan() functions(Thomas)\nRemove archive stuff(Bruce)\nAllow for a pg_password authentication database that is separate from\n\tthe system password file(Todd)\nDump ACLs, GRANT, REVOKE permissions(Matt)\nDefine text, varchar, and bpchar string length functions(Thomas)\nFix Query handling for inheritance, and cost computations(Bruce)\nImplement CREATE TABLE/AS SELECT (alternative to SELECT/INTO)(Thomas)\nAllow NOT, IS NULL, IS NOT NULL in constraints(Thomas)\nImplement UNIONs for SELECT(Bruce)\nAdd UNION, GROUP, DISTINCT to INSERT(Bruce)\nvarchar() stores only necessary bytes on disk(Bruce)\nFix for BLOBs(Peter)\nMega-Patch for JDBC...see README_6.3 for list of changes(Peter)\nRemove unused \"option\" from PQconnectdb()\nNew LOCK command and lock manual page describing deadlocks(Bruce)\nAdd new psql \\da, \\dd, \\df, \\do, \\dS, and \\dT commands(Bruce)\nEnhance psql \\z to show sequences(Bruce)\nShow NOT NULL and DEFAULT in psql \\d table(Bruce)\nNew psql .psqlrc file startup(Andrew)\nModify sample startup script in contrib/linux to show syslog(Thomas)\nNew types for IP and MAC addresses in contrib/ip_and_mac(TomH)\nUnix system time conversions with date/time types in contrib/unixdate(Thomas)\nUpdate of contrib stuff(Massimo)\nAdd Unix socket support to DBD::Pg(Goran)\nNew python interface (PyGreSQL 2.0)(D'Arcy)\nNew frontend/backend protocol has a version number, network byte order(Phil)\nSecurity features in pg_hba.conf enhanced and documented, many cleanups(Phil)\nNew HTML and Postscript documentation(Thomas)\nCHAR() now faster access than VARCHAR() or TEXT\necpg embedded SQL preprocessor\nAdd GROUP BY to INSERT INTO table SELECT * FROM table2\nReduce system column overhead(Vadmin)\nRemove pg_time table(Vadim)\nAdd pg_type attribute to identify types that need length (bpchar, varchar)\nAdd report of offending line when COPY command fails\nAllow VIEW permissions to be set separately from the underlying tables. \n\tFor security, use GRANT/REVOKE on views as appropriate(Jan)\nTables now have no default GRANT SELECT TO PUBLIC. You must\n\texplicitly grant such permissions.\n\nSource Tree Changes\n-------------------\nAdd new html development tools, and flow chart in /tools/backend\nFix for SCO compiles\nStratus computer port \"Gillies, Robert\" <[email protected]>\nAdded support for shlib for BSD44_derived & i386_solaris\nMake configure more automated(Brook)\nAdd script to check regression test results\nBreak parser functions into smaller files, group together(Bruce)\nRename heap_create to heap_create_and_catalog, rename heap_creatr\n\tto heap_create()(Bruce)\nSparc/Linux patch for locking(TomS)\nRemove PORTNAME and reorganize port-specific stuff(Marc)\nAdd optimizer README file(Bruce)\nRemove some recursion in optimizer and clean up some code there(Bruce)\nFix for NetBSD locking(Henry)\nFix for libptcl make(Tatsuo)\nAIX patch(Darren)\nChange IS TRUE, IS FALSE, ... to expressions using \"=\" rather than\n\tfunction calls to istrue() or isfalse() to allow optimization(Thomas)\nVarious fixes NetBSD/Sparc related(TomH)\nAlpha linux locking(Travis,Ryan)\nChange elog(WARN) to elog(ERROR)(Bruce)\nFAQ for FreeBSD(Marc)\nBring in the PostODBC source tree as part of our standard distribution(Marc)\nA minor patch for HP/UX 10 vs 9(Stan)\nNew pg_attribute.atttypmod for type-specific info like varchar length(Bruce)\nUnixware patches(Billy)\nNew i386 'lock' for spin lock asm(Billy)\nSupport for multiplexed backends is removed\nStart an OpenBSD port\nStart an AUX port\nStart a Cygnus port\nAdd string functions to regression suite(Thomas)\nExpand a few function names formerly truncated to 16 characters(Thomas)\nRemove un-needed malloc() calls and replace with palloc().\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 10:25:15 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "HISTORY list for 6.3" }, { "msg_contents": "Bruce Momjian writes:\n> Here it is. Any changes? I will have a paragraph or two highlighting\n> some of the major changes.\n> ...\n> ecpg embedded SQL preprocessor\n> ...\n\nPlease use <[email protected]> as my email address in case you want to add\nit.\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Fri, 27 Feb 1998 16:45:03 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] HISTORY list for 6.3" }, { "msg_contents": "> \n> Bruce Momjian writes:\n> > Here it is. Any changes? I will have a paragraph or two highlighting\n> > some of the major changes.\n> > ...\n> > ecpg embedded SQL preprocessor\n> > ...\n> \n> Please use <[email protected]> as my email address in case you want to add\n> it.\n> \n> Michael\n\nYes, thank you. Have I missed anyone at the top of the TODO list on our\nweb page?\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 11:12:07 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] HISTORY list for 6.3" }, { "msg_contents": "> > Bruce Momjian writes:\n> > > Here it is. Any changes? I will have a paragraph or two highlighting\n> > > some of the major changes.\n\nGood idea. That list is _really_ dense :)\n\nI've got a minor patch to pg_operator.h to fix a few geometric boolean\noperators. Vadim had spotted the problem. Also, the docs are coming along; I\nhave the tutorial and user's guides completed, and the programmer's guide and\nadministrator's manual in final formatting. Got stuck at the moment converting\nthat ugly big gif picture of the table schema (Applixware wants to truncate\npieces) but I have gimp at work and that seemed to be viable (X over a modem is\ntoo slow to actually fix it, so will do it later from the office).\n\n - Tom\n\n", "msg_date": "Fri, 27 Feb 1998 16:55:27 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] HISTORY list for 6.3" } ]
[ { "msg_contents": "> I wonder if I didn't make a mistake in the money type. As a C library\n> function it made sense to add the \"$\" to the display because it was\n> easy to add one to the return value if it wasn't required. I'm finding\n> it to be a bit of a problem with my Python interface. I was just\n> going to strip it in my module but I thought I would see if others\n> felt that it should simply be dropped from the PostgreSQL output.\n> \nRemove it! Those of us who aren't American/Canadian/Australian don't want \na dollar sign for money anyway :-)\n\n\nAndrew\n\n----------------------------------------------------------------------------\nDr. Andrew C.R. Martin University College London\nEMAIL: (Work) [email protected] (Home) [email protected]\nURL: http://www.biochem.ucl.ac.uk/~martin\nTel: (Work) +44(0)171 419 3890 (Home) +44(0)1372 275775\n", "msg_date": "Fri, 27 Feb 1998 15:50:33 GMT", "msg_from": "Andrew Martin <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Money type display" }, { "msg_contents": "Thus spake Andrew Martin\n> > I wonder if I didn't make a mistake in the money type. As a C library\n> > function it made sense to add the \"$\" to the display because it was\n> > easy to add one to the return value if it wasn't required. I'm finding\n> > it to be a bit of a problem with my Python interface. I was just\n> > going to strip it in my module but I thought I would see if others\n> > felt that it should simply be dropped from the PostgreSQL output.\n> > \n> Remove it! Those of us who aren't American/Canadian/Australian don't want \n> a dollar sign for money anyway :-)\n\nRight. The original code that that comes from used locale extensively\nfor things like that.\n\nAlso, what about the commas? Again, locale is supposed to be used to\ndetermine which character to use but I am sure it just causes confusion.\n\nIn fact, perhaps we should just turn the money code into the decimal\ntype. I understand we have a mechanism now for specifying an argument\nto the input and output functions so we can specify the precision of\nthe decimal. Is this correct? If someone can help me out with the\ntype specifications, I'll start creating the code to handle decimal\ntypes. I'll just take the money code and modify it.\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 424 2871 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Fri, 27 Feb 1998 11:32:53 -0500 (EST)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Money type display" }, { "msg_contents": "> In fact, perhaps we should just turn the money code into the decimal\n> type. I understand we have a mechanism now for specifying an argument\n> to the input and output functions so we can specify the precision of\n> the decimal. Is this correct? If someone can help me out with the\n> type specifications, I'll start creating the code to handle decimal\n> types. I'll just take the money code and modify it.\n\nYep, it's in there. atttypmod is passed to all input/output function as\nthe third argument.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 12:19:34 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Money type display" }, { "msg_contents": "\nWhat's the second argument?\n\nOn Fri, 27 February 1998, at 12:19:34, Bruce Momjian wrote:\n\n> Yep, it's in there. atttypmod is passed to all input/output function as\n> the third argument.\n> \n> -- \n> Bruce Momjian | 830 Blythe Avenue\n> [email protected] | Drexel Hill, Pennsylvania 19026\n> + If your life is a hard drive, | (610) 353-9879(w)\n> + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 10:29:39 -0800 (PST)", "msg_from": "Brett McCormick <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Money type display" }, { "msg_contents": "> \n> \n> What's the second argument?\n> \n> On Fri, 27 February 1998, at 12:19:34, Bruce Momjian wrote:\n> \n> > Yep, it's in there. atttypmod is passed to all input/output function as\n> > the third argument.\n> > \n\nIf it is an array, and the base type.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 13:33:20 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Money type displayt" } ]
[ { "msg_contents": "It does. I had some problems with my database. After re-creating it it\nworked fine.\n\nMichael\n\n--\nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n\n> -----Original Message-----\n> From:\tVadim B. Mikheev [SMTP:[email protected]]\n> Sent:\tFriday, February 27, 1998 5:11 PM\n> To:\tMichael Meskes\n> Cc:\tBruce Momjian; PostgreSQL Hacker\n> Subject:\tRe: [HACKERS] common area\n> \n> Michael Meskes wrote:\n> > \n> > Bruce Momjian writes:\n> > > This seems strange. Is a vacuum being done so the optimizer knows\n> how\n> > > large each table is?\n> > \n> > No. The problem is how to send a vacuum from ecpg. I do not know\n> enough\n> > about libpq to know the command. And just sending it via PQexec\n> doesn't work.\n> \n> ^^^^^^^^^^^^^^^^^^^\n> Should work! \n> \n> Vadim\n", "msg_date": "Fri, 27 Feb 1998 17:04:15 +0100", "msg_from": "\"Meskes, Michael\" <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] common area" } ]
[ { "msg_contents": "You guys were correct of course. I've added a vacuum (which didn't work\nbecause of that ecpg bug) and now it looks better but still much slower than\nOracle:\n\nI needed 9 seconds and 748620 microseconds for the insert test.\nI needed 5 seconds and 882221 microseconds for the selection&projection test.\nI needed 10 seconds and 614912 microseconds for the join test.\nI needed 0 seconds and 586992 microseconds for the update test.\n\nAnyway, here's the patch on top of may last one to get vacuum going:\n\n*** ./preproc/ecpg.c.orig\tFri Feb 27 16:57:18 1998\n--- ./preproc/ecpg.c\tFri Feb 27 16:58:09 1998\n***************\n*** 58,65 ****\n \t\t/* after the options there must not be anything but filenames */\n \t\tfor (fnr = optind; fnr < argc; fnr++)\n \t\t{\n! \t\t\tchar\t *filename,\n! \t\t\t\t\t *ptr2ext;\n \t\t\tint\t\t\text = 0;\n \n \t\t\tfilename = mm_alloc(strlen(argv[fnr]) + 4);\n--- 58,64 ----\n \t\t/* after the options there must not be anything but filenames */\n \t\tfor (fnr = optind; fnr < argc; fnr++)\n \t\t{\n! \t\t\tchar\t *filename, *ptr2ext;\n \t\t\tint\t\t\text = 0;\n \n \t\t\tfilename = mm_alloc(strlen(argv[fnr]) + 4);\n***************\n*** 70,77 ****\n--- 69,79 ----\n \t\t\t/* no extension or extension not equal .pgc */\n \t\t\tif (ptr2ext == NULL || strcmp(ptr2ext, \".pgc\") != 0)\n \t\t\t{\n+ #if 0\n+ /* dumps core under some circumstances */\n \t\t\t\tif (ptr2ext == NULL)\n \t\t\t\t\text = 1;\t/* we need this information a while later */\n+ #endif\n \t\t\t\tptr2ext = filename + strlen(filename);\n \t\t\t\tptr2ext[0] = '.';\n \t\t\t}\n*** ./preproc/preproc.y.orig\tFri Feb 27 16:56:00 1998\n--- ./preproc/preproc.y\tFri Feb 27 16:56:12 1998\n***************\n*** 607,613 ****\n /* FIXME: instead of S_SYMBOL we should list all possible commands */\n sqlcommand : S_SYMBOL | SQL_DECLARE;\n \n! sqlstatement_words : sqlstatement_word\n \t\t | sqlstatement_words sqlstatement_word;\n \t\n sqlstatement_word : ':' symbol \n--- 607,613 ----\n /* FIXME: instead of S_SYMBOL we should list all possible commands */\n sqlcommand : S_SYMBOL | SQL_DECLARE;\n \n! sqlstatement_words : /* empty */\n \t\t | sqlstatement_words sqlstatement_word;\n \t\n sqlstatement_word : ':' symbol \n*** ./test/perftest.pgc.orig\tFri Feb 27 17:00:36 1998\n--- ./test/perftest.pgc\tFri Feb 27 17:01:39 1998\n***************\n*** 16,21 ****\n--- 16,22 ----\n \t\tusec+=1000000;\n \t}\n \tprintf(\"I needed %ld seconds and %ld microseconds for the %s test.\\n\", sec, usec, text);\n+ \texec sql vacuum;\n }\n \n int\n***************\n*** 106,113 ****\n \texec sql drop index number1;\n \n \texec sql drop table perftest1;\n- \n- \texec sql commit;\n \n \treturn (0);\n }\n--- 107,112 ----\n\nMichael\n\n-- \nDr. Michael Meskes, Project-Manager | topsystem Systemhaus GmbH\[email protected] | Europark A2, Adenauerstr. 20\[email protected] | 52146 Wuerselen\nGo SF49ers! Go Rhein Fire! | Tel: (+49) 2405/4670-44\nUse Debian GNU/Linux! | Fax: (+49) 2405/4670-10\n", "msg_date": "Fri, 27 Feb 1998 17:06:15 +0100 (CET)", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "performance & vacuum" } ]
[ { "msg_contents": "Hi Everybody,\n\nToday I got the snapshot (2/27). I took it and put it on my little intel \nLinux box, RH5.0. I compiled the sucker with no problem. I installed it \nwith no problem. The output of initdb --debug is as follows:\n\n(snip)\n<description text>\n \n> CREATED relation pg_description with OID 18791\n> Commit End\nAmopen: relation pg_description. attrsize 61\ncreate attribute 0 name objoid len 4 num 1 type 26\ncreate attribute 1 name description len -1 num 2 type 25\n> Amclose: relation (null).\nWARN:heap_modifytuple: repl is \\ -9\n> initdb: could not create template database\n\nDoes anyone know why this is? My source is undisturbed, except that I \nchanged the max # of backends from 32 to 64 in the sinvaltid.h file in \ninclude/... as directed by the FAQ.\n\nThanks!\n\nEddie\[email protected]\n", "msg_date": "Fri, 27 Feb 1998 11:25:28 -0500 (EST)", "msg_from": "Integration <[email protected]>", "msg_from_op": true, "msg_subject": "Odd behavior of initdb" }, { "msg_contents": "On Fri, 27 Feb 1998, Integration wrote:\n\n> Hi Everybody,\n> \n> Today I got the snapshot (2/27). I took it and put it on my little intel \n> Linux box, RH5.0. I compiled the sucker with no problem. I installed it \n> with no problem. The output of initdb --debug is as follows:\n> \n> (snip)\n> <description text>\n> \n> > CREATED relation pg_description with OID 18791\n> > Commit End\n> Amopen: relation pg_description. attrsize 61\n> create attribute 0 name objoid len 4 num 1 type 26\n> create attribute 1 name description len -1 num 2 type 25\n> > Amclose: relation (null).\n> WARN:heap_modifytuple: repl is \\ -9\n> > initdb: could not create template database\n> \n> Does anyone know why this is? My source is undisturbed, except that I \n> changed the max # of backends from 32 to 64 in the sinvaltid.h file in \n> include/... as directed by the FAQ.\n\n\tMy experience with this one is that I had an older libpq floating\naround...that was my problem on both FreeBSD and Solaris...\n\n\n", "msg_date": "Fri, 27 Feb 1998 11:45:42 -0500 (EST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Odd behavior of initdb" } ]
[ { "msg_contents": "Hi\n\nI tried to define a table on my Linux box, PostgreSQL 6.3 as:\n\njava=> CREATE TABLE tabella(campo VARCHAR(30) DEFAULT CURRENT_USER);\nERROR: DEFAULT: type mismatched\n\njava=> CREATE TABLE tabella(campo VARCHAR(30));\nCREATE\njava=> insert into tabella values (CURRENT_USER);\nERROR: parser: attribute 'campo' is of type 'varchar' but expression is of type 'name'\n\njava=> insert into tabella values (CAST CURRENT_USER AS VARCHAR);\nERROR: func_get_detail: function varchar(name) does not exist\njava=> insert into tabella values (CURRENT_USER::VARCHAR);\nERROR: func_get_detail: function varchar(name) does not exist\n\nand I had this error. PostgreSQL CURRENT_USER returns a type \"name\",\nbut SQL-Standard says that niladic builtin function CURRENT_USER returns a\nCHARACTER string representing the current authorization ID and \"name\" isn't\nan SQL type. I think this is a bug. What do you think about?\n\n(see A Guide To The SQL Standard C.J.Date).\n\n Ciao, Jose'\n ___, / \n |_+_| /| / ~ \n~~~~~~~~~~~~~~~~~~~~~~~~~ | / | /| ~~~~~~~~~~~~~~~~~~~~~\n Jose' Soares Da Silva ~ |/ | / | / \"As armas e os Baroes\n Progetto \"OS LUSIADAS\" ~ | |/| | /| assinalados, que da\n SFERA CARTA SOFTWARE ~ /| / | | / | Occidental praia Lusitana\n Via Bazzanese, 69 / | / | | /| | por mares nunca de antes\nCasalecchio R. BO - Italy / | / | |/ | | navegados, passarono\nhttp://www.sferacarta.com / |/____|_/__|_| ainda alem da Taprobana\"\n [email protected] /____|__| | __|___________ ~\n Fax. ++39 51 6131537 ____________|_____|_/ LUSIADAS / (Luis de Camoes,\n Tel. ++39 51 591054 \\ o / Os Lusiadas, canto I)\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~\\~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n", "msg_date": "Fri, 27 Feb 1998 17:25:46 +0000 (GMT)", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "CURRENT_USER" }, { "msg_contents": "> java=> CREATE TABLE tabella(campo VARCHAR(30) DEFAULT CURRENT_USER);\n> ERROR: DEFAULT: type mismatched\n> I had this error. PostgreSQL CURRENT_USER returns a type \"name\",\n> but SQL-Standard says that niladic builtin function CURRENT_USER returns a\n> CHARACTER string representing the current authorization ID and \"name\" isn't\n> an SQL type. I think this is a bug. What do you think about?\n\nYup.\n\n", "msg_date": "Mon, 02 Mar 1998 14:02:31 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] CURRENT_USER" } ]
[ { "msg_contents": "Here is my attempt at a general features/description for 6.3.\n\n---------------------------------------------------------------------------\n\nThere are some general 6.3 issues that I want to mention. These are\nonly the big items that can not be described in one sentence. A review\nof the HISTORY files is still needed.\n\nFirst, we now have subselects. Now that we have them, I would like to\nmention that without subselects, SQL is a very limited language.\nSubselects are a major feature, and you should review your code for\nplaces where subselects provide a better solution for your queries. I\nthink you will find that there are more uses for subselects than you may\nthink. Vadim has put us on the big SQL map with subselects, and fully\nfunctional ones too. The only thing you can't do with subselects is to\nuse them in the target list.\n\nSecond, 6.3 uses unix domain sockets rather than TCP/IP by default. To\nenable connections from other machines, you have to use the new\npostmaster -i option, and of course edit pg_hba.conf. Also, for this\nreason, the format of pg_hba.conf has changed.\n\nThird, char() fields will now allow faster access than varchar() or\ntext. Specifically, the text and varchar() have a penalty for access to\nany columns after the first column of this type. char() used to also\nhave this access penalty, but it no longer does. This may suggest that\nyou redesign some of your tables, especially if you have short character\ncolumns that you have defined as varchar() or text. This and other\nchanges make 6.3 even faster than earlier releases.\n\nWe now have passwords definable independent of any Unix file. There are\nnew SQL USER commands. See the pg_hba.conf manual page for more\ninformation. There is a new table, pg_shadow, which is used to store\nuser information and user passwords, and it by default only SELECT-able\nby the postgres super-user. pg_user is now a view of pg_shadow, and is\nSELECT-able by PUBLIC. You should keep using pg_user in your\napplication without changes.\n\nUser-created tables now no longer have SELECT permission to PUBLIC by\ndefault. This was done because the ANSI standard requires it. You can\nof course GRANT any permissions you want after the table is created. \nSystem tables continue to be SELECT-able by PUBLIC.\n\nWe also have real deadlock detection code. No more sixty-second\ntimeouts. And the new locking code implements a FIFO better, so there\nshould be less resource starvation during heavy use. For performance\nreasons, time travel is gone, but can be implemented using triggers (see\npgsql/contrib/spi/README). Please check out the new \\d command for\ntypes, operators, etc. Also, views have their own permissions now, not\nbased on the underlying tables, so permissions on them have to be set\nseparately. Check /pgsql/interfaces for some new ways to talk to\nPostgreSQL.\n\nThis is the first release that really required an explaination for\nexisting users. In many ways, this was necessary because the new\nrelease removes many limitations, and the work-arounds people were using\nare no longer needed.\n\nLong live PostgreSQL.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 13:17:41 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "6.3 Features" }, { "msg_contents": "> \n> Here is my attempt at a general features/description for 6.3.\n> \n> ---------------------------------------------------------------------------\n> \n> There are some general 6.3 issues that I want to mention. These are\n> only the big items that can not be described in one sentence. A review\n> of the HISTORY files is still needed.\n> \n\nI have added this to the 6.3 migration file.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 17:09:33 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] 6.3 Features" }, { "msg_contents": "> I have added this to the 6.3 migration file.\n\n... And for v6.4 we'll do this in SGML, a week ahead of release, right? :))\n\n - Tom\n\n", "msg_date": "Sat, 28 Feb 1998 02:37:36 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] 6.3 Features" }, { "msg_contents": "> \n> > I have added this to the 6.3 migration file.\n> \n> ... And for v6.4 we'll do this in SGML, a week ahead of release, right? :))\n\nYea, right. :-)\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 22:08:51 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] 6.3 Features" }, { "msg_contents": "We should mention ability to create procedural languages (in addition\nto supported 'C' and 'SQL') and that PL/tcl is in distribution.\n\nVadim\n", "msg_date": "Sat, 28 Feb 1998 18:34:46 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] 6.3 Features" }, { "msg_contents": "> \n> We should mention ability to create procedural languages (in addition\n> to supported 'C' and 'SQL') and that PL/tcl is in distribution.\n> \n> Vadim\n> \n\nI have a mention of PL:\n\n* New PostgreSQL Procedural Language (PL) backend interface(Jan)\n\nI didn't think it was more functional to mention more. Is it? Should I\nmention more?\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 09:52:03 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] 6.3 Features" } ]
[ { "msg_contents": "I have made all my changes necessary for the 6.3 release.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 17:16:25 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "6.3 ready" } ]
[ { "msg_contents": "Open items:\n\n---------------------------------------------------------------------------\n\nSelf-join optimizer performance problem\nGet interfaces fixed for new protocol\nProfiling improvements?\nProblem with tables >2Gb, add elog()?\nDo we want to add timestamps to elog messages?\nScanKeyData missing initializations\nAlpha/64-bit issues, mkoidname() problem\nlarge objects memory exhaustion\nCommit sgml document sources(Thomas)\nCommit html documents(Thomas)\nCommit postscript documents(Thomas)\nSunOS4 problems\nlibpgtcl undefined symbol?\nlarge objects and pg_dump poblem\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Fri, 27 Feb 1998 17:17:54 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Open 6.3 issues" }, { "msg_contents": "> Do we want to add timestamps to elog messages?\n\nWe haven't done it yet; should go on the v6.4 ToDo list...\n\n", "msg_date": "Sat, 28 Feb 1998 02:05:24 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Open 6.3 issues" }, { "msg_contents": ">Open items:\n>\n>---------------------------------------------------------------------------\n>SunOS4 problems\n\nWith my patches they should be fixed.\n--\nTatsuo Ishii\[email protected]\n", "msg_date": "Mon, 02 Mar 1998 11:37:04 +0900", "msg_from": "[email protected]", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Open 6.3 issues " } ]
[ { "msg_contents": "> oe> Try setting the environment variable LANG before starting the\n> oe> postmaster:\n> oe> $ export LANG=en_US\n> Unfortunately, this doesn't prevent the backend problem; the backend\n> still complains about the money format the and front-end gets a broken\n> pipe. Not sure what about the locale postgres doesn't like. For now,\n> I guess I'll just stick with my home-built version that doesn't use\n> the locale at all.\n\nI tried this at my clean RH5.0 machine at work, with the RH5.0 rpm\ninstallation of Postgres. It didn't help, and I guess I would have been\nsuprised if it did since the locale environment should have defaulted to\nthe \"C\" (same as \"POSIX\"?) conventions. I didn't get a backend crash,\njust the usual symptom.\n\nDidn't find a new Postgres package in Cristian's directory when I looked\nthis morning, but _did_ find a glibc2.0.7-2. Unfortunately it didn't seem\nto fix the rounding problem in date/time. I stopped and restarted the\nPostgres backend, but did not reboot the machine; was that sufficient?\nSeems like 2.0.7-2 should have the features (and fixes) Oliver reported\nfor Debian, so don't know the story :(\n\nMy little test program, which also fails on my RH4.2 system, is included\nbelow. It should return some characters related to locale; in this\nversion it tries the numeric decimal point (which does print) and the\nmoney decimal point, which doesn't. Used to work, though as I mentioned\nthe code as it is currently may be damaged by my trial and error attempts\nto get locale support working.\n\n - Tom", "msg_date": "Sat, 28 Feb 1998 03:02:40 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] 6.2.1 COPY X FROM stdin; -- broken pipe" }, { "msg_contents": "On Sat, 28 Feb 1998, Thomas G. Lockhart wrote:\n\n> Didn't find a new Postgres package in Cristian's directory when I looked\n> this morning, but _did_ find a glibc2.0.7-2. Unfortunately it didn't seem\n> to fix the rounding problem in date/time. I stopped and restarted the\n\nI've put the packages on ftp://ftp.redhat.com/home/gafton/pgsql. For the\nbeta 6.3 I have put the regression test results too, so anybody can take a\nlook at them and comment.\n\nPlease take a look at the packages and tell me if there is something\nmissing from them (that is, things not installed by default by 'make\ninstall' that ought to be included in a binary package though...\n\nBest wishes,\n\nCristian\n--\n----------------------------------------------------------------------\nCristian Gafton -- [email protected] -- Red Hat Software, Inc.\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n UNIX is user friendly. It's just selective about who its friends are.\n\n\n\n", "msg_date": "Sun, 1 Mar 1998 04:23:53 -0500 (EST)", "msg_from": "Cristian Gafton <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Re: [QUESTIONS] 6.2.1 COPY X FROM stdin; -- broken pipe" } ]
[ { "msg_contents": "We are coasting to the March 1 release date. No show-stoppers, assuming\nThomas finishes the new manuals.\n\nWe have a lot of nice effort go into the release, with many people\ninvolved, and some really heavy coding. Seems we did all the easy\ncoding in previous releases, so this release required the hard work, and\nwe have some heavy-duty features/fixes to show for it.\n\nAlso seems like we have more 'expert' developers now than we ever had\nbefore. And we haven't really lost any big developers since we started\nwith PostgreSQL, except maybe Bryan Henderson. I take this stability to\nmean we are managing things well, and the effort is well co-ordinated\nand fruitful.\n\nAnd I feel the features in 6.3, especially subselects, bring us up one\nwrung on the database ladder.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 00:09:20 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Coasting to 6.3 release" }, { "msg_contents": "On Sat, 28 Feb 1998, Bruce Momjian wrote:\n\n> We have a lot of nice effort go into the release, with many people\n> We are coasting to the March 1 release date. No show-stoppers, assuming\n> Thomas finishes the new manuals.\n\n\tAnd nobody asking me for a postponement...yet :)\n\n> Also seems like we have more 'expert' developers now than we ever had\n> before. And we haven't really lost any big developers since we started\n> with PostgreSQL, except maybe Bryan Henderson. \n\n\tAnd, he's proven a few times in this release that he's still out\nthere lurking :)\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sat, 28 Feb 1998 01:40:18 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Coasting to 6.3 release" }, { "msg_contents": "The Hermit Hacker wrote:\n> \n> On Sat, 28 Feb 1998, Bruce Momjian wrote:\n> \n> > We have a lot of nice effort go into the release, with many people\n> > We are coasting to the March 1 release date. No show-stoppers, assuming\n> > Thomas finishes the new manuals.\n> \n> And nobody asking me for a postponement...yet :)\n\nDid you keep fingers crossed ? :)\nAlvin ([email protected]) still gets ASSERT for some\nqueries. He posted me new test data and I'll try it now.\nI mostly believe that problem caused by using indices in inner\nplan of MergeJoin. Hope to fix it soon...\n\nVadim\n", "msg_date": "Sat, 28 Feb 1998 19:07:49 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Coasting to 6.3 release" }, { "msg_contents": "On Sat, 28 Feb 1998, Bruce Momjian wrote:\n\n> Also seems like we have more 'expert' developers now than we ever had\n> before. And we haven't really lost any big developers since we started\n> with PostgreSQL, except maybe Bryan Henderson. I take this stability to\n> mean we are managing things well, and the effort is well co-ordinated\n> and fruitful.\n>\nNot to diminish the significance of Bruce's remarks, but I think 2\nadditional factors are also at work:\n\t1)Success builds on success. The better the software, the more\nlikely someone will use it --> The more likely someone will find a bug\nor need a new feature and have the skills and desire to fix it.\n\n\t2)Related to #1. Inclusion of pgsql in some major linux\ndistributions is drawing in more developers and users. This effect\nseems to be far more powerful than the apparent boost derived from the\nbook publication that spurred development of v6.2\n \nMarc (not-to-be-confused-with-Hermit-Hacker) Zuckman\[email protected]\n\n\n", "msg_date": "Sat, 28 Feb 1998 08:34:24 -0500 (EST)", "msg_from": "Marc Howard Zuckman <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Coasting to 6.3 release" }, { "msg_contents": "Just fixed using indices in inner plan of MergeJoin.\n\nVadim\n", "msg_date": "Sat, 28 Feb 1998 21:08:26 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Coasting to 6.3 release" }, { "msg_contents": "> \n> On Sat, 28 Feb 1998, Bruce Momjian wrote:\n> \n> > We have a lot of nice effort go into the release, with many people\n> > We are coasting to the March 1 release date. No show-stoppers, assuming\n> > Thomas finishes the new manuals.\n> \n> \tAnd nobody asking me for a postponement...yet :)\n\nA major feat.\n\n> \n> > Also seems like we have more 'expert' developers now than we ever had\n> > before. And we haven't really lost any big developers since we started\n> > with PostgreSQL, except maybe Bryan Henderson. \n> \n> \tAnd, he's proven a few times in this release that he's still out\n> there lurking :)\n\nGood point.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 09:34:46 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Coasting to 6.3 release" }, { "msg_contents": "> \n> Just fixed using indices in inner plan of MergeJoin.\n\nAdded to HISTORY list.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 09:57:17 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Coasting to 6.3 release" }, { "msg_contents": "On Sat, 28 Feb 1998, Vadim B. Mikheev wrote:\n\n> Did you keep fingers crossed ? :)\n\n\tAlways :)\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sat, 28 Feb 1998 15:03:48 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Coasting to 6.3 release" } ]
[ { "msg_contents": "> On Fri, 27 Feb 1998, D'Arcy J.M. Cain wrote:\n>\n> > I wonder if I didn't make a mistake in the money type. As a C library\n> > function it made sense to add the \"$\" to the display because it was\n> > easy to add one to the return value if it wasn't required. I'm finding\n> > it to be a bit of a problem with my Python interface. I was just\n> > going to strip it in my module but I thought I would see if others\n> > felt that it should simply be dropped from the PostgreSQL output.\n>\n...\n\n> In a nutshell, there were two problems: it didn't handle the case where\n> locales were defined for the build, but not for the run. Also, the\n> output didn't make use of all of the features of the locale, though I\n> don't recall the details of that complaint.\n>\n...\n\n> Lately, I've been thinking of building some Python classes to support\n> certain Web-based operations on databases. (I do lots of active Web\n> pages\n> based upon Postgres databases.) I was going to have a class for money\n> fields, but I wasn't going to use the Postgres currency class. This\n> was\n> because the fact that I wanted Postgres to handle the value, with the\n> Python handling the formatting of the output. It seems like such a\n> waste\n> to have the Postgres back end do all this formatting only to have some\n> other code parse it so that I could manipulate the value and then\n> reformat\n> it. I don't particularly want to do all the arithmetic in SQL.\n\nI think that using locales in _backend_ is a _bad_thing_ in general.\nAFAIK unix (and C libraries) do not use locales in storage of the data\nbut only representation. And as the representation is done in the\nfront-end, it only introduces additional problems if we have the\nprotocol changing depending on locales (of both front-end and back-end).\nIt is a good thing to have an ASCII protocol, especially for debugging,\nbut also for ease of implementing new frontends, but it should not\nchange for random causes. So the input and output functions for types\nshould _not_ use locales at all.\n\n--------------------------\nHannu Krosing\n\n>\n\n", "msg_date": "Sat, 28 Feb 1998 15:08:49 +0200", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Money type display" } ]
[ { "msg_contents": "> Furthermore, it appaers as if buil;ding indices on varchar fields are \n> *much* slower. Probably because the changes to how they're stored on \n> disk. I suspect text willalso be slower. Didn't get to do much other \n> testing yet (still building indices..), but if I notice other strange \n> things, I'll lt them know to all of you (sorry for the mis-spellings, my \n> compu isn't very responsive att the moment)..\n\n[Moved to hackers list.]\n\nIs varchar/text slower than it used to be, or slower than char()?\n\nShould just be slower than char(), not slower than old code.\n\n> \n> btw. at what time do you expect 6.3 to be released? Will the goal of \n> march 1st be reached?\n\nMarch 1 is still target.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 09:54:16 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [QUESTIONS] On the febr. 28 snapshot" } ]
[ { "msg_contents": "Still getting these errors:\n\ncvs checkout: cannot open\n/usr/local/cvsroot/pgsql/src/test/regress/regression.Solaris-Sparc,v:\nPermission denied\ncvs checkout: cannot open\n/usr/local/cvsroot/pgsql/src/test/regress/regression.Solaris-Sparc,v:\nPermission denied\ncvs checkout: nothing known about\npgsql/src/test/regress/regression.Solaris-Sparc\n$\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 09:57:05 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "cvs problem" }, { "msg_contents": "\nHello\n\nWhat is the rule size for views?\n\nThis seems to have changed in this beta; I have a view that worked in a \nprevious beta but fails to create. \n\"ERROR: DefineQueryRewrite: rule plan string too big.\"\n\nI have about 33 column headings with a join of 5 tables.\n\nI have the latest cvsup tree as of a few minutes ago.\nLinux 2.0.30\npgcc compiler\n\nMichael\n\n* Michael J. Rogan, Network Administrator, 905-624-3020 *\n* Mark IV Industries, F-P Electronics & I.V.H.S. Divisions *\n* [email protected] [email protected] *\n", "msg_date": "Sat, 28 Feb 1998 15:04:56 +0000", "msg_from": "\"Michael J. Rogan\" <[email protected]>", "msg_from_op": false, "msg_subject": "Rule plan size for views?" }, { "msg_contents": "\nFixed, sorry for the delay...\n\n\n\nOn Sat, 28 Feb 1998, Bruce Momjian wrote:\n\n> Still getting these errors:\n> \n> cvs checkout: cannot open\n> /usr/local/cvsroot/pgsql/src/test/regress/regression.Solaris-Sparc,v:\n> Permission denied\n> cvs checkout: cannot open\n> /usr/local/cvsroot/pgsql/src/test/regress/regression.Solaris-Sparc,v:\n> Permission denied\n> cvs checkout: nothing known about\n> pgsql/src/test/regress/regression.Solaris-Sparc\n> $\n> -- \n> Bruce Momjian | 830 Blythe Avenue\n> [email protected] | Drexel Hill, Pennsylvania 19026\n> + If your life is a hard drive, | (610) 353-9879(w)\n> + Christ can be your backup. | (610) 853-3000(h)\n> \n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sat, 28 Feb 1998 15:06:01 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] cvs problem" }, { "msg_contents": "> \n> \n> Hello\n> \n> What is the rule size for views?\n> \n> This seems to have changed in this beta; I have a view that worked in a \n> previous beta but fails to create. \n> \"ERROR: DefineQueryRewrite: rule plan string too big.\"\n> \n> I have about 33 column headings with a join of 5 tables.\n> \n> I have the latest cvsup tree as of a few minutes ago.\n> Linux 2.0.30\n> pgcc compiler\n\nYes. More of the structure elements are dumped into the view than it\nused to. We hoped to allow larger block sizes in 6.3, but no luck.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 22:25:42 -7700 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Rule plan size for views?" } ]
[ { "msg_contents": "I have compiled the perl5 interface and installed it without problem.\n\nA simple script that makes a connection to a database and read a table\nworks , read and print the informtion corectly but it generates the\nfollowing warnings right at the begining of script execution :\n\nwarning: setlocale(LC_CTYPE, \"\") failed.\nwarning: LC_ALL = \"(null)\", LC_CTYPE = \"(null)\", LANG = \"us\",\nwarning: falling back to the \"C\" locale.\n\nI am trying to use that script into a cgi-bin called from within a web\npage but the first lines that must come out from the script execution\nmust be :\n\nContent-type:text/html\n\nand not that warnings ...\n\nThat's why my cgi-bin didn't worked and my web server reports :\nDocuments contain no data.\n\nWhat do I have in order to fix that warning messages ?\n\nThanks in advance,\n(please cc: me directly ,[email protected] ) \n-- \nConstantin Teodorescu\nFLEX Consulting Braila, ROMANIA\n", "msg_date": "Sat, 28 Feb 1998 16:57:55 +0200", "msg_from": "Constantin Teodorescu <[email protected]>", "msg_from_op": true, "msg_subject": "Little problem with perl5 interface" }, { "msg_contents": "Constantin Teodorescu wrote:\n> \n> I have compiled the perl5 interface and installed it without problem.\n> \n> A simple script that makes a connection to a database and read a table\n> works , read and print the informtion corectly but it generates the\n> following warnings right at the begining of script execution :\n> \n> warning: setlocale(LC_CTYPE, \"\") failed.\n> warning: LC_ALL = \"(null)\", LC_CTYPE = \"(null)\", LANG = \"us\",\n> warning: falling back to the \"C\" locale.\n> \n> I am trying to use that script into a cgi-bin called from within a web\n> page but the first lines that must come out from the script execution\n> must be :\n> \n> Content-type:text/html\n> \n> and not that warnings ...\n> \n> That's why my cgi-bin didn't worked and my web server reports :\n> Documents contain no data.\n> \n> What do I have in order to fix that warning messages ?\n> \n> Thanks in advance,\n> (please cc: me directly ,[email protected] )\n> --\n> Constantin Teodorescu\n> FLEX Consulting Braila, ROMANIA\n\n\nthis is perl-related problem. Try perldoc locale. \n\nEdmund\n-- \nEdmund Mergl mailto:[email protected]\nIm Haldenhau 9 http://www.bawue.de/~mergl\n70565 Stuttgart fon: +49 711 747503\nGermany gsm: +49 171 2645325\n", "msg_date": "Sat, 28 Feb 1998 17:45:04 +0100", "msg_from": "Edmund Mergl <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Little problem with perl5 interface" } ]
[ { "msg_contents": "Sorry, I forgot to mention the most important details :\n\nO.S. = RedHat Linux i386 4.2 with 2.0.32 kernel\nPostgreSQL 6.3 snapshot from Feb 23\nHardware : Pentium 200MMX 64 Mb RAM\n\n-- \nConstantin Teodorescu\nFLEX Consulting Braila, ROMANIA\n", "msg_date": "Sat, 28 Feb 1998 17:02:52 +0200", "msg_from": "Constantin Teodorescu <[email protected]>", "msg_from_op": true, "msg_subject": "Re:Little problem with perl5 interface" } ]
[ { "msg_contents": "\nHello\n\nWhat is the best way to deal with ' \" \\ in a char/varchar/text fields?\n\nI have escaped them with \\ which works and pg_dump dumps them correctly \nhowever psql does not accept them. Is there a way to tell psql to pass \nall commands it does not understand?\n\nI need \\\\ \\' \\\" passed through to the database or do I have to write my \nown reload program or modify psql myself?\n\nMichael\n\n* Michael J. Rogan, Network Administrator, 905-624-3020 *\n* Mark IV Industries, F-P Electronics & I.V.H.S. Divisions *\n* [email protected] [email protected] *\n", "msg_date": "Sat, 28 Feb 1998 15:43:49 +0000", "msg_from": "\"Michael J. Rogan\" <[email protected]>", "msg_from_op": true, "msg_subject": "Reload of database with escaped data." }, { "msg_contents": " Hello\n\nLooking at the psql.c file it looks like it already checks to see if it is \nin a quoted string so it seems that it is broken.\nCould someone check the latest tree?\n\nMichael\n\n> \n> What is the best way to deal with ' \" psql.c in a char/varchar/text fields?\n> \n> I have escaped them with \\ which works and pg_dump dumps them correctly \n> however psql does not accept them. Is there a way to tell psql to pass \n> all commands it does not understand?\n> \n> I need \\\\ \\' \\\" passed through to the database or do I have to write my \n> own reload program or modify psql myself?\n> \n> Michael\n> \n> * Michael J. Rogan, Network Administrator, 905-624-3020 *\n> * Mark IV Industries, F-P Electronics & I.V.H.S. Divisions *\n> * [email protected] [email protected] *\n> \n> \n\n* Michael J. Rogan, Network Administrator, 905-624-3020 *\n* Mark IV Industries, F-P Electronics & I.V.H.S. Divisions *\n* [email protected] [email protected] *\n", "msg_date": "Sat, 28 Feb 1998 16:13:01 +0000", "msg_from": "\"Michael J. Rogan\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Reload of database with escaped data." } ]
[ { "msg_contents": "Running \"configure --help\" says that a \"--with-x\" option is available,\nbut makes no mention of \"--with-perl\" or \"--with-tcl\". If someone has\ntime to fix this, they should probably at the same time make a small\nchange to the \"--with-tcl\" handling: I use TK 4.2 and TCL 7.6, and\nthey seem to work just fine. The configure script, however, demands\nto find version 8.0 of both packages. This is probably just a matter\nof adding \"tk42\" and \"tcl76\" to the lists of possible library names to\nbe looked for.\n\nAmazing fact: I already use TK and TCL with other applications, and it\nseems that PostgreSQL actually works with the same versions of these\nlibraries as one of those. Specifically, PostgreSQL 6.3 and Scotty\n2.1.7 can both use TK 4.2 and TCL 7.6. Up until now, I though it was\na fundamental truth, and an element of how the universe works, that\nevery single different TK and/or TCL application must use different,\nunique to that one single application versions of these libraries.\nNow, I have proof positive that there exist two different applications\nthat in their current versions can share a TK/TCL installation! Wow!\n\nOf course, if I'm mistaken, and there is stuff in the PostgreSQL 6.3\ndistribution that needs TK/TCL 8.0 to work right, everything is back\nto normal, and I'll have to install yet another version of them...\n\n-tih (who dislikes TCL almost as much as he dislikes Perl)\n-- \nPopularity is the hallmark of mediocrity. --Niles Crane, \"Frasier\"\n", "msg_date": "Sat, 28 Feb 1998 16:58:07 +0100", "msg_from": "Tom I Helbekkmo <[email protected]>", "msg_from_op": true, "msg_subject": "Just a couple minor nits..." }, { "msg_contents": "On Sat, 28 Feb 1998, Tom I Helbekkmo wrote:\n\n> Running \"configure --help\" says that a \"--with-x\" option is available,\n> but makes no mention of \"--with-perl\" or \"--with-tcl\". \n\nThis goes out to everyone...try out configure now...I've just converted\nover all the -enable/-with options so that they use AC_ARG_{ENABLE,WITH},\nwhich are proper m4 macros, and which provide for the -help options...my\nfirst pass through, I futzed up something that broke configure, but this\ntime through, it appears to be clean...\n\n> If someone has time to fix this, they should probably at the same time\n> make a small change to the \"--with-tcl\" handling: I use TK 4.2 and TCL\n> 7.6, and they seem to work just fine. The configure script, however,\n> demands to find version 8.0 of both packages. This is probably just a\n> matter of adding \"tk42\" and \"tcl76\" to the lists of possible library\n> names to be looked for. \n> \n\n\tTake a look around line 611 in configure.in and let me know what\nyou'd like to have added or changed...\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sat, 28 Feb 1998 16:07:08 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Just a couple minor nits..." }, { "msg_contents": "> \n> Running \"configure --help\" says that a \"--with-x\" option is available,\n> but makes no mention of \"--with-perl\" or \"--with-tcl\". If someone has\n> time to fix this, they should probably at the same time make a small\n> change to the \"--with-tcl\" handling: I use TK 4.2 and TCL 7.6, and\n\nSomeone submitted a patch to do this. I thought it was applied.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 22:47:48 -7700 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Just a couple minor nits..." }, { "msg_contents": "On Sat, Feb 28, 1998 at 04:07:08PM -0400, The Hermit Hacker wrote:\n\n> This goes out to everyone...try out configure now...I've just converted\n> over all the -enable/-with options so that they use AC_ARG_{ENABLE,WITH},\n> which are proper m4 macros, and which provide for the -help options...my\n> first pass through, I futzed up something that broke configure, but this\n> time through, it appears to be clean...\n\nDoesn't work at all here. I've got the March 1 snapshot, and when I\nsay \"--with-tcl --with-perl\", it reports (immediately) that those\noptions are turned on...\n\n\tchecking setting USE_TCL... enabled\n\tchecking setting USE_PERL... enabled\n\n...but that's the last I hear of it. It seems that the USE_TCL and\nUSE_PERL variables are not set properly, because no attempt is made to\nfind the header files and libraries later on.\n\nAs for my observation that the previous releases, tcl7.6 and tk4.2,\nalso seem to work just fine:\n\n> \tTake a look around line 611 in configure.in and let me know what\n> you'd like to have added or changed...\n\nI was thinking something along the lines of:\n\n*** configure.in.orig\tSun Mar 1 09:00:33 1998\n--- configure.in\tSun Mar 1 14:30:04 1998\n***************\n*** 564,570 ****\n then\n TCL_INCDIR=no\n AC_CHECK_HEADER(tcl.h, TCL_INCDIR=)\n! for f in /usr/include /usr/include/tcl8.0 /usr/local/include /usr/local/include/tcl8.0; do\n if test \"$TCL_INCDIR\" = \"no\"; then\n AC_CHECK_HEADER($f/tcl.h, TCL_INCDIR=$f)\n fi\n--- 564,570 ----\n then\n TCL_INCDIR=no\n AC_CHECK_HEADER(tcl.h, TCL_INCDIR=)\n! for f in /usr/include /usr/include/tcl8.0 /usr/include/tcl7.6 /usr/local/include /usr/local/include/tcl8.0 /usr/local/include/tcl7.6; do\n if test \"$TCL_INCDIR\" = \"no\"; then\n AC_CHECK_HEADER($f/tcl.h, TCL_INCDIR=$f)\n fi\n***************\n*** 580,586 ****\n if test \"$USE_TCL\" = \"true\"\n then\n TCL_LIB=\n! for f in tcl8.0 tcl80; do\n if test -z \"$TCL_LIB\"; then\n AC_CHECK_LIB($f, main, TCL_LIB=$f)\n fi\n--- 580,586 ----\n if test \"$USE_TCL\" = \"true\"\n then\n TCL_LIB=\n! for f in tcl8.0 tcl80 tcl7.6 tcl76; do\n if test -z \"$TCL_LIB\"; then\n AC_CHECK_LIB($f, main, TCL_LIB=$f)\n fi\n***************\n*** 610,616 ****\n \n TK_INCDIR=no\n AC_CHECK_HEADER(tk.h, TK_INCDIR=)\n! for f in /usr/include /usr/include/tk8.0 /usr/local/include /usr/local/include/tk8.0; do\n if test \"$TK_INCDIR\" = \"no\"; then\n AC_CHECK_HEADER($f/tk.h, TK_INCDIR=$f)\n fi\n--- 610,616 ----\n \n TK_INCDIR=no\n AC_CHECK_HEADER(tk.h, TK_INCDIR=)\n! for f in /usr/include /usr/include/tk8.0 /usr/include/tk4.2 /usr/local/include /usr/local/include/tk8.0 /usr/local/include/tk4.2; do\n if test \"$TK_INCDIR\" = \"no\"; then\n AC_CHECK_HEADER($f/tk.h, TK_INCDIR=$f)\n fi\n***************\n*** 631,637 ****\n if test \"$USE_TCL\" = \"true\"\n then\n TK_LIB=\n! for f in tk8.0 tk80; do\n if test -z \"$TK_LIB\"; then\n AC_CHECK_LIB($f, main, TK_LIB=$f)\n fi\n--- 631,637 ----\n if test \"$USE_TCL\" = \"true\"\n then\n TK_LIB=\n! for f in tk8.0 tk80 tk4.2 tk42; do\n if test -z \"$TK_LIB\"; then\n AC_CHECK_LIB($f, main, TK_LIB=$f)\n fi\n\n-tih\n-- \nPopularity is the hallmark of mediocrity. --Niles Crane, \"Frasier\"\n", "msg_date": "Sun, 1 Mar 1998 15:06:41 +0100", "msg_from": "Tom I Helbekkmo <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Just a couple minor nits..." } ]
[ { "msg_contents": "\ndarrenk\n\nSo when I do it as a select statement the plan can grow larger than 8K \nbecause I can run the SQL command itself.\n\nHas the plan generation changed in the last week? I was able to create \nanother view in an earlier beta but cannot now.\n\nIs there a way to find out the size of the plan?\n\nMichael\n\n> > \n> > What is the rule size for views?\n> > \n> > This seems to have changed in this beta; I have a view that worked in a \n> > previous beta but fails to create. \n> > \"ERROR: DefineQueryRewrite: rule plan string too big.\"\n> > \n> > I have about 33 column headings with a join of 5 tables.\n> > \n> > I have the latest cvsup tree as of a few minutes ago.\n> > Linux 2.0.30\n> > pgcc compiler\n> \n> The rule plan is stored as a tuple, hence for this release that limit\n> is a little under 8k.\n> \n> For 6.4, you will be able to use a bigger block size, therefore have\n> bigger tuples and this should then work again.\n> \n> Sounds like the plan internally grew (possible w/subselect stuff?!?) and\n> has gone over that 8k limit.\n> \n> I know it's little consolation, but as soon as I can get the variable\n> block size working (actually only breaks in the create_triggers regression\n> test when sorting to disk), I could post it as a patch for 6.3 as well as\n> put it into the 6.4 tree.\n> \n> darrenk\n> \n> \n\n* Michael J. Rogan, Network Administrator, 905-624-3020 *\n* Mark IV Industries, F-P Electronics & I.V.H.S. Divisions *\n* [email protected] [email protected] *\n", "msg_date": "Sat, 28 Feb 1998 16:52:08 +0000", "msg_from": "\"Michael J. Rogan\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> \n> What is the rule size for views?\n> \n> This seems to have changed in this beta; I have a view that worked in a \n> previous beta but fails to create. \n> \"ERROR: DefineQueryRewrite: rule plan string too big.\"\n> \n> I have about 33 column headings with a join of 5 tables.\n> \n> I have the latest cvsup tree as of a few minutes ago.\n> Linux 2.0.30\n> pgcc compiler\n\nThe rule plan is stored as a tuple, hence for this release that limit\nis a little under 8k.\n\nFor 6.4, you will be able to use a bigger block size, therefore have\nbigger tuples and this should then work again.\n\nSounds like the plan internally grew (possible w/subselect stuff?!?) and\nhas gone over that 8k limit.\n\nI know it's little consolation, but as soon as I can get the variable\nblock size working (actually only breaks in the create_triggers regression\ntest when sorting to disk), I could post it as a patch for 6.3 as well as\nput it into the 6.4 tree.\n\ndarrenk\n", "msg_date": "Sat, 28 Feb 1998 15:43:08 -0500", "msg_from": "[email protected] (Darren King)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> Sounds like the plan internally grew (possible w/subselect stuff?!?) and\n> has gone over that 8k limit.\n> \n> I know it's little consolation, but as soon as I can get the variable\n> block size working (actually only breaks in the create_triggers regression\n> test when sorting to disk), I could post it as a patch for 6.3 as well as\n> put it into the 6.4 tree.\n\nSome structure members were skipped in the dump, but now they are\nincluded.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Sat, 28 Feb 1998 23:40:46 -7700 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> \n> > \n> > What is the rule size for views?\n> > \n> > This seems to have changed in this beta; I have a view that worked in a \n> > previous beta but fails to create. \n> > \"ERROR: DefineQueryRewrite: rule plan string too big.\"\n> > \n> > I have about 33 column headings with a join of 5 tables.\n> > \n> > I have the latest cvsup tree as of a few minutes ago.\n> > Linux 2.0.30\n> > pgcc compiler\n> \n> The rule plan is stored as a tuple, hence for this release that limit\n> is a little under 8k.\n> \n> For 6.4, you will be able to use a bigger block size, therefore have\n> bigger tuples and this should then work again.\n> \n> Sounds like the plan internally grew (possible w/subselect stuff?!?) and\n> has gone over that 8k limit.\n\n I think it must be due to the cleanups in the node-print and\n read funcs. They now output/read ALL fields in the nodes.\n\n> \n> I know it's little consolation, but as soon as I can get the variable\n> block size working (actually only breaks in the create_triggers regression\n> test when sorting to disk), I could post it as a patch for 6.3 as well as\n> put it into the 6.4 tree.\n> \n> darrenk\n> \n> \n\n\nJan\n\n\n-- \n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n", "msg_date": "Mon, 2 Mar 1998 09:02:05 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> > Sounds like the plan internally grew (possible w/subselect stuff?!?) and\n> > has gone over that 8k limit.\n>\n> I think it must be due to the cleanups in the node-print and\n> read funcs. They now output/read ALL fields in the nodes.\n\nOh, I didn't realize that the print functions were actually used for something\nother than printing and debugging. I had started to add a few new nodes when I\nwas trying to debug the \"primary key\" code.\n\nShould we go through and bracket some of those with #ifdef QUERYDEBUG or\nsomething like that? Where are they actually used? Should we try to keep these\nat a minimum for production compiles of the system??\n\n - Tom\n\n", "msg_date": "Mon, 02 Mar 1998 13:57:37 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> \n> > > Sounds like the plan internally grew (possible w/subselect stuff?!?) and\n> > > has gone over that 8k limit.\n> >\n> > I think it must be due to the cleanups in the node-print and\n> > read funcs. They now output/read ALL fields in the nodes.\n> \n> Oh, I didn't realize that the print functions were actually used for something\n> other than printing and debugging. I had started to add a few new nodes when I\n> was trying to debug the \"primary key\" code.\n> \n> Should we go through and bracket some of those with #ifdef QUERYDEBUG or\n> something like that? Where are they actually used? Should we try to keep these\n> at a minimum for production compiles of the system??\n\nDid you add stuff to dump that wasn't dumped before, or were they fields\nof existing structure that used to be skipped?\n\nThey are used for the rewrite system and for views.\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 2 Mar 1998 12:05:15 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> > > > Sounds like the plan internally grew (possible w/subselect stuff?!?) and\n> > > > has gone over that 8k limit.\n> > >\n> > > I think it must be due to the cleanups in the node-print and\n> > > read funcs. They now output/read ALL fields in the nodes.\n> >\n> > Oh, I didn't realize that the print functions were actually used for something\n> > other than printing and debugging. I had started to add a few new nodes when I\n> > was trying to debug the \"primary key\" code.\n> >\n> > Should we go through and bracket some of those with #ifdef QUERYDEBUG or\n> > something like that? Where are they actually used? Should we try to keep these\n> > at a minimum for production compiles of the system??\n>\n> Did you add stuff to dump that wasn't dumped before, or were they fields\n> of existing structure that used to be skipped?\n>\n> They are used for the rewrite system and for views.\n\nI added a few nodes (maybe two?), _and_ added some call-outs to existing nodes to\nfollow their children down. This stuff can be bracketed with debugging #ifdef's; it\nwas very helpful for me when debugging but it isn't good if they are adding\nunnecessary limitations on sizes. The additional nodes I added are a \"don't care\";\nit's the additional printing of child nodes (fields of existing structures) which\nis loading things down.\n\nI am not absolutely certain that we are talking about the same thing, so should\nconfirm that it is the same routines which are causing trouble; this is the same\nprinting/formatting code used for \"explain\"??\n\nI'd be happy to help clean them up, but I think you should help too; as I recall we\nwere both mucking around there about the same time ;)\n\n - Tom\n\n", "msg_date": "Mon, 02 Mar 1998 17:48:15 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> I added a few nodes (maybe two?), _and_ added some call-outs to existing nodes to\n> follow their children down. This stuff can be bracketed with debugging #ifdef's; it\n> was very helpful for me when debugging but it isn't good if they are adding\n> unnecessary limitations on sizes. The additional nodes I added are a \"don't care\";\n> it's the additional printing of child nodes (fields of existing structures) which\n> is loading things down.\n\nThe stuff is in nodes/outfuncs.c, and is used in EXPLAIN VERBOSE. I\nquestion whether your structures would actually be output as part of a\nrule.\n\nI hesitate to remove any of the outfuncs stuff. It is very useful, and\nif it is missing, things are harder to debug. Adding the fields I did\nhelped solve several problems I had when testing subselects, and I know\nVadim uses that output too. Shame it goes into the rule, but hard to\nimagine why the rule would not need it, except for fields that are only\nused by the parser, but I think we need to be complete. A better\nsolution would be to allow rewrite rules to span multiple blocks, or a\nleast allow them to take the space of two blocks.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 2 Mar 1998 13:40:22 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "Hi,\n\n>\n> > > > > Sounds like the plan internally grew (possible w/subselect stuff?!?) and\n> > > > > has gone over that 8k limit.\n> > > >\n> > > > I think it must be due to the cleanups in the node-print and\n> > > > read funcs. They now output/read ALL fields in the nodes.\n> > >\n> > > Oh, I didn't realize that the print functions were actually used for something\n> > > other than printing and debugging. I had started to add a few new nodes when I\n> > > was trying to debug the \"primary key\" code.\n> > >\n> > > Should we go through and bracket some of those with #ifdef QUERYDEBUG or\n> > > something like that? Where are they actually used? Should we try to keep these\n> > > at a minimum for production compiles of the system??\n> >\n> > Did you add stuff to dump that wasn't dumped before, or were they fields\n> > of existing structure that used to be skipped?\n> >\n> > They are used for the rewrite system and for views.\n>\n> I added a few nodes (maybe two?), _and_ added some call-outs to existing nodes to\n> follow their children down. This stuff can be bracketed with debugging #ifdef's; it\n> was very helpful for me when debugging but it isn't good if they are adding\n> unnecessary limitations on sizes. The additional nodes I added are a \"don't care\";\n> it's the additional printing of child nodes (fields of existing structures) which\n> is loading things down.\n>\n> I am not absolutely certain that we are talking about the same thing, so should\n> confirm that it is the same routines which are causing trouble; this is the same\n> printing/formatting code used for \"explain\"??\n>\n> I'd be happy to help clean them up, but I think you should help too; as I recall we\n> were both mucking around there about the same time ;)\n\n I think we talk about the same group of functions. But I'm\n not sure if the nodes you're talking about are parsenodes.\n Only parsenodes are printed during rule creation to build the\n querytree string stored in the pg_rewrite catalog (views are\n implemented by rules and do an internal CREATE RULE on CREATE\n VIEW).\n\n Anyway - If your nodes are parsenodes and you didn't created\n the corresponding node readfuncs, I would expect trouble\n during the rewrite handling when the printed rule action is\n parsed back to the backends internal querytree structures.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#======================================== [email protected] (Jan Wieck) #\n\n\n", "msg_date": "Mon, 2 Mar 1998 19:53:26 +0100 (MET)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "Bruce Momjian wrote:\n> \n> > I added a few nodes (maybe two?), _and_ added some call-outs to existing nodes to\n> > follow their children down. This stuff can be bracketed with debugging #ifdef's; it\n> > was very helpful for me when debugging but it isn't good if they are adding\n> > unnecessary limitations on sizes. The additional nodes I added are a \"don't care\";\n> > it's the additional printing of child nodes (fields of existing structures) which\n> > is loading things down.\n> \n> The stuff is in nodes/outfuncs.c, and is used in EXPLAIN VERBOSE. I\n> question whether your structures would actually be output as part of a\n> rule.\n> \n> I hesitate to remove any of the outfuncs stuff. It is very useful, and\n> if it is missing, things are harder to debug. Adding the fields I did\n> helped solve several problems I had when testing subselects, and I know\n> Vadim uses that output too. Shame it goes into the rule, but hard to\n> imagine why the rule would not need it, except for fields that are only\n> used by the parser, but I think we need to be complete. A better\n> solution would be to allow rewrite rules to span multiple blocks, or a\n> least allow them to take the space of two blocks.\n\nOr use LO.\n\nVadim\n", "msg_date": "Tue, 03 Mar 1998 08:43:38 +0700", "msg_from": "\"Vadim B. Mikheev\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> > I hesitate to remove any of the outfuncs stuff. It is very useful, and\n> > if it is missing, things are harder to debug. Adding the fields I did\n> > helped solve several problems I had when testing subselects, and I know\n> > Vadim uses that output too. Shame it goes into the rule, but hard to\n> > imagine why the rule would not need it, except for fields that are only\n> > used by the parser, but I think we need to be complete. A better\n> > solution would be to allow rewrite rules to span multiple blocks, or a\n> > least allow them to take the space of two blocks.\n> \n> Or use LO.\n\nYea, that makes a lot of sense.\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 2 Mar 1998 21:29:17 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "Jan Wieck wrote:\n\n> Hi,\n>\n> >\n> > > > > > Sounds like the plan internally grew (possible w/subselect stuff?!?) and\n> > > > > > has gone over that 8k limit.\n> > > > >\n> > > > > I think it must be due to the cleanups in the node-print and\n> > > > > read funcs. They now output/read ALL fields in the nodes.\n> > > >\n> > > > Oh, I didn't realize that the print functions were actually used for something\n> > > > other than printing and debugging. I had started to add a few new nodes when I\n> > > > was trying to debug the \"primary key\" code.\n> > > >\n> > > > Should we go through and bracket some of those with #ifdef QUERYDEBUG or\n> > > > something like that? Where are they actually used? Should we try to keep these\n> > > > at a minimum for production compiles of the system??\n> > >\n> > > Did you add stuff to dump that wasn't dumped before, or were they fields\n> > > of existing structure that used to be skipped?\n> > >\n> > > They are used for the rewrite system and for views.\n> >\n> > I added a few nodes (maybe two?), _and_ added some call-outs to existing nodes to\n> > follow their children down. This stuff can be bracketed with debugging #ifdef's; it\n> > was very helpful for me when debugging but it isn't good if they are adding\n> > unnecessary limitations on sizes. The additional nodes I added are a \"don't care\";\n> > it's the additional printing of child nodes (fields of existing structures) which\n> > is loading things down.\n> >\n> > I am not absolutely certain that we are talking about the same thing, so should\n> > confirm that it is the same routines which are causing trouble; this is the same\n> > printing/formatting code used for \"explain\"??\n> >\n> > I'd be happy to help clean them up, but I think you should help too; as I recall we\n> > were both mucking around there about the same time ;)\n>\n> I think we talk about the same group of functions. But I'm\n> not sure if the nodes you're talking about are parsenodes.\n> Only parsenodes are printed during rule creation to build the\n> querytree string stored in the pg_rewrite catalog (views are\n> implemented by rules and do an internal CREATE RULE on CREATE\n> VIEW).\n>\n> Anyway - If your nodes are parsenodes and you didn't created\n> the corresponding node readfuncs, I would expect trouble\n> during the rewrite handling when the printed rule action is\n> parsed back to the backends internal querytree structures.\n\nWell, how to we come to a conclusion here? Here are apparently new calls (since v6.2.1)\nin outfuncs.c which could print out something. There are a few, and some may be printed\nas children of parsetree nodes. Anyone have an idea if any of these are in parsetree\nnodes and could be affecting the view and rewrite storage?\n\nbtw, I don't recall doing anything in the readfuncs, so there aren't likely any new\nroutines there.\n\n - Tom\n\n> _outCreateStmt(StringInfo str, CreateStmt *node)\n> _outNode(str, node->tableElts);\n> _outNode(str, node->inhRelnames);\n> _outNode(str, node->constraints);\n> _outIndexStmt(StringInfo str, IndexStmt *node)\n> _outNode(str, node->indexParams);\n> _outNode(str, node->withClause);\n> _outNode(str, node->whereClause);\n> _outNode(str, node->rangetable);\n> _outColumnDef(StringInfo str, ColumnDef *node)\n> _outNode(str, node->typename);\n> _outNode(str, node->constraints);\n> _outTypeName(StringInfo str, TypeName *node)\n> _outNode(str, node->arrayBounds);\n> _outIndexElem(StringInfo str, IndexElem *node)\n> _outNode(str, node->args);\n> _outNode(str, node->tname);\n> case T_CreateStmt:\n> _outNode(str, node->utilityStmt);\n> case T_IndexStmt:\n> _outNode(str, node->utilityStmt);\n> case T_NotifyStmt:\n> _outNode(str, node->sortClause);\n> _outNode(str, node->groupClause);\n> _outNode(str, node->havingQual);\n> _outNode(str, node->unionClause);\n> _outSortClause(StringInfo str, SortClause *node)\n> _outNode(str, node->resdom);\n> _outGroupClause(StringInfo str, GroupClause *node)\n> _outNode(str, node->entry);\n> sprintf(buf, \" :size %d \", node->plan_size);\n> sprintf(buf, \" :width %d \", node->plan_width);\n> _outIntList(str, node->extParam);\n> _outIntList(str, node->locParam);\n> _outNode(str, node->initPlan);\n> _outNode(str, node->unionrts);\n> _outSubPlan(StringInfo str, SubPlan *node)\n> _outNode(str, node->plan);\n> sprintf(buf, \" :planid %u \", node->plan_id);\n> _outNode(str, node->rtable);\n> _outIntList(str, node->setParam);\n> _outIntList(str, node->parParam);\n> _outNode(str, node->sublink);\n> _outNode(str, node->aggs);\n> appendStringInfo(str, node->fj_initialized ? \"true\" : \"false\");\n> sprintf(buf, \" :nNodes %d \", node->fj_nNodes);\n> appendStringInfo(str, (node->fj_alwaysDone[i]) ? \"true\" : \"false\");\n> case SUBPLAN_EXPR:\n> _outNode(str, node->target);\n> _outSubLink(StringInfo str, SubLink *node)\n> _outNode(str, node->lefthand);\n> _outNode(str, node->oper);\n> _outNode(str, node->subselect);\n> _outNode(str, node->expr);\n> _outAExpr(StringInfo str, A_Expr *node)\n> _outNode(str, node->lexpr);\n> _outNode(str, node->rexpr);\n> _outIdent(StringInfo str, Ident *node)\n> _outAConst(StringInfo str, A_Const *node)\n> _outValue(str, &(node->val));\n> case T_CreateStmt:\n> _outCreateStmt(str, obj);\n> case T_IndexStmt:\n> _outIndexStmt(str, obj);\n> case T_ColumnDef:\n> _outColumnDef(str, obj);\n> case T_TypeName:\n> _outTypeName(str, obj);\n> case T_IndexElem:\n> _outIndexElem(str, obj);\n> case T_SortClause:\n> _outSortClause(str, obj);\n> case T_GroupClause:\n> _outGroupClause(str, obj);\n> case T_SubPlan:\n> _outSubPlan(str, obj);\n> case T_SubLink:\n> _outSubLink(str, obj);\n> case T_A_Expr:\n> _outAExpr(str, obj);\n> case T_Ident:\n> _outIdent(str, obj);\n> case T_A_Const:\n> _outAConst(str, obj);\n\n", "msg_date": "Tue, 03 Mar 1998 02:50:07 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "I don't see any of these affecting the rewrite system. They should\nalready have been in the code. Were they not?\n\n> \n> > _outCreateStmt(StringInfo str, CreateStmt *node)\n> > _outNode(str, node->tableElts);\n> > _outNode(str, node->inhRelnames);\n> > _outNode(str, node->constraints);\n> > _outIndexStmt(StringInfo str, IndexStmt *node)\n> > _outNode(str, node->indexParams);\n> > _outNode(str, node->withClause);\n> > _outNode(str, node->whereClause);\n> > _outNode(str, node->rangetable);\n> > _outColumnDef(StringInfo str, ColumnDef *node)\n> > _outNode(str, node->typename);\n> > _outNode(str, node->constraints);\n> > _outTypeName(StringInfo str, TypeName *node)\n> > _outNode(str, node->arrayBounds);\n> > _outIndexElem(StringInfo str, IndexElem *node)\n> > _outNode(str, node->args);\n> > _outNode(str, node->tname);\n> > case T_CreateStmt:\n> > _outNode(str, node->utilityStmt);\n> > case T_IndexStmt:\n> > _outNode(str, node->utilityStmt);\n> > case T_NotifyStmt:\n> > _outNode(str, node->sortClause);\n> > _outNode(str, node->groupClause);\n> > _outNode(str, node->havingQual);\n> > _outNode(str, node->unionClause);\n> > _outSortClause(StringInfo str, SortClause *node)\n> > _outNode(str, node->resdom);\n> > _outGroupClause(StringInfo str, GroupClause *node)\n> > _outNode(str, node->entry);\n> > sprintf(buf, \" :size %d \", node->plan_size);\n> > sprintf(buf, \" :width %d \", node->plan_width);\n> > _outIntList(str, node->extParam);\n> > _outIntList(str, node->locParam);\n> > _outNode(str, node->initPlan);\n> > _outNode(str, node->unionrts);\n> > _outSubPlan(StringInfo str, SubPlan *node)\n> > _outNode(str, node->plan);\n> > sprintf(buf, \" :planid %u \", node->plan_id);\n> > _outNode(str, node->rtable);\n> > _outIntList(str, node->setParam);\n> > _outIntList(str, node->parParam);\n> > _outNode(str, node->sublink);\n> > _outNode(str, node->aggs);\n> > appendStringInfo(str, node->fj_initialized ? \"true\" : \"false\");\n> > sprintf(buf, \" :nNodes %d \", node->fj_nNodes);\n> > appendStringInfo(str, (node->fj_alwaysDone[i]) ? \"true\" : \"false\");\n> > case SUBPLAN_EXPR:\n> > _outNode(str, node->target);\n> > _outSubLink(StringInfo str, SubLink *node)\n> > _outNode(str, node->lefthand);\n> > _outNode(str, node->oper);\n> > _outNode(str, node->subselect);\n> > _outNode(str, node->expr);\n> > _outAExpr(StringInfo str, A_Expr *node)\n> > _outNode(str, node->lexpr);\n> > _outNode(str, node->rexpr);\n> > _outIdent(StringInfo str, Ident *node)\n> > _outAConst(StringInfo str, A_Const *node)\n> > _outValue(str, &(node->val));\n> > case T_CreateStmt:\n> > _outCreateStmt(str, obj);\n> > case T_IndexStmt:\n> > _outIndexStmt(str, obj);\n> > case T_ColumnDef:\n> > _outColumnDef(str, obj);\n> > case T_TypeName:\n> > _outTypeName(str, obj);\n> > case T_IndexElem:\n> > _outIndexElem(str, obj);\n> > case T_SortClause:\n> > _outSortClause(str, obj);\n> > case T_GroupClause:\n> > _outGroupClause(str, obj);\n> > case T_SubPlan:\n> > _outSubPlan(str, obj);\n> > case T_SubLink:\n> > _outSubLink(str, obj);\n> > case T_A_Expr:\n> > _outAExpr(str, obj);\n> > case T_Ident:\n> > _outIdent(str, obj);\n> > case T_A_Const:\n> > _outAConst(str, obj);\n> \n> \n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Mon, 2 Mar 1998 23:07:35 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> I don't see any of these affecting the rewrite system. They should\n> already have been in the code. Were they not?\n\nI recall adding code to print the nodes of a create index statement, and the nodes of a\ntable create statement. I don't quite remember which other ones, but everything listed\nbelow is new since v6.2.1.\n\n> > > _outCreateStmt(StringInfo str, CreateStmt *node)\n> > > _outNode(str, node->tableElts);\n> > > _outNode(str, node->inhRelnames);\n> > > _outNode(str, node->constraints);\n> > > _outIndexStmt(StringInfo str, IndexStmt *node)\n> > > _outNode(str, node->indexParams);\n> > > _outNode(str, node->withClause);\n> > > _outNode(str, node->whereClause);\n> > > _outNode(str, node->rangetable);\n> > > _outColumnDef(StringInfo str, ColumnDef *node)\n> > > _outNode(str, node->typename);\n> > > _outNode(str, node->constraints);\n> > > _outTypeName(StringInfo str, TypeName *node)\n> > > _outNode(str, node->arrayBounds);\n> > > _outIndexElem(StringInfo str, IndexElem *node)\n> > > _outNode(str, node->args);\n> > > _outNode(str, node->tname);\n> > > case T_CreateStmt:\n> > > _outNode(str, node->utilityStmt);\n> > > case T_IndexStmt:\n> > > _outNode(str, node->utilityStmt);\n> > > case T_NotifyStmt:\n> > > _outNode(str, node->sortClause);\n> > > _outNode(str, node->groupClause);\n> > > _outNode(str, node->havingQual);\n> > > _outNode(str, node->unionClause);\n> > > _outSortClause(StringInfo str, SortClause *node)\n> > > _outNode(str, node->resdom);\n> > > _outGroupClause(StringInfo str, GroupClause *node)\n> > > _outNode(str, node->entry);\n> > > sprintf(buf, \" :size %d \", node->plan_size);\n> > > sprintf(buf, \" :width %d \", node->plan_width);\n> > > _outIntList(str, node->extParam);\n> > > _outIntList(str, node->locParam);\n> > > _outNode(str, node->initPlan);\n> > > _outNode(str, node->unionrts);\n> > > _outSubPlan(StringInfo str, SubPlan *node)\n> > > _outNode(str, node->plan);\n> > > sprintf(buf, \" :planid %u \", node->plan_id);\n> > > _outNode(str, node->rtable);\n> > > _outIntList(str, node->setParam);\n> > > _outIntList(str, node->parParam);\n> > > _outNode(str, node->sublink);\n> > > _outNode(str, node->aggs);\n> > > appendStringInfo(str, node->fj_initialized ? \"true\" : \"false\");\n> > > sprintf(buf, \" :nNodes %d \", node->fj_nNodes);\n> > > appendStringInfo(str, (node->fj_alwaysDone[i]) ? \"true\" : \"false\");\n> > > case SUBPLAN_EXPR:\n> > > _outNode(str, node->target);\n> > > _outSubLink(StringInfo str, SubLink *node)\n> > > _outNode(str, node->lefthand);\n> > > _outNode(str, node->oper);\n> > > _outNode(str, node->subselect);\n> > > _outNode(str, node->expr);\n> > > _outAExpr(StringInfo str, A_Expr *node)\n> > > _outNode(str, node->lexpr);\n> > > _outNode(str, node->rexpr);\n> > > _outIdent(StringInfo str, Ident *node)\n> > > _outAConst(StringInfo str, A_Const *node)\n> > > _outValue(str, &(node->val));\n> > > case T_CreateStmt:\n> > > _outCreateStmt(str, obj);\n> > > case T_IndexStmt:\n> > > _outIndexStmt(str, obj);\n> > > case T_ColumnDef:\n> > > _outColumnDef(str, obj);\n> > > case T_TypeName:\n> > > _outTypeName(str, obj);\n> > > case T_IndexElem:\n> > > _outIndexElem(str, obj);\n> > > case T_SortClause:\n> > > _outSortClause(str, obj);\n> > > case T_GroupClause:\n> > > _outGroupClause(str, obj);\n> > > case T_SubPlan:\n> > > _outSubPlan(str, obj);\n> > > case T_SubLink:\n> > > _outSubLink(str, obj);\n> > > case T_A_Expr:\n> > > _outAExpr(str, obj);\n> > > case T_Ident:\n> > > _outIdent(str, obj);\n> > > case T_A_Const:\n> > > _outAConst(str, obj);\n\n\n\n", "msg_date": "Tue, 03 Mar 1998 05:49:56 +0000", "msg_from": "\"Thomas G. Lockhart\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" }, { "msg_contents": "> \n> > I don't see any of these affecting the rewrite system. They should\n> > already have been in the code. Were they not?\n> \n> I recall adding code to print the nodes of a create index statement, and the nodes of a\n> table create statement. I don't quite remember which other ones, but everything listed\n> below is new since v6.2.1.\n\nI think I added many of these to fixed rule problems.\n\n> \n> > > > _outCreateStmt(StringInfo str, CreateStmt *node)\n> > > > _outNode(str, node->tableElts);\n> > > > _outNode(str, node->inhRelnames);\n> > > > _outNode(str, node->constraints);\n> > > > _outIndexStmt(StringInfo str, IndexStmt *node)\n> > > > _outNode(str, node->indexParams);\n> > > > _outNode(str, node->withClause);\n> > > > _outNode(str, node->whereClause);\n> > > > _outNode(str, node->rangetable);\n\n\n-- \nBruce Momjian | 830 Blythe Avenue\[email protected] | Drexel Hill, Pennsylvania 19026\n + If your life is a hard drive, | (610) 353-9879(w)\n + Christ can be your backup. | (610) 853-3000(h)\n", "msg_date": "Tue, 3 Mar 1998 00:58:38 -0500 (EST)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Rule plan size for views?" } ]
[ { "msg_contents": "Hi:\nIs create domain command implemented in 6.3??\nI am trying to use\n create domain employed as char(10)\n check (\nvalue = \"YES\" or\nvalue = \"NO\" or\nvalue = \"RETIRED\" or\nvalue = \"DISABLED\" or\nvalue is NULL\n);\nin SQL scripts but is failing in 6.2.1 postgresql.\n\nI can find work around BUT there are tons of create domains in my SQL\nscripts and will be very tedious.\nBy the way, create domain is in defined in SQL 92\nsee this chapter 42 in\nhttp://sunsite.unc.edu/LDP/HOWTO/Database-HOWTO.html\n\nal\n\"This world is wasting billions of dollars and millions manhours\nre-inventing the TECHNOLOGY WHEELS!!\"\n_________________________________________________________\nDO YOU YAHOO!?\nGet your free @yahoo.com address at http://mail.yahoo.com\n\n", "msg_date": "Sat, 28 Feb 1998 08:57:48 -0800 (PST)", "msg_from": "al dev <[email protected]>", "msg_from_op": true, "msg_subject": "Is \"CREATE DOMAIN\" in 6.3 ??" }, { "msg_contents": "On Sat, 28 Feb 1998, al dev wrote:\n\n> Hi:\n> Is create domain command implemented in 6.3??\n> I am trying to use\n> create domain employed as char(10)\n> check (\n> value = \"YES\" or\n> value = \"NO\" or\n> value = \"RETIRED\" or\n> value = \"DISABLED\" or\n> value is NULL\n> );\n> in SQL scripts but is failing in 6.2.1 postgresql.\n> \n> I can find work around BUT there are tons of create domains in my SQL\n> scripts and will be very tedious.\n> By the way, create domain is in defined in SQL 92\n> see this chapter 42 in\n> http://sunsite.unc.edu/LDP/HOWTO/Database-HOWTO.html\n\n\tI took a look here, and it didn't say (at least not in chapter\n42)...what exactly does 'create domain' do? We don't, and won't, have it\nfor v6.3, not with a release in a few days, and since I do recall anyone\nelse having mentioned it before, it isn't on our TODO list, but sounds\nlike something else to be added...\n\n\tBut, a short description of what it does would be nice, as I've\nnever heard of that one before :)\n\nMarc G. Fournier \nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sat, 28 Feb 1998 16:10:28 -0400 (AST)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Is \"CREATE DOMAIN\" in 6.3 ??" }, { "msg_contents": "At 22:10 +0200 on 28/2/98, The Hermit Hacker wrote:\n\n> \tI took a look here, and it didn't say (at least not in chapter\n> 42)...what exactly does 'create domain' do? We don't, and won't, have it\n> for v6.3, not with a release in a few days, and since I do recall anyone\n> else having mentioned it before, it isn't on our TODO list, but sounds\n> like something else to be added...\n>\n> \tBut, a short description of what it does would be nice, as I've\n> never heard of that one before :)\n\nThe idea, I think, is to define datatypes so that fields which are supposed\nlogically to be of the same kind will all have the same domain. Thus, if\nthe domain is later changed (say, implementation is changed from money to\nfloat), all fields defined that way are changed together.\n\nThis is from SQL 1992:\n\n A domain is a set of permissible values. A domain is defined in\n a schema and is identified by a <domain name>. The purpose of a\n domain is to constrain the set of valid values that can be stored\n in SQL-data by various operations.\n\n A domain definition specifies a data type. It may also specify a\n <domain constraint> that further restricts the valid values of the\n domain and a <default clause> that specifies the value to be used\n in the absence of an explicitly specified value or column default.\n\n A domain is described by a domain descriptor. A domain descriptor\n includes:\n\n - the name of the domain;\n\n - the data type descriptor of the data type of the domain;\n\n - the <collation name> from the <collate clause>, if any, of the\n domain;\n\n - the value of <default option>, if any, of the domain; and\n\n - the domain constraint descriptors of the domain constraints, if\n any, of the domain.\n\nThe syntax:\n\n <domain definition> ::=\n CREATE DOMAIN <domain name> [ AS ] <data type>\n [ <default clause> ]\n [ <domain constraint>... ]\n [ <collate clause> ]\n\n <domain constraint> ::=\n [ <constraint name definition> ]\n <check constraint definition> [ <constraint attributes> ]\n\nI won't quote the entire syntax rules from SQL 1992 - I'm sure someone out\nthere has a copy. In any case, this is NOT Entry-Level SQL 1992, but rather\nIntermediate Level.\n\nHerouth\n\n\n", "msg_date": "Sun, 1 Mar 1998 12:25:30 +0200", "msg_from": "Herouth Maoz <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [QUESTIONS] Re: [HACKERS] Is \"CREATE DOMAIN\" in 6.3 ??" } ]
[ { "msg_contents": "\nSent two patches tonite to fix the tutorial. Couple of people had\nmentioned it being broken on questions, don't know if it was broke for\neveryone of just certain ports.\n\nFixed the Makefile, updated the README, added semicolons after every\nstatement and added to complex.source to delete all that it created.\n\nDarren [email protected]\n", "msg_date": "Sat, 28 Feb 1998 19:45:27 -0500", "msg_from": "[email protected] (Darren King)", "msg_from_op": true, "msg_subject": "Tutorial fixed." } ]
[ { "msg_contents": "> darrenk\n>\n\nJust 'Darren' for short. :)\n\n> So when I do it as a select statement the plan can grow larger than 8K \n> because I can run the SQL command itself.\n\nThe plan is the internal plan generated by the parser/optimizer. A very\nshort sql statement could generate a very big plan. No real easy way to\ntell without actually running it.\n\n> Has the plan generation changed in the last week? I was able to create \n> another view in an earlier beta but cannot now.\n\nThis I don't know. Any little change to the nodes or the parser/optimizer\ncould have bumped you over the limit. \n\n> Is there a way to find out the size of the plan?\n\nCould add some debugging statements in the rewrite code to show it. Snoop\naround the src/backend/rewrite directory a little.\n\nDarren\n", "msg_date": "Sat, 28 Feb 1998 19:53:17 -0500", "msg_from": "[email protected] (Darren King)", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Rule plan size for views?" } ]