Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hi. I made a data display and update asp pages using frontpage. displa

Status
Not open for further replies.
Jan 21, 2005
46
US
Hi. I made a data display and update asp pages using frontpage. display.asp gets date values(MM/DD/YYYY) from MS Access database, parse an ID parameter to update.asp page. update.asp page is supposed to show the parsed ID and date values, but it only shows ID and text fields, not date fields. I think I need some formatting in the date format in between processes, but don't know how.
I also need to write/update dates to Access database after successfully displayed them, so if a new format is needed to do that, please give me an instruction.

The display.asp shows date without any problem(6/1/2006). Each text box's initial value in update.asp is set to like <%=request("ETD")%>. Thanks for your help in advance.
 
Hi, Chris,

1. display.asp's query look like this: fp_sQry="SELECT * FROM tblDetail WHERE (CustPO = '::CustPO::') ORDER BY OrderDetailID ASC"
And it shows data like this: <%=FP_FieldVal(fp_rs,"ETD")%>

2. update.asp has a form to display data and to upload to update_records.asp.
<form method="POST" action="update_records.asp">
:
<input type="text" class="content4" name="ETD1" size="12" value="<%=request("ETD")%>"></td>

3. update_records.asp's SQL looks like this: fp_sQry="UPDATE tblDetail SET ETD='::ETD::', ETA='::ETA::' , Vessel='::Vessel::', Container='::Container::', ShipDocsCopy='::ShipDocsCopy::', ShipDocsOriginal='::ShipDocsOriginal::', MillPaid='::MillPaid::', PayReceived='::payReceived::', DetailMemo='::DetailMemo::', Destination_Detail='::Destination_Detail::' WHERE OrderDetailID = ::OrderDetailID:: "

I have a problem from step 2, so I need to first make update.asp successfully displays data in date format fields, then proceed to step 3 to successfully update Access database. Where and how should I use FormatDateTime function?
 
OK, somehow I made it show data in update.asp page in frontpage, but now when I try to update the record, I get a database error. Here's the SQL:

UPDATE tblDetail SET CustPOTrack='::CustPOTrack::', Destination_Detail=':estination_Detail::', ETD='::ETD::', ETA='::ETA::' , Vessel='::Vessel::', Container='::Container::', ShipDocsCopy='::ShipDocsCopy::', ShipDocsOriginal='::ShipDocsOriginal::', MillPaid='::MillPaid::', PayReceived='::payReceived::', DetailMemo=':etailMemo::' WHERE OrderDetailID = ::OrderDetailID::

What could be wrong when executing this SQL?
 
I've never seen this format before, but it looks a little inconsistent to me.

Destination_Detail=':[!]:D[/!]estination_Detail::',

And

DetailMemo=':[!]:D[/!]etailMemo::'



-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top