timestamp

MySQL: How to create trigger for setting creation date for new rows

I ran into a problem as I tried to create two TIMESTAMP columns in my database. One called created and one called updated. I figured it would be easy to set the default value of both to CURRENT_TIMESTAMP and then ON UPDATE CURRENT_TIMESTAMP for the updated column. But for some reason MySQL means that's a bad idea... so I have been lookin...

Convert RSS pubDate to a timestamp

Hello ! How to convert a date string Mon, 24 May 2010 17:54:00 GMT from RSS feed to a timestamp in PHP ? ...

PHP How to find the time elapsed since a date time?

How to find the time elapsed since a date time stamp like '2010-04-28 17:25:43', final out put text should be like 'xx Minutes Ago'/'xx Days Ago' ...

SQL Timstamp Function

Is there any difference between these two queries? select * from tbl where ts < '9999-12-31-24.00.00.000000'; and select * from tbl where ts < timestamp('9999-12-31-24.00.00.000000'); When is the timestamp function required? Is there a difference in performance? ...

Clear a file without changing its timestamp

Is it possible to clear a file preserving its timestamp, using standard Linux commands? For example: echo "" > file-name converts the text file to empty, this is OK for me. But I need to keep the timestamp unchanged. ...

How to compare sqlite TIMESTAMP values

I have an Sqlite database in which I want to select rows of which the value in a TIMESTAMP column is before a certain date. I would think this to be simple but I can't get it done. I have tried this: SELECT * FROM logged_event WHERE logged_event.CREATED_AT < '2010-05-28 16:20:55' and various variations on it, like with the date functio...

how to convert from timestamp to data in QT ?

hello all i have unix timestamp and i need to convert it to Human readable data + time how can it be done in QT ? ...

Which Perl moudle can handle variety of date formats with unicode characters ?

My requirement is parsing xml files which contains wide varieties of timestamps based on the locales at which they are written. They may contain Unicode characters in case of Chinese or Korean locales. I have to parse these timestamps and put then in a standard format something like 2009-11-26 12:40:54 to put them in a oracle database. S...

FTP script retain timestamp of a file after put

I know that FTP does not support transferring and retaining file date/time stamps Wondering if anyone has any ideas/scripts (Shell/perl) that would retain a transfered file's timestamp after a put operation? ...

Change Timestamp value in enterprise library exception handling formatter

I am using enterprize library 5.0 with c# for exception handling and for that I am using formatter.Now In my log file Timestamp is not giving the right time. Can I change the value of timestamp in formatter. ...

git rebase without changing commit timestamps

Would it make sense to perform git rebase while preserving the commit timestamps? I believe a consequence would be that the new branch will not necessarily have commit dates chronologically. Is that theoretically possible at all? (e.g. using plumbing commands; just curious here) If it is theoretically possible, then is it possible in p...

Getting compilation timestamp of a java class

Is it possible to reliably determine the compilation time stamp of a given class for both java applications running locally and as applets and/or JNLP webapps ? ...

Programmatically Determine If An Excel File (.xls) Contains Macros

Is there any way to programmatically determine if an .xls contains macros, without actually opening it in Excel? Also are there any methods to examine which certificate (including timestamp cert) these macros are signed with? Again without using Excel. I'm wondering in particular if there are any strings that always show up in the raw ...

php mysql timestamp

I need to track the date and time a user was created in my mysql database. I have column called 'created' and the data type as TIMESTAMP. The problem is that when a user changes their password or other information the TIMESTAMP value changes. How can I set this to not change???? ...

question about timestamp with timezone in postgresql+java?

hey guys i have a column in the database(postgresql) i want to insert the current time in GMT in this column when getting the current time and inserting it into the DB it's inserted in the server timezone GMT-5 although that time was in GMT+0 any ideas how to insert this time in the database in GMT timezone ? ...

send sql server Timestamp from C#

Hello, Does someone knows how can I send a Timestamp value from C# to my Sql stored procedure which expect to get a timestamp value? the sp looks like this create sp1(@TS Timestamp) --do do something... go ...

MySQL delete row after 'expiry'

Hi, I am trying to delete expired entries in a MySQL database, on creation or update a field called lastBeat is updated with CURRENT_TIME and I use the following query to check/delete rows older than 20 seconds: DELETE * FROM rmachines WHERE lastBeat < (NOW() - 20); I have also tried CURRENT_TIME instead of NOW() There are 2 ma...

insert a time-stamp value in my db by php

I'm using oracle express and in my application i would insert a time-stamp value in my table: $marca = date('y-m-d H:i:s'); $query = " INSERT INTO SA_VERSIONE ( ID_ACCETTAZIONE, MARCA_TEMPORALE, TESTO, FIRMA, MEDICO) VALUES ('$id', '$marca', '$testo', '$firma', '$medico')...

Embed application compilation time stamp

Is there an easy way to configure in a build process to write in the time stamp of the build to be displayed in the application to have something like "This page was last updated: 06/26/2010" ...

SQL - First row inserted every day for the past X days

A tough SQL question (I'm using postgres by the way). I need the first row inserted every day for the past X days. one of my columns is a timestamp, which i hold the time inserted, and another column is the row id. If it's not possible to get the first row inserted every day, i at least need a unique one; a single row for every day fo...