• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: EOModeler syntax error
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: EOModeler syntax error


  • Subject: Re: EOModeler syntax error
  • From: Kieran Kelleher <email@hidden>
  • Date: Thu, 4 Mar 2004 11:57:00 -0500

USER is a reserved word in MySQL (a function actually), so change it to something else for that table.


________________________________________________________________
Config = OS X 10.3.2 / Java 1.4.1 / WO 5.2.2 / MySQL 4.0.18 / Connector-J 3.0.11
Blog: http://webobjects.webhop.org/



On Mar 4, 2004, at 11:13 AM, Ben Schwartz wrote:

Hi,

I'm new to the WO world and I'm trying out some code generation with
EOModeler.
I created a model of a MySQL table in there, and saved that model - I then
wanted to start populating that db so I decided to use the "Display Group
Component" within New Project > Display Group Component in Xcode. It works
great and makes a page where I should be able to insert new records in the
DB. Unfortunately when I input a new record and tell it to save to the db
here is the error message I get:


Error: com.webobjects.eoaccess.EOGeneralAdaptorException:
EvaluateExpression failed: : Next exception:SQL State:42000 -- error code:
1064 -- msg: Syntax error or access violation: You have an error in your SQL
syntax near 'User(pk, password, username) VALUES (1, 'password', 'ben')' at
line 1


The reason why that syntax is wrong is because there is no space between
"User" and the first "(" . The problem is that the SQL syntax is generated
by either Xcode or EOModeler - I don't know which one and that's where I
need help. Is there something I am doing wrong for the syntax to be wrong
and is there a place where I could manually change it for the syntax to be
correct?


Thanks very much in advance for your help,

-Ben
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: EOModeler syntax error
      • From: Ben Schwartz <email@hidden>
References: 
 >EOModeler syntax error (From: Ben Schwartz <email@hidden>)

  • Prev by Date: Custom link attachments and IE
  • Next by Date: Re: EOModeler syntax error
  • Previous by thread: EOModeler syntax error
  • Next by thread: Re: EOModeler syntax error
  • Index(es):
    • Date
    • Thread