2003-01-15 Rodrigo Moya <rodrigo@ximian.com>
[mono.git] / mcs / class / Mono.Data.DB2Client / Mono.Data.Db2Client / DB2ClientConstants.cs
1 #region Licence\r
2         /// DB2DriverCS - A DB2 driver for .Net\r
3         /// Copyright 2003 By Christopher Bockner\r
4         /// Released under the terms of the MIT/X11 Licence\r
5         /// Please refer to the Licence.txt file that should be distributed with this package\r
6         /// This software requires that DB2 client software be installed correctly on the machine\r
7         /// (or instance) on which the driver is running.  \r
8 #endregion\r
9 using System;\r
10 \r
11 namespace DB2ClientCS\r
12 {\r
13         /// <summary>\r
14         /// Summary description for DB2Constants.\r
15         /// </summary>\r
16         public class DB2ClientConstants\r
17         {\r
18                 public DB2ClientConstants()\r
19                 {\r
20                         //\r
21                         // TODO: Add constructor logic here\r
22                         //\r
23 \r
24                 }\r
25                 public const short  SQL_HANDLE_ENV = 1;\r
26                 public const short  SQL_HANDLE_DBC = 2;\r
27         public const short  SQL_HANDLE_STMT = 3;\r
28         public const short  SQL_HANDLE_DESC = 4;\r
29 \r
30                 /* RETCODE values             */\r
31         public const long  SQL_SUCCESS                   = 0;\r
32         public const long  SQL_SUCCESS_WITH_INFO = 1;\r
33         public const long  SQL_NEED_DATA         = 99;\r
34         public const long  SQL_NO_DATA           = 100;\r
35         public const long  SQL_STILL_EXECUTING   = 2;\r
36         public const long  SQL_ERROR             = -1;\r
37         public const long  SQL_INVALID_HANDLE    = -2;\r
38                 public const long  SQL_NULL_HANDLE               = 0L;\r
39                 public const short SQL_COMMIT                    = 0;\r
40                 public const short SQL_ROLLBACK                  = 1;\r
41                 public const short SQL_NO_DATA_FOUND     = 100;\r
42 \r
43                 /* Isolation levels */\r
44                 public const long  SQL_TXN_READ_UNCOMMITTED             = 0x00000001L;\r
45                 public const long  SQL_TXN_READ_COMMITTED               = 0x00000002L;\r
46                 public const long  SQL_TXN_REPEATABLE_READ              = 0x00000004L;\r
47                 public const long  SQL_TXN_SERIALIZABLE_READ    = 0x00000008L;\r
48                 public const long  SQL_TXN_NOCOMMIT                             = 0x00000020L;\r
49 \r
50                 /* Connect options */\r
51                 public const long SQL_TXN_ISOLATION             = 108;\r
52                 public const long SQL_AUTOCOMMIT                = 102;\r
53 \r
54                 public const long SQL_AUTOCOMMIT_OFF    = 0L;\r
55                 public const long SQL_AUTOCOMMIT_ON             = 1L;\r
56 \r
57                 /*Data Types */\r
58                 public const int  SQL_CHAR                              = 1;\r
59                 public const int  SQL_DECIMAL                   = 3;\r
60                 public const int  SQL_VARCHAR                   = 12;\r
61                 public const int  SQL_TYPE_DATE                 = 91;\r
62                 public const int  SQL_TYPE_TIME                 = 92;\r
63                 public const int  SQL_TYPE_TIMESTAMP    = 93;\r
64 \r
65                 public const int  SQL_C_CHAR                    = SQL_CHAR;\r
66                 \r
67                 }\r
68 }\r