diff options
author | randomdan <randomdan@localhost> | 2014-03-03 20:57:27 +0000 |
---|---|---|
committer | randomdan <randomdan@localhost> | 2014-03-03 20:57:27 +0000 |
commit | 274b757c0626abcda3a0414451fc4d1b2bc766f9 (patch) | |
tree | 714942e2fd8694548c7ced7859a996475e30a571 /libmysqlpp/selectcommand.cpp | |
parent | Fix slice scanner and split .ice files back into logical blocks (diff) | |
download | libdbpp-mysql-274b757c0626abcda3a0414451fc4d1b2bc766f9.tar.bz2 libdbpp-mysql-274b757c0626abcda3a0414451fc4d1b2bc766f9.tar.xz libdbpp-mysql-274b757c0626abcda3a0414451fc4d1b2bc766f9.zip |
Adds native support for time_duration as a variable type
Pass/retrieve boost::posix_time ptime and time_duration into/out of the db tier
Diffstat (limited to 'libmysqlpp/selectcommand.cpp')
-rw-r--r-- | libmysqlpp/selectcommand.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libmysqlpp/selectcommand.cpp b/libmysqlpp/selectcommand.cpp index e6bf789..b361fb1 100644 --- a/libmysqlpp/selectcommand.cpp +++ b/libmysqlpp/selectcommand.cpp @@ -44,6 +44,9 @@ MySQL::SelectCommand::execute() case MYSQL_TYPE_DATETIME: columns.insert(boost::shared_ptr<ColumnBase>(new Column<MYSQL_TIME, MYSQL_TYPE_DATETIME>(fieldDefs[i].name, i, &fields[i]))); break; + case MYSQL_TYPE_TIME: + columns.insert(boost::shared_ptr<ColumnBase>(new Column<MYSQL_TIME, MYSQL_TYPE_TIME>(fieldDefs[i].name, i, &fields[i]))); + break; case MYSQL_TYPE_STRING: case MYSQL_TYPE_VAR_STRING: columns.insert(boost::shared_ptr<ColumnBase>(new StringColumn(fieldDefs[i].name, i, &fields[i], fieldDefs[i].length))); @@ -56,7 +59,6 @@ MySQL::SelectCommand::execute() case MYSQL_TYPE_SET: case MYSQL_TYPE_ENUM: case MYSQL_TYPE_GEOMETRY: - case MYSQL_TYPE_TIME: default: mysql_free_result(prepare_meta_result); throw Error("Unexpected type"); |