开发者

OracleDataAdapter can't get the data query by the sql string contaning inner join

开发者 https://www.devze.com 2023-01-31 11:58 出处:网络
OracleDataAdapter returns no rows, but the query string works in SQLDevelope开发者_开发百科r .

OracleDataAdapter returns no rows, but the query string works in SQLDevelope开发者_开发百科r .

select * 
from MESSAGE_YXX 
inner join EMPLOYEE_YXX SedPerson ON MESSAGE_YXX.SPID=SedPerson.id

but it works when I change "inner join " to "left join"

thanks.


Try:

select * from (
select * 
from MESSAGE_YXX 
join EMPLOYEE_YXX SedPerson ON MESSAGE_YXX.SPID=SedPerson.id
);

I remember cases where this helped when the query was not returning all columns.

Besides I never write inner, it is an optinal keyword.

0

精彩评论

暂无评论...
验证码 换一张
取 消