Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

301
Vistas
DocumentDB updateOne fails with 163 Name is not valid for storage

I've seen issues with $ prefixed fields when writing into Mongo/Document DB, I still don't get what I'm missing.

writing into collections sessions works fine:

db.updateOne(
  { _id: '32c8529b-561f-413c-a6eb-daffbdf1b1e0_google-oauth2|666666666666666666666' },
  { '$set': { _id: '32c8529b-561f-413c-a6eb-daffbdf1b1e0_google-oauth2|666666666666666666666', value: {} } },
  { upsert: true }
)

however writing into collection data fails:

db.updateOne(
  { _id: 'google-oauth2|666666666666666666666' },
  { '$set': { _id: 'google-oauth2|666666666666666666666', value: { data: [Object], revision: 76 } } },
  { upsert: true }
)

With message: 163 MongoError Name is not valid for storage

Both collections have been implicitly created, there's no extra config.

I can only guess at this point that the data (which is a 200kb JSON) contains some key that results in this? there's no $ signs in that whole JSON and most of the keys are uuids.

Any idea what's broken here?

Thanks

over 4 years ago · Santiago Trujillo
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda