Inserting data into MySQL using PHP

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • nungo
    New Member
    • Mar 2007
    • 6

    Inserting data into MySQL using PHP

    Hi fellow members,
    It has been a long journey in the school of PHP and MySQL self study.... I have created MySQL database and can be able to display data from it using PHP.

    My problem is everytime I need to enter data I have to do so in MySQL code i.e. INSERT INTO table_name (No, Name.....); I am sure the reason for databases and Websites if for user-friendliness.

    Does anyone have an idea of how to Input data into my database via PHP? I will be really grateful and surely if I have this done I will be able to get some sleep.

    Thanks in advance.
    Nungo
  • ronverdonk
    Recognized Expert Specialist
    • Jul 2006
    • 4259

    #2
    Whoever said that MySQL should be user friendly? It is for the programmer. It is a relational database of which the data content can be filled and extracted programmaticall y. It is not a GUI based end-user tool for the desktop!

    When you want to insert data into the MySQL database you basically have 3 options:
    1. using a program you use the php commands (starting with mysql_*) to perform all db operations
    2. you use a user interface like phpMyAdmin or the likes. Here also you have to specify SQL statements
    3. load the data from a text file. You also achive this using the LOAD DATA mysql command.


    Ronald :cool:

    Comment

    Working...