Thread: Help With SQL

Results 1 to 3 of 3
  1. #1
    Join Date
    Aug 2009
    Location
    Washington
    Posts
    82
    Plugin Contributions
    1

    red flag Help With SQL

    I have installed the MRSP addon and in thread http://www.zen-cart.com/forum/showth...highlight=msrp
    it says to add to the sql tools in the admin area i did then I tried the phpmyadmin and got the same message error
    Error

    SQL query:

    `products_msrp` DECIMAL( 15, 4 ) NOT NULL AFTER `products_price`

    MySQL said: Documentation
    #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 '`products_msrp` DECIMAL( 15, 4 ) NOT NULL AFTER `products_price`' at line 1

    for the SQL i am using

    1. Add a new field to the products table to hold the MSRP value.

    ALTER TABLE products ADD `products_msrp` DECIMAL( 15, 4 ) NOT NULL AFTER `products_price` ;
    <-------the code in red is what I use, is this correct?
    the rest is for the stylesheet
    2. In includes/templates/your_template/css/stylesheet.css, or includes/templates/classic/css/stylesheet.css

    Add:

    .smalltext1 {
    font-family:Tahoma;
    text-align: center;
    color:#FFFF00;
    font-weight:bold;
    }

    .save {
    font-family:Tahoma;
    text-align: center;
    color:#00FFFF;
    font-weight:bold;
    }

    .norm {
    font-family:Tahoma;
    text-align: center;
    color:#FF0000;
    font-weight:bold;
    }

    some help or ideas would be great

  2. #2
    Join Date
    Jan 2004
    Posts
    66,444
    Plugin Contributions
    279

    Default Re: Help With SQL

    Um ... an ALTER TABLE statement requires that you use the *entire* statement. I have no idea why you would use only the part after the "ADD".
    Use the whole line.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Aug 2009
    Location
    Washington
    Posts
    82
    Plugin Contributions
    1

    customer issue Re: Help With SQL

    thank you Dr. that worked great, and you have a zenned day.

 

 

Similar Threads

  1. I need some help with a SQL error
    By sw1138lr in forum Basic Configuration
    Replies: 1
    Last Post: 25 Mar 2013, 12:25 AM
  2. Help with Zipcodezone SQL or with a SMC sql for it...
    By GypsyPhoenix in forum Addon Shipping Modules
    Replies: 0
    Last Post: 3 Apr 2010, 09:50 PM
  3. Help with a sql query
    By batteryman in forum General Questions
    Replies: 21
    Last Post: 3 Oct 2008, 11:12 PM
  4. Help with SQL query
    By Danielle in forum General Questions
    Replies: 3
    Last Post: 9 Jun 2008, 05:24 AM
  5. Need Help with SQL error
    By kevinmc3 in forum Setting Up Categories, Products, Attributes
    Replies: 1
    Last Post: 4 Apr 2008, 07:31 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg