Solved

mysql create table

Posted on 2014-02-01
2
491 Views
Last Modified: 2014-02-01
Tried the below showing syntax error at last line

#1064 - 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 'group varchar(255) )' at line 53

create table magento_customer (
website varchar(255),
email  varchar(255),
group_id varchar(255),
disable_auto_group_change varchar(255),
firstname varchar(255),
lastname varchar(255),
password_hash varchar(255),
billing_prefix varchar(255),
billing_firstname  varchar(255),
billing_middlename varchar(255),
billing_lastname varchar(255),
billing_suffix varchar(255),
billing_street_full varchar(255),
billing_street1 varchar(255),
billing_street2 varchar(255),
billing_street3 varchar(255),
billing_street4 varchar(255),
billing_street5 varchar(255),
billing_street6 varchar(255),
billing_street7 varchar(255),
billing_street8 varchar(255),
billing_city varchar(255),
billing_region varchar(255),
billing_country varchar(255),
billing_postcode varchar(255),
billing_telephone varchar(255),
billing_company varchar(255),
billing_fax varchar(255),
shipping_prefix varchar(255),
shipping_firstname varchar(255),
shipping_middlename varchar(255),
shipping_lastname varchar(255),
shipping_suffix varchar(255),
shipping_street_full varchar(255),
shipping_street1 varchar(255),
shipping_street2 varchar(255),
shipping_street3 varchar(255),
shipping_street4 varchar(255),
shipping_street5 varchar(255),
shipping_street6 varchar(255),
shipping_street7 varchar(255),
shipping_street8 varchar(255),
shipping_city varchar(255),
shipping_region varchar(255),
shipping_country varchar(255),
shipping_postcode varchar(255),
shipping_telephone varchar(255),
shipping_company varchar(255),
shipping_fax varchar(255),
created_in varchar(255),
is_subscribed varchar(255),
group varchar(255)
)

Open in new window

0
Comment
Question by:magento
2 Comments
 
LVL 34

Accepted Solution

by:
Dan Craciun earned 500 total points
ID: 39826331
Group is a reserved word. You cannot use it as a column name: https://dev.mysql.com/doc/refman/5.6/en/reserved-words.html

HTH,
Dan
0
 
LVL 5

Author Comment

by:magento
ID: 39826340
Dan,

Good catch . Thanks for the url . I learned it now .
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

As a database administrator, you may need to audit your table(s) to determine whether the data types are optimal for your real-world data needs.  This Article is intended to be a resource for such a task. Preface The other day, I was involved …
Popularity Can Be Measured Sometimes we deal with questions of popularity, and we need a way to collect opinions from our clients.  This article shows a simple teaching example of how we might elect a favorite color by letting our clients vote for …
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now