Microsoft
Software
Hardware
Network
Question : db.Execute result
I'm using the following to insert a record in a table:
1: 2: 3:
sql="INSERT INTO table (Order,Quantity) VALUES ('test',10) db.execute (sql)
How can I find out the db.execute actually added a new record or not.
If the
order
field's
Index
is set to
Yes(No Duplicate)
it will fail to insert a new record if
Order
is duplicated
thanks for any kind of help
Answer : db.Execute result
Dim lRecs As Long
sql="INSERT INTO table (Order,Quantity) VALUES ('test',10)
With CurrentDb
.execute (sql)
lRecs = .RecordsAffected
End With
If lRecs>0 then ' it happened
mx
Random Solutions
edit excel object embedded in PowerPoint via PowerPoint macro
Need some urgent help with adding totals on a page
Sharepoint HostHeader Web site and Office Web Applications not working correctly
PHP - display HTML table as inverted mysql table
classic asp 3.0 an email
acer aspire am5640...darn sound!!!
Using rand() to generate data
QoS Prioritzation - Branch Office vs. YouTube
Adding Disk Space to VM Ware Server
The difference between DVD and digital format?