S
softdog
Unregistered / Unconfirmed
GUEST, unregistred user!
在ADOQuery中写下面的SQL语句:
select *, (select stkname from stock where stock.stkno=orders.stkno) as stkname
from orders
where docno=:adocno
只要一Active:=true(IDE环境中),系统马上提示"Access volation .... 'ntdll.dll'"
但是如果改成下面的语句就不会有错了:
declare @docno varchar(20)
set @docno=:adocno
select *, (select stkname from stock where stock.stkno=orders.stkno) as stkname
from orders
where docno=@docno
这是为什么?
软件环境:NT4 Workstation + SP6, IE5, MS SQL Server 7.0
Delphi 5.0 + sp1 + ADOExpress sp2
select *, (select stkname from stock where stock.stkno=orders.stkno) as stkname
from orders
where docno=:adocno
只要一Active:=true(IDE环境中),系统马上提示"Access volation .... 'ntdll.dll'"
但是如果改成下面的语句就不会有错了:
declare @docno varchar(20)
set @docno=:adocno
select *, (select stkname from stock where stock.stkno=orders.stkno) as stkname
from orders
where docno=@docno
这是为什么?
软件环境:NT4 Workstation + SP6, IE5, MS SQL Server 7.0
Delphi 5.0 + sp1 + ADOExpress sp2