incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian Candler <B.Cand...@pobox.com>
Subject Re: Re: {"error":"bad_request","reason":"invalid UTF-8 JSON"}
Date Wed, 09 Dec 2009 09:46:51 GMT
On Tue, Dec 08, 2009 at 06:08:48PM +0100, Stefan Fischer wrote:
> Hi,
> I added the ',' to the command:
> curl -X PUT 
> http://xxxx.xxx.xxx:5984/albums/6e1295ed6c29495e54cc05947f18c8af 
>   -d{"title":"There is Nothing Left to Lose","artist":"Foo Fighters"}'
> 
> Still the same problem:
> {"error":"bad_request","reason":"invalid UTF-8 JSON"}

Shell quoting is a nightmare in Windows, and I don't think there's an
equivalent to the single-quote in Unix.

You could try escaping using the caret (up-arrow):
http://thepursuitofalife.com/escape-characters-in-windows-cmdexe/

I'm not sure what actually needs escaping, so to start with, escape
everything that's remotely non-alphanumeric:

    -d^{^"title^"^: ...etc... ^}

Mime
View raw message