we have the following method that is quite fast with oracle 10.2 but becomes very very slow (unusable) if it is used with oracle 11.2.
the line of code where it becomes slow is
DetailTable->Fields->Fields[ i ]->ReadOnly = disabilita;
void __fastcall TConfordi::DisabilitaCampi( bool disabilita )
{
String ls;
//DetailTable is a TSmartQuery
for ( int i = 0; i < DetailTable->FieldCount; i++ )
{
ls = DetailTable->Fields->Fields[ i ]->FieldName.UpperCase();
if ( ( ls != "F_VALID" ) &&
( ls != "DATA_ULTIMA_MODIFICA" ) &&
( ls != "ID_UTENTE" ) &&
( ls!= "DATA_RIENTRO_TINT_PREV" ) &&
( ls!= "COSTO_LAVORAZIONE" ) &&
( ls != "DATA_LAVORAZIONE" ) &&
( ls != "TINTORIA" ) &&
( ls != "DATA_RIENTRO_TINT_PREV1" ) &&
( ls != "COSTO_LAVORAZIONE1" ) &&
( ls != "DATA_LAVORAZIONE1" ) &&
( ls != "TINTORIA1" ) &&
( ls != "DATA_RIENTRO_TINT_PREV2" ) &&
( ls != "COSTO_LAVORAZIONE2" ) &&
( ls!= "DATA_LAVORAZIONE2" ) &&
( ls != "TINTORIA2" ) &&
( ls != "TIPO_LAVORAZIONE1" ) &&
( ls != "TIPO_LAVORAZIONE2" ) &&
( ls != "TIPO_LAVORAZIONE3" ) &&
( ls != "DATA_CONSEGNA" ) &&
( ls != "NO_LABDIP" ) )
DetailTable->Fields->Fields[ i ]->ReadOnly = disabilita;
}
}
setting TField readOnly very slow on oracle 11.2
Re: setting TField readOnly very slow on oracle 11.2
Hello,
We couldn't reproduce the described problem. Please compose a small simple sample reproducing the problem and send it to alexp*devart*com .
We couldn't reproduce the described problem. Please compose a small simple sample reproducing the problem and send it to alexp*devart*com .
Re: setting TField readOnly very slow on oracle 11.2
Dear sir.
I found a patch that works in my case
I just set the TOraDataSource->DataSet to which DetailTable is connected to NULL at the beginning of the method and I reset it to DetailTable at the end of the method. With the patch the method is fast again. Thus the problem is due to the connection between the TSmartQuery fields and the controls on the user interface.
Nevertheless I think you still have a problem because the difference in behaviour between version 10.2 and version 11.2 is quite awful.
By the way our version of ODAC is 8.0.2. In any case we are going to upgrade the version to the present one (9.4) in the next days (you will receive an order)
I found a patch that works in my case
I just set the TOraDataSource->DataSet to which DetailTable is connected to NULL at the beginning of the method and I reset it to DetailTable at the end of the method. With the patch the method is fast again. Thus the problem is due to the connection between the TSmartQuery fields and the controls on the user interface.
Nevertheless I think you still have a problem because the difference in behaviour between version 10.2 and version 11.2 is quite awful.
By the way our version of ODAC is 8.0.2. In any case we are going to upgrade the version to the present one (9.4) in the next days (you will receive an order)
Re: setting TField readOnly very slow on oracle 11.2
As I wrote your earlier, we couldn't reproduce the problem. The performance loss may be due to settings of indexes in tables on different servers.
P.S. Instead of setting the DataSet property to Null you can use the DataSet DisableControls/EnableControls methods.
P.S. Instead of setting the DataSet property to Null you can use the DataSet DisableControls/EnableControls methods.
Re: setting TField readOnly very slow on oracle 11.2
thank you very much. I will follow your suggestion.
I consider the support request as closed
I consider the support request as closed
Re: setting TField readOnly very slow on oracle 11.2
If you have any further questions, feel free to contact us.