Index: sql/connection.h |
diff --git a/sql/connection.h b/sql/connection.h |
index 65020a04ebb86e0842f1048d119e2d88185b4fbf..126261ff8722eaf78cf547a96963cffc931ff097 100644 |
--- a/sql/connection.h |
+++ b/sql/connection.h |
@@ -24,6 +24,16 @@ namespace sql { |
class Statement; |
+// Possible return values from ColumnType in a statement. These should match |
+// the values in sqlite3.h. |
+enum ColType { |
+ COLUMN_TYPE_INTEGER = 1, |
+ COLUMN_TYPE_FLOAT = 2, |
+ COLUMN_TYPE_TEXT = 3, |
+ COLUMN_TYPE_BLOB = 4, |
+ COLUMN_TYPE_NULL = 5, |
+}; |
Scott Hess - ex-Googler
2012/10/02 03:58:47
AFAICT, this is not used in this file? Either tha
|
+ |
// Uniquely identifies a statement. There are two modes of operation: |
// |
// - In the most common mode, you will use the source file and line number to |
@@ -289,6 +299,10 @@ class SQL_EXPORT Connection { |
// Returns true if a column with the given name exists in the given table. |
bool DoesColumnExist(const char* table_name, const char* column_name) const; |
+ // Returns the type/affinity of the given column in the given table. |
+ const std::string GetColumnType(const char* table_name, |
+ int column_index) const; |
+ |
// Returns sqlite's internal ID for the last inserted row. Valid only |
// immediately after an insert. |
int64 GetLastInsertRowId() const; |