By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,521 Members | 1,259 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,521 IT Pros & Developers. It's quick & easy.

delete query

P: n/a
The following delete query:

DoCmd.RunSQL "delete * from [SBCD] where [SRF#]='" & strInput & "'"

and

DoCmd.RunSQL "delete [SRF#] from [SBCD] where [SRF#]='" & strInput & "'"

Are they equivalent in term of functionality?
Nov 13 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Thompson Yip wrote:
The following delete query:

DoCmd.RunSQL "delete * from [SBCD] where [SRF#]='" & strInput & "'"

and

DoCmd.RunSQL "delete [SRF#] from [SBCD] where [SRF#]='" & strInput & "'"

Are they equivalent in term of functionality?


Yes.

I've never used the latter, from a logical standpoint that could look like:
"update sbcd set [srf#]=null where [SRF#]='" & strInput & "'" as it
looks like it's deleting one column and not the entire row.

Access' delete statement is an enigma as the syntax looks column based
yet the delete command itself is rowset based. Compare that to SQL
Server where the command would be:

delete from tablename where columnname='something'

--
Error reading sig - A)bort R)etry I)nfluence with large hammer
Nov 13 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.