Hello,

If a user selects a vendor from a drop-down list, I want to populate a form and main 
table called "purchases" with the info from the vendor data that I have in stored in 
another table called "vendor". Here is some of the code that checks the option field 
in the drop-down menu. I get a syntax error with this though.

Any better way?

Robert O.

<CFIF selectvendor is not "New Vendor">
<cfquery name="addvendor" datasource="purchases">
INSERT INTO purchases (
vendor,
Contact,
Address)
VALUES (
'#FORM.vendor#',
'#FORM.contact#',
'#FORM.Address#')
from selectedvendor
</cfquery>
</CFIF>
______________________________________________________________________
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to