Commit Graph
108 Commits
Author SHA1 Message Date
Gonzalo Paniagua Javier 55bbc22620 Use IndexOf (char)
svn path=/trunk/mcs/; revision=122121
2008-12-25 07:46:26 +00:00
Gonzalo Paniagua Javier 1bced9acdb 2008-12-20 Gonzalo Paniagua Javier <[email protected]>
* SqlConnection.cs: close the connection on error.


svn path=/trunk/mcs/; revision=121920
2008-12-20 08:53:16 +00:00
Gert Driesen cd1071406b * SqlConnection.cs (ClearPool): Added null check.
* SqlConnectionTest.cs: Added test for null check in ClearPool.

svn path=/trunk/mcs/; revision=118309
2008-11-09 14:01:56 +00:00
Gert Driesen 82dd9fc53c * TdsConnectionPool.cs: Added TdsConnectionPoolManager.GetConnection
overload that can be used to retrieve an existing connection pool.
Modified ResetConnectionPool () to skip free slots in the pool and to
close pooled connections that are not in use. Pooled connections that
are in use are now marked as non-pooled so that they are no longer
returned to the pool when they are closed. Fixes bug #443131.
* SqlConnection.cs: In Close, also remove reference to pool. In Open,
set TdsConnection.Pooling to false for a non-pooled connection.
Fixed ClearAllPools to no longer create a new connection for each
pool. In ClearPool, perform a lookup of the pool to clear using
the connectionstring as the pool field may refer to another pool
(as the connectionstring may have changed).
* SqlConnectionTest.cs: Added tests for ClearPool and ClearAllPools.

svn path=/trunk/mcs/; revision=118308
2008-11-09 13:36:37 +00:00
Marek Safar 02e9af391d Warnings cleanup
svn path=/trunk/mcs/; revision=111855
2008-08-28 19:08:55 +00:00
Gert Driesen 9fb7f7aad0 * SqlConnection.cs: Use constants for min/max values. When value is
zero-length string, then fallback to default value for boolean and
integer backed properties. Throw ArgumentException when min pool size
exceeds max pool size. Check whether value for 'MARS' is a bool.
The 'user instance' property is 2.0 only.
* SqlConnectionTest.cs: Enabled connection string related tests that
previously failed. Added/improved connection string tests.

svn path=/trunk/mcs/; revision=110471
2008-08-14 11:12:49 +00:00
Gert Driesen 1f9160fe78 * SqlConnection.cs: Convert keywords to lowercase instead of uppercase
to avoid further case changes in exception messages.

svn path=/trunk/mcs/; revision=110468
2008-08-14 11:02:54 +00:00
Gert Driesen e5b3cc5096 * SqlCommand.cs: Fixed order of arguments for ArgumentException in
CommandTimeout. 
* SqlConnection.cs (ChangePassword): Do not allow empty connection
string. Updated exception messages.
* SqlConnectionTest.cs: Enabled tests for ChangePassword argument
checks.

svn path=/trunk/mcs/; revision=109060
2008-07-28 18:37:07 +00:00
Gert Driesen 4c4ae3f815 * SqlConnection.cs: Use null as default value for connectionString
field. Remove Init method, as initialization is done in
SetDefaultConnectionParameters. Initialize parms in
SetDefaultConnectionParameters to avoid calling Reset on newly
initialized collection. In Dispose (bool), also invoke base.Dispose if 
SqlConnection was already disposed. Fixes bug #412571.
* SqlConnectionTest.cs: Enabled and improved test for bug #412571.

svn path=/trunk/mcs/; revision=109013
2008-07-28 14:46:55 +00:00
Gert Driesen 8485db3629 * SqlConnection.cs(ChangeState): Return immediately when new state
equals original state. Fixes bug #412574. Removed extra whitespace.
* SqlConnectionTest.cs: Enabled test for bug #412574.

svn path=/trunk/mcs/; revision=109009
2008-07-28 13:53:56 +00:00
Rodrigo Kumpera d786469a74 In .:
2008-07-03  Rodrigo Kumpera  <[email protected]>

	* SqlConnection.cs: Remove connStringParameters as nobody uses it.
	

svn path=/trunk/mcs/; revision=107193
2008-07-03 21:23:20 +00:00
Veerapuram Varadhan 9191732ff0 Do not call tds.Reset () as it is already done in the connection pool.
svn path=/trunk/mcs/; revision=105719
2008-06-12 19:01:03 +00:00
Veerapuram Varadhan 33b4b7433b Update according to the new return type of
TdsConnectionPool.GetConnectionPool()

svn path=/trunk/mcs/; revision=105432
2008-06-10 14:00:02 +00:00
Marek Habersack d1ee1bfd9c 2008-06-09 Ankit Jain <[email protected]>
* Mono.Data.SybaseClient/SybaseCommand.cs: Use Tds instead of ITds now.
        * Mono.Data.SybaseClient/SybaseConnection.cs: Likewise.

2008-06-09  Ankit Jain  <[email protected]>

        * ITds.cs: Removed.
        * Mono.Data.Tds.dll.sources: Update.

2008-06-09  Ankit Jain  <[email protected]>

        * TdsCommand.cs, TdsConnection.cs: Use Tds instead of ITds now.

2008-06-09  Ankit Jain  <[email protected]>

        * SqlCommand.cs: Use Tds instead of ITds now.
        * SqlConnection.cs:  Likewise.


svn path=/trunk/mcs/; revision=105402
2008-06-10 10:22:11 +00:00
Gert Driesen a323b7331e * SqlConnection.cs: Added support for '.' as alias for localhost.
Improve exception message when TCP/IP protocol is not enabled.

svn path=/trunk/mcs/; revision=104196
2008-05-27 20:13:00 +00:00
Marek Habersack 6e3497df0d 2008-05-14 Marek Habersack <[email protected]>
* SqlConnection.cs: added support for USER INSTANCE keyword in the
	connection string.

svn path=/trunk/mcs/; revision=103209
2008-05-14 18:04:46 +00:00
Gert Driesen 3aeddf81e9 * SqlBulkCopyColumnMappingCollection.cs: Changed argument names to
match MS. Code formatting.
* SqlCommand.cs: Changed argument names to match MS. Code formatting.
Do not include explicit IDbCommand implementation on 2.0 profile.
* SqlCommandBuilder.cs: Changed argument names to match MS. Code
formatting.
* SqlDataReader.cs: Changed argument names to match MS. Code
formatting.
* SqlParameterCollection.cs: Do not include IList, ICollection and
IDataParameterCollection explicit interface implementation on 2.0
profile. Code formatting.
* SqlConnection.cs: Changed argument names to match MS.
* SqlDataAdapter.cs: Changed argument names to match MS.
* SqlTransaction.cs: Do not include explicit interface implementation
of IDbTransaction.Connection on 2.0 profile. Code formatting.

svn path=/trunk/mcs/; revision=101355
2008-04-21 18:59:17 +00:00
Marek Habersack e3eefaf541 2008-04-08 Marek Habersack <[email protected]>
* SqlConnection.cs: TCP port discovery via UDP port 1434 should
	honor the timeout specified in the connection string (or the
	default one). In some environments 100 microseconds might not be
	enough to discover the port.

svn path=/trunk/mcs/; revision=100077
2008-04-08 00:51:19 +00:00
Gert Driesen 3930b4b9cf * System.Data_test.dll.sources: Added DbDataAdapterTest.cs,
OdbcCommandTest.cs, OdbcConnectionTest.cs, OdbcDataAdapterTest.cs, 
OleDbCommandTest.cs, OleDbConnectionTest.cs, OleDbDataAdapterTest.cs, 
SqlDataAdapterTest.cs.
* DbDataAdapter.cs: Implemented UpdateBatchSize setter.
* DataAdapter.cs: In FillLoadOption setter, ensure value is valid.
Modified MissingMappingAction and MissingSchemaAction setters to use
ExceptionHelper.CheckEnumValue to validate value. Spaces to tabs and
code formatting.
* ExceptionHelper.cs: Added CheckEnumValue method and modified
InvalidEnumValueException method to return AORE on 2.0 profile. Added
ConnectionClosed method that returns an InvalidOperationException.
* OleDbDataAdapter.cs: In default ctor, set SelectCommand to null.
Only initialize SelectCommand in ctors. Use direct assignment in
IDbDataAdapter implementation.
* OleDbCommand.cs: Added constant for default CommandTimeout, instead
of using a magic number. Avoid unnecessary initialization. Fixed
default value for DesignTimeVisible. Return zero-length string if
CommandText is null. Added implementation for UpdatedRowSource.
* OleDbConnection.cs: Moved initialization of gda to Open ().
Avoid unnecessary initialization. Return zero-length string if
ConnectionString is null. If getters to Database, DataSource and
Provider return zero-length string if the connection is closed.
In ServerVersion, BeginTransaction and GetSchema, throw an
InvalidOperationException if connection is closed.
* OdbcCommand.cs: Added constant for default CommandTimeout, instead
of using a magic number. Avoid unnecessary initialization. Fixed
default value for DesignTimeVisible. Return zero-length string if
CommandText is null. Spaces to tabs and code formatting.
* OdbcError.cs: Fixed typo in exception message.
* OdbcConnection.cs: Return zero-length string if ConnectionString is
null. In getters for Database, DataSource and Driver return a
zero-length string if connection is closed. In BeginTransaction and
GetSchema throw InvalidOperationException if connection is closed.
Added override for GetSchema (string, string []). Use string.Empty
instead of "".
* OdbcDataAdapter.cs: Avoid unnecessary initializations. Use direct
assignment in IDbDataAdapter implementation. In default ctor, set
SelectCommand to null.
* SqlCommand.cs: Added constant for default CommandTimeout, instead
of using a magic number. Avoid unnecessary initialization. Fixed
default value for DesignTimeVisible. Return zero-length string if
CommandText is null. Use ExceptionHelper.InvalidEnumValueException
to avoid code duplication. Spaces to tabs and code formatting.
* SqlConnection.cs: Use different default package size on 2.0 profile.
Added constants for default values, instead of using magic numbers.
Avoid unnecessary initialization. In PacketSize, return default or
configured packet size when connection is not open. Use 
ExceptionHelper.ConnectionClosed instead of local method. Removed   
use of some hardcoded values in SetDefaultConnectionParameters, and
use Environment.MachineName as default WorkstationId instead of 
DNS host name. Code formatting.
* SqlDataAdapter.cs: In default ctor, set SelectCommand to null.
Avoid unnecessary initializations. Use direct assignment in   
IDbDataAdapter implementation. Fixed exception message for negative
UpdateBatchSize. In Dispose override, make sure to invoke base
method.
* DbDataAdapterTest.cs: Added test for UpdateBatchSize.
* DataAdapterTest.cs: Added tests for AcceptChangesDuringFile,   
AcceptChangesDuringUpdate, ContinueUpdateOnError, FillLoadOption,
MissingMappingAction, MissingSchemaAction and                      
ReturnProviderSpecificTypes.
* OdbcDataAdapterTest.cs: Added tests for ctors, DeleteCommand,
InsertCommand, SelectCommand, UpdateCommand and Dispose.
* OdbcDataReaderTest.cs: fixed line endings.
* OdbcCommandTest.cs: Added tests for ctors and CommantText.
* OdbcConnectionTest.cs: Removed original test that relied on MySQL.
Added ctor tests. Added tests for BeginTransaction, GetSchema and 
ServerVersion with connection that is closed.
* OleDbDataAdapterTest.cs: Added tests for ctors, DeleteCommand, 
InsertCommand, SelectCommand, UpdateCommand and Dispose.
* OleDbCommandTest.cs: Added tests for ctors and CommandText.
* OleDbConnectionTest.cs: Added tests for ctors and ConnectionString. 
Added tests for BeginTransaction, GetSchema and ServerVersion with connection that is closed.
* SqlCommandTest.cs: Added tests for ctors and CommantText. 
* SqlConnectionTest.cs: Added tests for ctors, ConnectionString and 
ServerVersion.
* SqlDataAdapterTest.cs: Added tests for ctors, DeleteCommand,
InsertCommand, SelectCommand, UpdateCommand, UpdateBatchSize and 
Dispose.

svn path=/trunk/mcs/; revision=87859
2007-10-20 23:16:52 +00:00
Gert Driesen 7fdd4ffb8d * SqlConnection.cs: Avoid unnecessary initialization. Use string.Empty
for assigning zero-length string, and use String.Length to check for
zero-length string. Added support for IsolationLevel.Snapshot.
Added StructuredTypeMembers schema collection and restrictions. Fixed
table name for MetaDataCollections collection. Implemented
DataSourceInformation collection. Added missing data types (probably
introduced in 2.0 SP1). In GetSchema, throw InvalidOperationException
if connection is closed and throw NotImplementedException for
StructuredTypeMembers collection.

svn path=/trunk/mcs/; revision=87751
2007-10-18 14:21:44 +00:00
Gert Driesen e72a3d8b55 * SqlConnection.cs: On 1.0 profile, IsolationLevel.Unspecified is
not valid. On 2.0 profile, when IsolationLevel.Unspecified is passed
make sure to also set SqlTransaction.IsolationLevel to
ReadCommitted. Modified exceptions to match MS.

svn path=/trunk/mcs/; revision=87735
2007-10-18 08:36:46 +00:00
Nagappan Alagappan 741bd7514a * SqlConnection.cs: BeginTransaction does not handle
IsolationLevel.Unspecified, so the default is set as ReadCommited.
  Thanks to Jerome Haltom <[email protected]> for this patch.
  Fixes bug # 333082.
* SqlTransaction.cs: If transaction count is greater then 0 then roll
  back. Thanks to Jerome Haltom <[email protected]> for this
  patch. Fixes bug # 331953.

svn path=/trunk/mcs/; revision=87659
2007-10-17 12:32:16 +00:00
Nagappan Alagappan 38ed697ceb * SqlConnection.cs: Added MonoTODO appropriately.
svn path=/trunk/mcs/; revision=86519
2007-09-27 17:30:19 +00:00
Nagappan Alagappan 66cf8bc111 2007-09-25 Nagappan A <[email protected]>
* SqlInitialCatalogConverter.cs, SqlDataSourceConverter.cs:
	NetworkLibraryConverter.cs: Added new files.

	* SqlParameter.cs: 2.0 attribute changes.

	* SqlDataAdapter.cs: 2.0 attribute changes.

	* SqlConnectionStringBuilder.cs: 2.0 attribute changes.

	* SqlConnection.cs (ClearAllPools, ClearPool): Implemented 2.0
	APIs, other 2.0 attribute changes.

	* SqlCommandBuilder.cs (GetSchemaTable, InitializeCommand):
	Implemented 2.0 APIs, other 2.0 attribute changes.

	* SqlBulkCopyColumnMappingCollection.cs: Added constructor, 2.0
	API compatibility changes.

	* SqlException.cs: 2.0 attribute changes.


svn path=/trunk/mcs/; revision=86297
2007-09-25 06:37:24 +00:00
Nagappan Alagappan 6f36ba36cd 2007-08-13 Nagappan A <[email protected]>
* SqlConnection.cs (ConnectionString): 2.0 compatibility changes.

	* SqlDataReader.cs (IsCommandBehavior): Fixed spelling mistake of
	the method name.
	(Dispose): 2.0 compatibility changes.

	* SqlBulkCopy.cs (SqlRowsCopied): Fixed spelling mistake of the
	event name.
	(RowsCopied): Generates event when NotifyAfter is set.

	* SqlCommandBuilder.cs (Dispose, RefreshSchema): 2.0 compatibility
	changes.

	* SqlClientFactory.cs (CreateDataSourceEnumerator): Removed bogus
	TODO.

	* SqlException.cs (Message): 2.0 compatibility changes.


svn path=/trunk/mcs/; revision=83931
2007-08-13 08:33:29 +00:00
Nagappan Alagappan 8195433dd7 2007-08-06 Nagappan A <[email protected]>
* SqlCommand.cs, SqlDataReader.cs, SqlConnection.cs: When the
	server resets the connection, now the client code also disconnects
	the session and remove the instance from pool. Fixes bug # 81933.


svn path=/trunk/mcs/; revision=83522
2007-08-06 07:17:20 +00:00
Nagappan Alagappan 958cc8d1e3 2007-07-22 Nagappan A <[email protected]>
* SqlBulkCopy.cs (NotifyAfter): Implemented 2.0 property.
	(GetColumnMetaData, GenerateColumnMetaData):
	(ValidateColumnMapping): Implemented private method's to generate
	and validate SqlBulkCopy headers.
	(BulkCopyToServer): Private method to actually do the bulk copy
	processing.
	(WriteToServer): Implemented 2.0 missing overloaded methods.
	(IDisposable.Dispose): Implemented 2.0 missing method.

	* SqlBulkCopyColumnMappingCollection.cs (Add, CopyTo): Implemented
	missing API.
	(Item): Implemented missing property.

	* SqlBulkCopyColumnMapping.cs: Modified the implementation of
	Constructors to use property.

	* SqlDataReader.cs (GetSqlXml, IsCommandBehaviour): Added 2.0
	missing method.
	(Connection): Added missing property.

	* SqlParameter.cs (SetSqlDbType, ConvertToFrameworkType): Modified
	method as internal from private.

	* SqlConnection.cs: Fixed 2.0 missing feature.

	* SqlException.cs: Fixed 2.0 missing feature.

	* SqlClientPermission.cs: Fixed 2.0 missing feature.


svn path=/trunk/mcs/; revision=82428
2007-07-22 07:09:26 +00:00
Gert Driesen 61bba85f06 * ISqlNotificationReceiver.cs: Removed.
* SqlClientFactory.cs: Use SqlDataSourceEnumerator from S.D.Sql and
marked method todo. Avoid unnessary casts. Code formatting.
* SqlCommand.cs: Explicit interface implementation of IDbCommand not
necessary on 2.0 profile. Fixes API mismatches. Avoid unnecessary
casts. Code formatting.
* SqlConnection.cs: Also use RecommendAsConfigurable instead of
SettingBindableAttribute on 2.0. Use StateChange event from base class
on 2.0. Only explicitly implement IDbConnection methods on 1.0, since
these are implemented by base class on 2.0 profile. Removed extra
explicit implementation of IDisposable since the base class implements
this. Code formatting.
* SqlDataAdapter.cs: Dispose (bool) override not necessary on 2.0
profile. Stubbed ICloneable.Clone. Fixes API mismatches.
* SqlDataReader.cs: On 2.0, IDisposable.Dispose is implemented by
DbDataReader. Only 1.0 profile, explicitly implemented IEnumerable
GetEnumerator. Code formatting.
* SqlDataSourceEnumerator.cs: Removed.
* SQLDebugging.cs: Marked sealed on 2.0. Code formatting.
* SqlNotificationAuthType.cs: Removed.
* SqlNotificationInfo.cs: Added missing fields. Code formatting.
* SqlNotificationSource.cs: Added missing fields. Code formatting.
* SqlNotificationTransports.cs: Removed.
* SqlNotificationType.cs: Added missing Unknown field. Code formatting.
* SqlParameter.cs: Removed Browsable and EditorBrowsable attributes
from Precision and Scale. Fixes API mismatches. Code formatting fixes.
* SqlTransaction.cs: On 2.0 profile, Dispose method is exposed by
base class. Fixes API mismatches. Code formatting fixes.
* System.Data.dll.sources: Removed ISqlNotificationReceiver.cs,
SqlDataSourceEnumerator.cs, SqlNotificationAuthType.cs,
SqlNotificationTransports.cs.

svn path=/trunk/mcs/; revision=81134
2007-07-01 08:46:06 +00:00
Nagappan Alagappan e5121ef8b4 2007-06-21 Nagappan A <[email protected]>
* SqlConnection.cs: Fixed compiler warning.


svn path=/trunk/mcs/; revision=80468
2007-06-21 13:11:58 +00:00
Nagappan Alagappan e5dd400d6a 2007-06-11 Nagappan A <[email protected]>
* SqlConnection.cs (ParseDataSource): Adds tcp support in
	connection string. Fixes bug # 80975.


svn path=/trunk/mcs/; revision=79151
2007-06-11 07:01:29 +00:00
Nagappan Alagappan d6af08e613 2007-06-11 Nagappan A <[email protected]>
* SqlCommand.cs (Dispose): On disposing the command object, don't
	dispose connection and transaction.


svn path=/trunk/mcs/; revision=79148
2007-06-11 06:01:44 +00:00
Nagappan Alagappan 240d238b80 2007-06-06 Nagappan A <[email protected]>
* SqlCommand.cs, SqlConnectionStringBuilder.cs, SqlConnection.cs:
	Fixed 1.0 and 2.0 extras, errors as stated in class status page.

	* SqlDataAdapter.cs, SqlParameter.cs:Fixed 1.0 and 2.0 extras,
	errors as stated in class status page.

	* SqlBulkCopyColumnMappingCollection.cs: Fixed 1.0 and 2.0 extras,
	errors as stated in class status page.


svn path=/trunk/mcs/; revision=78717
2007-06-06 10:39:33 +00:00
Nagappan Alagappan 0fd75cc776 2007-05-30 Nagappan A <[email protected]>
* SqlParameter.cs (SqlParameter): Updated constructor to use the
	new TDS RPC implementation.
	Fixed missing attributes.
	(SetDbType): Added new case for sql_variant type.
	(ConvertToFrameworkType): Implemented new private method to
	convert the data type to framework type.

	* SqlParameterCollection.cs: Fixed missing attributes and
	implemented missing methods.

	* SqlConnection.cs: Fixed missing attributes.

	* SqlConnectionStringBuilder.cs: Certain attributes are missing or
	its value or they are not appropriate. Fixed them.

	* SqlDataReader.cs (GetData): Method is available only under 1.0
	profile.
	
	* SqlCommandBuilder.cs: Certain attributes are available only
	under 2.0 profile, so moved them inside ifdef.

	* SqlCommand.cs: Certain attributes are available only under 2.0
	profile, so moved them inside ifdef.


svn path=/trunk/mcs/; revision=78186
2007-05-30 10:52:37 +00:00
Nagappan Alagappan 3bd42f9b0c 2007-04-03 Amit Biswas <[email protected]>
* SqlDataReader.cs (GetSqlBytes, GetProviderSpecificFieldType)
	(GetProviderSpecificValue, GetProviderSpecificValues): Implemented
	missing API.

	* SqlParameter.cs (XmlSchemaCollectionDatabase): Implemented missing property
	(XmlSchemaCollectionName): Implemented missing property
	(XmlSchemaCollectionOwningSchema): Implemented missing property
	(SourceColumnNullMapping): Existing implementation was not correct, Replaced the implementation
	(.ctor): Implemented mising constructor new in .net 2.0

	* SqlErrorCollection.cs (CopyTo): Implemented missing API

	* SqlParameter.cs (InferSqlType): Corrected bug related to default values of
	SqlDbType and DbType
	(ResetSqlDbType): Implemented missing API
	(ResetDbType): Implemented missing API	

2007-03-09  Amit Biswas  <[email protected]>

	* SqlParameterCollection.cs (CopyTo): Implemented missing API


svn path=/trunk/mcs/; revision=76655
2007-05-04 04:07:41 +00:00
Nagappan Alagappan c317c256c1 2007-03-20 Nidhi Rawal <[email protected]>
* SqlClientFactory.cs: Added two using directives.
	(CreateConnectionStringBuilder): Implemented the method.
	(CreatePermission): Implemented the property.
	
	* SqlCommand.cs: Added one using directive.
	(Clone): Implemented the method.
	(Dispose): Implemented the method.
	(BeginExecuteXmlReader): Implemented the method.
	
	* SqlCommandBuilder.cs (QuoteIdentifier): Implemented the method.
	(UnquoteIdentifier): Implemented the method.
	
	* SqlConnection.cs (ChangePassword): Implemented the method.

2007-03-19  Nidhi Rawal  <[email protected]>

	* SqlClientFactory.cs (CanCreateDataSourceEnumerator): Implemented
	the property.

	* SqlCommand.cs (Notification): Implemented the property.
	(NotificationAutoEnlist): Implemented the property.

	* SqlDataReader.cs (VisibleFieldCount): Implemented the property.

	* SqlConnectionStringBuilder.cs (TrustServerCertificate): Implemented
	the property.
	(TypeSystemVersion): Implemented the property.
	(UserInstance): Implemented the property.
	(ContextConnection): Implemented the property.

	* SqlConnection.cs (FireInfoMessageEventOnUserErrors): Implemented
	the property.
	(StatisticsEnabled): Implemented the property.
	
	* SqlDataAdapter.cs (UpdateBatchSize): Implemented the property.

	* SqlParameter.cs: Implemented one attribute.


svn path=/trunk/mcs/; revision=75189
2007-03-30 12:43:28 +00:00
Nagappan Alagappan 80f1f8ad35 2007-02-16 Nidhi Rawal <[email protected]>
* SqlParameter.cs (CompareInfo): Implemented the property
	CompareInfo.

2007-02-15  Nidhi Rawal  <[email protected]>

	* SqlCommand.cs: Added some attributes which were not implemented
	for .NET 2.0 and removed extra attribute which are not there in
	.NET 2.0.

	* SqlCommandBuilder.cs: Added some attributes that were not 
	implemented for .NET 2.0.

	* SqlParameterCollection.cs: Added some attributes that were 
	not implemented for .NET 2.0.

	* SqlConnectionStringBuilder.cs: Added some attributes that
	 were not implemented for .NET 2.0.
	
	* SqlConnection.cs: Added attribute that was not implemented
	for .NET 2.0.

	* SqlParameter.cs: Added some attributes which were not
	implemented for .NET 2.0 and removed some extra attributes which
	are not there in .NET 2.0


svn path=/trunk/mcs/; revision=73144
2007-02-20 06:16:02 +00:00
Nagappan Alagappan 16ade3ad4f 2007-02-09 Nagappan A <[email protected]>
* SqlConnection.cs (SetConnectionString): Fixes bug # 80712. A
	small typo.


svn path=/trunk/mcs/; revision=72537
2007-02-09 13:49:49 +00:00
Nagappan Alagappan f0d2e2860d 2007-01-08 Nagappan A <[email protected]>
* SqlTransaction.cs (Dispose): Fixed compliation warning.

	* SqlDataReader.cs (GetValues): Length of elements to be copied was
	decided based on the argument array passed, which caused a bug, if
	the length of given array is more than actual column values.

	* SqlCommandBuilder.cs (CatalogSeparator, SchemaSeparator)
	(CatalogLocation): Implemented missing properties.
	(CreateDeleteCommand, CreateInsertCommand, CreateUpdateCommand):
	Modified private methods to take bool flag. If true, add actual
	parameter name instead of p1, p2 etc.
	(CreateParameter): Added overloaded private method to create
	parameter with the actual column name.
	(GetUpdateCommand, GetDeleteCommand, GetInsertCommand):
	Implemented missing overloaded methods.
	(SetRowUpdatingHandler): Implemented missing protected method.

	* SqlCommand.cs: Fixed compilation warning. Removed bogus
	MonoTODO's.


svn path=/trunk/mcs/; revision=70619
2007-01-08 05:54:50 +00:00
Nagappan Alagappan 8d54a64faf * SqlConnection.cs: Implemented SqlConnection.GetSchema ().
svn path=/trunk/mcs/; revision=64544
2006-08-30 11:30:57 +00:00
Senganal T dbcfcb27fe 2006-07-13 Senganal T <[email protected]>
* Test/System.Data.Common/DBDataPermissionTest.cs : Removed invalid tests

	* System.Data.Common/SchemaInfo.cs DbDataAdapter.cs DbConnectionOptions.cs DbParameter.cs 
	DbMetaDataColumnNames.cs DbTransaction.cs DataTableMapping.cs DataAdapter.cs 
	FieldNameLookup.cs DbDataRecord.cs DataColumnMappingCollection.cs DbCommand.cs 
	DbDataPermission.cs DbProviderFactory.cs DbCommandBuilder.cs DbConnectionString.cs 
	RowUpdatedEventArgs.cs DbDataReader.cs DbConnectionStringBuilder.cs DbConnection.cs 
	DataTableMappingCollection.cs :
		2.0 Api fixes

	* System.Data.SqlClient/SqlClientFactory.cs SqlCommand.cs SqlConnectionFactory.cs 
	SqlClientPermission.cs SqlParameterCollection.cs SqlDataReader.cs 
	SqlConnection.cs SqlParameter.cs SqlTransaction.cs :
		2.0 Api fixes

	* System.Data.Odbc/OdbcTransaction.cs OdbcCommand.cs OdbcConnectionFactory.cs 
	OdbcPermission.cs OdbcDataReader.cs OdbcParameterCollection.cs 
	OdbcConnection.cs OdbcFactory.cs OdbcParameter.cs :
		2.0 Api fixes

	* System.Data.OleDb/OleDbCommand : 2.0 Api fixes

	* System.Data.dll.sources: 
		- Added to build :
			System.Data.Common/DbMetaDataColumnNames.cs
		- Removed from build :
			System.Data.Common/DbCommandOptionalFeatures.cs
			System.Data.Common/DbCommandSet.cs
			System.Data.Common/DbProviderSupportedClasses.cs
			System.Data.Common/SchemaLocation.cs
			System.Data.Odbc/OdbcConnectionFactory.cs
			System.Data.SqlClient/SqlConnectionFactory.cs
			System.Data.ProviderBase/DbCommandBase.cs
			System.Data.ProviderBase/DbConnectionBase.cs
			System.Data.ProviderBase/DbConnectionFactory.cs
			System.Data.ProviderBase/DbConnectionInternal.cs
			System.Data.ProviderBase/DbConnectionPoolCounters.cs
			System.Data.ProviderBase/DbConnectionPoolOptions.cs
			System.Data.ProviderBase/DbDataReaderBase.cs
			System.Data.ProviderBase/DbMetaDataFactory.cs
			System.Data.ProviderBase/DbParameterBase.cs
			System.Data.ProviderBase/DbParameterCollectionBase.cs
			System.Data.ProviderBase/DbReferenceCollection.cs

	* Makefile : Add System.Transactions library reference to net_2_0 PROFILE


svn path=/trunk/mcs/; revision=62561
2006-07-13 14:19:17 +00:00
Gert Driesen 0a3f08261d * SqlConnection.cs: Removed extra destructor, as destructor on
System.ComponentModel.Component already calls Dispose.
* SqlParameter.cs: Removed explicit interface implementation of
IDataParameter.ParameterName.
* OdbcErrorCollection.cs: Removed explicit interface implementation
of IEnumerable.GetEnumerator ().
* OdbcCommand.cs: Removed destructor as the destructor in
System.ComponentModel.Component already calls the Dispose method.
Removed explicit interface implemenation of members that are
implement by public members.
* OdbcDataReader.cs: Removed explicit interface implemenation of
IDataRecord.GetData.
* OleDbErrorCollection.cs: Removed explicit interface implementation
of IEnumerable.GetEnumerator ().
* OleDbParameterCollection.cs: Removed explicit interface
implementation members that are already implementation by public
members.
* DataTable.cs: Renamed initInProgress to fInitInProgress. BeginInit
and EndInit must only be virtual in 2.0 profile. Set eol-style to CRLF.

svn path=/trunk/mcs/; revision=61328
2006-05-31 13:55:23 +00:00
Senganal T 5cd065b00a 2006-04-18 Senganal T <[email protected]>
* Test/ProviderTests/System.Data.SqlClient/SqlConnectionTest.cs :
		- OpenTest_1 : test InvalidOperationException is raised if
		ConnectionString is empty
		- DisposeTest : test nullreference exception is not raised
	* System.Data.SqlClient/SqlConnection.cs :
		- SetConnectionString : set the pareameter to default values
		if connection string is empty or null
		- Open : Raise InvalidOperationException if Connection String
		is empty or null
		- Dispose : Test exception not raised if dispose called on a
		connection with empty connection string

	slight modification of the patch by Jonel Rienton


svn path=/trunk/mcs/; revision=59582
2006-04-18 09:58:08 +00:00
Chris Toshok c21950a927 In System.Data.OleDb:
* OleDbDataAdapter.cs, OleDbCommand.cs, OleDbParameter.cs,
	OleDbCommandBuilder.cs, OleDbConnection.cs: remove
	DataSysDescriptions for >= 2.0.

2006-02-17  Chris Toshok  <[email protected]>

In System.Data.SqlClient:
	* SqlCommand.cs, SqlCommandBuilder.cs, SqlConnection.cs,
	SqlDataAdapter.cs: remove DataSysDescription attributes for >= 2.0

2006-02-17  Chris Toshok  <[email protected]>

In System.Data:
	* System.Data/DataSet.cs, System.Data/DataView.cs,
	System.Data/ForeignKeyConstraint.cs,
	System.Data/DataViewManager.cs, System.Data/DataRow.cs,
	System.Data/DataSysDescriptionAttribute.cs,
	System.Data/UniqueConstraint.cs, System.Data/DataTable.cs,
	System.Data/DataRelation.cs: lots of attribute work, removing
	DataSysDescription atributes (and marking the class obsolete) for
	2.0.

2006-02-17  Chris Toshok  <[email protected]>


svn path=/trunk/mcs/; revision=57018
2006-02-17 20:34:22 +00:00
Senganal T 1d1645c3cc 2005-11-24 Senganal T <[email protected]>
* Mono.Data.Tds/Mono.Data.Tds.Protocol/Tds.cs 
	* Mono.Data.Tds/Mono.Data.Tds.Protocol/Tds70.cs : 
		- Modifications to set the desired packetsize info when connecting
		to database
	* System.Data/System.Data.SqlClient/SqlConnection.cs 
		- Modifications to get the correct Packet Size


svn path=/trunk/mcs/; revision=53443
2005-11-24 09:20:54 +00:00
Gonzalo Paniagua Javier 60f41af7be 2005-11-12 Gonzalo Paniagua Javier <[email protected]>
* SqlConnection.cs: don't throw NotImplementedException when using
	'PERSIST SECUTIRY INFO'. Just do nothing.


svn path=/trunk/mcs/; revision=52951
2005-11-12 19:00:09 +00:00
Senganal T 07cfd11085 2005-10-19 Senganal T <[email protected]>
* Mono.Data.Tds/Mono.Data.Tds.Protocol/TdsConnectionParameter.cs :
		- Added a class variable 'AttachDBFileName' to store the location
		of the DB file.

	* Mono.Data.Tds/Mono.Data.Tds.Protocol/Tds70.cs (Connect) :
		- Modified to append the bytes corresponding to AttachDBFileName 
		into the Tds Packets. 

	* System.Data/System.Data.SqlClient/SqlConnection.cs (SetProperties) :
		- Added support for AttachDBFileName


svn path=/trunk/mcs/; revision=51909
2005-10-19 13:12:58 +00:00
Senganal T 694cd01513 In Mono.Data.Tds:
* Mono.Data.Tds.Protocol/Tds.cs: 
		- Modified the way Server Version number is calculated
		- Added a new varaible to remember the original database
		connected to and to reset the Database property when the
		connection to database is closed.
	* Mono.Data.Tds.Protocol/Tds70.cs: 
		modified Reset() to Call the Reset() of base class which 
		in turn resets the database name. 

In System.Data/Test/ProviderTests/System.Data.SqlClient:

	* SqlConnectionTest.cs: removed some hardcoded database names
	in DatabasePropertyTest ().

In System.Data/System.Data.SqlClient:
	* SqlConnection.cs : 
		- Set the correct Default Values for Parameters.
		- Added Argument Checks (where missing) for the Properties and 
		throw the correct exception on error.
		- Modified SetDefaultParameters() to make sure that the parameters
		are all reset to default values everytime it is called.
		- Modified SetProperties() to take into account the order of the 
		keywords in the ConnectionString.

svn path=/trunk/mcs/; revision=50377
2005-09-21 14:27:58 +00:00
Sureshkumar T 8164beede8 In System.Data/System.Data.SqlClient:
2005-08-26  Sureshkumar T  <[email protected]>

	* SqlConnection.cs (Open): enable sp_reset_connection.

In Mono.Data.Tds/Mono.Data.Tds.Protocol:
2005-08-26  Sureshkumar T  <[email protected]>

	* Tds70.cs (ExecProc): if no parameters, execute via RPC. parameter
	support has to be added.

	* Tds.cs (ExecRPC): added virtual method to execute via RPC.

	This fixes bug #68978 by enabling execution of sp_reset_connection.


svn path=/trunk/mcs/; revision=48881
2005-08-26 09:31:43 +00:00
Sureshkumar T 88fba070be In System.Data.Common:
2005-07-22  Sureshkumar T  <[email protected]>

	* DataColumnMappingCollection.cs: updated attributes & attribute
	descriptions to match with masterinfos.

In System.Data.SqlClient:
2005-07-22  Sureshkumar T  <[email protected]>

	* SqlCommandBuilder.cs, SqlParameterCollection.cs,
	SqlConnection.cs, SqlParameter.cs:
	- updated attributes & attribute descriptions to match with
	masterinfos.

In System.Data:
	* DataViewSettingCollection.cs, DataTableCollection.cs,
	DataSet.cs, DataView.cs, DataColumn.cs, ForeignKeyConstraint.cs,
	DataRelationCollection.cs, UniqueConstraint.cs, DataTable.cs,
	DataColumnCollection.cs, DataRelation.cs, DataSet.cs:
	- updated attributes & attribute descriptions to match with
	masterinfos.

In System.Data.Odbc:
	* OdbcParameter.cs: updated attributes & attribute descriptions to
	match with masterinfos.


svn path=/trunk/mcs/; revision=47554
2005-07-22 10:57:02 +00:00
Sureshkumar T be58549d6e 2005-06-29 Sureshkumar T <[email protected]>
* Mono.Data.Tds/Mono.Data.Tds.Protocol/TdsInternalException.cs: Add ctor for InnerException.
	* Mono.Data.Tds/Mono.Data.Tds.Protocol/TdsComm.cs: Throw TdsInternalException rather than
	  SocketException.
	* System.Data/System.Data.SqlClient/SqlConnection.cs: Open (): catch TdsInternalException and throw
	  SqlException.
	* System.Data/System.Data.SqlClient/SqlException.cs: code re-organised to pass message as well with
	  the exception.


svn path=/trunk/mcs/; revision=46722
2005-06-29 13:31:18 +00:00