incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sleepy <wanpee...@gmail.com>
Subject Re: Create date of a document
Date Wed, 22 Sep 2010 20:06:23 GMT
Thanks for your answer.

I tried to add a date in an update handler and it works.
Now I'm curious. Can I add create date using validation function?

It seems Couch doesn't allow me to change the doc in a validation function.

2010/9/23 Mirko Kiefer <mirko.kiefer@arcor.de>

> Hi, you can simply get the date through
> var date = new Date();
>
> the object is documented here:
> http://www.w3schools.com/js/js_obj_date.asp
>
> On Sep 22, 2010, at 5:35 PM, sleepy wrote:
>
> > Is there a way to get server time in validation function? I need that
> > information in order to avoid data with future date-time
> > Or can I record create date of a document using server time which is
> ensured
> > by server?
> >
> > sleepnova
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message