raisefunctionError("cannot find fields to modify")
fields=fieldstext.split("\n")
#output some text
t=t+"<CENTER bgcolor=white>The document <B>%s</B> has been found in the database.</CENTER><BR>Please modify the following fields:<BR>Then press the 'END' button at the bottom of the page<BR>\n"%rn
forfieldinfields:
subfield=""
value=""
marccode=""
text=""
# retrieve and display the modification text
t=t+"<FONT color=darkblue>\n"
res=run_sql("SELECT modd FROM sbmMODIFY WHERE modn='%s'"%field)
iflen(res)>0:
t=t+"<small>%s</small> </FONT>\n"%res[0][0]
# retrieve the marc code associated with the field
res=run_sql("SELECT marccode FROM sbmFIELDDESC WHERE name='%s'"%field)
iflen(res)>0:
marccode=res[0][0]
# then retrieve the previous value of the field
ifmarccode!="":
value=Get_Field(marccode,sysno)
res=run_sql("SELECT * FROM sbmFIELDDESC WHERE name = '%s'"%field)