List:Internals« Previous MessageNext Message »
From:Michael Widenius Date:August 21 2008 10:35am
Subject:Re: About evaluation of expressions
View as plain text  
Hi!

>>>>> "Nihal" == Nihal Dindar <dindarn@stripped> writes:

Nihal> Hi,
Nihal> Thank you very much for your reply, but I still couldn't figure out how 
Nihal> to solve the problem.

Michael-> To be able to help you we would need more information at which place in the
code you need access to the data for an old/new record.

Nihal> I do work on finding specified(at query) patterns between rows for my 
Nihal> thesis.  Because of this reason,  at execution phase I need to move 
Nihal> between some rows and run the expression on both old and current rows 
Nihal> [sql/sql_select.cc,  inside evaluate_join_record method].

Nihal> Where does it specified the record that val_xxx run on? In 
table-> record[], join_tab->readrecord.record or somewhere else?

Normally in table->record[],

The exception is in case of 'summary records', like those generated by
the seoond phase of "select field,count(*) from table group by field".
For the second phase there is no easy way for you to get access to
other rows, but that shouldn't be relevant for you.

Michael-> The record data is normally in table->record_buffer[]. The length of this
buffer is table->reclength.

Nihal> I am using the code of mysql-6.0.3-alpha and table doesn't have 
Nihal> reclength field. Should I use table->s->reclength instead?

Yes.  table->s is a shared structure that holds all constants that are
equal for two table objects from the same table.

Regards,
Monty
Thread
About evaluation of expressionsNihal Dindar15 Aug
Re: About evaluation of expressionsMichael Widenius17 Aug
Re: About evaluation of expressionsMichael Widenius21 Aug