bson_compare() — libbson 1.6.3

- libbson 1.6.3 »
- API Reference »
- bson_t

# bson_compare()

## Synopsis

    int
    bson_compare (const bson_t *bson, const bson_t *other);

## Parameters

- `bson`: A bson_t.
- `other`: A bson_t.

## Description

The bson_compare() function shall compare two bson documents for equality.

This can be useful in conjunction with _qsort()_.

If equal, 0 is returned.

## Returns

less than zero, zero, or greater than zero in `qsort()` style.

Created using Sphinx 1.5.3, based on Sphinx Readable Theme.