SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    SitePoint Evangelist
    Join Date
    Mar 2011
    Posts
    423
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Edit, Add and Delete: PHPMyAdmin, Administrators login @ web site or Excel?

    Hi,

    I've just installed MySQL to my MAC computer and was expecting database software like MS Excel. It seems it might not be that easy/intuitive however!

    From what I can work out it is not easy to view the database and edit it, add or delete entries.

    The three ways I have discovered are:
    1. PHP MyAdmin.
    2. Create login and edit, add and delete forms at web site.
    3. Download database using Excel, edit it, add or delete entries then upload it.

    Am I correct in pursuing these three concepts when designing the web site? Or are there easier methods?

    Thanks,

    Matt.

  2. #2
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,341
    Mentioned
    63 Post(s)
    Tagged
    3 Thread(s)
    using phpmyadmin is sufficient for all your database access/update requirements
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  3. #3
    SitePoint Evangelist
    Join Date
    Mar 2011
    Posts
    423
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Would you agree a MySQL login at the web site is the best way to 'view a database'?

    For example, web page asks users to enter their username and password. If, when they click submit, the password matches their username it displays the tables that user will want to view.

    This is quicker than PHP MyAdmin, right? And particularly if they are out of the office?

    Matt.

  4. #4
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,341
    Mentioned
    63 Post(s)
    Tagged
    3 Thread(s)
    Quote Originally Posted by MatthewBOnline View Post
    Would you agree a MySQL login at the web site is the best way to 'view a database'?
    for users, it should be the ~only~ way

    users should never, ever be given a tool like phpmyadmin
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  5. #5
    SitePoint Evangelist
    Join Date
    Mar 2011
    Posts
    423
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Regarding the basics of editing, can you advise on the LIVE purchasing environment?

    I know some companies use databases of stock holdings of each product. Then if there is 1 or greater than one in stock the web site says "IN STOCK - BUY NOW" otherwise it says "OUT OF STOCK".

    My issue is say products Jacket, Sports bag and Calculator were showing say 20 of each in stock but then there was a delivery to the warehouse of a 100 of each how do these new figures get added to the stock holding?

    1. If Excel was used and between the time of downloading and uploading the amendments one or more were purchased the upload would overwrite the fact that there were some sales whilst the file was being edited?

    2. If (and I'm not sure it is possible) PHP MyAdmin was used, since there is no visible table of entries, if there were 100 different products to change quantity for it may take some time remembering the unique ID or where abouts I may locate it.

    3. If you use a login at the web site, you need a method of fishing out and updating the relevant entries.

    No way seems 'worth doing' but companies like Amazon, etc. have no problem keeping this info up to date. Am I missing a trick?

    Matt.

  6. #6
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,341
    Mentioned
    63 Post(s)
    Tagged
    3 Thread(s)
    Quote Originally Posted by MatthewBOnline View Post
    My issue is say products Jacket, Sports bag and Calculator were showing say 20 of each in stock but then there was a delivery to the warehouse of a 100 of each how do these new figures get added to the stock holding?
    by an application interface that you would build, which allows you, the site administrator, to update the relevant columns in the product table

    1. If Excel was used and between the time of downloading and uploading the amendments one or more were purchased the upload would overwrite the fact that there were some sales whilst the file was being edited?
    sounds like you are quickly coming up to speed on the dangers of using excel to perform updates

    2. If (and I'm not sure it is possible) PHP MyAdmin was used, since there is no visible table of entries, if there were 100 different products to change quantity for it may take some time remembering the unique ID or where abouts I may locate it.
    you would obviously need to use a product key which is used not only in your database table, but also in the incoming data feed

    and i'm not sure why you think there is no visible table of entries
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  7. #7
    SitePoint Wizard
    Join Date
    Jul 2003
    Location
    Kent
    Posts
    1,921
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    You are confusing database management system with a database user interface - in every database management system you have to build an interface to prevent the user working with the actual raw tables, if you want a sensible, safer system. Ever seen oracle at the command line for example? MySQL is just the same.

    How you build your user interface to MySQL is up to you; most people use PHP to present the data the way they want it displayed in a web browser. You could use Access to interface with MySQL from a desktop within a company (works quite well, also works well with oracle). The point about the user interface is that YOU control what you will let the user do and see. phpMyAdmin gives the users way too much power, and you have almost no control over what havoc they can wreck on your database. The database administrator for your system should be the only one who gets to play with phpmyadmin, or any similar tool.

    PS Excel is a spreadsheet, a calculating device, not a database, although many people use its column layout to simulate a database.


Bookmarks

Posting Permissions

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