Boost logo

Boost :

From: Bill Seymour (bsey_at_[hidden])
Date: 2001-06-06 08:34:53


I've looked over the _Introduction to the Database Template
Library_ document, and I've reread about the first half more
carefully. The second half hasn't sunk in yet.

I have a few concerns:

- I would recommend not overloading the == operator to bind
  database columns to structure members. In accordance with
  the "principle of least surprise," overloaded operators
  should do the same kind of thing that the corresponding
  built-in operators do. I suggest a conventional member
  function for doing the binding. The name "bind" comes
  to mind. 8-)

- Without random-access iterators, it seems like there's
  no way to mimic the functionality of scroll cursors.
  They're part of standard SQL.

- What's the first DefaultInsValidate<>::operator() argument?
  It's not referenced in the sample code. Could it have
  something to do with validating a row based on values
  in other rows? If so, I think that violates the relational
  paradigm.

- In the IndexedViewExample() function, it looks like the
  framework allows modifying keys. This seems dangerous.

- There are several places in the document where it's implied
  that SGI documentation contains the authoritative description
  of the part of the C++ standard library commonly called the
  STL. I don't mean to cast any aspersions on CGI; but isn't
  the ISO standard a better authority to cite?

--Bill Seymour


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk