[00:12:57] <quarters> does mongodb keep the connection open only for as long as the query is being made typically?
[01:54:24] <OrangeManBad> what's the best web interface for mongodb?
[06:35:43] <hendry> hi, how do i query just the size object in this example? https://docs.mongodb.com/manual/tutorial/query-documents/ i.e. just want to see size
[10:24:53] <negaduck> hello. I'm trying to increase throughput, I have a primary and two secondaries on different vms. When I just do MongoClient('ip'), I have around 133 req/s. When I do MongoClient('mongodb://ip,ip,ip', replicaSet='repl0', read_preference=ReadPreference.NEAREST), I get the same 133 req/s overall, every machine gets a third of the load. I'm confused. How to max throughput of each mongo?
[12:48:10] <adamo> Hi, any known issue that doesn't allow me to create an index using { "_id" : 1, xxx: 1, "_id" : -1 } ?
[12:50:10] <Derick> you can't have the same field twice in an index
[12:50:23] <Derick> why would you want to do that? e.g., what is your use case?
[12:50:30] <synthmeat> i didn't even know you can do anything to _id index
[12:50:43] <Derick> synthmeat: you can't, but you can add the _id field to other indexes
[12:53:01] <adamo> @Derick the idea of adding the _id -1 was to sort the find.. I'm using $gte and $lte in the _id + the xxx field to query..
[12:53:16] <adamo> right now the sort process is taking a lot
[12:56:38] <adamo> _id is being choosen but the cost of opening docs and sorting are killing me, the interesting part is that mongodb changes the index to: { "_id" : -1, "xxx" : 1 } and the sort still slow
[12:58:22] <adamo> maybe I should not rely on _id to query and create an additional field with a timestamp
[13:00:59] <Derick> adamo: can you show your query in a pastebin?
[13:05:56] <adamo> Derick I'm sorry but I can't share the explain as it has sensitive data. You already answered my question. I will send a question with the explain without sensitive data (test case) to the google group as soon as possible.
[13:08:25] <adamo> In order to fix it I will create a new field and then index the {timestamp : 1, xxx: 1, _id : -1 } so no repeated field in the index :)
[17:29:00] <wfq> Is there anyway to a query based on the date of the week of the current date and time of the mongodb database please? I have seem most of the examples by getting the day of the week out of a datetime field, but I just want to do it from now - now from the server where the database sits and not the client as this is dead simple
[17:29:52] <wfq> I want to do something like select dayWeek(now()) union select ... in RBDMS's
[17:30:20] <wfq> or select ... where dayWeek(now()) = 7
[17:30:58] <wfq> I know I can do that using $where and a javascript function but I'd like to use pure non_sql language
[17:36:26] <wfq> need to get my head around mongo and understand why certain things seem too wooden to do