Asp classic 记录集rowcout-1

Asp classic 记录集rowcout-1,asp-classic,recordset,Asp Classic,Recordset,对不起我的英语 我使用经典asp并尝试使用以下查询打开记录集 query = "SELECT "+_ "op.""ID"","+_ "replace(op.""FIO"",'""','\""') AS FIO, "+_ "replace(op.""Fax"",'""','\""') AS Fax, "+_ "replace(p.""Phone"",'"

对不起我的英语

我使用经典asp并尝试使用以下查询打开记录集

 query = "SELECT "+_
                  "op.""ID"","+_
                  "replace(op.""FIO"",'""','\""') AS FIO, "+_
                  "replace(op.""Fax"",'""','\""') AS Fax, "+_
                  "replace(p.""Phone"",'""','\""')AS Phone,  "+_
                  "replace(p.""INN"",'""','\""') AS INN, "+_
                  "replace(v.""ParentID"",'""','\""') AS ParentID, "+_
                  "replace(v.""Name"",'""','\""') AS Name, "+_
                  "replace(v.""ShortName"",'""','\""') AS ShortName, "+_
                  "replace(v.""AddIndex"",'""','\""') AS AddIndex, "+_
                  "replace(v.""StateID"",'""','\""') AS StateID, "+_
                  "replace(coalesce(p.""Address"",op.""LawAddress""),'""','\""') as ""Address"", "+_
                  "replace(coalesce(p.""ZIPCode"",op.""LawZIPCode""),'""','\""') as ""ZIPCode"", "+_
                  "replace(coalesce(p.""Country"",op.""LawCountry""),'""','\""') as ""Country"", "+_
                  "replace(coalesce(p.""Oblast"",op.""LawOblast""),'""','\""') as ""State"", "+_
                  "replace(coalesce(p.""City"",op.""LawCity""),'""','\""') as ""City"", "+_ 
                  "replace(coalesce(p.""Address"",op.""LawAddress""),'""','\""') as ""Street"", "+_
                  "replace(coalesce(p.""House"",op.""LawHouse""),'""','\""') as ""House"", "+_
                  "replace(op.""LawOffice"",'""','\""')  as ""Office"""+_
                 " FROM "+_
                 "   DBO.""LDOrgPartner"" op, "+_
                 "   DBO.""LDPartner"" p, "+_
                 "   DBO.""LDVocabulary"" v "+_
                 " WHERE "+_
                 "   p.""ID""=op.""ID"" AND "+_
                 "   v.""ID""=op.""ID"" AND "+_ 
                 "   v.""ObjectTypeID"" in (19,44) "&wherePart

        response.Write(query)
        Set rs = Server.CreateObject("ADODB.Recordset")
        rs.PageSize=1000
        rs.Open query, con

wherePart=”和p.“INN”如“%38%”都可以正常工作,但如果
wherePart=”和v.“ShortName”如“%38%”,则记录集行数为-1。在Management studio中使用
wherePart=“AND v.“ShortName”如“%of theo%”“
执行查询返回900行

将该行添加到代码中:

rs.CursorLocation = 3 'adUseClient
默认设置可能不允许动态遍历,从而“禁用”分页机制