List:Internals« Previous MessageNext Message »
From:Vyacheslav Akhmechet Date:May 1 2009 6:12pm
Subject:Questions about write_row and rnd_next
View as plain text  
Hi,

When MySQL calls storage engine's write_row, is there a way to quickly
find out the size of the data in the buffer passed as the first
parameter? Currently I use table->s->reclength, but from what I
understand this value is constant for fixed length rows, so I am not
handling variable length rows correctly. If I simply want to write out
the buffer without picking apart the fields, can I find out its size?
Also, how are BLOBs handled? I understand that rows just store
pointers (file offsets) to them, but is there a special callback
storage engines need to implement for storing BLOBs?

Similarly, what is the maximum size of the buffer passed to rnd_next?
There must be a limit to how much I can write to the buffer, but what
is it?

Also, a related question. I understand that when write_row is called,
table->field points to field structures that contain values for the
row in question (so the server sets up the structures every time
before calling write_row). Is this correct?

Regards,
- Slava
Thread
Questions about write_row and rnd_nextVyacheslav Akhmechet1 May
  • Re: Questions about write_row and rnd_nextIvan Novick1 May
    • Re: Questions about write_row and rnd_nextVyacheslav Akhmechet6 May
      • Re: Questions about write_row and rnd_nextKristian Nielsen6 May
        • Re: Questions about write_row and rnd_nextVyacheslav Akhmechet6 May
          • Re: Questions about write_row and rnd_nextKristian Nielsen6 May
            • Re: Questions about write_row and rnd_nextVyacheslav Akhmechet6 May
              • Re: Questions about write_row and rnd_nextKristian Nielsen6 May
                • Re: Questions about write_row and rnd_nextVyacheslav Akhmechet6 May
  • question on storage engine API rnd_endZhixuan Zhu15 May
  • RE: Questions about write_row and rnd_nextZhixuan Zhu15 May