docHistory

Definition

Returns historical information about one or more documents. Wrapper for the docHistory command.

Syntax

db.docHistory(collectionName,filter condition)

Example

ProvenDB v7754 (current)> db.docHistory('guysCollection',{_id:4})
{
        "ok" : 1,
        "docHistory" : [
                {
                        "collection" : "guysCollection",
                        "_id" : 4,
                        "history" : {
                                "versions" : [
                                        {
                                                "minVersion" : NumberLong(4531),
                                                "maxVersion" : NumberLong(4536),
                                                "status" : "Unproven",
                                                "started" : "2019-05-28 05:42:11",
                                                "ended" : "2019-05-28 05:42:11",
                                                "document" : {
                                                        "x" : 1,
                                                        "y" : "0.6f9sqy".9ivvczxw5c50.7srwyazjw6v0.qu8llxjxc70.cxkilwnq8m"
                                                }
                                        },
                                        {
                                                "minVersion" : NumberLong(4537),
                                                "maxVersion" : NumberLong(4537),
                                                "status" : "Unproven",
                                                "started" : "2019-05-28 05:42:11",
                                                "ended" : "2019-05-28 05:42:11",
                                                "document" : {
                                                        "x" : 2,
                                                        "y" : "0.6f9sqybr21"
                                                }
                                        }

                                ]
                        }
                }
        ]
}

See also

docHistory