Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Apr 21 22:42
    AleRoe commented #1990
  • Apr 21 22:07
    DaNeubi labeled #1990
  • Apr 21 22:07
    DaNeubi opened #1990
  • Apr 20 18:57
    r-koubou commented #1543
  • Apr 20 18:21
    r-koubou commented #1543
  • Apr 20 17:56
    r-koubou commented #1543
  • Apr 20 16:46
    Amleto commented #1977
  • Apr 20 16:46
    Amleto commented #1977
  • Apr 20 14:00
    r-koubou commented #1543
  • Apr 20 13:54
    r-koubou commented #1543
  • Apr 20 09:23
    alb3ric commented #1976
  • Apr 20 02:55
    smadyelse labeled #1989
  • Apr 20 02:55
    smadyelse opened #1989
  • Apr 20 02:52
    smadyelse opened #1988
  • Apr 19 21:26
    alb3ric commented #1976
  • Apr 19 17:49
    helamanb opened #1987
  • Apr 19 17:49
    helamanb labeled #1987
  • Apr 18 11:38
    mgtheone commented #1916
  • Apr 17 16:18
    sveins12 commented #1922
  • Apr 17 16:04
    LennardF1989 commented #1622
Gerard Burger
@gtnb_twitter
Sorry, I mean issue #349.
Fungusware
@Fungusware

Hi all. I'm trying to find the best way to query a large collection of documents, which include a byte[]. I need a fast way to find the most recent Timestamp filtered by an Id

I currently have

var qry = col.Query().
Where(x => x.SensorId == sensorId).
OrderByDescending(x => x.TimeStampUTC).
Limit(1);

But it perform very slow.
Eric Vollenweider
@EricVoll
Hi everybody,
I am using v4.1.4 and am trying to change the password of a db using Shrink(). I get a OutOfMemoryException since it takes >2GB of Ram for a 500MB DB file. This issue is discussed here (mbdavid/LiteDB#531) but doesn't seem to solve my issue or be to in v4.1.4.
Can anybody help me to figure out a solution? Thanks!
(I'll gladly provide more info if needed...)
LBarthe
@LBarthe
Hello, I'm looking for something like this :
GetCollection.Query().Where([LiteDB.Query]::Contains("$a",$Search)-or("$b,$Search"))
But i can't find the solution.
For more info, i use powershell. Thanks !
Paul Smith 🌷🇬🇧
@PJSmith_twitter
Hello All. Having trouble trying to find docs and code examples for insertbulk. I am trying to do this for performance reasons instead of lots of .Insert. Can anyone point me in the right direction? I'm thinking I can just add all my class items to a List and bulk insert the list in one operation, but I'm a little out of my depth without some examples :) Thanks!
LxLeChat
@LxLeChat
hello all ! i'm new to nosql ... so i wanted to know if someone could help me with some queries i'm trying to build ! I found LiteDB and find it super helpful!
I'm trying to use it with powershell !
LBarthe
@LBarthe
Hi @LxLeChat ! You can do something like this $GetCollection.Query().Where([LiteDB.Query]::Contains("Name",$MyVar), you can find few help here https://smsagent.blog/2020/11/23/using-a-litedb-portable-database-with-your-powershell-project/
LxLeChat
@LxLeChat
sweet! i ll check it out !
Raí Toffoletto
@raibtoffoletto
Hey Folks, I wonder if any f you can help me, I started a new job (as frontend) and they putted me to work on a project that I'm having to rebuild the dotnet backend. It uses LiteDB to store data (any data, from csv, excell) in different DBs for different datasets. I'm wondering that is anyway to access this data without mapping it to a poco class.... they way the person before me solved the problem is very buggy, so If anyone can just point me in the right direction I'll be super glad! Thanks in advance for any tips :)
Mi.Chi
@AlessioMiky76_twitter
@raibtoffoletto im developing a framework that do what you need. There is an old preview here: alemik.com. If it is intersting for you contact me by email.
alt160
@alt160
is it possible to get the document 'type' from a BsonDocument? If i wanted to store different types in one database (Person, Company, and Job), how could i enumerate each type in the database? For example if I use _db.GetCollection<Person>(), will the underlying BsonDocument contain the .NET classname?
tengulak
@tengulak
Hi, its looks like Query.Not not working on lastest LiteDB 5.0.10 version, i tried on table with string _id. Query.EQ (=) working ok, but Query.Not (!=) not !!!!!!!!!!!!
winkmichael
@winkmichael
Hello all, I believe this is a bit of a repeat question (sorry). I see mention of a MAC client, is there a MAC client that Google is not helping me find?
That being a OSX version of the LiteDB.Studio
Amleto
@Amleto
Hello. I was wondering if there are any extensions or utils that help to insert/upsert entities when they are added as a dbref in another collection?
Ruslan Mogilevskiy
@ruslanmogilevskiy
Hi there. Could someone unveil how to select the records that contain Dictionary<string, string> property by dictionary's key and value? I.e. I have a Foo class with 'public Dictionary<string, string> Bar' property and I need to select all (or single) Foo that have the key='k1' and value='v1' in its Bar dictionary. I tried collection.FindOne("Bar[*].k1 any in @1", "v1") but it always returns NULL.
Amleto
@Amleto
Wouldnt you need to start with "Foo.Bar... ?
Ruslan Mogilevskiy
@ruslanmogilevskiy
@Amleto , no because collection is strong typed, i.e. collection = db.Collection<Foo>() so the entity name is known.
tried with Foo.Bar[*]... doesn`t work as well
is there any documentation related to any/all out there? Found nothing neither in query samples nor in wiki\docs\api documentation
square brackets looks like its for a list
did you try {} for doc/dict?
also seem syou should start with $.Bar
it's Evidenty not very active here. Try on a programming/c# discord
Ruslan Mogilevskiy
@ruslanmogilevskiy
do you mean Bar{*}.k1 any in '1'? - query format error
Start the query with $. doesn`t work as well
Amleto
@Amleto
well theres no example at all that starts with a property name
Ruslan Mogilevskiy
@ruslanmogilevskiy
yeh ((
Amleto
@Amleto
actually:
"The $ symbol are optional and default in document navigation (Address.Street works too)"
Ruslan Mogilevskiy
@ruslanmogilevskiy
ok, thanks mate, will try my luck on github issues
Amleto
@Amleto
get on discord is my advice
Ruslan Mogilevskiy
@ruslanmogilevskiy
do you have the link for discord channel for litedb?
Amleto
@Amleto
there isn't specific litedb, but I have found this to be a good one
https://discord.gg/csharp
Ruslan Mogilevskiy
@ruslanmogilevskiy
litedb has a unique sql/query syntax so generic c# developer (I am) wont help. Without clear documentation, only litedbs authors know to deal with this
Amleto
@Amleto
or people that have used it... of which you are likely to find on the server
Ruslan Mogilevskiy
@ruslanmogilevskiy
thank you, will try
alb3ric
@alb3ric:matrix.org
[m]
Hello, I have a question concerning shrink (or rebuild). I have a litdb database (4.1.4) with only one collection, in this collection I save datas, that I keep 5 days (every day I delete all the items older than 5 days). My question is what happen about the index ? is it going to keep growing if i don't shrink my database sometimes ? (the application is a windows service that never stop, and the database is continously written) | Thanks for your help :p
alb3ric
@alb3ric:matrix.org
[m]
any help ? :)
cam-coding
@cam-coding
I wonder if anyone has ideas on my issue. A user runs my first application in admin mode, which creates my LiteDB with admin rights. Then in a second application (where they user cannot run the application in admin mode) they are unable to access the DB due to permission issues. Is there anything I can do on DB creation to change this? Or do I need to create the DB normally then find an alternate way of changing the file permissions?
Amleto
@Amleto
If you have an ILitecollection<T>, and it has data for some T (t1, say) with id=1. Then I make a new T (t2, say), set t2.id=1, and change one property on t2. How do I merge that one property into the collection?
Haseeb Iftikhar
@haseeb.iftikhar:matrix.org
[m]
I am getting "The process cannot access the file because it is being used by another process." exception in windows service while using litedb 5.0.8 version.
Helmut Wahrmann
@hwahrmann

i've got 2 questions:

  1. is there a way to influence the file size of the DB. My database is 780MB big compared to 350MB for the same data/index in sqlite

  2. i am inserting 1.8 million documents/rows having 4 fields, the _id and 3 others which need to be indexed.
    inserting them in bulks of 100k and then doing an EnsureIndex on the 3 fields gives me a runtime of roughly 5 minutes
    having the EnsureIndex in place before i start the bulkinsert gives me 9:30 minutes

    Is there a difference in query performance, foing it with method 1 or 2?

Arshel Melfor
@arshel
hey maybe a stupid question but what can mac users use as a alternative to litedb.studio?
jeeshenlee
@jeeshenlee_twitter

I am getting "The process cannot access the file because it is being used by another process." exception in windows service while using litedb 5.0.8 version.

You will need to add connection=shared in the connection string

Refer mbdavid/LiteDB#1453

tleylan
@tleylan
Hi. I just dl'd LiteDB Studio v1.0.2.0 and tried to open an existing DB (created by the NEOS app). I get an error dialog "Ticks must be between DateTime.MinValue.Ticks... etc." Any idea what the issue might be? And is there a way to identify the DB version from the DB file, maybe that's the problem? Thanks.
hidemat
@hidemat
Hello! Hope it's ok to post a noob question here. Does anyone know of a good way to implement full text search using liteDB and a third party search engine (lucene.Net, etc.)?
John Harris
@johncharris
How big of a database does litedb support? I'm thinking about switching over to it so I have have something easy to install, eg no server dependencies. Are there any issues with multiple users as asp.net core?
Aristote Ngoy
@harriscreativity
is possible to sync litedb to cloud using azure mobile sync