Alexey Gaidukov wrote:

> Becker, Holger пишет:
> 
> >Alexey Gaidukov wrote:
> >
> >>I have table with 2 millions records. I have a field with index.
> >>Simple 
> >>statement: "select * from table where field in (1,2,3)" performs very 
> >>fast. But the statement "delete from table where field in (1,2,3)" takes 
> >>about 15 minutes. What is wrong? I'm using MaxDB alone so thare aren't any 
> >>locks.
> >>    
> >>
> >
> >Hi,
> >
> >In general Index should be used by select and by delete.
> >
> >Would you mind sending me the ouput of the explain statement of
> >the select statement extended by for reuse clause.
> >
> >Example:
> >explain
> >select * from table where field in (1,2,3) for reuse
> >
> 
> If I try to delete record with CARTNUM=1 from PATS and in the table 
> INVEST there are recodrs with CARTNUM=1 then I get error message
> Integrity constraint violation;350 POS(1) Referential integrity 
> violated:INVEST_CARTNUM_FK
> very fast. But if there don't exist records in INVEST with CARTNUM=1 
> then deleting takes some hours.

Hi List,

with support of Alexey we found a bug in foreign key handling if an index is 
defined on foreign key columns.
The bug is included in version >= 7.6 and will be fixed with one of the next 
patches 
(see http://www.sapdb.org/webpts?wptsdetail=yes&ErrorType=0&ErrorID=1136273).

Thanks to Alexey for his help.

Kind regards
Holger

--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to