Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Sep 2006
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unhappy MySQL Database Error, Screen Shots Included

    Well heres my dilemma, i have a script that contains a pre_checkout.php file for credit card orders, people can order different packages from my website, from 19.99 too 39.99.. anyway, when i was testing my site i recieve an error when i try to order a package

    heres a screen shot of what the error looks like
    in internet explorer:



    also: here is a picture of my database tables concerning this area, "TransactionsMembership" in phpMyAdmin



    am i missing some fields? i dont see the state field anywhere, if i am missing fields, what would i have to query too create them?

    any and all help is appreciated, im fairly certain it is a database problem and nothing wrong with the actual php script.

    thanks guys, ive been tryin to fix this for about 4 days now and cant seem to figure it out

    if theres anymore info needed by anyone to help me solve this, im more then happy to try and get it and tell you

  • #2
    New to the CF scene
    Join Date
    Sep 2006
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    also the script emails me the error

    Unknown column 'State' in 'field list'
    Query: 'INSERT INTO `TransactionsMembership` (ID, Sum, State ) VALUES ( 1158643712931, 19.99, '0' );'

  • #3
    raf
    raf is offline
    Master Coder
    Join Date
    Jul 2002
    Posts
    6,589
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Welcome here!

    you need to add the field "State" to your table.
    In the middle of that screenshot, you see tthe "Add 1 field(s) ..." line, so hit the "Go" button on that line and in the next screen, fill in the columnname and type.

    i would also recommend that you only use lowercase letters for the table and columnnames, and that you don't use function or datatype names as columns (date, type, sum) --> although they are not reserved words in mysql, it's confusing for other coders + i'll probably mess up your colourcoding when you look at the sql-statements in a better db-front
    Posting guidelines I use to see if I will spend time to answer your question : http://www.catb.org/~esr/faqs/smart-questions.html


  •  

    Posting Permissions

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