MySQL Forums
Forum List  »  Connector/C (libmysql)

UDF_INIT * initid->const_item
Posted by: Roland Bouman
Date: December 02, 2005 03:18AM

The UDF_INIT struct passed to UDF's contains a const_item member. It is not documented in the manual, but in mysql_com.h a comment sais this:

my_bool const_item; /* 0 if result is independent of arguments */

Does anyone know the exact semantics of this one?

I mean, the name suggests it should be set to TRUE to mark your udf as a constant. However this does not cover the meaning of "...independent of arguments..." : i can have a function that is neither constant, nor dependant upon the arguments.

Also, the comment suggests we should set it to 0 to mark it , i expected to need to set it to 1, not 0

So what is it?

Edited 1 time(s). Last edit at 12/02/2005 03:32AM by Roland Bouman.

Options: ReplyQuote

Written By
UDF_INIT * initid->const_item
December 02, 2005 03:18AM
December 05, 2005 07:06PM
December 06, 2005 03:19AM
December 06, 2005 04:58AM
December 06, 2005 03:43AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.