Hi,
I'm no expert at all, so can anyone see what this error might be coming
from?
Database mysql1 - Table machines running on localhost
Error
SQL-query :
CREATE TABLE `machines` (
`zrecord_serial` DOUBLE( 30 ) ,
`machine_type` VARCHAR( 30 ) ,
`model` VARCHAR( 30 ) ,
`machine_id` VARCHAR( 30 ) UNSIGNED AUTO_INCREMENT ,
`building` VARCHAR( 30 ) ,
`room` VARCHAR( 30 ) ,
`id_display` VARCHAR( 30 ) ,
`os` VARCHAR( 30 ) ,
`mac_address` DOUBLE( 30 ) ,
PRIMARY KEY ( `mac_address` )
) TYPE = MYISAM
MySQL said:
You have an error in your SQL syntax near '), `machine_type`
VARCHAR(30), `model` VARCHAR(30), `machine_id` VARCHAR(30) UNS' at line
1
I was trying to create the table by importing this file with phpMyAdmin:
# Script: machines_create_table1.sql
# Features: This sql script creates the MySQL
# table for the FileMaker data.
#
# Notes:
# This file only needs run if
# the table does not already exist
# in the destination database.
# The DBA should modify the table creation
# commands as needed before running this file.
#
# Usage: mysql mysql1 -u mysqluser1 < machines_create_table1.sql
#
# Used By: run manually by the MySQL DBA on the database server
# Copyright 2003 by .com Solutions Inc.
#
# ---------------------- Revision History ---------------
# Date By Changes
# 3-29-2003 dsimpson Initial Release
#
# This output file was created by FmPro Migrator version 1.24 on Sun
May 25 04:30:31 2003. By .com Solutions Inc. www.dotcomsolutionsinc.net
#
# specify database name
use mysql1
# drop table command - commented out
# DROP TABLE IF EXISTS mysql1.machines;
# create MySQL table to match structure of FileMaker file
CREATE TABLE IF NOT EXISTS mysql1.machines
(
zrecord_serial DOUBLE
NULL,
machine_type
VARCHAR(255) NULL,
model
VARCHAR(255) NULL,
machine_id
VARCHAR(255) UNSIGNED AUTO_INCREMENT NOT NULL,
building
VARCHAR(255) NULL,
room
VARCHAR(255) NULL,
id_display
VARCHAR(255) NULL,
os
VARCHAR(255) NULL,
mac_address DOUBLE
NULL,
PRIMARY KEY(machine_id)
) TYPE=MyISAM;
quit
Thanks very much for taking a look,
Ted