在后台点 产品管理》首年特殊定价 出现错误:
Microsoft JET Database Engine 错误 '80040e37'
Microsoft Jet 数据库引擎找不到输入表或查询 'Pricelevellist'。 确定它是否存在,以及它的名称的拼写是否正确。
/siteadmin/SystemSet/PriceSet.asp,行 112
==============================
问题原因: 没有按顺序打补丁所致,解决办法: 如果没有升级至最新版,请在后台先升级为最新版,如果还是不行,将下面代码存为 update.asp 放在网站的根目录,然后访问 :http://您的域名/update.asp 访问一次就可以了,然后删除这个文件。
<!--#include virtual="/config/config.asp" -->
<%
on error resume next
conn.open constr
conn.execute "Create TABLE [Pricelevellist](p_id Counter NOT NULL,p_level Long,p_proid Text(25),p_price long,p_date Time default now())"
if reguser_cnprice and reguser_cnprice_user>0 and isnumeric(reguser_level) then
conn.execute "insert into Pricelevellist(p_level,p_proid,p_price) values("& reguser_level &",'domcn',"& reguser_cnprice_user &")"
end if
Filename=server.MapPath("/config/const.asp")
dim delarr(1)
delarr(0)="reguser_cnprice_user="
delarr(1)="reguser_cnprice="
call delconststr(Filename,delarr)
seatstr="USEtemplate"
newstr="USEmanagerTpl=""2""'用户管理中心模板设置"
call addconstrstr(Filename,seatstr,newstr)
conn.close
function delconststr(byval Filename,byval delarr)
Set fsoobj = CreateObject("Scripting.FileSystemObject")
If fsoobj.FileExists(Filename) Then
set hndFile = fsoobj.OpenTextFile(Filename)
LoadFile = hndFile.ReadAll
Set hndFile = Nothing
end if
for each delstritem in delarr
delstritem=trim(delstritem)
if not isnull(loadfile) and loadfile<>"" and instr(LoadFile,delstritem)>0 then
allarr=split(loadFile,delstritem)
if ubound(allarr)>0 then
pos=instr(allarr(1),vbcrlf)
if pos>0 then
nstr=mid(allarr(1),pos + 1)
LoadFile=allarr(0) & nstr
end if
end if
end if
next
'response.write replace(replace(LoadFile,"%",""),vbcrlf,"<br>")
if LoadFile<>"" then
Set OutStream = fsoobj.OpenTextFile(Filename,2,True)'打开文件并写入文件不存在就创建
OutStream.Write LoadFile
set OutStream=nothing
end if
Set fsoobj = Nothing
end function
function addconstrstr(byval Filename,byval seatstr,byval newstr)
endstr=""
Set fsoobj = CreateObject("Scripting.FileSystemObject")
If fsoobj.FileExists(Filename) Then
set hndFile = fsoobj.OpenTextFile(Filename)
LoadFile = hndFile.ReadAll
Set hndFile = Nothing
end if
if not isnull(loadfile) and loadfile<>"" and instr(LoadFile,newstr)=0 then
loadfile=trim(loadfile)
allarr=split(loadFile,seatstr)
if ubound(allarr)>0 then
pos=instr(allarr(1),vbcrlf)
if pos>0 then
nstr=mid(allarr(1),1,pos)
ostr=mid(allarr(1),pos)
endstr=allarr(0) & seatstr & nstr & vbcrlf & newstr & ostr
if instr(endstr,newstr)>0 then
Set OutStream = fsoobj.OpenTextFile(Filename,2,True)'打开文件并写入文件不存在就创建
OutStream.Write endstr
set OutStream=nothing
end if
end if
end if
end if
Set fsoobj = Nothing
end function
response.write "升级完毕!请删除本文件!"
%>