SA-MP Forums Archive
Little help Incorrect syntax near - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Little help Incorrect syntax near (/showthread.php?tid=612167)



Little help Incorrect syntax near - kbalor - 14.07.2016

I need a help with this problem. I'm trying to fix it but I couldn't find the exact lines.
Example of the incorrect syntax
Код:
Msg 156, Level 15, State 1, Line 14
Incorrect syntax near the keyword 'IF'.
Msg 102, Level 15, State 1, Line 14
Incorrect syntax near '`'.
This is the line 14
Код:
CREATE TABLE IF NOT EXISTS `accounts` (
  `Key` int(11) NOT NULL AUTO_INCREMENT,
Full Error link http://pastebin.com/hKdwt51e
SQL Script Link: http://pastebin.com/3w58vMbf


Re: Little help Incorrect syntax near - kbalor - 16.07.2016

any idea guys?


Re: Little help Incorrect syntax near - Pearson - 16.07.2016

I think so.... but wait.


Re: Little help Incorrect syntax near - Pearson - 16.07.2016

PHP код:
    querystr1 "CREATE TABLE IF NOT EXISTS `Account`(`ID`int AUTO_INCREMENT PRIMARY KEY, `Name` varchar(24) NOT NULL, `Password` varchar(129) NOT NULL, `Email` varchar(129) NOT NULL, `Admin` int(11) NOT NULL, `Sex` int(11) NOT NULL, `Age` int(11) NOT NULL, `Level` int(11) NOT NULL, `Money` int(11) NOT NULL, `Skin` int(11) NOT NULL, `pJob` int(11) NOT NULL,";
    
querystr2 "`pCar` int(11) NOT NULL,`pSaxlid` int(11) NOT NULL,`pInterieri` int(11) NOT NULL,`pBankfuli` int(11) NOT NULL,`pBorbali` int(11) NOT NULL,`pSpoileri` int(11) NOT NULL,`pBamperi2` int(11) NOT NULL,`pPaintjobi` int(11) NOT NULL,`pHydrawlic` int(11) NOT NULL,`pSatiety` int(11) NOT NULL,`pWyurvili` int(11) NOT NULL, `pRank` int(11) NOT NULL, `pMember` int(11) NOT NULL, `pLeader` int(11) NOT NULL)"
Try Making Your Script Like This dude.


Re: Little help Incorrect syntax near - [cS]Owain - 16.07.2016

Remove these comments from top and then try to import.
Код:
-- --------------------------------------------------------
-- Host:                         127.0.0.1
-- Server version:               10.0.20-MariaDB - mariadb.org binary distribution
-- Server OS:                    Win32
-- HeidiSQL Version:             9.1.0.4867
-- --------------------------------------------------------
 
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET NAMES utf */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;