BUG: AV Using Insert With Correlated Subquery and Check OptionLast reviewed: April 9, 1997Article ID: Q155181 |
The information in this article applies to:
SYMPTOMSIf you insert into a view, which has a correlated subquery preceded by the IN operator and which has been created with the WITH CHECK OPTION, a handled Access Violation error occurs.
WORKAROUNDDo not use the WITH CHECK OPTION or rewrite the correlated subquery in the view as a Join.
STATUSMicrosoft has confirmed this to be a problem in Microsoft SQL Server versions 6.0 and 6.5. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.
MORE INFORMATIONConsider the following script:
create table X (xCol1 int not null, xCol2 int not null) go create table Y (yCol1 int not null) go create view vX as select xCol1, xCol2 from X where xCol1 in (select yCol1 from Y where yCol1 = xCol1) with check option goThe following query causes a handled access violation:
insert vX values (1,1) |
Additional query words: AV
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |