Jump to content

[SOLVED] REPLACE using two keys?


allspiritseve

Recommended Posts

I would like to use a REPLACE query using two separate text fields as keys. If both keys match, the record is replaced, while if one or the other matches, but not both, a new record is inserted. I am not sure exactly what my db structure needs to look like, as I've only ever used an int pkey with auto-increment. I am using MySQL 5.0.45 on a LAMP server.

 

Thanks,

 

Cory

Link to comment
https://forums.phpfreaks.com/topic/81388-solved-replace-using-two-keys/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.