Skip to main content

Hi,

I want to insert or replace a json document in a collection using PUT and mongodb_id with a Featurewriter.

If the document don't exists, no probleme

If the document exist, there is an errror message:

 

E11000 duplicate key error collection: fdppma_dev_pdpg.Couche index: _id_ dup key: { : ObjectId('62b01e134c2300007e0001a5') }: generic server error

 

I believe that Put delete the object before insert it.

 

Someone have got an idea ?

 

Thanks

 

Hello @pg.souque​, thanks for posting! Would you be able to share a bit more information about:

  • What version of FME you're using?
  • What data formats you're reading/writing to?
  • What tool are you using to make the updates? (eg. where is PUT statement being used?)
  • A full logfile?

If you're able to share a smaller workspace where I can reproduce the error, that would be great! Otherwise, it might be helpful to know how your FME workbench is currently set up? (screenshot would suffice). Happy to help, Kailin


Hi @kailinatsafe​ ,

  • Fme version: FME(R) 2022.0.1.1 (20220617 - Build 22350 - WIN64) 
  • Data format : Json to a mongodb collection
  • Update with Featurewriter (see attachment)
  • log: error at 2022-10-19 08:28:33 (can i send to you the entire log by mail ?) :
  •  Attributes: only a json and mongodb_id

Thank you

FeatureWriter jsonEnd of Workbench


Reply