/    Sign up×
Community /Pin to ProfileBookmark

Hi All,

Can it be possible in mysql to fetch the data which is modified , I mean i only want to see the data which is modified by user .

Let tell me what should be the mysql query for this requirement

Thanks In Advance

Regards,

Ashish Sood

to post a comment
PHP

5 Comments(s)

Copy linkTweet thisAlerts:
@ginerjmJan 15.2014 — What do you mean by "modified"? Data that was just modified in the last query you ran? Or data that has been modified since a certain date/time? Unless you have stored a datetime value on the record and can use that as a reference point how do you expect to recognized changed data?
Copy linkTweet thisAlerts:
@Ashish_SoodauthorJan 15.2014 — Let me explain you, I have a table name "orders", which contain following field, OID, ONAME, DATE, STATUS, TIMESTAMP.

Now i want to fetch only those order whose timestamps has changed recently(current date).

Thanks
Copy linkTweet thisAlerts:
@ginerjmJan 15.2014 — This makes SOOO much more sense. Why didn't you say so before???


Of course you can do what you ask. Simply compose your query and check for the timestamp field greater than a specific date/time value.
Copy linkTweet thisAlerts:
@Ashish_SoodauthorJan 15.2014 — Thanks for your reply.?


Below is my current mysql query.

$selectreq = mysql_query ("SELECT * FROM orders WHERE STATUS !='COMPLETED' AND STATUS !='CANCELLED'");
[/QUOTE]


I want to integrate my requirement into this existing query. can it be possible, If yes, then could you please, show me with example.
Copy linkTweet thisAlerts:
@ginerjmJan 16.2014 — and timedate > "2013-12-31 00:00:00" should do it although you might have to tinker with the format of the value.
×

Success!

Help @Ashish_Sood spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.12,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...