Invalid Queries in Designer
Hi,
I often have a problem that a ODAC-Dataset gets invalid in the designer.
If this happens I cannot unfold the dataset-details so it's not possible to use field references
in the report definition. The item of the dataset doesn't appear in bold font indicating that
something is wrong in its definition I guess.
I am using FastReport 4.5
The problem can be reproduced like this:
1) call designer
2) add a TODACQuery component
3) use a SQL-Statement with DateTime parameters (see below for examples)
4) link the parameters with engine-variables (TDateTime variables with Oracle DateTime fieldtype)
Now as soon as I change the name of one of the parameters in the SQL-definition, the query gets invalid.
example:
original query:
modify to:
or modify to:
leaves the query invalid, if the parameters were linked with engine variables.
Any hint?
My workaround is to remove the query component, add a clear one and rebuild
the query.
Thanks a lot, Daniel
I often have a problem that a ODAC-Dataset gets invalid in the designer.
If this happens I cannot unfold the dataset-details so it's not possible to use field references
in the report definition. The item of the dataset doesn't appear in bold font indicating that
something is wrong in its definition I guess.
I am using FastReport 4.5
The problem can be reproduced like this:
1) call designer
2) add a TODACQuery component
3) use a SQL-Statement with DateTime parameters (see below for examples)
4) link the parameters with engine-variables (TDateTime variables with Oracle DateTime fieldtype)
Now as soon as I change the name of one of the parameters in the SQL-definition, the query gets invalid.
example:
original query:
SELECT *
FROM mytable
WHERE mydatefield BETWEEN :dteleft AND :dteright
modify to:
SELECT *
FROM mytable
WHERE mydatefield BETWEEN :dteleft AND :dteright + 1
or modify to:
SELECT *
FROM mytable
WHERE mydatefield BETWEEN :dteLeft AND :dteRight
leaves the query invalid, if the parameters were linked with engine variables.
Any hint?
My workaround is to remove the query component, add a clear one and rebuild
the query.
Thanks a lot, Daniel