12.10.xC2: MongoDB compatibility
Posted in 2013
Anyone using or investigating MongoDB? -bash-3.2$ mongo --nodb MongoDB shell version: 2.4.6 > db_mongo = connect("localhost:50000/test") connecting to: localhost:50000/test test > db_informix = connect("localhost:27017/stores") connecting to: localhost:27017/stores stores > db_mongo.state.find() > var list = db_informix.state.find().toArray() > db_mongo.state.insert(list) > db_mongo.state.find() { "_id" : ObjectId("523b6e7484887aaa074d9b3d"), "code" : "AK", "sname" : "Alaska" } { "_id" : ObjectId("523b6e7484887aaa074d9b3e"), "code" : "HI", "sname" : "Hawaii" } { "_id" : ObjectId("523b6e7484887aaa074d9b3f"), "code" : "CA", "sname" : "California" } { "_id" : ObjectId("523b6e7484887aaa074d9b40"), "code" : "OR", "sname" : "Oregon" } { "_id" : ObjectId("523b6e7484887aaa074d9b41"), "code" : "WA", "sname" : "Washington" } { "_id" : ObjectId("523b6e7484887aaa074d9b42"), "code" : "ID", "sname" : "Idaho" } { "_id" : ObjectId("523b6e7484887aaa074d9b43"), "code" : "NV", "sname" : "Nevada" } { "_id" : ObjectId("523b6e7484887aaa074d9b44"), "code" : "MT", "sname" : "Montana" } { "_id" : ObjectId("523b6e7484887aaa074d9b45"), "code" : "WY", "sname" : "Wyoming" } { "_id" : ObjectId("523b6e7484887aaa074d9b46"), "code" : "UT", "sname" : "Utah" } { "_id" : ObjectId("523b6e7484887aaa074d9b47"), "code" : "AZ", "sname" : "Arizona" } { "_id" : ObjectId("523b6e7484887aaa074d9b48"), "code" : "NM", "sname" : "New Mexico" } { "_id" : ObjectId("523b6e7484887aaa074d9b49"), "code" : "CO", "sname" : "Colorado" } { "_id" : ObjectId("523b6e7484887aaa074d9b4a"), "code" : "ND", "sname" : "North Dakota" } { "_id" : ObjectId("523b6e7484887aaa074d9b4b"), "code" : "SD", "sname" : "South Dakota" } { "_id" : ObjectId("523b6e7484887aaa074d9b4c"), "code" : "NE", "sname" : "Nebraska" } { "_id" : ObjectId("523b6e7484887aaa074d9b4d"), "code" : "KS", "sname" : "Kansas" } { "_id" : ObjectId("523b6e7484887aaa074d9b4e"), "code" : "OK", "sname" : "Oklahoma" } { "_id" : ObjectId("523b6e7484887aaa074d9b4f"), "code" : "TX", "sname" : "Texas" } { "_id" : ObjectId("523b6e7484887aaa074d9b50"), "code" : "MN", "sname" : "Minnesota" } Type "it" for more > This looks nice :) -- Fernando Nunes Portugal http://informix-technology.blogspot.com My email works... but I don't check it frequently... --047d7b5db26a1002e604e6c3b238