r89232 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r89231‎ | r89232 | r89233 >
Date:22:44, 31 May 2011
Author:rfaulk
Status:deferred
Tags:
Comment:
adding 'query_type' and 'column_names' as class members to data loader objects to associate with query
retrieve connection credentials from settings.py
Modified paths:
  • /trunk/fundraiser-statistics/fundraiser-scripts/classes/DataLoader.py (modified) (history)

Diff [purge]

Index: trunk/fundraiser-statistics/fundraiser-scripts/classes/DataLoader.py
@@ -23,6 +23,7 @@
2424 import datetime
2525 import re # regular expression matching
2626
 27+import Fundraiser_Tools.settings as projSet
2728 import Fundraiser_Tools.classes.QueryData as QD
2829 import Fundraiser_Tools.classes.TimestampProcessor as TP
2930 import Fundraiser_Tools.classes.Helper as Hlp
@@ -63,7 +64,7 @@
6465
6566 """ Establish connection """
6667 #db = MySQLdb.connect(host='db10.pmtpa.wmnet', user='rfaulk', db='faulkner')
67 - self._db_ = MySQLdb.connect(host='127.0.0.1', user='rfaulk', db='faulkner', port=3307)
 68+ self._db_ = MySQLdb.connect(host=projSet.__db_server__, user=projSet.__user__, db=projSet.__db__, port=projSet.__db_port__)
6869 #self.db = MySQLdb.connect(host='storage3.pmtpa.wmnet', user='rfaulk', db='faulkner')
6970
7071 """ Create cursor """

Status & tagging log