简体   繁体   中英

How to update an Entry Visual Basic 2010

I can add delete update search and edit my simple pos system . But I have a little bit of a problem .

My professor requested this to add on my systemExample On my database I have an itemname called NUTELLA and its quantity is 10If I put Nutella/NUTELLA and Quantity is 30 on my inventory system it should not create a new line on my database and the quantity should add so it suppose to be ItemName : NUTELLA Quantity: 40

I hope you help me with my problem

Try this:

qry = "update tablename set Quantity=Quantity + '" & Quantity.text & "' where lower(ItemName) = '" & LCase(ItemName.text) & "'"

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM