Using the below method,
<%
remaining_stock = cint(product_stock) - cint(chQuantity)
%>
<%
sqlString = "UPDATE Products SET " &_
"product_stock='" & remaining_stock & "'," &_
"WHERE product_id='" &chID& "'"
Conn.execute sqlString
%>
i keep getting the error : invalid user.table.column, table.column, or column specification. sigh what's wrong?
if i use response.write, i do get what i want, which is
UPDATE Products SET product_stock='49',WHERE product_id='1'
My products table looks like this.
Create table Products(
product_id INTEGER not null unique,
product_name VARCHAR(50),
product_price REAL,
product_description VARCHAR(3000),
product_category VARCHAR(30),
product_subcategory VARCHAR(30),
product_stock INTEGER,
product_image VARCHAR(50),
product_status INTEGER,
product_featured INTEGER,
PRIMARY KEY (product_id)
);
Does it have anything to do with the fields being set to an integer?
************************************************** ********************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...