[PHP-CVS] cvs: php4 /ext/mnogosearch README

2001-03-02 Thread Sergey Kartashoff

gluke   Fri Mar  2 04:14:20 2001 EDT

  Modified files:  
/php4/ext/mnogosearch   README 
  Log:
  # TODO updates in mnoGoSearch module README
  
  
Index: php4/ext/mnogosearch/README
diff -u php4/ext/mnogosearch/README:1.6 php4/ext/mnogosearch/README:1.7
--- php4/ext/mnogosearch/README:1.6 Thu Feb 22 05:02:37 2001
+++ php4/ext/mnogosearch/README Fri Mar  2 04:14:20 2001
@@ -1,5 +1,5 @@
 $Source: /local/repository/php4/ext/mnogosearch/README,v $
-$Id: README,v 1.6 2001/02/22 13:02:37 gluke Exp $
+$Id: README,v 1.7 2001/03/02 12:14:20 gluke Exp $
 
 mnoGoSearch extension module for PHP4.
 
@@ -13,8 +13,7 @@
   TODO
   
 
-1. Implement all mnoGoSearch functions and update module
-   accoding to the latest version of mnoGoSearch.
+1. Implement native ispell functions. 
 
-2. Test with more databases. Currently tested with MySQL.
-Actually it should work fine with other supported databases.
+2. Implement indexing functions of the library.
+   For example retrieving, parsing, checking of the URL and so on...



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/mnogosearch README

2001-02-22 Thread Sergey Kartashoff

gluke   Thu Feb 22 05:02:37 2001 EDT

  Modified files:  
/php4/ext/mnogosearch   README 
  Log:
  README for mnoGoSearch module updated.
  
  
Index: php4/ext/mnogosearch/README
diff -u php4/ext/mnogosearch/README:1.5 php4/ext/mnogosearch/README:1.6
--- php4/ext/mnogosearch/README:1.5 Mon Feb  5 05:12:15 2001
+++ php4/ext/mnogosearch/README Thu Feb 22 05:02:37 2001
@@ -1,9 +1,10 @@
 $Source: /local/repository/php4/ext/mnogosearch/README,v $
-$Id: README,v 1.5 2001/02/05 13:12:15 gluke Exp $
+$Id: README,v 1.6 2001/02/22 13:02:37 gluke Exp $
 
 mnoGoSearch extension module for PHP4.
-mnoGoSearch function implementation.
 
+For details please refer to http://search.mnogo.ru
+
 If used with mysql you should not use bundled mysql library 
 in the php distribution. You should use native mysql 
 library. To do this you should compile php with specefying mysql-dir
@@ -11,14 +12,9 @@
 
   TODO
   
-
-1. Implement all mnoGoSearch functions.
 
-2. Fix  config.m4 to detect whether mnoGoSearch is actually installed.
-Currently there is no any checking. ./configure just trust that mnoGoSearch
-does exist.
+1. Implement all mnoGoSearch functions and update module
+   accoding to the latest version of mnoGoSearch.
 
-3. Test with more databases. Currently tested with MySQL.
+2. Test with more databases. Currently tested with MySQL.
 Actually it should work fine with other supported databases.
-
-4. Write PHP interface documentation.



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/mnogosearch README php_mnogo.c php_mnogo.h test.php

2001-02-05 Thread Sergey Kartashoff

gluke   Mon Feb  5 05:12:15 2001 EDT

  Modified files:  
/php4/ext/mnogosearch   README php_mnogo.c php_mnogo.h test.php 
  Log:
  Added new Udm_Add_Search_Limit mnoGoSearch extension function.
  Some bugfixes and example update.
  @- Added new Udm_Add_Search_Limit mnoGoSearch extension function.
  @  Some bugfixes and example update. (gluke)
  
  
Index: php4/ext/mnogosearch/README
diff -u php4/ext/mnogosearch/README:1.4 php4/ext/mnogosearch/README:1.5
--- php4/ext/mnogosearch/README:1.4 Mon Feb  5 00:42:53 2001
+++ php4/ext/mnogosearch/README Mon Feb  5 05:12:15 2001
@@ -1,8 +1,8 @@
 $Source: /local/repository/php4/ext/mnogosearch/README,v $
-$Id: README,v 1.4 2001/02/05 08:42:53 gluke Exp $
+$Id: README,v 1.5 2001/02/05 13:12:15 gluke Exp $
 
 mnoGoSearch extension module for PHP4.
-Basic mnoGoSearch function implementation.
+mnoGoSearch function implementation.
 
 If used with mysql you should not use bundled mysql library 
 in the php distribution. You should use native mysql 
@@ -12,7 +12,7 @@
   TODO
   
 
-1. Implement more mnoGoSearch functions.
+1. Implement all mnoGoSearch functions.
 
 2. Fix  config.m4 to detect whether mnoGoSearch is actually installed.
 Currently there is no any checking. ./configure just trust that mnoGoSearch
Index: php4/ext/mnogosearch/php_mnogo.c
diff -u php4/ext/mnogosearch/php_mnogo.c:1.6 php4/ext/mnogosearch/php_mnogo.c:1.7
--- php4/ext/mnogosearch/php_mnogo.c:1.6Mon Feb  5 00:42:53 2001
+++ php4/ext/mnogosearch/php_mnogo.cMon Feb  5 05:12:15 2001
@@ -1,5 +1,5 @@
 /* $Source: /local/repository/php4/ext/mnogosearch/php_mnogo.c,v $ */
-/* $Id: php_mnogo.c,v 1.6 2001/02/05 08:42:53 gluke Exp $ */
+/* $Id: php_mnogo.c,v 1.7 2001/02/05 13:12:15 gluke Exp $ */
 
 /*
+--+
@@ -51,6 +51,12 @@
 #define UDM_PARAM_STOPTABLE7
 #define UDM_PARAM_STOPFILE 8
 
+/* udm_add_search_limit constants */
+#define UDM_LIMIT_URL  1
+#define UDM_LIMIT_TAG  2
+#define UDM_LIMIT_LANG 3
+#define UDM_LIMIT_CAT  4
+
 #define UDM_TRACK_ENABLED  1
 #define UDM_TRACK_DISABLED 0
 
@@ -66,6 +72,7 @@
 function_entry mnogosearch_functions[] = {
PHP_FE(udm_alloc_agent, NULL)
PHP_FE(udm_set_agent_param, NULL)
+   PHP_FE(udm_add_search_limit,NULL)
PHP_FE(udm_free_agent,  NULL)
 
PHP_FE(udm_errno,   NULL)
@@ -133,6 +140,12 @@
REGISTER_LONG_CONSTANT("UDM_PARAM_STOPTABLE",UDM_PARAM_STOPTABLE,CONST_CS | 
CONST_PERSISTENT);  
REGISTER_LONG_CONSTANT("UDM_PARAM_STOPFILE",UDM_PARAM_STOPFILE,CONST_CS | 
CONST_PERSISTENT);

+   /* udm_add_search_limit constants */
+   REGISTER_LONG_CONSTANT("UDM_LIMIT_CAT",UDM_LIMIT_CAT,CONST_CS | 
+CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT("UDM_LIMIT_URL",UDM_LIMIT_URL,CONST_CS | 
+CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT("UDM_LIMIT_TAG",UDM_LIMIT_TAG,CONST_CS | 
+CONST_PERSISTENT);  
+   REGISTER_LONG_CONSTANT("UDM_LIMIT_LANG",UDM_LIMIT_LANG,CONST_CS | 
+CONST_PERSISTENT);
+   
/* udm_get_res_param constants */
REGISTER_LONG_CONSTANT("UDM_PARAM_FOUND",UDM_PARAM_FOUND,CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("UDM_PARAM_NUM_ROWS",UDM_PARAM_NUM_ROWS,CONST_CS | 
CONST_PERSISTENT);
@@ -353,8 +366,67 @@

break;

+   default:
+   php_error(E_WARNING,"Udm_Set_Agent_Param: Unknown agent 
+session parameter");
+   RETURN_FALSE;
+   break;
+   }
+   RETURN_TRUE;
+}
+/* }}} */
+
+
+/* {{{ proto int udm_add_search_limit(int agent, int var, string val)
+   Add mnoGoSearch search restrictions */
+DLEXPORT PHP_FUNCTION(udm_add_search_limit)
+{
+   pval **yyagent, **yyvar, **yyval;
+   char *val;
+   int var;
+   UDM_AGENT * Agent;
+
+   switch(ZEND_NUM_ARGS()){
+   
+   case 3: 
+   if(zend_get_parameters_ex(3,&yyagent,&yyvar,&yyval)==FAILURE){
+   RETURN_FALSE;
+   }
+   convert_to_long_ex(yyvar);
+   convert_to_string_ex(yyval);
+   ZEND_FETCH_RESOURCE(Agent, UDM_AGENT *, yyagent, -1, 
+"mnoGoSearch-agent", le_link);
+   var = (*yyvar)->value.lval;
+   val = (*yyval)->value.str.val;
+   
+   break;
+   
+   default:
+   WRONG_PARAM_COUNT;
+   break;
+   }
+   
+   switch(var){
+   case UDM_LIMIT_URL: 
+   UdmAddURLLimit(Agent->Conf,val);
+   
+   break;
+   
+   case UDM

[PHP-CVS] cvs: php4 /ext/mnogosearch README php_mnogo.c php_mnogo.h

2001-02-05 Thread Sergey Kartashoff

gluke   Mon Feb  5 00:42:54 2001 EDT

  Modified files:  
/php4/ext/mnogosearch   README php_mnogo.c php_mnogo.h 
  Log:
  Fixed mnogosearch protos. Fixed mnogosearch functions return values.
  A bug with capital letters break search has been fixed.
  @- Fixed mnogosearch protos. Fixed mnogosearch functions return values.
  @  A bug with capital letters break search has been fixed. (gluke)
  
  
Index: php4/ext/mnogosearch/README
diff -u php4/ext/mnogosearch/README:1.3 php4/ext/mnogosearch/README:1.4
--- php4/ext/mnogosearch/README:1.3 Fri Feb  2 04:54:14 2001
+++ php4/ext/mnogosearch/README Mon Feb  5 00:42:53 2001
@@ -1,5 +1,5 @@
 $Source: /local/repository/php4/ext/mnogosearch/README,v $
-$Id: README,v 1.3 2001/02/02 12:54:14 gluke Exp $
+$Id: README,v 1.4 2001/02/05 08:42:53 gluke Exp $
 
 mnoGoSearch extension module for PHP4.
 Basic mnoGoSearch function implementation.
@@ -12,14 +12,13 @@
   TODO
   
 
-1. Implement more UdmSearch functions.
+1. Implement more mnoGoSearch functions.
 
-2. Fix  config.m4 to detect whether UdmSearch is actually installed.
-Currently there is no any checking. ./configure just trust that UdmSearch
+2. Fix  config.m4 to detect whether mnoGoSearch is actually installed.
+Currently there is no any checking. ./configure just trust that mnoGoSearch
 does exist.
 
-3. Test with more databases. Currently tested with MySQL which is compiled into
-PHP4 by default and does not require any additional UdmSearch libraries.
-  Actually it should work fine with other supported database.
+3. Test with more databases. Currently tested with MySQL.
+Actually it should work fine with other supported databases.
 
 4. Write PHP interface documentation.
Index: php4/ext/mnogosearch/php_mnogo.c
diff -u php4/ext/mnogosearch/php_mnogo.c:1.5 php4/ext/mnogosearch/php_mnogo.c:1.6
--- php4/ext/mnogosearch/php_mnogo.c:1.5Fri Feb  2 07:49:58 2001
+++ php4/ext/mnogosearch/php_mnogo.cMon Feb  5 00:42:53 2001
@@ -1,5 +1,5 @@
 /* $Source: /local/repository/php4/ext/mnogosearch/php_mnogo.c,v $ */
-/* $Id: php_mnogo.c,v 1.5 2001/02/02 15:49:58 eschmid Exp $ */
+/* $Id: php_mnogo.c,v 1.6 2001/02/05 08:42:53 gluke Exp $ */
 
 /*
+--+
@@ -174,7 +174,7 @@
 }
 
 
-/* {{{ proto int mnogosearch_alloc_agent(string dbaddr [, string dbmode])
+/* {{{ proto int udm_alloc_agent(string dbaddr [, string dbmode])
Allocate mnoGoSearch session */
 DLEXPORT PHP_FUNCTION(udm_alloc_agent)
 {
@@ -233,7 +233,7 @@
 /* }}} */
 
 
-/* {{{ proto int udm_set_agent_param(string agent, int var, string val)
+/* {{{ proto int udm_set_agent_param(int agent, int var, string val)
Set mnoGoSearch agent session parameters */
 DLEXPORT PHP_FUNCTION(udm_set_agent_param)
 {
@@ -363,7 +363,7 @@
 /* }}} */
 
 
-/* {{{ proto int udm_find(int agent_identifier, string query)
+/* {{{ proto int udm_find(int agent, string query)
Perform search */
 DLEXPORT PHP_FUNCTION(udm_find)
 {
@@ -385,13 +385,17 @@
}
ZEND_FETCH_RESOURCE(Agent, UDM_AGENT *, yyagent, id, "mnoGoSearch-Agent", 
le_link);
convert_to_string_ex(yyquery);
-   Res=UdmFind(Agent,(*yyquery)->value.str.val);
-   ZEND_REGISTER_RESOURCE(return_value,Res,le_res);
+   
+   if (Res=UdmFind(Agent,UdmTolower((*yyquery)->value.str.val,Agent->charset))) {
+   ZEND_REGISTER_RESOURCE(return_value,Res,le_res);
+   } else {
+   RETURN_FALSE;
+   }   
 }
 /* }}} */
 
 
-/* {{{ proto int udm_get_res_field(int res_identifier, int row_num, int field_name)
+/* {{{ proto int udm_get_res_field(int res, int row, int field)
Fetch mnoGoSearch result field */
 DLEXPORT PHP_FUNCTION(udm_get_res_field){
pval **yyres, **yyrow_num, **yyfield_name;
@@ -440,8 +444,8 @@
 /* }}} */
 
 
-/* {{{ proto int udm_get_res_param(int res_identifier, int param_id)
-   mnoGoSearch result parameters */
+/* {{{ proto int udm_get_res_param(int res, int param)
+   Get mnoGoSearch result parameters */
 DLEXPORT PHP_FUNCTION(udm_get_res_param)
 {
pval ** yyres, ** yyparam;
@@ -473,7 +477,7 @@
 /* }}} */
 
 
-/* {{{ proto int udm_free_res(int res_identifier)
+/* {{{ proto int udm_free_res(int res)
mnoGoSearch free result */
 DLEXPORT PHP_FUNCTION(udm_free_res)
 {
@@ -492,12 +496,13 @@
}
ZEND_FETCH_RESOURCE(Res, UDM_RESULT *, yyres, -1, "mnoGoSearch-Result", 
le_res);
zend_list_delete((*yyres)->value.lval);
-
+   
+   RETURN_TRUE;
 }
 /* }}} */
 
 
-/* {{{ proto int udm_errno(int agent_identifier)
+/* {{{ proto int udm_errno(int agent)
mnoGoSearch error number */
 DLEXPORT PHP_FUNCTION(udm_errno)
 {
@@ -520,7 +525,7 @@
 /* }}} */
 
 
-/* {{{ proto int udm_error(int agent_identifier)
+/* {{{ proto string udm_error(int agent)
mnoGoSearch error message */
 DLEXPORT PHP_FUNCTION(udm_error)
 {
@@ -544,7 +549,7 @@
 /* }}} */
 
 
-/* {{{ proto int udm_free_agent(int agent_identifier)
+/* {{{ p

[PHP-CVS] cvs: php4 /ext/mnogosearch README php_mnogo.c test.php

2001-02-02 Thread Sergey Kartashoff

gluke   Fri Feb  2 04:54:15 2001 EDT

  Modified files:  
/php4/ext/mnogosearch   README php_mnogo.c test.php 
  Log:
  Added new UDM_PARAM_STOPTABLE and UDM_PARAM_STOPFILE parameters
  for Udm_Set_Agent_Params mnoGoSearch module. Now it can use stopwords
  stored either in database or in the plain text files. Added php warnings.
  Test example updated.
  @- Added new UDM_PARAM_STOPTABLE and UDM_PARAM_STOPFILE parameters
  @  for Udm_Set_Agent_Params mnoGoSearch module. Now it can use stopwords
  @  stored either in database or in the plain text files. Added php warnings.
  @  Test example updated. (gluke)
  
  

Index: php4/ext/mnogosearch/README
diff -u php4/ext/mnogosearch/README:1.2 php4/ext/mnogosearch/README:1.3
--- php4/ext/mnogosearch/README:1.2 Wed Jan 31 06:04:29 2001
+++ php4/ext/mnogosearch/README Fri Feb  2 04:54:14 2001
@@ -1,7 +1,7 @@
 $Source: /local/repository/php4/ext/mnogosearch/README,v $
-$Id: README,v 1.2 2001/01/31 14:04:29 gluke Exp $
+$Id: README,v 1.3 2001/02/02 12:54:14 gluke Exp $
 
-mnoGoSearch extension module version 0.3 for PHP4.
+mnoGoSearch extension module for PHP4.
 Basic mnoGoSearch function implementation.
 
 If used with mysql you should not use bundled mysql library 
@@ -12,8 +12,7 @@
   TODO
   
 
-1. Implement more UdmSearch functions. Only basic minimal functions
-set is implemented for now.
+1. Implement more UdmSearch functions.
 
 2. Fix  config.m4 to detect whether UdmSearch is actually installed.
 Currently there is no any checking. ./configure just trust that UdmSearch
@@ -24,6 +23,3 @@
   Actually it should work fine with other supported database.
 
 4. Write PHP interface documentation.
-
-5. Add nice warnings when unknown parameters are passed to PHP functions.
-Those places are marked with FIXME is php_udm.c
Index: php4/ext/mnogosearch/php_mnogo.c
diff -u php4/ext/mnogosearch/php_mnogo.c:1.3 php4/ext/mnogosearch/php_mnogo.c:1.4
--- php4/ext/mnogosearch/php_mnogo.c:1.3Thu Feb  1 05:06:25 2001
+++ php4/ext/mnogosearch/php_mnogo.cFri Feb  2 04:54:14 2001
@@ -1,5 +1,5 @@
 /* $Source: /local/repository/php4/ext/mnogosearch/php_mnogo.c,v $ */
-/* $Id: php_mnogo.c,v 1.3 2001/02/01 13:06:25 gluke Exp $ */
+/* $Id: php_mnogo.c,v 1.4 2001/02/02 12:54:14 gluke Exp $ */
 
 /*
+--+
@@ -48,6 +48,8 @@
 #define UDM_PARAM_CACHE_MODE   4
 #define UDM_PARAM_TRACK_MODE   5
 #define UDM_PARAM_CHARSET  6
+#define UDM_PARAM_STOPTABLE7
+#define UDM_PARAM_STOPFILE 8
 
 #define UDM_TRACK_ENABLED  1
 #define UDM_TRACK_DISABLED 0
@@ -128,6 +130,8 @@
REGISTER_LONG_CONSTANT("UDM_PARAM_CACHE_MODE",UDM_PARAM_CACHE_MODE,CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("UDM_PARAM_TRACK_MODE",UDM_PARAM_TRACK_MODE,CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("UDM_PARAM_CHARSET",UDM_PARAM_CHARSET,CONST_CS | 
CONST_PERSISTENT);  
+   REGISTER_LONG_CONSTANT("UDM_PARAM_STOPTABLE",UDM_PARAM_STOPTABLE,CONST_CS | 
+CONST_PERSISTENT);  
+   REGISTER_LONG_CONSTANT("UDM_PARAM_STOPFILE",UDM_PARAM_STOPFILE,CONST_CS | 
+CONST_PERSISTENT);

/* udm_get_res_param constants */
REGISTER_LONG_CONSTANT("UDM_PARAM_FOUND",UDM_PARAM_FOUND,CONST_CS | 
CONST_PERSISTENT);
@@ -285,7 +289,8 @@
break;

default:
-   RETURN_STRING("",1);
+   
+php_error(E_WARNING,"Udm_Set_Agent_Param: Unknown search mode");
+   RETURN_FALSE;
break;
}

@@ -303,7 +308,8 @@

default:
Agent->cache_mode=UDM_CACHE_DISABLED;
-   RETURN_STRING("",1);
+   php_error(E_WARNING,"Udm_Set_Agent_Param: 
+Unknown cache mode");
+   RETURN_FALSE;
break;
}

@@ -320,7 +326,8 @@
break;

default:
-   RETURN_STRING("",1);
+   php_error(E_WARNING,"Udm_Set_Agent_Param: 
+Unknown track mode");
+   RETURN_FALSE;
break;
}

@@ -332,34 +339,26 @@
 
break;

-   default:
-   RETURN_STRING("",1);
- 

[PHP-CVS] cvs: php4 /ext/mnogosearch README config.m4 php_mnogo.c php_mnogo.h setup.stub test.php

2001-01-31 Thread Sergey Kartashoff

gluke   Wed Jan 31 06:04:30 2001 EDT

  Modified files:  
/php4/ext/mnogosearch   README config.m4 php_mnogo.c php_mnogo.h 
setup.stub test.php 
  Log:
  Added search cache and track query features.
  @-Added search cache and track query features.
  # For example please refer at ext/mnogosearch/test.php 
  
  

Index: php4/ext/mnogosearch/README
diff -u php4/ext/mnogosearch/README:1.1 php4/ext/mnogosearch/README:1.2
--- php4/ext/mnogosearch/README:1.1 Tue Jan 30 04:53:49 2001
+++ php4/ext/mnogosearch/README Wed Jan 31 06:04:29 2001
@@ -1,3 +1,6 @@
+$Source: /local/repository/php4/ext/mnogosearch/README,v $
+$Id: README,v 1.2 2001/01/31 14:04:29 gluke Exp $
+
 mnoGoSearch extension module version 0.3 for PHP4.
 Basic mnoGoSearch function implementation.
 
Index: php4/ext/mnogosearch/config.m4
diff -u php4/ext/mnogosearch/config.m4:1.1 php4/ext/mnogosearch/config.m4:1.2
--- php4/ext/mnogosearch/config.m4:1.1  Tue Jan 30 04:53:50 2001
+++ php4/ext/mnogosearch/config.m4  Wed Jan 31 06:04:29 2001
@@ -1,5 +1,5 @@
-dnl $Id: config.m4,v 1.1 2001/01/30 12:53:50 gluke Exp $
-
+dnl $Source: /local/repository/php4/ext/mnogosearch/config.m4,v $
+dnl $Id: config.m4,v 1.2 2001/01/31 14:04:29 gluke Exp $
 
 PHP_ARG_WITH(mnogosearch,for mnoGoSearch support,
 [  --with-mnogosearch[=DIR]   Include mnoGoSearch support.  DIR is the 
mnoGoSearch base
Index: php4/ext/mnogosearch/php_mnogo.c
diff -u php4/ext/mnogosearch/php_mnogo.c:1.1 php4/ext/mnogosearch/php_mnogo.c:1.2
--- php4/ext/mnogosearch/php_mnogo.c:1.1Tue Jan 30 04:53:50 2001
+++ php4/ext/mnogosearch/php_mnogo.cWed Jan 31 06:04:29 2001
@@ -1,3 +1,6 @@
+/* $Source: /local/repository/php4/ext/mnogosearch/php_mnogo.c,v $ */
+/* $Id: php_mnogo.c,v 1.2 2001/01/31 14:04:29 gluke Exp $ */
+
 /*
+--+
| PHP version 4.0  |
@@ -18,8 +21,6 @@
|  Further development by  Sergey Kartashoff <[EMAIL PROTECTED]>|
+--+
  */
- 
-/* $Id: php_mnogo.c,v 0.3 2001/01/27 15:30:00 */
 
 #include "php.h"
 #include "php_mnogo.h"
@@ -40,12 +41,19 @@
 #define UDM_FIELD_SCORE256
 #define UDM_FIELD_MODIFIED 512
 
+/* udm_set_agent_param constants */
 #define UDM_PARAM_PAGE_SIZE1
 #define UDM_PARAM_PAGE_NUM 2
-#define UDM_PARAM_SEARCH_MODE  4
-#define UDM_PARAM_CHARSET  8
-#define UDM_PARAM_NUM_ROWS 16
-#define UDM_PARAM_FOUND32
+#define UDM_PARAM_SEARCH_MODE  3
+#define UDM_PARAM_CACHE_MODE   4
+#define UDM_PARAM_TRACK_MODE   5
+
+#define UDM_TRACK_ENABLED  1
+#define UDM_TRACK_DISABLED 0
+
+/* udm_get_res_param constants */
+#define UDM_PARAM_NUM_ROWS 256
+#define UDM_PARAM_FOUND257
 
 /* True globals, no need for thread safety */
 static int le_link,le_res;
@@ -112,18 +120,30 @@
REGISTER_LONG_CONSTANT("UDM_FIELD_SCORE",   UDM_FIELD_SCORE,CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("UDM_FIELD_MODIFIED",UDM_FIELD_MODIFIED,CONST_CS | 
CONST_PERSISTENT);
 
+   /* udm_set_agent_param constants */
REGISTER_LONG_CONSTANT("UDM_PARAM_PAGE_SIZE",UDM_PARAM_PAGE_SIZE,CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("UDM_PARAM_PAGE_NUM",UDM_PARAM_PAGE_NUM,CONST_CS | 
CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT("UDM_PARAM_SEARCH_MODE",UDM_PARAM_SEARCH_MODE,CONST_CS 
| CONST_PERSISTENT);
-   REGISTER_LONG_CONSTANT("UDM_PARAM_CHARSET",UDM_PARAM_CHARSET,CONST_CS | 
CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT("UDM_PARAM_SEARCH_MODE",UDM_PARAM_SEARCH_MODE,CONST_CS 
+| CONST_PERSISTENT);  
+   REGISTER_LONG_CONSTANT("UDM_PARAM_CACHE_MODE",UDM_PARAM_CACHE_MODE,CONST_CS | 
+CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT("UDM_PARAM_TRACK_MODE",UDM_PARAM_TRACK_MODE,CONST_CS | 
+CONST_PERSISTENT);
+   
+   /* udm_get_res_param constants */
REGISTER_LONG_CONSTANT("UDM_PARAM_FOUND",UDM_PARAM_FOUND,CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("UDM_PARAM_NUM_ROWS",UDM_PARAM_NUM_ROWS,CONST_CS | 
CONST_PERSISTENT);
-
 
+   /* search modes */
REGISTER_LONG_CONSTANT("UDM_MODE_ALL",UDM_MODE_ALL,CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("UDM_MODE_ANY",UDM_MODE_ANY,CONST_CS | 
CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("UDM_MODE_BOOL",UDM_MODE_BOOL,CONST_CS | 
CONST_PERSISTENT);
 
+   /* search cache params */
+   REGISTER_LONG_CONSTANT("UDM_CACHE_ENABLED",UDM_CACHE_ENABLED,CONST_CS | 
+CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT("UDM_CACHE_DISABLED",UDM_CACHE_DISABLED,CONST_CS | 
+CONST_PERSISTENT);
+   
+   /* track mode params */
+   REGISTER_LONG_CONSTANT("UDM_TRACK_ENABLED",UDM_TRACK_ENABLED,CONST_CS | 
+CONST_PERSISTENT);
+   REGISTER_LONG_CONSTANT("UDM_TRACK_DISA