Re: [HACKERS] GIST_LEAF vs. leaf_key; gist?entryinit

2003-03-03 Thread Teodor Sigaev
gistPageAddItem doesn't used. Look at mail archive, it was a discussion about
keep thes or not. Shortly: gistPageAddItem suppose to recompress entry, but we 
can't
find any reason to do it.  One more - gistPageAddItem works only with
single-key indexes.

Itai Zukerman wrote:
In the examples I've seen, in the consistent method we have:

  if (GIST_LEAF(entry)) [...]

but in compress we have:

  if (entry-leafkey) [...]

I can see what the latter's doing, but I'm not sure what GIST_LEAF
does, or why you'd want to use it.
Also, I noticed this in src/backend/access/gist:

  static void gistcentryinit(GISTSTATE *giststate, int nkey,
 GISTENTRY *e, Datum k,
 Relation r, Page pg,
 OffsetNumber o, int b, bool l, bool isNull);
and later (in gistPageAddItem):

gistcentryinit(giststate, 0, tmpcentry, dentry-key, r, page,
   offsetNumber, dentry-bytes, FALSE);
Isn't the call missing the isNull parameter?

--
Teodor Sigaev
[EMAIL PROTECTED]


---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]


[HACKERS] GIST_LEAF vs. leaf_key; gist?entryinit

2003-02-28 Thread Itai Zukerman
In the examples I've seen, in the consistent method we have:

  if (GIST_LEAF(entry)) [...]

but in compress we have:

  if (entry-leafkey) [...]

I can see what the latter's doing, but I'm not sure what GIST_LEAF
does, or why you'd want to use it.

Also, I noticed this in src/backend/access/gist:

  static void gistcentryinit(GISTSTATE *giststate, int nkey,
 GISTENTRY *e, Datum k,
 Relation r, Page pg,
 OffsetNumber o, int b, bool l, bool isNull);

and later (in gistPageAddItem):

gistcentryinit(giststate, 0, tmpcentry, dentry-key, r, page,
   offsetNumber, dentry-bytes, FALSE);

Isn't the call missing the isNull parameter?

-- 
Itai Zukerman  http://www.math-hat.com/~zukerman/

---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster