couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sebastian Cohnen <sebastiancoh...@googlemail.com>
Subject Re: couchdb modify the json object
Date Wed, 01 Jun 2011 13:10:13 GMT
Hi Sujan,

what are you expecting?

curl -H "Content-Type: application/json" -X POST "http://localhost:5984/test" -d '{"createddate":"\\/Date(-684302343434)\\/"}'
# -> {"ok":true,"id":"496da5f24ef4d4c11f80b8b22e0004e8","rev":"1-1b46cd563ef2dcca42c5e9f45de8c308"}

curl -X GET http://localhost:5984/test/496da5f24ef4d4c11f80b8b22e0004e8
# -> {"_id":"496da5f24ef4d4c11f80b8b22e0004e8","_rev":"1-1b46cd563ef2dcca42c5e9f45de8c308","createddate":"\\/Date(-684302343434)\\/"}

On 01.06.2011, at 14:56, Sujan Dutta wrote:

> 
> I am new to couchdb and i have a problem now
> 
> well i have a date field which i am putting it as
> 
> "createddate":"\\/Date(-684302343434)\\/"
> 
> but it is storing in doc as 
> 
> "createddate":"/Date(-684302343434)/"
> 
> how do i could solve this problem ?
> 		 	   		  


Mime
View raw message