On May 2, 2012, at 6:18 AM, RUSSELL Thomas wrote:
> Where do I find the code that actually loads the dataset with data from the
> db itself? I traced things back to this line:
>
> self.DataSet = self.DataSetFunction()
>
> but cannot see where or how the data is loaded. I would like to trace this
> out as I did some quick tests in straight python and am able to see the data
> from my db the way I see it elsewhere so I surmise something is amiss here.
The actual communication with the database occurs in
db/dCursorMixin.py, it the execute() method, which starts at line 311. Line 396
is where we actually bring the data from the dbapi cursor into Dabo:
395 try:
396 _records = self.fetchall()
397 except Exception, e:
398 _records = dabo.db.dDataSet()
399 # Database errors need to be decoded from database encoding.
400 try:
401 errMsg = ustr(e).decode(self.Encoding)
402 except UnicodeError:
403 errMsg = ustr(e)
404 dabo.log.error("Error fetching records: (%s, %s)" % (type(e),
errMsg))
When debugging stuff like this, I generally put a lot of 'print'
statements in the code so that I can see what values are at particular points
in the code.
-- Ed Leafe
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message:
http://leafe.com/archives/byMID/[email protected]