Subject Re: [IBO] Searching with ib_searchpanel
Author stanw1950
Thanks Nick but I can't quite get this to work. The sql in the
tib_query is 'select * from part'. I want to add 'where part starting
with 144'. When I run the following code the where part is never
used. What am I doing wrong? Thanks. (Delphi 6, ibo 4.2.fr)

sl := stringlist.create;
try
//tib_searchpanel name = sp
sl.Add('CTL.' + sp.Owner.Name + '.sp=' + ' where part starting
with 144');
with query do begin
ReadSearch(sl);
Search;
Post;
InvalidateSQL; //tried with and without this line
Refresh; //tried with and without this line
end;
finally
sl.free;
end;


--- In IBObjects@y..., "Kaputnik" <delphi@k...> wrote:
> The IBO-Search-Mode does ADD to, not replace the where-clause of
the query.
> If you have a parameter, it stays in place.
> In one of my applications, where I was in need to isolate one
record via a
> hyperlink-jump, I did not use a parameter, but manually assigned
> search-criteria to the query.
> This is not too hard, and you can search this list's archive under
> http://groups.yahoo.com for the keywords "Search Kaputnik" on the
second
> page you'll find a nice thread which explains, how to use the direct
> search-criteria.
>
> CU,
>
> Nick Josipovic
>
> BIT Institute
> Prof. Dr. Franz Steffens
> University of Mannheim
> T: ++49 621 181 1621
> M: ++49 179 133 44 16
> S: ++49 621 181 1622
> F: ++49 621 181 1618
> nick.josipovic@b...