Compose Database-as-a-Service Help and Documentation

Everything you need to know about Compose, Hosted or Enterprise, is here in our help system. Whether you run one database for your businesses' sole application or six different databases to support an entire corporation, we've got the information you need.

Log Errors

We track errors raised from MongoDB in the log files. Below is a list of errors that we raise.

General

Error Code Description Resolution
10057 You have an unauthorized mongodb command. Check your username and password and make sure you are autheticating properly before performing any operations.
10065 problem detected during query Check log snippet for details
10068 invalid operator You have a malformed query that needs to be corrected
10080 ns name too long, max size is 128 Check log snippet for details
10128 too much data for sort() with no index Add an index or specify a smaller limit
10295 getFile() bad file number value (corrupt db?) run repair Repair database
10334 Invalid BSONObj size Repair database
11000 This occurs when you have a unique index and attempt to insert or update a duplicate key. Depending on your updates, this may be expected behavior. If not, you should check for a unique index and figure out why your updates contain existing values.
12501 quota exceeded You will need to upgrade from a sandbox
13038 Can't find a special index for a specific type of query. Add the required index for the query you are trying to perform (ex. a 2d index to do a $near)
13435 not master and slaveOk=false Make sure you are connecting to a primary for writes or use slaveOk for secondary reads
13440 bad offset 0 accessing file filename.0 - consider repairing database Repair database
16256 Invalid ns Choose a valid ns

Geo

Error Code Description Resolution
13022 can't have 2 geo field Check log snippet for details
13023 2d has to be first in index Check log snippet for details
13024 no geo field specified Check log snippet for details
13026 geo values have to be numbers Check log snippet for details
13027 point not in interval of [_min, _max] Check log snippet for details
13028 bits in geo index must be between 1 and 32 Check log snippet for details
13042 missing geo field _geo Check log snippet for details
13046 param missing/invalid Check log snippet for details
13047 wrong type for geo index. if you're using a pre-release version, need to rebuild index Check log snippet for details
13057 $within has to take an object or array Check log snippet for details
13058 unknown $within information - a shape must be specified. Check log snippet for details
13059 $center has to take an object or array Check log snippet for details
13060 $center needs 2 fields (middle,max distance) Check log snippet for details
13061 need a max distance >= 0 Check log snippet for details
13063 $box needs 2 fields (bottomLeft,topRight) Check log snippet for details
13064 need an area > 0 Check log snippet for details
13065 $box has to take an object or array Check log snippet for details
13067 geo field is empty Check log snippet for details
13068 geo field only has 1 element Check log snippet for details
13314 can't have 2 geo fields Check log snippet for details
13315 2d has to be first in index Check log snippet for details
13316 no geo field specified Check log snippet for details
13317 no other fields specified Check log snippet for details
13318 near needs to be an array Check log snippet for details
13319 maxDistance needs a number Check log snippet for details
13320 search needs to be an object Check log snippet for details
13321 need bucketSize Check log snippet for details
13322 not a number Check log snippet for details
13323 latlng not an array Check log snippet for details
13326 quadrant search can only have 1 other field for now Check log snippet for details
13460 invalid $center query type Check log snippet for details
13461 Spherical MaxDistance > PI. Are you sure you are using radians? Check log snippet for details
13462 Spherical distance would require wrapping, which isn't implemented yet Check log snippet for details
13464 invalid $near search type Check log snippet for details
13654 location object expected, location array not in correct format Check log snippet for details
13656 the first field of $center object must be a location object Check log snippet for details
14029 $polygon has to take an object or array Check log snippet for details
14030 polygon must be defined by three points or more Provide 3 or more point to polygon
14808 point must be in earth-like bounds of long [-180, 180], lat [-90, 90] Make sure the lat/long points are with the bounds of long [-180, 180], lat [-90, 90]

Matcher

Error Code Description Resolution
10066 $where may only appear once in query Check log snippet for details
10067 $where query, but no script engine Check log snippet for details
10068 invalid operator Check log snippet for details
10069 BUG - can't operator for Check log snippet for details
10070 $where compile error Check log snippet for details
10071 Check log snippet for details
10072 unknown error in invocation of $where function Check log snippet for details
10073 mod can't be 0 Check log snippet for details
10341 scope has to be created first! Check log snippet for details
10342 pcre not compiled with utf8 support Check log snippet for details
12517 $elemMatch needs an Object Check log snippet for details
13020 with $all, can't mix $elemMatch and others Check log snippet for details
13029 can't use $not with $options, use BSON regex type instead Check log snippet for details
13030 $not cannot be empty Check log snippet for details
13031 invalid use of $not Check log snippet for details
13032 can't use $not with $regex, use BSON regex type instead Check log snippet for details
13086 $and/$or/$nor must be a nonempty array Check log snippet for details
13087 $and/$or/$nor match element must be an object Check log snippet for details
13089 no current client needed for $where Check log snippet for details
13276 $in needs an array Check log snippet for details
13277 $nin needs an array Check log snippet for details
13629 can't have undefined in a query expression Check log snippet for details
14844 $atomic specifier must be a top level field Check log snippet for details
15882 $elemMatch not allowed within $in Check log snippet for details
15902 $where expression has an unexpected type Check log snippet for details

Query

Error Code Description Resolution
10110 bad query object Check log snippet for details
13051 tailable cursor requested on non capped collection Check log snippet for details
13052 only {$natural:1} order allowed for tailable cursor Check log snippet for details
13530 bad or malformed command request? Check log snippet for details
14833 auth error Check log snippet for details
16083 reserve 16083 Check log snippet for details

Update

Error Code Description Resolution
10131 $push can only be applied to an array Check log snippet for details
10132 $pushAll can only be applied to an array Check log snippet for details
10133 $pushAll has to be passed an array Check log snippet for details
10134 $pull/$pullAll can only be applied to an array Check log snippet for details
10135 $pop can only be applied to an array Check log snippet for details
10136 $bit needs an object Check log snippet for details
10137 $bit can only be applied to numbers Check log snippet for details
10138 $bit cannot update a value of type double Check log snippet for details
10139 $bit field must be number Check log snippet for details
10140 Cannot apply $inc modifier to non-number Check log snippet for details
10141 Cannot apply $push/$pushAll modifier to non-array Check log snippet for details
10142 Cannot apply $pull/$pullAll modifier to non-array Check log snippet for details
10143 Cannot apply $pop modifier to non-array Check log snippet for details
10145 LEFT_SUBFIELD only supports Object Check log snippet for details
10147 Invalid modifier specified Check log snippet for details
10148 Mod on _id not allowed Check log snippet for details
10149 Invalid mod field name, may not end in a period Check log snippet for details
10150 Field name duplication not allowed with modifiers Check log snippet for details
10151 have conflicting mods in update Check log snippet for details
10152 Modifier $inc allowed for numbers only Check log snippet for details
10153 Modifier $pushAll/pullAll allowed for arrays only Check log snippet for details
10154 Modifiers and non-modifiers cannot be mixed Check log snippet for details
10155 cannot update reserved $ collection Check log snippet for details
10156 cannot update system collection Check log snippet for details
10157 multi-update requires all modified objects to have an _id Check log snippet for details
10158 multi update only works with $ operators Check log snippet for details
10159 multi update only works with $ operators Check log snippet for details
10161 Invalid modifier specified Check log snippet for details
10399 ModSet createNewFromMods - RIGHT_SUBFIELD should be impossible Check log snippet for details
10400 unhandled case Check log snippet for details
12522 $ operator made object too large Check log snippet for details
12527 not okForStorage Check log snippet for details
12591 Cannot apply $addToSet modifier to non-array Check log snippet for details
12592 $addToSet can only be applied to an array Check log snippet for details
13478 can't apply mod in place - shouldn't have gotten here Check log snippet for details
13479 invalid mod field name, target may not be empty Check log snippet for details
13480 invalid mod field name, source may not begin or end in period Check log snippet for details
13481 invalid mod field name, target may not begin or end in period Check log snippet for details
13482 $rename affecting _id not allowed Check log snippet for details
13483 $rename affecting _id not allowed Check log snippet for details
13484 field name duplication not allowed with $rename target Check log snippet for details
13485 conflicting mods not allowed with $rename target Check log snippet for details
13486 $rename target may not be a parent of source Check log snippet for details
13487 $rename source may not be dynamic array Check log snippet for details
13488 $rename target may not be dynamic array Check log snippet for details
13489 $rename source field invalid Check log snippet for details
13490 $rename target field invalid Check log snippet for details
13492 mod must be RENAME_TO type Check log snippet for details
13494 $rename target must be a string Check log snippet for details
13495 $rename source must differ from target Check log snippet for details
13496 invalid mod field name, source may not be empty Check log snippet for details
15896 Modified field name may not start with $ Check log snippet for details
16069 ModSet createNewFromMods - Check log snippet for details
9015 Check log snippet for details
9016 nknown $bit operation Check log snippet for details
9017 od apply can't handle type Check log snippet for details

Delete

Error Code Description Resolution
10100 cannot delete from collection with reserved $ in name Check log snippet for details
10101 can't remove from a capped collection Check log snippet for details
12050 cannot delete from system namespace Check log snippet for details

Queryutil

Error Code Description Resolution
10102 bad order array Check log snippet for details
10103 bad order array [2] Check log snippet for details
10104 too many ordering elements Check log snippet for details
10105 bad skip value in query Check log snippet for details
10370 $all requires array Check log snippet for details
12001 E12001 can't sort with $snapshot Check log snippet for details
12002 E12002 can't use hint with $snapshot Check log snippet for details
12580 invalid query Check log snippet for details
13033 can't have 2 special fields Check log snippet for details
13034 invalid use of $not Check log snippet for details
13041 invalid use of $not Check log snippet for details
13050 $all requires array Check log snippet for details
13262 $or requires nonempty array Check log snippet for details
13263 $or array must contain objects Check log snippet for details
13274 no or clause to pop Check log snippet for details
13291 $or may not contain 'special' query Check log snippet for details
13303 combinatorial limit of $in partitioning of result set exceeded Check log snippet for details
13304 combinatorial limit of $in partitioning of result set exceeded Check log snippet for details
13385 combinatorial limit of $in partitioning of result set exceeded Check log snippet for details
13454 invalid regular expression operator Check log snippet for details
13513 sort must be an object or array Check log snippet for details
14048 FieldRangeSetPair invalid index specified Check log snippet for details
14049 FieldRangeSetPair invalid index specified Check log snippet for details
14816 $and expression must be a nonempty array Check log snippet for details
14817 $and elements must be objects Check log snippet for details
15881 $elemMatch not allowed within $in Check log snippet for details

Log Errors


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.