Announcement

Collapse
No announcement yet.

unable to execute query from myadmin or vb window

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • unable to execute query from myadmin or vb window

    vBulletin Message
    An error occurred while attempting to execute your query. The following information was returned.
    error number: 1064
    error desc: 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 ';
    CREATE TABLE affiliates (
    affiliate_id int(10) NOT NULL a




    I get that kind of an error whenever I try to manually make a table wth data in it. this code or any other random code, it just dosn't take it..

    i'm on a win2003 server with plesk 6.5..
    php is uptodate n everything.. what could the be the syntax problem ?

  • #2
    affiliates isn't a vBulletin table, we can't give support on custom code.

    The error tells me the query itself is incorrect. Check with the MySQL documentation on how the query should be properly syntaxed. Don't forget to include a table_ prefix if you have one set in the config.php from vBulletin.

    If you run a query through the admin control panel and the page won't load you first need to update config.php with a variable $canrunqueries = 'your userid';

    Comment


    • #3
      All those are okay, prefix n everything are set to vb3_ and user ids etc..


      it's not the affiliate mod that I need support on. Its jsut that any custom mod that requires me to insert something or create a table, I copy paste the query like everyone else, but it goes me errors like those.. how come.

      Comment


      • #4
        Copy/paste in the EXACT query, character for character, and we'll see....

        Comment


        • #5
          okay I'm pasting a manual query I was asked to run.. remember I'm not asking support for the mod..just why the syntax error is coming in

          ANY queries I'm trying to run manually..

          Code:
          DROP TABLE IF EXISTS affiliates;
          CREATE TABLE affiliates (
            affiliate_id int(10) NOT NULL auto_increment,
            sitename varchar(50) NOT NULL,
            siteurl varchar(250) NOT NULL,
            sitedesc mediumtext NOT NULL,
            buttonurl varchar(150) NOT NULL,
            type tinyint(4) NOT NULL,
            email varchar(250) NOT NULL,
            clicksout int(20) NOT NULL,
            clicksin int(20) NOT NULL,
            active tinyint(4) NOT NULL,
            totalrating bigint(20) NOT NULL,
            totalvotes bigint(20) NOT NULL,
            approved tinyint(4) NOT NULL,
            PRIMARY KEY (affiliate_id),
            KEY sitename (sitename),
            KEY siteurl (siteurl),
            KEY email (email)
          );
          a code like that gives an error like this..

          Code:
          vBulletin Message 
          An error occurred while attempting to execute your query. The following information was returned. 
          error number: 1064 
          error desc: 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 ';
          CREATE TABLE affiliates (
          affiliate_id int(10) NOT NULL a

          Comment


          • #6
            This is not a vB query or table. Is this from a hack you are trying to install?
            Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
            Change CKEditor Colors to Match Style (for 4.1.4 and above)

            Steve Machol Photography


            Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


            Comment


            • #7
              nvm, I found the syntax error that was conflicting with my server version.
              Last edited by Deviant++; Wed 26 Jan '05, 8:17pm.

              Comment

              widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
              Working...
              X