Subject | Re: Questions on searchinglinks example |
---|---|
Author | petesouthwest |
Post date | 2005-09-21T08:15:06Z |
Hi
Further to my original post, although what i have done seems to work
for the primary key, it does not appear to be working for any other
field. As soon as I choose a field that isnt the primary key, no
records are displayed.
I cant see any obvious differences in what I have done compared with
the example.
Looking at the SQL Monitor display I did notice that the example displays:
EXECUTE STATEMENT
TR_HANDLE = 10254668
STMT_HANDLE = 10254724
PARAMS = [ Version 1 SQLd 1 SQLn 1
[LAST_NAME] = '' ]
----*/
as Oppossed to mine that says:
/*---
EXECUTE STATEMENT
TR_HANDLE = 3570400
STMT_HANDLE = 3559060
PARAMS = [ Version 1 SQLd 1 SQLn 1
[SNAME] = <NULL> ]
SECONDS = 0.031
----*/
Not sure why mine says NULL and the example has ''?? In both cases I
have not typed anything into the searchedit box.
Am i missing some documentation that explains how these examples work?
I thought I had downloaded all the documentation, but I cant see
anything explaining how the examples work :(
Pete
--- In IBObjects@yahoogroups.com, "petesouthwest" <petesouthwest@h...>
wrote:
Further to my original post, although what i have done seems to work
for the primary key, it does not appear to be working for any other
field. As soon as I choose a field that isnt the primary key, no
records are displayed.
I cant see any obvious differences in what I have done compared with
the example.
Looking at the SQL Monitor display I did notice that the example displays:
EXECUTE STATEMENT
TR_HANDLE = 10254668
STMT_HANDLE = 10254724
PARAMS = [ Version 1 SQLd 1 SQLn 1
[LAST_NAME] = '' ]
----*/
as Oppossed to mine that says:
/*---
EXECUTE STATEMENT
TR_HANDLE = 3570400
STMT_HANDLE = 3559060
PARAMS = [ Version 1 SQLd 1 SQLn 1
[SNAME] = <NULL> ]
SECONDS = 0.031
----*/
Not sure why mine says NULL and the example has ''?? In both cases I
have not typed anything into the searchedit box.
Am i missing some documentation that explains how these examples work?
I thought I had downloaded all the documentation, but I cant see
anything explaining how the examples work :(
Pete
--- In IBObjects@yahoogroups.com, "petesouthwest" <petesouthwest@h...>
wrote:
> Hi
>
> I'm looking at the searchinglinks sample project. I noticed that when
> searching, the grid displays all of the records, highlighting the one
> searched for. When I try an recreate the searching function in my
> project, searching results in only the record i have searched for
> being displayed in the grid. Can anyone please explain what is done in
> the example?
>
> I also dont understand what this bit of code is doing:
>
> tmpStr := OldParamValueLinks.LinkValues[ 'EMP_NO' ];
> if OrderingItemNo > 0 then begin
> SQLWhereItems.Add( 'EMP_NO >= :EMP_NO' );
> if (tmpStr = '-999') or (tmpStr = '') or (tmpStr = '999')
> then begin
> ParamValueLinks.Add( 'EMP_NO=-999' );
> end;
> end else begin
> SQLWhereItems.Add( 'EMP_NO <= :EMP_NO' );
> if (tmpStr = '-999') or (tmpStr = '') or (tmpStr = '999')
> then begin
> ParamValueLinks.Add( 'EMP_NO=999' );
>
>
> Thanks for any help given
>
> Pete