Changeset 2665 for pykota/trunk/pykota/storages
- Timestamp:
- 02/11/06 11:47:29 (18 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/pykota/storages/sql.py
r2657 r2665 130 130 thefilter = "AND %s" % thefilter 131 131 (startdate, enddate) = self.cleanDates(startdate, enddate) 132 if startdate and enddate : 133 thefilter = "%s AND jobdate>=%s AND jobdate<=%s" % (thefilter, self.doQuote(startdate), self.doQuote(enddate)) 132 if startdate : 133 thefilter = "%s AND jobdate>=%s" % (thefilter, self.doQuote(startdate)) 134 if enddate : 135 thefilter = "%s AND jobdate<=%s" % (thefilter, self.doQuote(enddate)) 134 136 result = self.doRawSearch("SELECT users.username,printers.printername,jobhistory.* FROM users,printers,jobhistory WHERE users.id=jobhistory.userid AND printers.id=jobhistory.printerid %s ORDER BY jobhistory.id ASC" % thefilter) 135 137 return self.prepareRawResult(result)