oracle - Delphi XE7 TFDTable View RowID error -
i'm converting delphi 5 / bde application delphi xe7 / firedac. 1 of forms has tfdtable component points oracle view containing "group by" clause in create statement.
this used work fine in "old" app (bde), firedac i'm getting error:
"ora-01446: cannot select rowid from, or sample, view distinct, group by, etc."
i understand error i'm getting oracle, i'm not selecting rowid, firedac is! there property on tfdtable component can set prevent adding rowid query? if not, how supposed use view?
your appreciated j
include fimeta
in fetchoptions.items
.
tfdquery, tfdtable, tfdmemtable, , tfdcommand automatically retrieve unique identifying columns (mkprimarykeyfields) main (first) table in select ... ... statements, when fimeta included in fetchoptions.items. note:
mkprimarykeyfields querying may time consuming; application may need explicitly specify unique identifying columns, when firedac fails determine them correctly.
to explicitly specify columns, exclude fimeta fetchoptions.items, , use 1 of following options:
set updateoptions.keyfields ';' separated list of column names; include pfinkey corresponding tfield.providerflags property.
when application creates persistent fields, tfield.providerflags set correctly. after that, automatic field setup not happen, when db structure or query changed. should manually update providerflags adjust column list. also, if primary key consists of several fields, of them must included persistent fields. row identifying columns
alternatively, row identifying column may included select list. when firedac founds such columns, not retrieve mkprimarykeyfields metadata , use column. supported dbmss following:
dbms row identifying column
firebird db_key
informix rowid
interbase db_key / rdb$db_key
oracle rowid
postgresql oid. table must created oids.
sqlite rowid
source : http://docwiki.embarcadero.com/radstudio/xe8/en/unique_identifying_fields_%28firedac%29
Comments
Post a Comment