pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jim Rowan <jmr@computing.com>
To: jwieck@debis.com
Cc: ertz@illite.u-strasbg.fr
Cc: pgsql-sql@postgreSQL.org
Subject: Re: [SQL] RewriteDefine.c : Rule size
Date: Thu, 08 Jul 1999 23:25:04 -0500
Message-ID: <199907090425.XAA12140@zee.computing.com> (raw)
In-Reply-To: <m112H3w-0003ktC@orion.SAPserv.Hamburg.dsh.de>

>> I'm using Postgres 6.4.2.  I want to create a view, but a message appear :
>> ERROR: DefineQueryRewrite: rule plan string too big.  What could be the
>> solution to avoid the problem? In fact, I have 31 columns in a table, and
>> i want to make a view on this table (with a line restrict = WHERE clause).

I get the same error from 6.5 when I create rules that are apparently too
complex.  My table has 25 or so columns.. 


>> I watched the RewriteDefine.c code and saw : #define RULE_PLAN_SIZE BLCKSZ
>> I thought changing the value of this size, but I don't find the place to
>> modify the BLCKSZ value.  But, before doing the modification and
>> recompile, I would like to have your opinion on the problem...perhaps is
>> there an easier way to resolve the problem.

wieck>     Never did it, but the BLCKSZ is defined in include/config.h.  That
wieck> is a file generated from config.h.in, so be sure to change it there
wieck> and reconfigure before recompiling.


Be careful here.  We changed BLCKSZ and found some scary results: 

First we multiplied it * 4.  This improved the ability to handle complex
rules, but didn't go far enough... (it still wouldn't handle all of what we
wanted it to). 

So we multiplied it * 8.  Initdb complained about "float4 not defined".  (As
I recall.. I'm not where the error message is and thus this may not be 100%
accurate...).  

We quickly changed it back to the original size and are implementing
alternative rules...  I can understand if it doesn't have enough working
space to do what I ask (or whatever the details are behind "rule plan string
too big") but if changing BLCKSZ breaks builtin types -- I don't want to mess 
with it!!!



view thread (6+ messages)  latest in thread

Message-ID: <199907090425.XAA12140@zee.computing.com>
Permalink:  ../199907090425.XAA12140@zee.computing.com/
Also on:    postgresql.org/message-id/199907090425.XAA12140@zee.computing.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: jmr@computing.com, jwieck@debis.com, ertz@illite.u-strasbg.fr
  Subject: Re: [SQL] RewriteDefine.c : Rule size
  In-Reply-To: <199907090425.XAA12140@zee.computing.com>
  References: <m112H3w-0003ktC@orion.SAPserv.Hamburg.dsh.de> <199907090425.XAA12140@zee.computing.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox