ImageBack = NULL, ImageBackSize = NULL, ImageBackType = NULL WHI AIM.AIMRetrievedItem.ArchiveRetrievalID =(SELECT AIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALID FROM AIM.ARCHIVERETRIEVAL, AIM.AIMRETRIEVEDITEM 在哪里 AIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALID = AIM.ARCHIVERETRIEVAL.ARCHIVERETRIEVALID 和AIM.ARCHIVERETRIEVAL.EXPIRATIONDATE< DATE( CURRENT TIMESTAMP)) 当我运行此查询时,我得到多个记录集错误。 我欢迎任何有关如何纠正问题的建议或想法。 提前致谢... ----------------------------------- -------------- 我怀疑问题出现在subselect中,它返回的价格比一个值多了。 I''m trying to UPDATE multiple rows in a single statement. I''ve seen some examples but to me they don''t seem to apply to my scenario. Below is my original SQL:UPDATE AIM.AIMRetrievedItemSET ImageFront=NULL,ImageFrontSize=NULL,ImageFrontType=NULL,ImageBack=NULL,ImageBackSize=NULL,ImageBackType=NULLWHERE AIM.AIMRetrievedItem.ArchiveRetrievalID = (SELECTAIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALIDFROMAIM.ARCHIVERETRIEVAL,AIM.AIMRETRIEVEDITEMWHEREAIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALID = AIM.ARCHIVERETRIEVAL.ARCHIVERETRIEVALIDAND AIM.ARCHIVERETRIEVAL.EXPIRATIONDATE < DATE(CURRENT TIMESTAMP))When I run this query, I get the multiple recordset error.I would welcome any suggestions or ideas on how to rectify the problem.Thanks in advance... 解决方案 "Anthony Robinison" <an*****@yahoo.com> wrote in messagenews:e9*****************@twister.rdc-kc.rr.com...I''m trying to UPDATE multiple rows in a single statement. I''ve seen someexamples but to me they don''t seem to apply to my scenario. Below is myoriginal SQL:UPDATE AIM.AIMRetrievedItemSET ImageFront=NULL,ImageFrontSize=NULL,ImageFrontType=NULL,ImageBack=NULL,ImageBackSize=NULL,ImageBackType=NULLWHERE AIM.AIMRetrievedItem.ArchiveRetrievalID = (SELECTAIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALIDFROMAIM.ARCHIVERETRIEVAL,AIM.AIMRETRIEVEDITEMWHEREAIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALID =AIM.ARCHIVERETRIEVAL.ARCHIVERETRIEVALIDAND AIM.ARCHIVERETRIEVAL.EXPIRATIONDATE < DATE(CURRENT TIMESTAMP))When I run this query, I get the multiple recordset error.I would welcome any suggestions or ideas on how to rectify the problem.Thanks in advance...-------------------------------------------------I suspect that the problem is in the subselect, which is returning more thanone value."Anthony Robinison" <an*****@yahoo.com> wrote in messagenews:e9*****************@twister.rdc-kc.rr.com...I''m trying to UPDATE multiple rows in a single statement. I''ve seen someexamples but to me they don''t seem to apply to my scenario. Below is myoriginal SQL:UPDATE AIM.AIMRetrievedItemSET ImageFront=NULL,ImageFrontSize=NULL,ImageFrontType=NULL,ImageBack=NULL,ImageBackSize=NULL,ImageBackType=NULLWHERE AIM.AIMRetrievedItem.ArchiveRetrievalID = (SELECTAIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALIDFROMAIM.ARCHIVERETRIEVAL,AIM.AIMRETRIEVEDITEMWHEREAIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALID =AIM.ARCHIVERETRIEVAL.ARCHIVERETRIEVALIDAND AIM.ARCHIVERETRIEVAL.EXPIRATIONDATE < DATE(CURRENT TIMESTAMP))When I run this query, I get the multiple recordset error.I would welcome any suggestions or ideas on how to rectify the problem.Thanks in advance...-------------------------------------------------I suspect that the problem is in the subselect, which is returning more thanone value.I''ve seen examples where they were able to get around the more than onerecord issue...Anyone seen this or have any ideas?"Mark A" <[email protected]> wrote in messagenews:gf*****************@news.uswest.net... "Anthony Robinison" <an*****@yahoo.com> wrote in message news:e9*****************@twister.rdc-kc.rr.com... I''m trying to UPDATE multiple rows in a single statement. I''ve seen some examples but to me they don''t seem to apply to my scenario. Below is my original SQL: UPDATE AIM.AIMRetrievedItem SET ImageFront=NULL, ImageFrontSize=NULL, ImageFrontType=NULL, ImageBack=NULL, ImageBackSize=NULL, ImageBackType=NULL WHERE AIM.AIMRetrievedItem.ArchiveRetrievalID = (SELECT AIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALID FROM AIM.ARCHIVERETRIEVAL, AIM.AIMRETRIEVEDITEM WHERE AIM.AIMRETRIEVEDITEM.ARCHIVERETRIEVALID = AIM.ARCHIVERETRIEVAL.ARCHIVERETRIEVALID AND AIM.ARCHIVERETRIEVAL.EXPIRATIONDATE < DATE(CURRENT TIMESTAMP)) When I run this query, I get the multiple recordset error. I would welcome any suggestions or ideas on how to rectify the problem. Thanks in advance... ------------------------------------------------- I suspect that the problem is in the subselect, which is returning morethan one value. 这篇关于更新多行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!
09-11 18:42