Jump to content

fenway

Staff Alumni
  • Posts

    16,168
  • Joined

  • Last visited

  • Days Won

    4

Everything posted by fenway

  1. fenway

    Primary Keys

    Hmmm... upon second thought, I guess mysql must respect all unique indexes... so I suppose you should have a UID field (PK) and the other two fields (unique across both). Sorry, my bad.
  2. What does this mean?
  3. Yikes, don't post screenshots.. just the text output! :-( You're asking for columns in tables that don't exist, like 'Invoice.ItemID"... of course you'll get errors.
  4. fenway

    Primary Keys

    You are correct in this special case -- if you're going to be using the combination of the two FKs as a UNIQUE key contraints (i.e. for REPLACE, or dupe control), then having another aspect of the record that's _always_ unique doesn't help much. In this case, I would suspect that adding a UID field would just mess things up... but I haven't tried this in a while.
  5. I agree, but this outside the rather outdated scope of RDBMS set theory. As long as your app controls the display, you can always run maintenance scripts to make sure nothing looks "funny". Sanity checks, basically.
  6. Hmmm... that's unusual.. could you post your table structure so I can test it?
  7. No idea at all? Hard to believe.... what class? When did it start? What do you have so far?
  8. I've never constrained this type of relationship in the DB...
  9. Is your UNIQUE index multi-column?
  10. I'm not sure I understand... write the necessary statements and run the cron...?
  11. This is a backend script... it has nothing to do with the browser.
  12. 2 mins to display (php) or to query (mysql)? You'd need to add a where clause... WHERE firstname LIKE 'B%'
  13. It's not clearer... what do you mean by "call"?
  14. Did you issue an UPDATE statement after you altered the table?
  15. Nothing should "mimic" the order... make it explicit with another field.
  16. A LEFT JOIN?
  17. Depends how you want to handle this... an unique index prevents the duplicate... but there are many different unique humans with the same name...?!?!
  18. Why don't you use an offset... e.g. LIMIT 1, 5?
  19. Then you're in trouble... what version was the old server running? You need to get the modes, or hope that it's the default (gulp).
  20. "another formula"? What does that mean?
  21. Do you have access to the old server? if you, grab the sql mode string from there.
  22. "Submit" isn't mysql. You're populating the field with blanks, not nulls from your script.
  23. Just remember this isn't index-friendly.
  24. fenway

    cache system

    Yes, that's true... but the query speed is probably due to the indexes.
  25. fenway

    cache system

    Look into memcached.
×
×
  • 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.