From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | pgsql-hackers(at)postgreSQL(dot)org |
Subject: | A further thought on rule string size |
Date: | 2000-02-27 22:39:07 |
Message-ID: | 17072.951691147@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Looking at the example I just cited, it's hard to avoid noticing how
much space is being used on purely-decorative field labels.
For example,
{ TARGETENTRY :resdom { RESDOM :resno 1 :restype 23 :restypmod -1
:resname f1 :reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk false }
:expr { VAR :varno 3 :varattno 1 :vartype 23 :vartypmod -1
:varlevelsup 0 :varnoold 3 :varoattno 1}}
doesn't really contain any information that's not in
{ TARGETENTRY { RESDOM 1 23 -1 f1 0 0 0 false } { VAR 3 1 23 -1 0 3 1}}
which takes a third as much space. Now I think I'd want to stick with
the more-verbose form for EXPLAIN output and debugging displays, but
I wonder if it isn't worth while to strip the labels from stored rule
strings.
Removing the labels would actually save code in readfuncs.c, which
wouldn't have to skip over them. In outfuncs.c, we could either
have every node-writing subroutine know about two output modes, or
make a post-pass that strips anything that looks like a field label.
The latter would be less maintenance work in the long run.
Comments?
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Keith Parks | 2000-02-27 23:42:00 | Rogue line in regression resultmap file. |
Previous Message | Don Baccus | 2000-02-27 22:16:24 | Re: [HACKERS] type coerce problem with lztext |