Warning, /sdk/codevis/thirdparty/soci/TODO is written in an unsupported language. File is not indexed.
0001 TODO 0002 0003 This file contains a raw bunch of ideas for future releases. 0004 Not all of these ideas will necessarily make sense - they are here to get them together. 0005 0006 --- 0007 Source of many concepts 0008 http://lists.boost.org/Archives/boost/2006/12/113961.php 0009 0010 --- 0011 RAII for transactions. 0012 0013 --- 0014 Query construction utilities (kind of Ultimate++) - can be easily incorporated into SOCI by just making them streamable. 0015 0016 --- 0017 CLOB 0018 0019 --- 0020 Streaming interface for BLOB 0021 0022 --- 0023 Standard names for Session constructor. 0024 0025 --- 0026 wstring 0027 Unicode support 0028 0029 --- 0030 Handle locales in Session (so that operator<< is immune to strange global locale in the user program). It might even make sense to expose imbue(), so that users set up whatever locale they want. 0031 It might even make sense to expose the whole stream object. 0032 Alternatively, the backend should decide on the locale, because the backend will know best how to format numbers, dates, etc. 0033 0034 --- 0035 sql << "select...", into(x, default(7)); 0036 0037 Note: default is a reserved word. 0038 0039 --- 0040 Provide statement-wide flag for eNoData case (because actually it *is* statement-wide, not field-wide). With this, boost.optional would handle the eNull case and the indicators could be dropped. 0041 0042 --- 0043 0044 query backend for supported featureset at runtime 0045 --- 0046 0047 Rowset<tuple> 0048 --- 0049 0050 Rowset<T>, including Rowset<tuple> - way to indicate nulls? 0051 Additional pair based val/indicator interface? 0052 0053 --- 0054 Consolidate iteration methods? 0055 most radical: do we still need Statement::fetch()? into()? 0056 (Rowset<Row> can currently be used for any query, supports indicators, 0057 defaults, and no need to check for eNodata) 0058 0059 --- 0060 ColumnProperties() more logically belongs to Rowset than to Row 0061 However Row::ColumnProperties() still needed if we support into(Row) 0062 0063 --- 0064 sql.prepare by default when constructing Rowsets and Statements? 0065 Rowset<int> rs = (sql << "select n from t";) 0066 0067 --- 0068 row[i].get<string>() instead of row.get<string>(i) 0069 row["col"].get<string>() instead of row.get<string>("col") 0070 0071 --- 0072 Make more member functions private 0073 0074 --- 0075 Values class should be reference counted 0076 0077 --- 0078 CSV backend 0079 0080 Example: 0081 Session s("csv:///etc/protocols"); 0082 rowset<string> rs = (s.prepare << "1:*"); 0083 copy(rs.begin(), rs.end(), ...); 0084 0085 where "1:*" is taken from the top of my head and would mean "first field 0086 from all rows" 0087 0088 - joins are tricky 0089 0090 --- 0091 DBF backend, similar to CSV 0092 0093 Session s("dbf:///table.dbf"); 0094 rowset<string> rs = (s.prepare << "1:*") // first field from all rows 0095 rowset<string> rs = (s.prepare << "firstname:*") // 'firstname' field from all rows 0096 rowset<Row> rs = (s.prepare << "firstname='John'") // rows where 'firstname' value is 'John' 0097 0098 Sub-concepts: 0099 0100 - joins are tricky 0101 0102 - boolean operators (<,>,=,<=,=> and <>) and WHERE-like clause support as a query 0103 0104 rowset<Row> rs = (s.prepare << "age > 28") // rows where field 'age' is less than 28 0105 rowset<Row> rs = (s.prepare << "age <> 28") // rows where field 'age' is less or more than 28 0106 rowset<Row> rs = (s.prepare << "firstname='John' AND age > 28") // multi-fields combined queries 0107 0108 - very simple home-made SQL parser or SQL-like queries support (see OGR utils from http://www.gdal.org) 0109 0110 ---