Logo Search packages:      
Sourcecode: freetds version File versions

void tds_add_row_column_size ( TDSRESULTINFO info,

Add a column size to result info row size and calc offset into row

info result where to add column
curcol column to add

Definition at line 749 of file token.c.

References tds_column_info::column_offset, tds_column_info::column_size, tds_column_info::column_type, tds_result_info::row_size, and tds_add_row_column_size().

Referenced by tds_add_row_column_size().

      /* the column_offset is the offset into the row buffer
       * where this column begins, text types are no longer
       * stored in the row buffer because the max size can
       * be too large (2gig) to allocate 
      curcol->column_offset = info->row_size;
      if (is_numeric_type(curcol->column_type)) {
            info->row_size += sizeof(TDS_NUMERIC);
      } else if (is_blob_type(curcol->column_type)) {
            info->row_size += sizeof(TDSBLOBINFO);
      } else {
            info->row_size += curcol->column_size;
      info->row_size += (TDS_ALIGN_SIZE - 1);
      info->row_size -= info->row_size % TDS_ALIGN_SIZE;

Generated by  Doxygen 1.6.0   Back to index