From 15c1e5566f7ad8448985ca6e52805ceb4ec389a8 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Mon, 24 May 2021 01:01:30 +0100 Subject: Basic support for queries with bound parameters Bit of a reshuffle to make the types not DB specific, add some basic tests over query execution, no selects yet and no validation anything is actually right. --- lib/streamSupport.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'lib/streamSupport.cpp') diff --git a/lib/streamSupport.cpp b/lib/streamSupport.cpp index acf6f7e..32c1fce 100644 --- a/lib/streamSupport.cpp +++ b/lib/streamSupport.cpp @@ -1,7 +1,7 @@ #include "streamSupport.h" #include "bitset.h" #include "compileTimeFormatter.h" -#include "mysql_types.h" +#include "dbTypes.h" #include #include #include @@ -35,21 +35,21 @@ namespace std { } std::ostream & - operator<<(std::ostream & s, const MyGrate::MySQL::Date & d) + operator<<(std::ostream & s, const MyGrate::Date & d) { return AdHoc::scprintf<"%04d-%02d-%02d">(s, d.year, d.month, d.day); } std::ostream & - operator<<(std::ostream & s, const MyGrate::MySQL::Time & t) + operator<<(std::ostream & s, const MyGrate::Time & t) { return AdHoc::scprintf<"%02d:%02d:%02d">(s, t.hour, t.minute, t.second); } std::ostream & - operator<<(std::ostream & s, const MyGrate::MySQL::DateTime & dt) + operator<<(std::ostream & s, const MyGrate::DateTime & dt) { - return AdHoc::scprintf<"%? %?">(s, (const MyGrate::MySQL::Date)dt, (const MyGrate::MySQL::Time)dt); + return AdHoc::scprintf<"%? %?">(s, (const MyGrate::Date)dt, (const MyGrate::Time)dt); } std::ostream & -- cgit v1.2.3