Hi all

really stuck here. am trying to update a field in a row in my database from within a procedure. have a connection to the database (OleDBConnection1). Trying to run an Update statement that will update the table "ITEMS" column "Quantity" with a WHERE clause based on "ItemID"

something like this

UPDATE ITEMS SET Quantity = Quantity - intSoldQty ' from txtbox
WHERE ItemID = xxx 'this is also from a txtbox

no matter which approach I take I seem to come unstuck. I think the approach I would need to take is to create a SQL command and run it from the procedure but don't really know how to go about this, and can't seem to find anything useful on the internet. I can post my existing code and database if that would be useful...but if anybody could give me some generic code for creating a SQL command that will run straight onto a database I would really appreciate it

thanks in advance

cameron