added timestamp code, support columns for group by and order by and tested load has-many eager code
This commit is contained in:
@@ -18,15 +18,19 @@ size_t determine_size(const blob_type_t &val);
|
||||
|
||||
}
|
||||
|
||||
class value
|
||||
{
|
||||
class value {
|
||||
public:
|
||||
value() = default;
|
||||
template<typename Type>
|
||||
template<typename Type, std::enable_if_t<!std::is_enum_v<Type>>* = nullptr>
|
||||
explicit value(Type value, size_t size = 0)
|
||||
: value_(value)
|
||||
, size_(size)
|
||||
, type_(data_type_traits<Type>::type(size)) {}
|
||||
template<typename Type, std::enable_if_t<std::is_enum_v<Type>>* = nullptr>
|
||||
explicit value(Type value, size_t size = 0)
|
||||
: value_(static_cast<int>(value))
|
||||
, size_(size)
|
||||
, type_(data_type_traits<Type>::type(size)) {}
|
||||
explicit value(basic_type data_type, size_t size = 0);
|
||||
value(const value &x) = default;
|
||||
value& operator=(const value &x) = default;
|
||||
@@ -74,11 +78,12 @@ public:
|
||||
[[nodiscard]] bool is_varchar() const;
|
||||
[[nodiscard]] bool is_date() const;
|
||||
[[nodiscard]] bool is_time() const;
|
||||
[[nodiscard]] bool is_timestamp() const;
|
||||
[[nodiscard]] bool is_blob() const;
|
||||
[[nodiscard]] bool is_null() const;
|
||||
|
||||
private:
|
||||
utils::database_type value_;
|
||||
database_type value_;
|
||||
size_t size_{};
|
||||
basic_type type_{basic_type::Null};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user