Error 1064!!! Dont know how to fix.

[expired user #6096]'s profile image [expired user #6096] posted 12 years ago in Running SQL scripts Permalink
Below is the error i get and the code. I get it on both heidsql and navicat. I have no idea what it means or how to correct it. Your input and correction would be greatly appreciated.Also my sql version is 5.1.58 running on a linux platform(ubuntu).

[Err] 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 '`auth`' at line 1
[Err]

Code:

/*
Navicat MySQL Data Transfer

Source Server : My server
Source Server Version : 50509
Source Host : 192.168.1.8:3306
Source Database : auth

Target Server Type : MYSQL
Target Server Version : 50509
File Encoding : 65001

Date: 2011-09-19 20:38:18
*/

SET FOREIGN_KEY_CHECKS=0;

-- ----------------------------
-- Table structure for `account`
-- ----------------------------
DROP TABLE IF EXISTS `account`;
CREATE TABLE `account` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Identifier',
`username` varchar(32) NOT NULL DEFAULT '',
`sha_pass_hash` varchar(40) NOT NULL DEFAULT '',
`sessionkey` longtext,
`v` longtext,
`s` longtext,
`email` text,
`joindate` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`last_ip` varchar(30) NOT NULL DEFAULT '127.0.0.1',
`failed_logins` int(11) unsigned NOT NULL DEFAULT '0',
`locked` tinyint(3) unsigned NOT NULL DEFAULT '0',
`last_login` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
`online` tinyint(4) NOT NULL DEFAULT '0',
`expansion` tinyint(3) unsigned NOT NULL DEFAULT '2',
`mutetime` bigint(40) unsigned NOT NULL DEFAULT '0',
`locale` tinyint(3) unsigned NOT NULL DEFAULT '0',
`recruiter` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`id`),
UNIQUE KEY `idx_username` (`username`)
) ENGINE=MyISAM AUTO_INCREMENT=7 DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC COMMENT='Account System';

-- ----------------------------
-- Records of account
-- ----------------------------
INSERT INTO `account` VALUES ('5', 'ADMINS', '1B5E796ABB4ED9AA505E583CAACCCA2346D971BD', '33DC723882589783DAF6DCC275C7C269E28C68AB8D3FFD2DFC8E5F93546A89553BA2DA42462624FD', '6A11E94FB6350F5B4A57EE3ABCAFE2B855DDFCE0D3AABC296FEB452DB9B751C3', 'A752E79DBC08307631DE4D448A61F1EBB6F2F4CC7E00902E3B2B3297744AED4B', 'admin@yourserver.com', '1993-07-27 02:12:30', '127.0.0.1', '0', '0', '2011-07-08 18:27:29', '0', '2', '0', '0', '0');

-- ----------------------------
-- Table structure for `account_access`
-- ----------------------------
DROP TABLE IF EXISTS `account_access`;
CREATE TABLE `account_access` (
`id` int(11) unsigned NOT NULL,
`gmlevel` tinyint(3) unsigned NOT NULL,
`RealmID` int(11) NOT NULL DEFAULT '-1',
PRIMARY KEY (`id`,`RealmID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC;

-- ----------------------------
-- Records of account_access
-- ----------------------------
INSERT INTO `account_access` VALUES ('5', '3', '-1');

-- ----------------------------
-- Table structure for `account_banned`
-- ----------------------------
DROP TABLE IF EXISTS `account_banned`;
CREATE TABLE `account_banned` (
`id` int(11) NOT NULL DEFAULT '0' COMMENT 'Account id',
`bandate` bigint(40) NOT NULL DEFAULT '0',
`unbandate` bigint(40) NOT NULL DEFAULT '0',
`bannedby` varchar(50) NOT NULL,
`banreason` varchar(255) NOT NULL,
`active` tinyint(4) NOT NULL DEFAULT '1',
PRIMARY KEY (`id`,`bandate`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC COMMENT='Ban List';

-- ----------------------------
-- Records of account_banned
-- ----------------------------

-- ----------------------------
-- Table structure for `ip_banned`
-- ----------------------------
DROP TABLE IF EXISTS `ip_banned`;
CREATE TABLE `ip_banned` (
`ip` varchar(32) NOT NULL DEFAULT '127.0.0.1',
`bandate` bigint(40) NOT NULL,
`unbandate` bigint(40) NOT NULL,
`bannedby` varchar(50) NOT NULL DEFAULT '[Console]',
`banreason` varchar(255) NOT NULL DEFAULT 'no reason',
PRIMARY KEY (`ip`,`bandate`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC COMMENT='Banned IPs';

-- ----------------------------
-- Records of ip_banned
-- ----------------------------

-- ----------------------------
-- Table structure for `logs`
-- ----------------------------
DROP TABLE IF EXISTS `logs`;
CREATE TABLE `logs` (
`time` int(14) NOT NULL,
`realm` int(4) NOT NULL,
`type` int(4) NOT NULL,
`string` text
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

-- ------
[Msg] Finished - Unsuccessfully
--------------------------------------------------
ansgar's profile image ansgar posted 12 years ago Permalink
There is no "`auth`" string in the above script so I assume you did not post the whole script here.

The above script is from Navicat, and you're asking HeidiSQL maintainers for support on that? You are kidding, man...
[expired user #6096]'s profile image [expired user #6096] posted 12 years ago Permalink
that was the entire code above and it does not work on either program. both spit out the same message as above. thanks for the help and criticism for trying to ask a question that someone may or may not have known.
ansgar's profile image ansgar posted 12 years ago Permalink
I could just successfully run your script, in a newly created database named "auth".
Which HeidiSQL version/revision do you use?

Please login to leave a reply, or register at first.