Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-7346

Documentation outdated in page http://www.couchbase.com/docs/couchbase-devguide-2.0/filter-extract-data.html



      The page at:


      Shows several documents with the _id and _rev fields. These meta data fields are no longer inlined in documents after DP4.

      Also, the field "language" for design documents has no special meaning in Couchbase (unlike Apache CouchDB), being superfluous and confusing to users.

      There's also a map function example with duplicated if conditional:

      function(doc) {
      if (doc.title) {

      { emit(doc.title, null); }


      Finally, the following paragraph:

      "As a best practice we want make sure that the fields we want to include in our index actually exist. Therefore we have our map function within a conditional: if (doc.age && doc.name). This ensures the fields exist in documents when we query the view and we therefore avoid a view failure when Couchbase Server generates the index."

      Is not completely correct. If doc.age or doc.name don't exist in a document, using them as keys or values doesn't produce an error.
      Undefined fields in JavaScript are serialized to a JSON null value.
      What would produce an error would be something like referencing doc.name.length, when name isn't defined in the document.

      No reviews matched the request. Check your Options in the drop-down menu of this sections header.


        FilipeManana Filipe Manana (Inactive) created issue -
        mccouch MC Brown (Inactive) made changes -
        Field Original Value New Value
        Assignee MC Brown [ mccouch ] Karen Zeller [ kzeller ]
        farshid Farshid Ghods (Inactive) made changes -
        Fix Version/s 2.0 [ 10114 ]
        kzeller kzeller made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        kzeller kzeller made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        FilipeManana Filipe Manana (Inactive) made changes -
        Resolution Fixed [ 1 ]
        Status Closed [ 6 ] Reopened [ 4 ]
        kzeller kzeller made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        kzeller kzeller made changes -
        Status Resolved [ 5 ] Closed [ 6 ]


          • Assignee:
            kzeller kzeller
            FilipeManana Filipe Manana (Inactive)
          • Votes:
            0 Vote for this issue
            1 Start watching this issue


            • Created:

              Gerrit Reviews

              There are no open Gerrit changes