Using Ttable.Filter with mySQL

Does mySQL support TTable Filter method? An error message raises when i use TTable with Filter method, do we have a workaround for this? Why does the Filter method works fine when i use TQuery component? I really need my Ttable filter to wqrk because ttable can append, edit or delete file but TQuery doesn't.

Thanks in advance.
girlswants_meAsked:
Who is Participating?
 
sun4sundayCommented:
BLOB cannot fliter
sun4sunday
0
 
girlswants_meAuthor Commented:
Thanks in advance.
0
 
girlswants_meAuthor Commented:
Anybody can help me?
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
sun4sundayCommented:
Does mySQL support TTable Filter method?
>> Flitering is doing by delphi not by the database, if I am correct.

To set the fliter
On the table properites

set    FLITER   FIELDNAME = CONDITION        EG:  STATUS = 'A'  
        FLITERED    TRUE

Make sure that the field you are setting is in the the Ttable

At run time to set teh fliter make sure that before setting the fliter set teh table FLITERED :=fALSE;
After setting the fliterMAKE  FLITERED again TRUE;

This link also will help you http://delphi.about.com/od/database/l/aa051501a.htm

sun4sunday

0
 
atul_parmarCommented:
Can you paste the code or tell us how you are setting the filters?
0
 
atul_parmarCommented:
And who said that TQuery can not append, edit and delete? You can do it very well.
0
 
girlswants_meAuthor Commented:
Sorry if im not that clear. I am using mySQL and with a field BLOB in it. It will return capability not supported.
0
 
girlswants_meAuthor Commented:
I also always encounter a "Filter handle is invalid"
0
 
girlswants_meAuthor Commented:
I also always encounter a "Filter handle is invalid" for simple fields like char and int
0
 
Kyle FosterCEOCommented:
BLOB cannot filter.

try use 2 tables include the blob field in the 2nd table and link the two tables using master/detail.  The detaiil will just have 1 record.  Then filter the 1st table.  To access the blob look at the BLOB field in the 2nd table.

The problem with the filter is that it is done locally inside the Delphi VCL.  So if you filter a 1000 row dataset down to 2 rows you still have to pull 1000 rows from the database to the client.

Better to use queries.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.