http://localhost:8888/$utils/peek.html
Create DB: A database must be named with all lowercase characters (a-z), digits (0-9), or any of these characters `_$()+-/` and must end with a slash in the URL.
1> [info] [<0.152.0>] HTTP Request: PUT /try1/ HTTP/1.1
Header:[{"cache-control","no-cache"},
{"connection","Keep-Alive"},
{"content-length","0"},
{"host","localhost:8888"},
{"user-agent",
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 2.0
.50727; .NET CLR 3.0.04506; .NET CLR 1.1.4322; MS-RTC LM 8)"},
{"accept-encoding","gzip, deflate"},
{"ua-cpu","x86"},
{"referer","http://localhost:8888/$utils/peek.html"},
{"accept-language","en-us"},
{"accept","*/*"}]
1> [info] [<0.152.0>] HTTP Response Code:201
Create document:
1> [info] [<0.165.0>] HTTP Request: POST /try1/ HTTP/1.1
Header:[{"cache-control","no-cache"},
{"connection","Keep-Alive"},
{"content-length","142"},
{"host","localhost:8888"},
{"user-agent",
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 2.0
.50727; .NET CLR 3.0.04506; .NET CLR 1.1.4322; MS-RTC LM 8)"},
{"accept-encoding","gzip, deflate"},
{"ua-cpu","x86"},
{"content-type","text/xml; charset=UTF-8"},
{"referer","http://localhost:8888/$utils/peek.html"},
{"accept-language","en-us"},
{"accept","*/*"}]
1> [info] [<0.165.0>] HTTP Response Code:201
<?xml version="1.0" ?>
- <doc id="60CF2C862F0EB074646574E28DD71919" rev="D4BA5040" xmlns="http://couchdb.org/doc">
- <field name="FirstName">
<text>Apoorv</text>
</field>
- <field name="LastName">
<text>Shrivastava</text>
</field>
</doc>
Create table:
/* Tables are just special documents, but don't forget to give them unique names! */
* Set the table statement. You can use the fabric language for that.
* Note that every field has to start with $table_ !
*/
select statement: select *
Oops!
<?xml version="1.0" ?>
- <doc id="1" rev="F2CD1E07" xmlns="http://couchdb.org/doc">
- <field name="$table_$table_1">
<text>select *</text>
</field>
</doc>
now:
Table id : 60CF2C862F0EB074646574E28DD71919
Table name : keeda_tablewithidsameasanotherexistingdocument
Select Statement : select *
1> [info] [<0.214.0>] HTTP Request: POST /try1/ HTTP/1.1
Header:[{"cache-control","no-cache"},
{"connection","Keep-Alive"},
{"content-length","171"},
{"host","localhost:8888"},
{"user-agent",
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 2.0
.50727; .NET CLR 3.0.04506; .NET CLR 1.1.4322; MS-RTC LM 8)"},
{"accept-encoding","gzip, deflate"},
{"ua-cpu","x86"},
{"content-type","text/xml; charset=UTF-8"},
{"referer","http://localhost:8888/$utils/peek.html"},
{"accept-language","en-us"},
{"accept","*/*"}]
1> [info] [<0.214.0>] -HTTP Error-
Response Code: 409.
Error id: conflict
Error message: conflict
1> [info] [<0.214.0>] HTTP Response Code:409