Search Question

Post Reply
gazim
Posts: 66
Joined: Sun Feb 18, 2001 1:01 pm

Search Question

Post by gazim »

The following query returns 173 hits.
select ID,PAGES from tblnew where (AUTHOR like 'claim' AND ATTPAGES like '0')"

When I changed the where clause to (ATTPAGES like '0' AND AUTHOR like 'claim'), it returned 151 hits.

Both AUTHOR and ATTPAGES are varchar(255). For the first query it seems like texis is treating [ATTPAGES like '0'] as [ATTPAGES like '0*']. It finds all rows that have 0 in ATTPAGES plus any other rows that have the character 0 along with other characters (5580 for example). Now if I switch the fields around in the where clause as I did in the 2nd query, it finds only 0's in ATTPAGES.
Any help will be appreciated. TIA
User avatar
John
Site Admin
Posts: 2622
Joined: Mon Apr 24, 2000 3:18 pm
Location: Cleveland, OH
Contact:

Search Question

Post by John »

You might want to adjust the wordc and langc settings. Since less than 1000 (maxlinearrows) rows match 'claim', it does not use the index for ATTPAGES. Since '0' is not "language" by the default langc, it does a substring match.

When you do it first, the index is used, and since you apparently have an index expression that includes just '0', it will find those "words".
John Turnbull
Thunderstone Software
gazim
Posts: 66
Joined: Sun Feb 18, 2001 1:01 pm

Search Question

Post by gazim »

What if 'claim' matched more than 1000 hits? Would that still try to do a substring match on ATTPAGES?
User avatar
John
Site Admin
Posts: 2622
Joined: Mon Apr 24, 2000 3:18 pm
Location: Cleveland, OH
Contact:

Search Question

Post by John »

No, that would be over maxlinearrows, which is settable, and so it would look to find an index to resolve the clause on ATTPAGES.
John Turnbull
Thunderstone Software
gazim
Posts: 66
Joined: Sun Feb 18, 2001 1:01 pm

Search Question

Post by gazim »

Thank you for your help john. I have another question on a different topic.

It seems like you guys have made significant changes to the Texis API that comes with 9-12-2003 NT version of texis. We have built some in-house tools using the API. None of them seem to be working with this new version of texis.

I am using Visual C++ on windows 2000 to compile my code. I replaced all header files with the new version.

As soon as I replaced texisnt.lib, tispnt.lib and api3nt.lib, the compiler started to throw error messages.

And also, i noticed that dbqueryi.h is now including "config_gen.h". This header file does not exist in the API folder.

Any help from you on this issue will be greatly appreciated. Thanks in advance!

excerpts from some of the error messages:

texisnt.lib(sysdep.obj) : error LNK2001: unresolved external symbol _epipathfindmode
texisnt.lib(txlicense.obj) : error LNK2001: unresolved external symbol _epipathfindmode
texisnt.lib(http.obj) : error LNK2001: unresolved external symbol _epipathfindmode
texisnt.lib(readconf.obj) : error LNK2001: unresolved external symbol _TXstrnispacecmp
texisnt.lib(http.obj) : error LNK2001: unresolved external symbol _htinet_ntoa
User avatar
John
Site Admin
Posts: 2622
Joined: Mon Apr 24, 2000 3:18 pm
Location: Cleveland, OH
Contact:

Search Question

Post by John »

Which order are you linking the libraries? We have noticed that some linkers require some libraries multiple times. I'll email you a copy of config_gen.h
John Turnbull
Thunderstone Software
gazim
Posts: 66
Joined: Sun Feb 18, 2001 1:01 pm

Search Question

Post by gazim »

Thank you for sending me the header file. I am still having some linking issues with the new libraries. linking order of the libraries ..

api3nt.lib tispnt.lib texisnt.lib wsock32.lib netapi32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib mtx.lib mtxguid.lib msvcrt.lib version.lib msvcrtd.lib

Thanks again.
User avatar
John
Site Admin
Posts: 2622
Joined: Mon Apr 24, 2000 3:18 pm
Location: Cleveland, OH
Contact:

Search Question

Post by John »

You might try including the libraries a second time, although it does look as if the order doesn't matter. Also are you sure all 3 libraries are the new version?
John Turnbull
Thunderstone Software
gazim
Posts: 66
Joined: Sun Feb 18, 2001 1:01 pm

Search Question

Post by gazim »

Thank you for all your help john. I was able to successfully compile my code with API version 4.04.1067366033 of Oct 28, 2003.

The new API is no longer backward compatible. Is it going to be the same for each versions to be released in the future?

Thanks again.
User avatar
John
Site Admin
Posts: 2622
Joined: Mon Apr 24, 2000 3:18 pm
Location: Cleveland, OH
Contact:

Search Question

Post by John »

We do in general suggest running the same version of the API as the other executables accessing the database. What kind of compatibility are you looking for?
John Turnbull
Thunderstone Software
Post Reply