Redian新闻
>
SQL server 2000有hidden records吗?
avatar
SQL server 2000有hidden records吗?# Database - 数据库
l*u
1
写了一个query对一小部分数据不work,这些数据明明是不符合query的条件.难道有
hidden records? SQL server 2000
avatar
B*g
2
把sql贴出来。

写了一个query对一小部分数据不work,这些数据明明是不符合query的条件.难道有
hidden records? SQL server 2000

【在 l********u 的大作中提到】
: 写了一个query对一小部分数据不work,这些数据明明是不符合query的条件.难道有
: hidden records? SQL server 2000

avatar
l*u
3
说具体点:
I wrote a query it select records from table 1 which has corresponding
records in table 2 and table 3. The query works fine on my machine (server
2005). I moved to clients Server (server 2000), the query works for most
cases, however there a few records get selected even they don't have any
corresponding records in table 2 and table 3 -- run select query on table 2
and 3 returns nothing. We can't figure out why this is happening?
avatar
l*u
4
query 如下:
select distinct prdoco from dbo.f43121 A where
(not exists
(select 1 from dbo.f43121 B where
A.prdoco=b.prdoco
and A.prdcto=b.prdcto
AND A.PRKCOo=B.PRKCOO
and B.PRMATC='2' AND((B.prdoc not in
(SELECT distinct prdoc FROM dbo.f43121, dbo.f0411
where prdoc=rpdoc and prdct=rpdct and prkco=rpkco))
or B.prdoc not in
(SELECT distinct prdoc FROM dbo.f43121, dbo.f0911
where prdoc=gldoc and prdct=gldct and prkco=glkco))))
avatar
l*u
5
我觉得query本身不是问题,在我这run的好好的. 但是也想不出client那边有什么猫腻.
怪就怪在客户那边几万条数据,只有那么15条不行.

【在 l********u 的大作中提到】
: query 如下:
: select distinct prdoco from dbo.f43121 A where
: (not exists
: (select 1 from dbo.f43121 B where
: A.prdoco=b.prdoco
: and A.prdcto=b.prdcto
: AND A.PRKCOo=B.PRKCOO
: and B.PRMATC='2' AND((B.prdoc not in
: (SELECT distinct prdoc FROM dbo.f43121, dbo.f0411
: where prdoc=rpdoc and prdct=rpdct and prkco=rpkco))

avatar
B*g
6
贴一个不行的例子

腻.

【在 l********u 的大作中提到】
: 我觉得query本身不是问题,在我这run的好好的. 但是也想不出client那边有什么猫腻.
: 怪就怪在客户那边几万条数据,只有那么15条不行.

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。