Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

only insert if different than existing

Posted on 2013-11-24
2
Medium Priority
?
180 Views
Last Modified: 2013-11-24
users have a title and body in their social networking website

using php, pdo with mysql

if they change their title and/or body  then

columns id,profile_id, timestamp, title, body.  If body,title is different save a new title,body
0
Comment
Question by:rgb192
2 Comments
 
LVL 58

Accepted Solution

by:
Gary earned 2000 total points
ID: 39673574
Just run a normal update.
If they changed it then it will be updated, if they didn't change it then it will be the same as before.
0
 

Author Closing Comment

by:rgb192
ID: 39673591
not what I was thinking because I want historical values

but you answered the question I wrote: which was update

thanks
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses how to create an extensible mechanism for linked drop downs.
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Suggested Courses

782 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question