Jump to content

fenway

Staff Alumni
  • Posts

    16,168
  • Joined

  • Last visited

  • Days Won

    4

Everything posted by fenway

  1. I meant in terms of scalability... this need not concern you at this stage, you'll just get lost in subjective opinions -- every case is different. Go with InnoDB, and don't use separate databases if you want to share anything. If anything, you can store the users in their own table, and use project prefixes -- or, if you want, separate project DBs and a users DB.
  2. "select distinct email, date and group by email" really should be "select email, date and group by email, date". Don't use DISTINCT -- it's evil.
  3. Yes, but we're talking about variable NAMES, not variable IDENTIFIERS -- so it's only beneficial to the human in question. And it matters even if you're not working on a team -- going back into 5-year-old code and trying to guess what a variable holds is all but impossible. A simple convention will save you hours.
  4. @abamaca -- post your query.
  5. Over 500? How did this random list of IDs get generated?
  6. Try the CSV engine type.
  7. Those sizes are screaming for another table.
  8. Sorry, I don't follow.
  9. You mean trigger into another table, or the same table?
  10. Don't mix DISTINCT and GROUP BY -- that's misleading and error-prone. You can group by both columns.
  11. Your table is just SCREAMING for a UID.
  12. Have you started this project yet? If not, these three shouldn't be your primary concern.
  13. Everything matters -- either it's the SQL statement (a string) or the query handle (an object).
  14. Then you're not storing IPs correctly.
  15. You really should always have a password for root.
  16. Height as an ENUM field? Bad idea. Height as a VARCHAR? Bad idea.
  17. You need to isolate a unique group first, and then join upwards.
  18. Learning SQL is like learning English -- don't bite off more than you can chew.
  19. You should NEVER need to retrieve the password.
  20. Well, you're not supposed to store delimited data when you (a) aren't storing individual elements of an array and (b) need access to an arbitrary element. You're missing some tables. And SUBSTRING_INDEX() can help you if the want the "inside".
  21. Oh, I really like that idea! +1
  22. Covers: Part 1: Using the MySQL Improved Extension, mysqli Part 2: Using the MySQL Extension, mysql Part 3: Using the PDO Extension With MySQL Driver, pdo_mysql Part 4: Using the MySQL Native Driver for PHP, mysqlnd Tutorial is here.
  23. Well, a scalar subquery, that is.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.