In this Microsoft Access tutorial, I'm going to teach you the difference between DoCmd.RunSQL and CurrentDb.Execute and when you would want to use each.
Mike from Newcastle, England (a Platinum Member) asks: I've been following your Microsoft Access videos for years, and you used to always use DoCmd.RunSQL in your code. But recently, I've noticed you using CurrentDb.Execute instead. What's the difference between the two, and what should I use?
Silver members and up get access to an Extended Cut of this video. Members will learn how to trap errors in db.Execute commands with the dbFailOnError parameter. We will also learn how to count how many records were affected with any SQL command by using the RecordsAffected property.
MEMBERS-ONLY EXTENDED CUT VIDEO:
• RunSQL vs. Execute EXT...
BECOME A MEMBER:
KZitem: / @599cd
or My Site: 599cd.com/THMember
LEARN MORE:
RunSQL vs Execute: 599cd.com/RunSQLvExecute
PREREQUISITES:
SQL with Access: 599cd.com/SQLwithAccess
Action Queries: 599cd.com/ActionQuery
Intro to VBA: 599cd.com/IntroVBA
LINKS:
Turn Off Warnings: 599cd.com/SetWarnings
Value From a Form: 599cd.com/FormName
Error Handling: 599cd.com/ErrorHandling
RECOMMENDED COURSES:
Access SQL Seminars: 599cd.com/SQL
Access Developer Courses: 599cd.com/Developer
RICK'S PICKS:
No Longer Set: nolongerset.com/avoid-docmd-ru...
DEVelopers HUT: devhut.net
Access Forever: accessforever.org
Denver Area Access Users Group: daaug.org
Access User Groups: accessusergroups.org
FREE TEMPLATE DOWNLOADS:
TechHelp Free Templates: 599cd.com/THFree
Blank Template: 599cd.com/Blank
Contact Management: 599cd.com/Contacts
Order Entry & Invoicing: 599cd.com/Invoicing
More Access Templates: 599cd.com/AccessTemplates
ADDITIONAL RESOURCES:
FREE Access Beginner Level 1: 599cd.com/Free1
How to Use Access in 30 Minutes: 599cd.com/30Minutes
$1 Access Level 2: 599cd.com/1Dollar
Donate to my Tip Jar: 599cd.com/TipJar
Get on my Mailing List: 599cd.com/YTML
Contact Me: 599cd.com/Contact
TechHelp: 599cd.com/TechHelp
Consulting Help: 599cd.com/DevNet
Twitter: / learningaccess
en.wikipedia.org/wiki/Microso...
products.office.com/en-us/access
microsoft.com/en-us/microsoft...
KEYWORDS:
access 2016, access 2019, access 2021, access 365, microsoft access, ms access, ms access tutorial, #msaccess, #microsoftaccess, #help, #howto, #tutorial, #learn, #lesson, #training, #database, What is the difference between docmd.runsql and currentdb.execute, Execute vs RunSQL, CurrentDb.Execute vs. docmd.runsql, suppress warnings, handle errors, dbFailOnError, RecordsAffected, run-time error 3061, too few parameters expected 1
QUESTIONS:
Please feel free to post your questions or comments below. Thanks.
Негізгі бет What's the Difference Between DoCmd.RunSQL and CurrentDb.Execute in Microsoft Access
Пікірлер: 11