| | |
| |
Active Server Pages what is asp programming how to sample asp example code scripts software asp forum mail sessions applications global.asa CJWSoft ASPProtect ASPBanner ASPClassifieds
(Advanced)
(Components)
(Database)
(General)
(Vbscript)

|
|
|
|
Subject: |
Help Converting to Currency |
|
From: |
Chris |
|
Date: |
8/25/2000 1:27:03 PM |
|
IP: |
12.26.184.110 |
I use the following code to try and enter the value stored in the variable "price", which was requested from a form, into a Currency type field in the underlying database:
SQL = "INSERT INTO tblCart (sid,prod,qty,color,price) VALUES ("
SQL = SQL & " " & sid & " ,"
SQL = SQL & " " & prod & " ,"
SQL = SQL & " " & qty & " ,"
SQL = SQL & " " & color & " ,"
SQL = SQL & " " & CONVERT(money, price) & " "
SQL = SQL & ")"
Response.Write(SQL)
Conn.Execute(SQL)
However, I get the following error when I try to do so:
Microsoft VBScript runtime error 800a000d
Type mismatch: CONVERT
additem.asp, line 32
|
Follow Up - Re: Help Converting to Currency - Afolabi Arowolo 10/2/2000 7:42:21 PM
|
|
|
|
|
|