Page 1 of 1

Filtering with TOraTable

Posted: Mon 27 Dec 2004 13:10
by Wojtek
Hi,

does anyone know how to use "Filter" and/or "FilterSQL" properties of
TOraTable object to filter data od date fields (using Oracle function to_date()).. I try to do this in several ways, but I still get runtime errors.

Thanks for any help.

Posted: Mon 27 Dec 2004 15:45
by Alex
You can use FilterSQL property to add necessary conditions in WHERE clause of SQL statement, for example:
OraQuery1.SQL.Text := 'Select * from Emp';
OraQuery1.FilterSQL := 'HIREDATE > to_date(''01-01-1981'',''dd-mm-yyyy'')';
OraQuery1.Filtered := True;
OraQuery1.Open;