Re: Updating a field in a record stored in a table
- From: "Rick Brandt" <rickbrandt2@xxxxxxxxxxx>
- Date: Thu, 18 Aug 2005 16:13:19 GMT
ndunwoodie wrote:
> I'm sorry to report that I did have a field name misspelled. Now my
> problem is that the code doesn't do any updating at all. My field,
> txtMBusDetention, in the table is just as empty after running the
> code as before(it is spelled correctly). It is supposed to have a 1
> in it.
And you get no errors? Is that field a number or text DataType? If it's
text you need to put quotes around the 1. Since the SQL string is already
inside double-quotes you have to use single quotes to avoid a conflict.
strSQL = "UPDATE students " & _
"SET txtMBusDetention = '1' " & _
"WHERE txtStudent = '" & Forms!frmMissBus!cboName & "'"
CurrentDb.Execute strSQL, dbFailOnError
--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
.
- Follow-Ups:
- Re: Updating a field in a record stored in a table
- From: ndunwoodie
- Re: Updating a field in a record stored in a table
- References:
- Updating a field in a record stored in a table
- From: ndunwoodie
- Re: Updating a field in a record stored in a table
- From: Rick Brandt
- Re: Updating a field in a record stored in a table
- From: ndunwoodie
- Re: Updating a field in a record stored in a table
- From: Rick Brandt
- Re: Updating a field in a record stored in a table
- From: ndunwoodie
- Re: Updating a field in a record stored in a table
- From: Rick Brandt
- Re: Updating a field in a record stored in a table
- From: ndunwoodie
- Re: Updating a field in a record stored in a table
- From: Rick Brandt
- Re: Updating a field in a record stored in a table
- From: ndunwoodie
- Updating a field in a record stored in a table
- Prev by Date: SendObject
- Next by Date: RE: Update Windows Registry w/Access
- Previous by thread: Re: Updating a field in a record stored in a table
- Next by thread: Re: Updating a field in a record stored in a table
- Index(es):
Relevant Pages
|