2010年5月11日星期二

[fw-db] reset iterator after fetchRow

Hi,

I have a fetchRow on a table.
After this fetchRow I have another query, using the same object.
But it seems I have to close the connection first, so the object is neutral again.

How should i do this?

Example in function 1
#sel = $this->where('code = :code')
       ->bind(array(':code'=>code))
$result = $this->fetchRow($sel);
return $result;

And after that in funtion 2 the where is not present on 'code' but it is still in the $this.

Tahnks,
Mark




没有评论: