timestamp

Change the date of wordpress

Hi, wondering how I change the date wordpress thinks today is.. where does it pull the time and day from and is it possible to change that to say 2010 instead of 09 ...

Can anyone recommend a good book or other resource on NTFS semantics?

I'd like to improve my understanding of NTFS semantics; ideally, I'd like some kind of specification document(s). I could (in theory) figure out the basics by experimentation, but there's always the possibility that I'd be ignoring some important variable. For example, I'm having difficulty finding definitive information on the followi...

JavaScript Date Object's month index begins with 0!

My goal is to convert a timestamp from MySQL into a JavaScript Date object in an efficient manner. Here is my current snippet that converts the MySQL timestamp into a formatted date in PHP: <?php // formats timestamp into following format: 2009, 7, 30 $date = date("Y, n, j", strtotime($row["date"])); ?> I am then using this $date va...

SQL to compare two unix timestamps?

Hi, I have a table with a field that contains unix timestamps for each record. I would like to return each row where the year and month are equal to the current year and month. Is there a simple way to do this? Thanks ...

How to include a timer in Bash Scripting?

Good day! Is there any way to include a timer (timestamp?or whatever term it is) in a script using bash? Like for instance; every 60 seconds, a specific function checks if the internet is down, if it is, then it connects to the wifi device instead and vice versa. In short, the program checks the internet connection from time to time. An...

surprising time shift for python call

I'm using the following code in Python 2.5.1 to generate a UTC timestamp from a string representation of a date: time.mktime(time.strptime("2009-06-16", "%Y-%m-%d")) The general result is: 1245103200 (16.6.2009 0:00 UTC or 15.6.09 22:00:00, if you're in my time zone). But now, I found that on some computers running Windows XP, this ...

Timestamps in Ant log?

Is there an easy way to have the Ant logger (default or other) add a timestamp to each message? The only way I can think of is to use the Log4jListener and have its settings include the timestamp. Or write a custom logger that subclasses DefaultLogger and writes the timestamp. If there's a better or easier way (preferably without req...

Bash timestamp comparisions

Im completely new to Bash scripting but I've been told, with little help, to create a file that compresses textures into PVR format only if the file has been modified since the last time the script was run. Heres the code I have so far: # variables TEXTURE_TOOL=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/texturetool INPUT...

fuzzy timestamp parsing with Python

hello, Is there a Python module to interpret fuzzy timestamps like the date command in unix: > date -d "2 minutes ago" Tue Aug 11 16:24:05 EST 2009 The closest I have found so far is dateutil.parser, which fails for the above example. thanks ...

Conversion from K2SEC or kSI2Ks to secs or mins

Hi, Since CPU's clock their cycles in kSI2Ks or K2SEC time units. I am wondering if some body know how to convert them in to seconds/minutes. Thanks, Omer ...

php/mysql - date_format and the time portion

Apologies if this has already been answered many times, but I was unable to find the answer and I was flummoxed. I have a mysql query which seemingly outputs the result I want when I run it in the database - however when I run the query through PHP, it does not output correctly. In the database, dates are stored like this: 2009-08-13T...

Why would a TableAdapter populate a DataSet with "1/1/2000" for an entire timestamp column?

I have a TableAdapter filling a DataSet, and for some reason every select query populates my timestamp column with the value 1/1/2000 for every selected row. I first verified that original values are intact on the DB side; for the most part, they are, although it seems a few rows lost their original timestamp because of update queries ...

Converting unix timestamp to YYYY-MM-DD HH:MM:SS.

I have a Unix timestamp that I need to get the individual year, month, day, hour, minute and second values from. I never was very good in math class so I was wondering if you guys could help me out a little :) I have to do everything myself (no time.h functions). The language is C. ...

MySQL (DEFAULT + ON UPDATE) TIMESTAMPs

I've a table where I've two fields: dateCreated dateUpdated I want both fields to hold timestamps, dateCreated to have a DEFAULT CURRENT TIMESTAMP flag and dateUpdated to have a ON UPDATE CURRENT TIMESTAMP behavior, however seems that I can't have more than one timestamps field types on the same table. It would be really useful if th...

UNIX Timestamp to MySQL DATETIME

Hi all, I have a table with statistics and a field named time with Unix Timestamps. There are about 200 rows in the table, but I would like to change the Unix timestamps to MySQL DATETIME. Without losing the current rows. What would be the best way to update the Unix Timestamp to MySQL's DATETIME? The current table: CREATE TABLE `s...

Actionscript 3 high precision time method (microseconds)?

I need a high precision time method in microseconds rather than milliseconds for actionscript, unfortunately I couldn't find much help on the web. I need such control in order to implement the usage of a fixed timestep in transitions as described in this article: http://gafferongames.com/game-physics/fix-your-timestep/, in order to solv...

Hibernate Timestamp with Timezone

I'm new to Hibernate and am working with an Oracle 10g database. We have columns in our tables that are of type TIMESTAMP WITH TIMEZONE. Hibernate does not seem to support this mapping directly. Is there a standard way to go about this? Thanks ...

convert from mysql datetime to coldfusion datetime

Is anyone aware of a simple way to convert mysql datetime values to coldfusion datetime values in CF8 (and it may have to be backwards compatible with CF6)? I need to store date times in mysql and have chosen to store them in mysql datetime format so I can get the db to do date ranges and comparisons for me. I could so this stuff in CF,...

MySQL - return only entries from the past X days

I'm working with a database that has date information stored as a Unix timestamp ( int(11) ) and what I want to do is only return entries from the past X days, the past 90 days for example. What I've come up with is: SELECT * FROM mytable WHERE category=1 AND FROM_UNIXTIME( time ) > DATE_SUB(now(), INTERVAL 91 DAY) Where 'time' is t...

MySQL Timestamp Question

i am looking at some practice questions Assume that you've just created this table: CREATE TABLE timestamptest ( ts1 TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, i INT ); When you look at its structure, you will notice that the TIMESTAMP column is declared NOT NULL. What happens if you insert these records: mys...