SQL 从字符串向 datetime 转换时失败.
selecta.readerNo,readerName,bookName,returnDatefromReadera,borrowb,Bookcwherea.reader...
select a.readerNo,readerName,bookName,returnDate
from Reader a,borrow b,Book c
where a.readerNo=b.readerNo and b.bookNo=c.bookNo and b.bookNo in(select b.bookNo from borrow
where returnDate='NULL' and bookNo in(select bookNo from borrow where bookNo='001-000029' ) ) 展开
from Reader a,borrow b,Book c
where a.readerNo=b.readerNo and b.bookNo=c.bookNo and b.bookNo in(select b.bookNo from borrow
where returnDate='NULL' and bookNo in(select bookNo from borrow where bookNo='001-000029' ) ) 展开
展开全部
select a.readerNo,readerName,bookName,returnDate
from Reader a,borrow b,Book c
where a.readerNo=b.readerNo and b.bookNo=c.bookNo and b.bookNo in(select b.bookNo from borrow
where returnDate is NULL and bookNo in(select bookNo from borrow where bookNo='001-000029' ) )
from Reader a,borrow b,Book c
where a.readerNo=b.readerNo and b.bookNo=c.bookNo and b.bookNo in(select b.bookNo from borrow
where returnDate is NULL and bookNo in(select bookNo from borrow where bookNo='001-000029' ) )
追问
语法没错误,可是输不出具体数据
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
2013-03-29
展开全部
returnDate='NULL'
修改为
returnDate IS NULL
修改为
returnDate IS NULL
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询