Skip to content
Snippets Groups Projects
Commit d8108c66 authored by Henrik Tjäder's avatar Henrik Tjäder
Browse files

Quick way to cat database

parent f876e724
No related branches found
No related tags found
No related merge requests found
catDB.py 0 → 100644
# pymongo for MongoDB support
import pymongo
# For timestamping in MongoDB
import datetime
#pymongo connect
DBConHost = 'localhost'
DBConPort = 27017
DBName = 'matningar'
DBTableName = 'stability'
DBCon = pymongo.MongoClient(DBConHost, DBConPort)
DB = DBCon[DBName]
DBTableStability = DB[DBTableName]
#post = {
##"timestamp" : int(time.time()),
##Not needed since first 4bits of _id is timestamp
#"stability" : mos,
#"position" : False # Position appended here
#}
for post in DBTableStability.find():
print(post)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment