|
drlaffoon -> RE: INSERT INTO Not working (1/14/2006 12:42:05)
|
What I am trying to do is within the database editor of frontpage create a button that will allow users to archive a record into another table before they change the record and continue with the update query. I did try and bracket [New] in the field list and this did not work however new is not bracketed on the page with the update query. Thanks for continuing to helping below is the whole code for the insert <!--webbot bot="DatabaseRegionStart" s-columnnames="archiveid,OffenderID,LastName,FirstName,MiddleName,Address,AptNo,City,State,Zip,Offense,RegisterDate,OffenseDate,CntyOffen,Felony,Misdemeanor,VictimAge,Notes,Case_Sub,DOB,Photo,MatchType,Country,New,Longitude,Latitude,BOLongitude,BOLatitude,Display" s-columntypes="3,3,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,5,5,5,5,202" s-dataconnection="sexoffenders" b-tableformat="FALSE" b-menuformat="FALSE" s-menuchoice s-menuvalue b-tableborder="TRUE" b-tableexpand="TRUE" b-tableheader="TRUE" b-listlabels="FALSE" b-listseparator="FALSE" i-ListFormat="0" b-makeform="FALSE" s-RecordSource s-displaycolumns s-criteria s-order s-sql="INSERT INTO ARCHIVE_SO ( OffenderID, LastName, FirstName, MiddleName, Address, AptNo, City, State, Zip, Offense, RegisterDate, OffenseDate, CntyOffen, Felony, Misdemeanor, VictimAge, Notes, Case_Sub, DOB, Photo, MatchType, Country, [New], Longitude, Latitude, BOLongitude, BOLatitude, Display ) VALUES ( ::OffenderID:: , '::LastName::' , '::FirstName::' , '::MiddleName::' , '::Address::' , '::AptNo::' , '::City::' , '::State::' , '::Zip::' , '::Offense::' , '::RegisterDate::' , '::OffenseDate::' , '::CntyOffen::' , '::Felony::' , '::Misdemeanor::' , '::VictimAge::' , '::Notes::' , '::Case_Sub::' , '::DOB::' , '::Photo::' , '::MatchType::' , '::Country::' , '::New::' , ::Longitude:: , ::Latitude:: , ::BOLongitude:: , ::BOLatitude:: , '::Display::' )" b-procedure="FALSE" clientside SuggestedExt="asp" s-DefaultFields="OffenderID=0&LastName=&FirstName=&MiddleName=&Address=&AptNo=&City=&State=&Zip=&Offense=&RegisterDate=&OffenseDate=&CntyOffen=&Felony=&Misdemeanor=&VictimAge=&Notes=&Case_Sub=&DOB=&Photo=&MatchType=&Country=&New=&Longitude=0&Latitude=0&BOLongitude=0&BOLatitude=0&Display=&archiveid=0" s-NoRecordsFound="Record updated in table." i-MaxRecords="1" i-GroupSize="0" u-dblib="../../../_fpclass/fpdblib.inc" u-dbrgn1="../../../_fpclass/fpdbrgn1.inc" u-dbrgn2="../../../_fpclass/fpdbrgn2.inc" Tag="BODY" startspan BOTID="0" preview="<table border=0 width="100%"><tr><td bgcolor="#FFFF00"><font color="#000000">This is the start of a Database Results region. The page must be fetched from a web server with a web browser to display correctly; the current web is stored on your local disk or network.</font></td></tr></table>" --><!--#include file="../../../_fpclass/fpdblib.inc"-->
<% if 0 then %>
<SCRIPT Language="JavaScript">
document.write("<div style='background: yellow; color: black;'>The Database Results component on this page is unable to display database content. The page must have a filename ending in '.asp', and the web must be hosted on a server that supports Active Server Pages.</div>");
</SCRIPT>
<% end if %>
<%
fp_sQry="INSERT INTO ARCHIVE_SO ( OffenderID, LastName, FirstName, MiddleName, Address, AptNo, City, State, Zip, Offense, RegisterDate, OffenseDate, CntyOffen, Felony, Misdemeanor, VictimAge, Notes, Case_Sub, DOB, Photo, MatchType, Country, [New], Longitude, Latitude, BOLongitude, BOLatitude, Display ) VALUES ( ::OffenderID:: , '::LastName::' , '::FirstName::' , '::MiddleName::' , '::Address::' , '::AptNo::' , '::City::' , '::State::' , '::Zip::' , '::Offense::' , '::RegisterDate::' , '::OffenseDate::' , '::CntyOffen::' , '::Felony::' , '::Misdemeanor::' , '::VictimAge::' , '::Notes::' , '::Case_Sub::' , '::DOB::' , '::Photo::' , '::MatchType::' , '::Country::' , '::New::' , ::Longitude:: , ::Latitude:: , ::BOLongitude:: , ::BOLatitude:: , '::Display::' )"
fp_sDefault="OffenderID=0&LastName=&FirstName=&MiddleName=&Address=&AptNo=&City=&State=&Zip=&Offense=&RegisterDate=&OffenseDate=&CntyOffen=&Felony=&Misdemeanor=&VictimAge=&Notes=&Case_Sub=&DOB=&Photo=&MatchType=&Country=&New=&Longitude=0&Latitude=0&BOLongitude=0&BOLatitude=0&Display=&archiveid=0"
fp_sNoRecords="Record updated in table."
fp_sDataConn="sexoffenders"
fp_iMaxRecords=1
fp_iCommandType=1
fp_iPageSize=0
fp_fTableFormat=False
fp_fMenuFormat=False
fp_sMenuChoice=""
fp_sMenuValue=""
fp_sColTypes="&archiveid=3&OffenderID=3&LastName=202&FirstName=202&MiddleName=202&Address=202&AptNo=202&City=202&State=202&Zip=202&Offense=202&RegisterDate=202&OffenseDate=202&CntyOffen=202&Felony=202&Misdemeanor=202&VictimAge=202&Notes=202&Case_Sub=202&DOB=202&Photo=202&MatchType=202&Country=202&New=202&Longitude=5&Latitude=5&BOLongitude=5&BOLatitude=5&Display=202&"
fp_iDisplayCols=16
fp_fCustomQuery=True
BOTID=0
fp_iRegion=BOTID
%>
<!--#include file="../../../_fpclass/fpdbrgn1.inc"-->
<!--webbot bot="DatabaseRegionStart" endspan i-checksum="63361" -->
<p><!--webbot bot="PurpleText" PREVIEW="This is the UPDATE query." --></p>
<!--webbot bot="DatabaseRegionEnd" b-tableformat="FALSE" b-menuformat="FALSE" u-dbrgn2="../../../_fpclass/fpdbrgn2.inc" i-groupsize="0" clientside Tag="BODY" startspan preview="<table border=0 width="100%"><tr><td bgcolor="#FFFF00"><font color="#000000">This is the end of a Database Results region.</font></td></tr></table>" --><!--#include file="../../../_fpclass/fpdbrgn2.inc"-->
<!--webbot bot="DatabaseRegionEnd" endspan i-checksum="9297" -->
</body>
</html>
|
|
|
|