Changes to prepare for LOB locators.
authorChristopher Bockner <chris@mono-cvs.ximian.com>
Fri, 11 Apr 2003 02:38:02 +0000 (02:38 -0000)
committerChristopher Bockner <chris@mono-cvs.ximian.com>
Fri, 11 Apr 2003 02:38:02 +0000 (02:38 -0000)
svn path=/trunk/mcs/; revision=13496

mcs/class/Mono.Data.DB2Client/Mono.Data.Db2Client/DB2ClientConstants.cs
mcs/class/Mono.Data.DB2Client/Mono.Data.Db2Client/DB2ClientDataReader.cs
mcs/class/Mono.Data.DB2Client/Mono.Data.Db2Client/DB2ClientPrototypes.cs

index 8029ff2af3b3e67b4f501200ed94128e1fadcee3..cbae8968f9e27464656d78e5a255f37e11e2c04e 100644 (file)
@@ -77,6 +77,14 @@ namespace DB2ClientCS
                public const int  SQL_C_CHAR                    = SQL_CHAR;\r
                public const int  SQL_C_DEFAULT                 = 99;\r
 \r
+               public const int  SQL_BLOB_LOCATOR              = 31;\r
+               public const int  SQL_CLOB_LOCATOR              = 41;\r
+               public const int  SQL_DBCLOB_LOCATOR    = -351;\r
+\r
+               public const int  SQL_C_BLOB_LOCATOR = SQL_BLOB_LOCATOR;\r
+               public const int  SQL_C_CLOB_LOCATOR = SQL_CLOB_LOCATOR;\r
+               public const int  SQL_C_DBCLOB_LOCATOR = SQL_DBCLOB_LOCATOR;\r
+\r
                public const int  SQL_USER_DEFINED_TYPE = (-450);\r
 \r
                /* SQLDriverConnect Options */\r
index 172ae5a16928015a7a7470f40b9d8fdd7e81a31e..533ad9fc6d4939e1fdb0728c986ea8076e11f9bc 100644 (file)
@@ -476,6 +476,17 @@ namespace DB2ClientCS
                        return Convert.ToString(this[col]);\r
                }\r
                #endregion\r
+\r
+               #region GetLobLocator\r
+               ///\r
+               ///Returns a LOB Locator class\r
+               ///\r
+               //DB2ClientLOBLocator GetLobLocator(int col)\r
+               //{\r
+\r
+               #endregion\r
+\r
+       \r
                #region GetValue\r
                ///\r
                /// GetVCalue, returns an object\r
index 29737a1df4eee0940bc415110e5f0b6fab8e6201..7de9ba6a73334809c910f82edb836a8aeb4b4aea 100644 (file)
@@ -63,6 +63,17 @@ namespace DB2ClientCS
                        internal static extern short SQLBindParameter(IntPtr stmtHandle, ushort paramNumber, \r
                        short dataType, short valueType, short paramType, uint colSize, short decDigits,\r
                        ref int dataBufferPtr, int dataBufferLength, int StrLen_or_IndPtr);\r
-\r
+               [DllImport("db2cli.dll", EntryPoint = "SQLGetLength")]\r
+                       internal static extern short SQLGetLength( IntPtr stmtHandle, short locatorCType, int Locator,\r
+                       IntPtr stringLength, IntPtr indicatorValue);\r
+               [DllImport("db2cli.dll", EntryPoint = "SQLGetPosition")]\r
+                       internal static extern short SQLGetPosition(IntPtr stmtHandle, short locatorCType, int sourceLocator, int searchLocator, \r
+                       string searchLiteral, int searchLiteralLength, uint fromPosition, IntPtr locatedAt, IntPtr indicatorValue);\r
+               [DllImport("db2cli.dll", EntryPoint = "SQLGetPosition")]\r
+                   internal static extern short SQLBindFileToCol (IntPtr stmtHandle, ushort colNum, string fileName, IntPtr fileNameLength, \r
+                       IntPtr fileOptions, short maxFileNameLength, IntPtr stringLength, IntPtr indicatorValue);\r
+               [DllImport("db2cli.dll", EntryPoint = "SQLGetPosition")]\r
+                   internal static extern short SQLBindFileToParam (IntPtr stmtHandle, ushort targetType, short dataType, string fileName,\r
+                       IntPtr fileNameLength, short maxFileNameLength, IntPtr indicatorValue);\r
        }\r
 }\r