Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
TMySQLRow.h
Go to the documentation of this file.
1 // @(#)root/mysql:$Id$
2 // Author: Fons Rademakers 15/02/2000
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TMySQLRow
13 #define ROOT_TMySQLRow
14 
15 #include "TSQLRow.h"
16 
17 #include <mysql.h>
18 
19 class TMySQLRow : public TSQLRow {
20 
21 private:
22  MYSQL_RES *fResult; // current result set
23  MYSQL_ROW fFields; // current row
24  ULong_t *fFieldLength; // length of each field in the row
25 
26  Bool_t IsValid(Int_t field);
27 
28 public:
29  TMySQLRow(void *result, ULong_t rowHandle);
30  ~TMySQLRow();
31 
32  void Close(Option_t *opt="");
33  ULong_t GetFieldLength(Int_t field);
34  const char *GetField(Int_t field);
35 
36  ClassDef(TMySQLRow,0) // One row of MySQL query result
37 };
38 
39 #endif
40