Subject | Re: [firebird-php] inserting timestamp values (now really) |
---|---|
Author | Yves Glodt |
Post date | 2007-04-30T13:30:14Z |
On Monday 30 April 2007, Alan McDonald wrote:
anymore...
I read that internally, firebird passes the formatstring to strftime().
So I tried to put %s, which is the unix timestamp since the epoch, and even
that fails.
It seems the format for inserting is not at all related to the
ibase.timestampformat setting, but to some system variable/setting (Since on
my dev.-box it just works with '26.04.2007 - 11:59' e.g.)
phpinfo() does not show any pointer to where it gets that format from.
I will investigate more.
yves
> > Hello,I had success with this, but as soon as I add a time value, it does not work
> >
> > it seems I am unable to insert any value into a TIMESTAMP column which is
> > different of 'NOW'.
> >
> > I set the following:
> >
> > ini_set('ibase.timestampformat', '%d.%m.%Y - %H:%M');
> >
> > ...and this seems to work well for formatting the displayed
> > resultset, but the
> > format of the dates to be inserted seems to be unaffected by this...
> >
> > Is there any other fixed format I need to use when I insert
> > timestamp data?
> >
> >
> > best regards,
> > yves
> >
> > p.s.
> > sorry for the previous prematurely sent mail
>
> actually, the most reliable way I have found to insert/update dates is to
> use the long date string
> April 30, 2007
>
> It gets over all forms of localisation
anymore...
I read that internally, firebird passes the formatstring to strftime().
So I tried to put %s, which is the unix timestamp since the epoch, and even
that fails.
It seems the format for inserting is not at all related to the
ibase.timestampformat setting, but to some system variable/setting (Since on
my dev.-box it just works with '26.04.2007 - 11:59' e.g.)
phpinfo() does not show any pointer to where it gets that format from.
I will investigate more.
yves
> Alan