[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Multiple Server Controls



So you are saying without using PAGE controls, get all the results
even though they are in thousands(by setting the size limit as ZERO,
unlimited).Will that be a proper approach to the problem?


On Sun, 20 Mar 2005 04:20:48 -0800, Howard Chu <hyc@symas.com> wrote:
> Those two controls are not compatible with each other, only one of the
> two will take effect.
> 
> In general, the Paged Results control is a waste of effort and should
> not be used.
> 
> Vishal Jose wrote:
> 
> >Hello,
> >
> >I have a problem regarding the usage multiple server controls within the
> >single search.One control is DIRSYNC CONTROL and another one is PAGE
> >CONTROL.
> >
> >The whole purpose of my application is LDAP server and LDAP client
> >synchronization.
> >
> >For the synchronization purpose, the DIRSYNC CONTROL is employed.
> >Considering the amount of results that may come from the LDAP Server, I
> >thought of implementing PAGE CONTROL.(My intention is to get all the
> >results, not necessarily separately).
> >
> >So before issuing a ldap_search_ext_s, I make DIRSYNC control and PAGE
> >control and add it to the server control list of the call.
> >Here PAGE control is made by making a call  "ldap_create_page_control(..)"
> >
> >So the sequence of the application can be put as
> >
> >1) Make LDAP DIRSYNC control
> >2) Make LDAP PAGE control (call to ldap_create_page_control)
> >3) Add the controls to the PLDAPControl array
> >4) Issue a ldap_search_ext_s function
> >5) Issue a ldap_parse_result function (Can retrieve the DIRSYNC control
> >returned as PLDAPControl * points to it after returning)
> >6) Using ldap_parse_page_control function , try to get the PAGE control,
> >which is giving an error number:93, "Specified control was not found in
> >message".
> >7) As I have specified in ldap_create_page_control function to return 5
> >results, only 5 results are returned in the above case.
> >    eg: ldap_create_page_control(m_hSessionHandle, 5,
> >Cookie,'T',&PageControl) ;
> >
> >Anybody can help me in where am I going wrong?
> >
> >- Vishal
> >
> >
> >
> >
> >
> >
> >
> >
> >
> 
> --
>  -- Howard Chu
>  Chief Architect, Symas Corp.       Director, Highland Sun
>  http://www.symas.com               http://highlandsun.com/hyc
>  Symas: Premier OpenSource Development and Support
> 
>