Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 626
  • Last Modified:

can't update enum field in MySQL

I've have this code where I use read as a boolean field it's just a enum field with a value of ('0','1').

Set rs = objConn.execute("UPDATE pm SET read = 0 (Where id = "&strid&") ")

But it won't update I get this error

Microsoft OLE DB Provider for ODBC Drivers error '80040e09'
[TCX][MyODBC]You have an error in your SQL syntax near 'read = 0 (Where id = 1) ' at line 1

I'm rather new to mysql and is mostly used to Access so I might be doing something basic wrong.


Cheers
bjawnie
0
bjawnie
Asked:
bjawnie
  • 5
  • 5
1 Solution
 
AlfaNoMoreCommented:
Set rs = objConn.execute("UPDATE pm SET read = 0 WHERE id = " & strid)
0
 
bjawnieAuthor Commented:
I didn't help get's the same error msg.
0
 
AlfaNoMoreCommented:
Set rs = objConn.execute("UPDATE pm SET read = 0 WHERE id = " & strid & ";")
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
bjawnieAuthor Commented:
still no change :(
0
 
AlfaNoMoreCommented:
Clutching @ straws here:

Set rs = objConn.execute("UPDATE [pm] SET [read] = 0 WHERE [id] = " & strid & ";")
0
 
bjawnieAuthor Commented:
No, that didn't help either. I confused :o(
0
 
AlfaNoMoreCommented:
Me too!
0
 
bjawnieAuthor Commented:
Found the problem.

It seems that I wasn't allowed to name a field "read" after changing it it works smooth.

Now how do I cancel this questiong?

/bjawnie
0
 
AlfaNoMoreCommented:
Ask a new question (0 points) inside http://www.experts-exchange.com/Community_Support/. Just copy the URL of THIS page into a message.
0
 
bjawnieAuthor Commented:
oki thanX
0
 
Computer101Commented:
Points refunded and placed in PAQ

Computer101
E-E Admin
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 5
  • 5
Tackle projects and never again get stuck behind a technical roadblock.
Join Now