I think I have answered my own question (at leat partially) - internally in 
SQLite I think that the dates are stored in YYYY-MM-DD format - so I could 
just concatenate the fields. Problem is, I suspect, that that wouldn't be a 
portable solution to other databases - so ... any suggestions?
Regards
Rodgy
----- Original Message ----- 
From: "Roger Lovelock" <[email protected]>
To: "Dabo Users list" <[email protected]>
Sent: Sunday, March 01, 2009 8:38 AM
Subject: [dabo-users] DataSet question


> Hi,
>  This probably reveals my ignorance of Python! I am producing some reports 
> and, of course need to sort the dataset first to suit my grouping of data 
> eg:-
>
> def requery(self):
>  # pass any selection criteria here
>  self.DataSet = self.myBizobj.getDataSet()
>  self.DataSet = self.DataSet.sort("AccountType")
>
> I want to sort on 2 fields - Account Type and Date - I can't just 
> concatenate the strings as they come from SQLite - I need to make the date 
> field meaningful as a sort sequence. Only thought I had was to sort by 
> date after it was converted to a yyyymmdd form, and then sort by 
> AccountType as 2 steps - but it seems a complicated way to do things. An 
> alternative was to concatenate AccountType with the reformatted date - but 
> again - seems a long way around. Does anyone have better suggestions?
> Thanks
> Rodgy
>
> --- StripMime Report -- processed MIME parts ---
> multipart/alternative
>  text/plain (text body -- kept)
>  text/html
> ---
>
[excessive quoting removed by server]

_______________________________________________
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/ec1404fa6db340c9a7e867ee51bd2...@roger

Reply via email to