• 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
MySQL Syntax Error
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

MySQL Syntax Error


  • Subject: MySQL Syntax Error
  • From: Ron X <email@hidden>
  • Date: Mon, 25 Feb 2013 12:57:55 +0300

Hi,

i use MySQL 5.1 with MySQL Adaptor (Wonder 5.7.1) and mysql-connector 5.1.22

and during the migration i have an error:

MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'null billingDescriptor VARCHAR(255) NOT NULL' at line 1
  at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
...

Caused by: java.lang.RuntimeException: Failed to execute 'alter table LoggedAction null billingDescriptor VARCHAR(255) NOT NULL'.

Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'null billingDescriptor VARCHAR(255) NOT NULL' at line 1
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)


my code is:

            loggedActionTable = database.existingTableNamed(LoggedAction.ENTITY_NAME);
            loggedActionTable.newStringColumn("billingDescriptor", 255, false);

why this 'null' appears?

any ideas?

Thanx.
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: MySQL Syntax Error
      • From: Pascal Robert <email@hidden>
  • Prev by Date: Re: Comments
  • Next by Date: Re: MySQL Syntax Error
  • Previous by thread: Re: Comments
  • Next by thread: Re: MySQL Syntax Error
  • Index(es):
    • Date
    • Thread