Newby questions - PHP/mysql

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Allan
    Junior Member
    • Jan 2005
    • 2

    #1

    Newby questions - PHP/mysql

    Just getting started with php and mysql. I'm writing a script that reads from a sequential CSV file and INSERTS rows into a table. The script runs without errors, but when I go to phpMyAdmin, there's no data in the table.

    Also tried importing the file directly from phpMyAdmin, but it only imports the last record.

    Any ideas would be a great help.

    Thanks!
  • sdjl
    Senior Member
    • Mar 2004
    • 502

    #2
    You could try running MySQL from command line.
    If the file is that large, phpmyadmin may have issues reading and inserting all the data.

    Code:
    mysql -u username -p -D DATABASE_NAME < /home/username/public_html/file.sql
    -----
    Do you fear the obsolescence of the metanarrative apparatus of legitimation?

    Comment

    • Allan
      Junior Member
      • Jan 2005
      • 2

      #3
      How do you get to the command line?

      Comment

      • Jonathan
        Senior Member
        • Mar 2004
        • 1229

        #4
        Originally posted by Allan
        How do you get to the command line?
        1. Make sure SSH is enabled for the account in question;
        2. Log into cPanel then click on "SSH" or "Shell" (forget name)
        3. It'll ask your User/Pass; use your cPanel username & password (askes 2twice)

        Your not logged onto SSH (command line)
        "How can someone be so distracted yet so focused?"
        - C

        Comment

        Working...