#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2000
    Posts
    3
    Rep Power
    0
    I have PHP and MySQL running, and working to gether, or so I thought...

    I've been able to select information from a test database, but I don't seem to be able to insert something into the database through PHP. Are there any debugging things that I can do to see where my problem is occuring?

    Thanks,
    Chris
  2. #2
  3. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2000
    Posts
    2
    Rep Power
    0
    do tell me the details..
    did u grant all the privilages in th test db?
    my_sql_query ..will actually do the stuff for u...if there is any probs...do mail!
    cheers
    ram
    <BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by crose:
    I have PHP and MySQL running, and working to gether, or so I thought...

    I've been able to select information from a test database, but I don't seem to be able to insert something into the database through PHP. Are there any debugging things that I can do to see where my problem is occuring?

    Thanks,
    Chris
    [/quote]

  4. #3
  5. .Net Developer
    Devshed Novice (500 - 999 posts)

    Join Date
    Feb 2000
    Location
    London
    Posts
    987
    Rep Power
    15
    use the mysql_error() function for seeing what error you are getting.

    use this after mysql_query.

    mysql_query("INSERT INTO test set field='value' WHERE sno=1",$con);

    print mysql_error();

    ------------------
    SR -
    shiju.dreamcenter.net

    "The fear of the LORD is the beginning of knowledge..."

    [This message has been edited by Shiju Rajan (edited May 23, 2000).]

Similar Threads

  1. Check MySQL Version thru PHP
    By wolftrap1 in forum PHP Development
    Replies: 2
    Last Post: February 11th, 2004, 08:51 PM
  2. Replies: 5
    Last Post: February 11th, 2004, 02:18 AM
  3. Replies: 0
    Last Post: February 10th, 2004, 11:44 PM
  4. Getting data from different tables in Mysql with PHP
    By Bosw8er in forum PHP Development
    Replies: 3
    Last Post: February 10th, 2004, 04:25 PM
  5. fread problem: doesn t compile php code
    By ghorghor2002 in forum PHP Development
    Replies: 2
    Last Post: February 3rd, 2004, 05:25 AM

IMN logo majestic logo threadwatch logo seochat tools logo