how to simply add any condition?
let's say I have
Code: Select all
select * from table
where id > 5how can I do without explcitly doing:
Code: Select all
msquery1.sql[1] := msquery1.sql[1] + ' or age > 30'The above approach forces me to keep manually track at which line the WHERE clause ends, I mean in practice what I do is
Code: Select all
const
POS_WHERE: integer := 34 // hardcoded, need to manually check every time I change SQL code
msquery1.sql[POS_WHERE] := msquery1.sql[POS_WHERE] + ' or age > 30'