question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error "Invalid format: Collection" when doing Upsert

See original GitHub issue

I am trying to do an “Collection.Upsert” on the following POCO class. [There are other classes like this where upsert works fine!. Only this class fails]. The error is: Error “Invalid format: Collection” when doing Upsert


public class Order : BindableBase { public Order() { this.OrderItems = new List<string>(); } public int Id { get; set; } [BsonRef(“OrderMaster”)] public OrderMaster OrderMaster { get; set; } public List<string> OrderItems { get; set; } }


Stack trace:

Invalid format: Collection at LiteDB.CollectionService.Add (System.String name) [0x0002b] in <b99fd1821def4ff9a5794b6636ed75ad>:0 at LiteDB.LiteEngine.GetCollectionPage (System.String name, System.Boolean addIfNotExits) [0x00035] in <b99fd1821def4ff9a5794b6636ed75ad>:0 at LiteDB.LiteEngine.Transaction[T] (System.String collection, System.Boolean addIfNotExists, System.Func`2[T,TResult] action) [0x00006] in <b99fd1821def4ff9a5794b6636ed75ad>:0

Thank you for the help…

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:16 (6 by maintainers)

github_iconTop GitHub Comments

4reactions
RenniePetcommented, Apr 7, 2018

It would be nice with more explicit error messages than just “Invalid format”. For example “Name too long” and “Invalid character in name” and …

1reaction
mbdavidcommented, Dec 19, 2017

Upgrade do 4.1, it´s fixed now in 60 chars (at limit of 3000 for all collections names)

Read more comments on GitHub >

github_iconTop Results From Across the Web

( INVALID_FIELD_FOR_INSERT_UPDATE, Attempting to ...
This error is telling you that you already have a record with field external_Id__c set to '100201' . When you do the upsert,...
Read more >
How to resolve an 'Invalid format version detected - ...
In my case, I was using the wrong version of yarn. After correcting the version with the help of volta, the error was...
Read more >
Salesforce Connector | Update/ Upsert operation fails with " ...
This article helps to resolve the error "value not of required type" with status code "INVALID_TYPE_ON_FIELD_IN_RECORD" when using the Update/ Upsert operation ...
Read more >
Invalid File Format when trying to update my Photon from ...
I inserted the drive into the Photon and booted it. Both files are visible, but even I try to print them I get...
Read more >
rsa - SSH Suddenly returning Invalid format
I was using an Ubuntu machine, with user ubuntu instead of ec2-user (as is stated on the official Amazon Linux server OS). But...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found