Solved

ASP - Assigning new val w/'request.form' var in update query

Posted on 1997-07-14
2
276 Views
Last Modified: 2013-12-25
In Visual InterDev, I'm attempting to assign a new value to an update query using [request.form("var")].  VInterDev accepts the variable, but when the ASP form handler is executed, I receive a syntax error.  The criteria can contain a variable name, but what is the proper syntax for entering a variable into the 'new value' field in query designer?

My SQL statement:
UPDATE     tblEFIActionItemRegister_Volt
SET            comments = [request.form("comments")]
WHERE      (id = [id])

Also, I'm using the DCC/DTC component.

Thanks in advance.
0
Comment
Question by:jlow
2 Comments
 
LVL 28

Accepted Solution

by:
sybe earned 100 total points
ID: 1854469
What I usually do is make a read/write recordset(named "RS") with a SQL statement like this:

SELECT * FROM Table WHERE ID=[ID]

then

RS("comments")=Request.Form("comments")
RS.Update

and it is done

I don't like the VisualInterdev Wizard, it produces too much code, and whenever you want to adapt something you are lost.

0
 

Author Comment

by:jlow
ID: 1854470
RS.Update using a select query is something that I have not run across.  I'll try it.  Thanks for the answer.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Accessibility and Usability are two concepts that seem to be closely related.  But, too many people seem to have a distorted perception of them. During last five years, those two words have come to the day-to-day work of almost every web develope…
"In order to have an organized way for empathy mapping, we rely on a psychological model and trying to model it in a simple way, so we will split the board to three section for each persona and a scenario and try to see what those personas would Do,…
This tutorial walks through the best practices in adding a local business to Google Maps including how to properly search for duplicates, marker placement, and inputing business details. Login to your Google Account, then search for "Google Mapmaker…
The viewer will learn how to count occurrences of each item in an array.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now