DatabaseDatum

Represents a single item in a result. A row is a set of these DatabaseDatums.

struct DatabaseDatum {
int platformSpecificTag;
LimitedVariant storage;
}

Constructors

this
this(string s)

These are normally constructed by the library, so you shouldn't need these constructors. If you're writing a new database implementation though, here it is.

Alias This

toString

For compatibility with earlier versions of the api, all data can easily convert to string implicitly and opCast keeps to!x(this) working.

The toArsdJsVar one is in particular subject to change.

Members

Functions

isNull
bool isNull()

Returns true if the item was NULL in the database.

opCast
T opCast()
toArsdJsVar
string toArsdJsVar()

Converts the datum to a string in a format specified by the database.

toString
string toString()

Converts the datum to a string in a format specified by the database.

Meta

History

Added June 2, 2023 (dub v11.0). Prior to this, it would always use string. This has alias toString this to try to maintain compatibility.

Suggestion Box / Bug Report