[Serdev] Nested MySQL queries

Jan Janak jan at iptel.org
Mon Sep 19 18:34:04 UTC 2005


On 19-09-2005 20:23, Andreas Granig wrote:
> Jan Janak wrote:
> >>Another possibility which is more elegant IMHO is storing the result in 
> >>a void-pointer in db_res_t, where it logically belongs to. Would this be 
> >>a passable solution?
> >
> >
> >  I don't know what is the internal structure of the data in mysqlclient
> >  library, the strings are zero terminated so most likely each of them
> >  has its own memory chunk.
> 
> No, what I mean is storing the MYSQL_RES pointer into a data pointer of 
> db_res_t like it is done with the connection as tail-pointer in db_con_t.

  I am not sure I understand, the data is gone if you call
  mysql_free_result. The function frees all memory used to hold the
  result.

    Jan.




More information about the Serdev mailing list