next up previous contents
Next: GetDataType Up: General Methods Previous: Column Option Constants

SetFlags

NAME SetFlags

PROTOTYPE

#include "SSTable.h"

int SSTable::SetFlags(char newOpts, int colIndex);

EXAMPLE

#include "SSTable.h"

SSTable * pTable = new SSTable();

... // do table construction 

// Set all columns to case insensitive strings
for (int i = 0; i < pTable->GetNumColumns(); i++) {
  pTable->SetFlags(SSTable::DT_STRING |
                   SSTable::CASE_INSENSE, i);
}
PURPOSE

SetFlags set the flags for a particular column. These flags dictate the datatype of the column and the behavior of searches done on the column.

RECEIVES

newOpts A bit field comprised of the bitwise ORing of the desired options.
colIndex The index of the column to have flags set.

RETURN VALUE

A negative value indicates an error or warning.

REMARKS

Note that setting one of case (in)sensitivity, white space (in)sensitivity, or datatype does not interfere with the current setting of the other two.

See also: Column Option Constants



Olivera Tosic
12/17/1999