PMXBOT Log file Viewer

Help | Karma | Search:

#mongodb logs for Tuesday the 5th of August, 2014

(Back to #mongodb overview) (Back to channel listing) (Animate logs)
[02:04:45] <idetik2> hello, very basic question here: if a document has a reference to another document (let's call it document2), and document2 is deleted, the reference seems to persist. is this by design? just want to know if i should be taking care of references myself or if mongo has some kind of built in reference monitor.
[02:10:11] <stefandxm> idetik2, are you asking if mongodb is a relational database?
[02:12:45] <idetik2> based on that answer, i'm going to assume i'll have to be taking care of references myself, thanks
[02:22:16] <stefandxm> idetik2, i hope you are right in that assumption ;-)
[03:28:18] <osirisx11> hi all
[03:28:23] <idetik2> hello
[03:28:34] <osirisx11> is it possible to create a selector that will return all documents where one field does not match another?
[03:28:51] <osirisx11> name and nickname, if they are not equal, i'd like to return them
[03:28:56] <osirisx11> if they are equal, i'd like to not return them
[03:32:49] <osirisx11> nevermind i think i figured it out :)
[03:33:51] <osirisx11> hm i guess i have to use $where?
[03:33:53] <osirisx11> is that the only way?
[03:35:45] <osirisx11> { $where: "this.a1.a != this.a2.a" }
[06:40:28] <Foad_NH> Hi, can I use $geoWithin + $box with 2dsphere index or it only works with 2d index?
[09:56:39] <ssarah> hei guy
[09:56:41] <ssarah> s
[09:56:50] <ssarah> gonna start using mongo now
[09:56:56] <ssarah> tell me a good place to start ? =)
[09:57:29] <ron> the docs.
[09:57:35] <ssarah> yeh?
[09:57:39] <ssarah> no nice tutorial?
[09:58:38] <ron> http://docs.mongodb.org/manual/ You see that getting started section?
[09:59:34] <richthegeek> is it possible to compare two fields in an aggregate $match? For example, {$match: {a: "$b"}} ?
[10:01:19] <sec_> where to practise mogodb online?
[10:04:13] <ssarah> ty ron, ima read that
[10:05:11] <Ravenheart> can i ask a stupid question
[10:05:23] <Ravenheart> say you give a new user the role userAdmin
[10:05:32] <Ravenheart> why can't he list/edit users in the db
[10:31:13] <rspijker_> richthegeek: not without javascript, and iirc you can;t use javascript in AFW
[13:01:53] <joannac> Ravenheart: they should be able to
[15:21:35] <scristian> hi all, I have a replicaSet from 4 members (1 pri, 1sec, 1 arb and 1 hidden non voting); the non voting hidden member I want to remain the only primary; how is the fastest way to make non voting member the primary and remove the arbitrer ? thank you
[15:23:06] <kali> scristian: you want the hidden to become visible and preferred primary ?
[15:23:14] <scristian> yes
[15:25:18] <kali> a reconf() should do it
[15:25:24] <kali> reconfig()
[15:26:28] <kali> fetch the current config document, discard the current arbiter, change the hidden status and priority of the node
[15:27:35] <scristian> great, thank you
[15:51:23] <rex_> hi all
[15:51:39] <rex_> anyone here? up and ready for a q now?
[15:51:52] <rex_> I have this db with users, who have user names
[15:52:04] <rex_> their user names are like upper and lower case letters and underscores
[15:52:31] <rex_> I want to use findOne for a user, based on the user name, but I don't want to match case
[15:52:34] <rex_> how do I do this?
[15:52:43] <Derick> with a regular expression perhaps?
[15:53:11] <Derick> db.col.find( name: /derick.*rethaNs/ ); might work for mine
[15:53:20] <rex_> ah, looks like that's the way. I have hte O'reily book right in front of me
[15:53:23] <Derick> alternatively, you can use a text index
[15:53:42] <rex_> and I guess regex is the way to do that
[15:53:52] <rex_> you mean the full text index feature?
[15:54:06] <Derick> rex_: yes, FTI. A regexp can't use an index though...
[15:54:28] <Derick> another option is to store both variants in the document:
[15:54:29] <rex_> then i might as well store the un-cased version of their name and index that
[15:54:37] <rex_> ! we agree
[15:54:39] <Derick> { name: "Derick Rethans", uname: "derick_rethans" }
[15:54:53] <rex_> yah that's genna be my best option
[15:54:55] <Derick> that'd by far be the "fastest" way
[15:55:34] <rex_> well, just wanted to check, but now to think about it, what I'd be doing is checking every user name (worst case)
[15:56:12] <rex_> Derick: what's the @ symbol mean on your uname?
[15:56:28] <Derick> rex_: that I'm one of the channel moderators
[15:56:38] <rex_> ah. you develop for mongodb?
[15:56:46] <Derick> yes
[15:56:59] <Derick> I work on the PHP driver
[15:57:22] <rex_> awesome. You guys are awesome. Some of mongo is still in the works, but the whole 'keep it simple' thing was really carried out
[15:57:45] <Derick> cheers
[15:57:47] <rex_> I tried couchdb first, but it makes you think in terms of map/reduce too much
[15:58:12] <Derick> I personally find MongoDB more flexible... but perhaps I am biased.
[15:58:27] <Derick> m/r is certainly a complex beast that I find difficult to debug
[15:59:29] <rex_> ok im outy for now. peace
[16:22:17] <bakhtiya> Any suggestions for instance-types on Amazon EC2 to run a sharded mongo cluster such that wasted resources are limited? Running a ~200GB mongo cluster now through 2 shards (both replicasets) on 2x (shards) 3x (per-replicaset) of r3.4xlarges but I'm wasting 8 out of the 16 cores on each machine (as mongo for some reason doesn't take advantage of the other cores)
[16:45:53] <vladuemilian> how can I store in MongoDB a dictionary which contain a unhashed list
[16:46:01] <vladuemilian> I want to let python to create hashes for the list
[16:46:33] <vladuemilian> example: {'Germany': ['Berlin', 'Stuttgard', 'Dortmund'] }
[16:47:06] <vladuemilian> I want to store this in a Countries document
[16:47:27] <vladuemilian> I want to let Mongo to ad _id to 'Germany' and for each item from the list
[16:47:29] <vladuemilian> I'm using python
[16:47:32] <vladuemilian> any ideea?
[17:53:37] <ryanstout> quick question, how do I match on a field (userId for example), then sum another field? I googled and googled and can’t find how to do it
[17:58:06] <shaggy_surfer> Hi there, can anyone tell me what the difference between mongo-10gen and mongo-org is? I have inherited existing amazon ami distro w/ mongo-10gen and it's on 2.4 and they want to go to 2.6, but it doesn't appear that 2.6 exists under mongo-10gen
[17:58:24] <shaggy_surfer> How can I upgrade to mongo-org from mongo-10gen
[18:20:34] <boonkerz> hello
[18:20:44] <boonkerz> anyone uses mongodb with docker?
[19:44:52] <desmondHume> somebody with any experience with mongoid + factory_girl?
[21:10:40] <reencoded> greeetings all!
[21:11:43] <ernetas> Hey guys.
[21:11:52] <ernetas> We're having a major MongoDB crash atm.
[21:12:41] <ernetas> One shard node has been restarted and since then, mongos is getting Socket exceptions when connecting to it. Although I can connect to it from the mongos server.
[21:12:59] <ernetas> And the shard node cannot connect to config servers.
[21:13:05] <ernetas> (again socket exception)
[21:20:32] <ernetas> What could be the issue? :/
[21:22:10] <sheki> hey i wonder why explain returns nscanned > $maxScanned
[21:22:37] <sheki> https://gist.github.com/sheki/4f477baaee9e67decde4
[21:34:39] <baegle> I can't figure out how to update records with values from those records
[21:35:00] <baegle> like collection.update({},{$set:{a:this.b}},0,1);
[21:35:06] <baegle> what's the right syntax?
[21:46:36] <iszak> So I have mongodb and it's allocating lots of space but it's not using it, under /var/lib/mongodb, how can I force a sync to disk?