Warren Young wrote:
> But recently, it came to me that the integer overloads were probably the
> least useful of the bunch in real-world code. Intelligent database
> design doesn't make the client code dependent on the number or order of
> database columns. So, I wonder if it would have been better to keep
> operator[](const char*) instead.
This depends a lot on how important lookup speed is. The integer lookup
is bound to be faster than the string lookup. Though there's already
enough of a speed hit in the mysqlpp::Row stuff that it may not matter.
However, I can say that my code currently does use the numeric index
lookup, because it knows what order the fields are in (they match
another list it's keeping). So there's at least one instance of real
world code that uses it.