Commit Graph
177 Commits
Author SHA1 Message Date
Veerapuram Varadhan 71eb517c49 [ado.net]bugfix:688773 - Assign default value to columns that does not
exist in the row that is being imported.
2011-05-05 03:29:54 +05:30
Veerapuram Varadhan 2ec0a00139 2010-07-23 Veerapuram Varadhan <[email protected]>
** Fixes #565616 - Based on Patch by Hubert FONGARNAND
	* DataContainer.cs (GetContainerData): If typecode is string,
	call Convert.ToString() irrespective of whether value is
	IConvertible or not.
2010-07-23 18:55:50 +05:30
Veerapuram Varadhan a13bcfb79c changelog changes
svn path=/trunk/mcs/; revision=154271
2010-03-26 13:45:50 +00:00
Veerapuram Varadhan 7c38ba4b7c 2010-03-26 Veerapuram Varadhan <[email protected]>
** Fixes #564833/580736
    * DbDataAdapter.cs (*Command): Fix for .NET compatibility which
    supports both type of adapters with/without discrete command
    instances.

svn path=/trunk/mcs/; revision=154270
2010-03-26 13:45:38 +00:00
Veerapuram Varadhan bba7b6a6f7 2009-10-28 Veerapuram Varadhan <[email protected]>
** Fixes #385028/#385029
	* DbCommandBuilder.cs (CreateInsertCommand): Workaround for inserting
	DEFAULT values to non-null-columns.
	(GetInsertCommand): New overload added to handle above workaround.
	(set_DataAdapter): Register for the RowUpdatingEventHandlers.

svn path=/trunk/mcs/; revision=144915
2009-10-27 20:18:37 +00:00
Jonathan Pryor 0dd3c5f987 * Makefile: Add Mono.Data.Tds, System.Transactions, System.Data, and
Mono.Data.Sqlite to the MonoTouch build.
	* System/System.ComponentModel/TypeConverter_2_1.cs: Skip this type in
		the MonoTouch profile; MonoTouch will be using the 2.0 version of 
		TypeConverter.
	* System/System.ComponentModel/ComponentCollection.cs, 
		System/System.ComponentModel/PropertyDescriptor.cs: MonoTouch uses the
		.NET 2.0 versions of these types.
	* System/monotouch_System.dll.sources: Add lots of additional .NET 2.0
		functionality to the MonoTouch profile.
	* System.Transactions/Makefile (VALID_PROFILE): Add monotouch.
	* System.Data/System.Data.Common/DbConnection.cs: Throw 
		NotImplementedException for DbConnection.DbProviderFactory, as 
		DbProviderFactories isn't included in the MonoTouch profile.
	* System.Data/System.Data.SqlClient/SqlConnection.cs: Remove 
		EnterpriseServices dependency from the MonoTouch profile.
	* System.Data/monotouch_System.Data.dll.sources: Added.
	* System.Data/System.Data/XmlSchemaDataImporter.cs: Remove 
		DbProviderFactories dependency in the MonoTouch profile.

svn path=/trunk/mcs/; revision=144150
2009-10-14 20:55:43 +00:00
Veerapuram Varadhan e08e9acfcc 1.x build fix
svn path=/trunk/mcs/; revision=139098
2009-07-30 16:57:47 +00:00
Veerapuram Varadhan 6a4a2997d8 2009-07-30 Veerapuram Varadhan <[email protected]>
* SqlDataAdapter.cs (IDbDataAdapter.*Command): Remove over-engineered
	checks as the base implementation is changed.

svn path=/trunk/mcs/; revision=139080
2009-07-30 13:41:31 +00:00
Veerapuram Varadhan 741394be33 2009-07-29 Veerapuram Varadhan <[email protected]>
* DbDataAdapter.cs (*Command properties): Don't call IDbDataAdapter.*Command,
	as provider specific DbDataAdapters would have its own implementation.

svn path=/trunk/mcs/; revision=139069
2009-07-30 12:37:30 +00:00
Veerapuram Varadhan 9c7e6d31d1 2009-07-27 Veerapuram Varadhan <[email protected]>
* DbCommandBuilder.cs (CreateUpdateCommand): Don't set Nullable
	property "Original_*" fields.

svn path=/trunk/mcs/; revision=139067
2009-07-30 12:36:57 +00:00
Veerapuram Varadhan 15afef1475 2009-07-24 Veerapuram Varadhan <[email protected]>
* DbCommandBuilder.cs (Create*Command): Fill up the missing pieces from
	SqlCommandBuilder version of Create*Commands that fixes the failing tests.

svn path=/trunk/mcs/; revision=139065
2009-07-30 12:36:23 +00:00
Veerapuram Varadhan 5ec22cbe2f 2009-07-24 Veerapuram Varadhan <[email protected]>
* DbCommandBuilder.cs (CreateDeleteCommand, CreateUpdateCommand): Add the
	nullcheck-param into the respective command's parameter list.  Fixes
	build breaks.  Individual provider's CommandBuilder classes from 2.0
	profile onwards use the base version of methods to maintain these commands.
	(Get*Command): Cleanup code duplication
	* DbDataAdapter (Update): Use SourceColumnNullMapping property to handle
	nullcheckparams.  Fixes #522624.  Patch by
	Gert Driesen  <[email protected]>.

svn path=/trunk/mcs/; revision=138678
2009-07-25 19:10:42 +00:00
Veerapuram Varadhan 46cdbd98ec * Utility changes to convert between DbType/SqlDbType/System.Type
svn path=/trunk/mcs/; revision=138434
2009-07-22 18:24:13 +00:00
Marek Habersack b9e3cd32a4 2009-05-10 Marek Habersack <[email protected]>
* DbConnection.cs: implemented the DbProviderFactory property

svn path=/trunk/mcs/; revision=133849
2009-05-10 18:15:05 +00:00
Veerapuram Varadhan 7ed3e19925 2009-03-31 Veerapuram Varadhan <[email protected]>
* Fixes rest of #480377
	* DataContainer.cs (GetContainerData, GetExplicitValue): Added to handle cases
	where passed type overloads an explicit operator for conversion of values.

svn path=/trunk/mcs/; revision=130709
2009-03-31 21:59:48 +00:00
Veerapuram Varadhan 02f82de85b 2009-03-31 Veerapuram Varadhan <[email protected]>
* Fixes rest of #480377
	* DataContainer.cs (GetContainerData, GetExplicitValue): Added to handle cases
	where passed type overloads an explicit operator for conversion of values.

svn path=/trunk/mcs/; revision=130708
2009-03-31 21:58:38 +00:00
Gert Driesen 13b9781926 * System.Data_test.dll.sources: Added SqlCommandBuilderTest.cs
and SqlParameterTest.cs.
* DbCommandBuilder.cs (QuoteIdentifier): Throw NotSupportedException.
* DbDataAdapter.cs (Update): Add row causing concurrency violation
to DBConcurrencyException.
* OdbcCommandBuilder.cs (QuoteIdentifier): Escape QuoteSuffix
character(s) in unquoted identifier.
* SqlCommandBuilder.cs: Added missing checks for QuotePrefix and
QuoteSuffix on 2.0 profile, and return a zero-length string if
not set (or set to null) on 1.0 profile. Do not allow the value
of CatalogSeparator and SchemaSeparator to be changed from '.'.
Modified generated SQL to match MS. Added implementation for
QuoteIdenfifier. Modified parameters to match MS.
* SqlParameter.cs (SqlValue): Keep Value in sync.
* DbCommandBuilderTest.cs: Added test for QuoteIdentifier.
* OdbcCommandBuilderTest.cs: Enabled test for QuoteIdentifier.
* SqlCommandBuilderTest.cs: Added tests for CatalogLocation,
CatalogSeparator, ConflictOption, QuoteIdentifier, QuotePrefix,
QuoteSuffix  and SchemaSeparator.
* SqlParameterTest.cs: Moved existing tests from ProviderTests
to increase their visibility. Added tests for type inference.

svn path=/trunk/mcs/; revision=122361
2009-01-03 14:24:15 +00:00
Raja R Harinath a1cae67e2c Mildly rewrite duplicate-inferring logic.
* Index.cs (IndexDuplicateState): Remove.
(_hasDuplicates): Remove.  Replace by ...
(know_have_duplicates, know_no_duplicates): ... these.

svn path=/trunk/mcs/; revision=122242
2008-12-30 14:58:57 +00:00
Gert Driesen dd1385a13b * DbCommandBuilder.cs: When CatalogSeparator or SchemaSeparator are
not set (or explicitly set to null or empty string), then return
default separator character. Added value check for CatalogLocation and
ConflictOption. Removed regions.
* DbCommandBuilderTest.cs: Added tests for properties.
* OdbcCommandBuilderTest.cs: Added tests for properties.

svn path=/trunk/mcs/; revision=122230
2008-12-30 10:21:41 +00:00
Gert Driesen fe34437ee6 * DbCommandBuilder.cs: Fixed default value for ConflicOption.
* OdbcCommandBuilder.cs: Added test for ConflictOption default value.

svn path=/trunk/mcs/; revision=122227
2008-12-30 05:11:15 +00:00
Gert Driesen b8ff346173 * DbCommandBuilder.cs: Return a zero-length string when QuotePrefix or
QuoteSuffix are not set (or are set to null). Changing QuotePrefix or
QuoteSuffix after a command has been generated should result in an
InvalidOperationException.
* DbConnectionStringBuilder.cs: Added support for ODBC rules. Major
rewrite fixing many compatibility issues, and improving support for
connectionstring formats/characters.
* System.Data_test.dll.sources: Added OdbcCommandBuilderTest.cs,
OdbcConnectionStringBuilderTest.cs and DbCommandBuilderTest.cs.
* libodbc.cs: Add IdentifierQuoteChar to OdbcInfo.
* OdbcCommandBuilder.cs: Return a zero-length string when QuotePrefix
or QuoteSuffix are not set (or are set to null). Changing QuotePrefix
or QuoteSuffix after a command has been generated should result in an
InvalidOperationException. Implemented support for obtaining
character(s) for quoting identifiers from specified connection.
Modified generated SQL to match MS.
* OdbcConnectionStringBuilder.cs: Improved special casing of Driver
and Dsn keywords. Re-use implemenation of DbConnectionStringBuilder.
Improved argument checks to match MS.
* DbCommandBuilderTest.cs: Added tests for QuotePrefix and
QuoteSuffix.
* DbConnectionStringBuilderTest.cs: Added tests for both odbc and
non-odbc rules.
* OdbcCommandBuilderTest.cs: Added tests for QuotePrefix and
QuoteSuffix. Added tests for QuoteIdentifier (some still marked
NotWorking).
* OdbcConnectionStringBuilderTest.cs: Moved from ProviderTests.
Added and improved tests.

svn path=/trunk/mcs/; revision=122225
2008-12-30 03:41:45 +00:00
Atsushi Eno 622852656f 2008-11-25 Atsushi Enomoto <[email protected]>
* DbDataRecord.cs : it is abstract, so create different impl. class.
	* DbEnumerator.cs : use above.


svn path=/trunk/mcs/; revision=119940
2008-11-25 10:32:45 +00:00
Raja R Harinath 9d0c64bbfd Avoid allocating empty arrays.
* Index.cs (empty): New empty array constant.
(Reset): Initialize '_array' to 'empty'.
(RebuildIndex): Don't allocate array if it will be empty.
(FindAllIndexes): Use 'empty' instead of 'new int [0]'.

svn path=/trunk/mcs/; revision=119008
2008-11-17 12:30:45 +00:00
Raja R Harinath 7b06496296 Simplify using some invariants
* Index.cs: Remove use of Array and Size properties by taking
advantage of the invariant that _array is never null.
(EnsureArray): Remove.
(Array): Remove.

svn path=/trunk/mcs/; revision=119007
2008-11-17 12:30:27 +00:00
Raja R Harinath 9ab60f6e52 * RecordCache.cs: Reduce some extraneous nesting.
svn path=/trunk/mcs/; revision=119006
2008-11-17 12:30:09 +00:00
Daniel Morgan cf3b4b10d7 2008-10-07 Daniel Morgan <[email protected]>
* DbConnectionStringBuilder.cs: fix setting and getting
	the ConnectionString property

svn path=/trunk/mcs/; revision=115173
2008-10-08 06:35:01 +00:00
Veerapuram Varadhan fb07f03a37 **Fixes bug#421336 - sanely handle various scenarios that lead to
exceptions while creating insert/delete and update commands.


svn path=/trunk/mcs/; revision=113180
2008-09-16 16:13:22 +00:00
Raja R Harinath b24f84250b Some more style nits
* DataContainer.cs (*.ZeroOut): Rename from the somewhat unclear
'SetDefaultValue'.
(IsNull): Use a more idiomatic form of the short-circuit.
(*.SetValue): Convert to one-liners.

svn path=/trunk/mcs/; revision=112367
2008-09-05 09:19:39 +00:00
Raja R Harinath 6540940241 Reduce massive code duplication
* System.Data.Common/DataContainer.cs (DataContainer): Rename from
AbstractDataContainer.
Introduce new 'protected abstract' members to encapsulate
type-specific handling, and move all common code here.
(DataContainer.Create): Rename from CreateInstance.
* System.Data/DataColumn.cs: Update to changes in DataCollection.

(Since a majority of the lines are changed, I decided to dos2unix the file
too)

svn path=/trunk/mcs/; revision=110002
2008-08-08 17:47:58 +00:00
Sebastien Pouliot 740631d6f3 2008-07-06 Sebastien Pouliot <[email protected]>
* DbDataReader.cs: Replace a few Type.GetType by typeof
	[Found using Gendarme AvoidTypeGetTypeForConstantStringsRule]


svn path=/trunk/mcs/; revision=107358
2008-07-07 00:19:15 +00:00
Veerapuram Varadhan 5d67ea84a4 check for null before fetching column mapping
svn path=/trunk/mcs/; revision=107144
2008-07-03 13:37:14 +00:00
Rodrigo Kumpera c2b894982a In System.Data:
2008-07-01  Rodrigo Kumpera  <[email protected]>

	* DataTable.cs: Kill some foreach loops.
	
	* DataRow.cs: Same.

In System.Data.Common:
2008-07-01  Rodrigo Kumpera  <[email protected]>

	* RecordCache.cs: Kill some foreach loops.


svn path=/trunk/mcs/; revision=107031
2008-07-02 04:02:55 +00:00
Gert Driesen 5be9b22ef3 * DataColumnMappingCollection.cs: Modified argument names to match
MS. Code formatting.
* DataTableMappingCollection.cs: Modified argument names to match MS.
Code formatting.

svn path=/trunk/mcs/; revision=101350
2008-04-21 17:43:13 +00:00
Gert Driesen 04897e44fc * DbDataAdapter.cs: Corcompare fixes and code formatting.
* DbDataRecord.cs: Corcompare fixes and code formatting.
* DataColumnMappingCollection.cs: Corcompare fixes and code formatting.
* RowUpdatedEventArgs.cs: Corcompare fixes and code formatting.
* DbParameterCollection.cs: Corcompare fixes and code formatting.

svn path=/trunk/mcs/; revision=98815
2008-03-23 09:15:34 +00:00
Atsushi Eno 18737776de 2007-11-15 Atsushi Enomoto <[email protected]>
* DbProviderFactoriesConfigurationHandler.cs : Create() now takes
	  parent DataSet into consideration i.e. it now merges items in
	  different configurations. Fixed bug #323708.


svn path=/trunk/mcs/; revision=89701
2007-11-15 20:13:44 +00:00
Gert Driesen c231373769 * DataColumn.cs: Fixed ParamName of ArgumentNullException. Modified
exception message for invalid DateTimeMode value to match MS. Code
formatting.
* DbDataPermissionAttribute.cs: In KeyRestrictionBehavior, reuse
ExceptionHelper.CheckEnumValue.   
* ExceptionHelper.cs: Use same exception message for both 1.0 and 2.0.
* Index.cs: Fixed compiler warnings. Code formatting.
* SqlCommand.cs: Use ExceptionHelper.CheckEnumValue for enum checks.
* OleDbCommand.cs: Use ExceptionHelper.CheckEnumValue for enum checks.
* DBDataPermissionAttributeTest.cs: Improved test for invalid
KeyRestrictionBehavior. Fixed line endings.
* DataColumnTest.cs: No longer derive from deprecated Assertion class.
Code formatting. Added test for DateTimeMode.

svn path=/trunk/mcs/; revision=87866
2007-10-21 13:26:43 +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 e2681602c2 * DbTransaction.cs: Do not perform a rollback in Dispose (bool).
Leaves it up to deriving classes to override Dispose (bool) and
perform a rollback if necessary. Fixes bug #325397. Code formatting.
* ExceptionHelper.cs: Added TransactionNotUsable method that constructs
an InvalidOperationException to be thrown by IDbTransaction
implementations when the transaction is no longer open.
* OdbcTransaction.cs: Keep state of the transaction, and update it
when performing commit or rollback. In Dispose (bool), only perform
a rollback if transaction was not committed or rollback before.
In Commit and Rollback, throw an InvalidOperationException if
transaction is no longer open.
* SqlTransaction.cs: Avoid unnecessary initialization. Remove
isRolledBack since its essentially the same as isOpen. Use
ExceptionHelper.TransactionNotUsable instead of duplicating code.
On 2.0 profile, ignore call to Rollback when transaction was already
disposed.
* OleDbTransaction.cs: Keep track of whether transaction is open and
whether it's disposed. In Commit an Rollback, throw an IOE if the
transaction is no longer open. In Dispose (bool), perform a rollback
if the transaction is still open.

svn path=/trunk/mcs/; revision=87835
2007-10-19 16:04:39 +00:00
Nagappan Alagappan d6b5b3c2df * DbDataAdapter.cs: Added MonoTODO in appropriate place.
* DbCommandBuilder.cs (initializeCommand): Implemented missing API.

svn path=/trunk/mcs/; revision=86517
2007-09-27 17:28:40 +00:00
Nagappan Alagappan ed44256006 2007-09-25 Nagappan A <[email protected]>
* DbConnection.cs: 2.0 attribute fixes.

	* DataColumnMapping.cs: 2.0 attribute fixes.

	* DbParameterCollection.cs: Code alignment.

	* DataAdapter.cs: 2.0 attribute fixes.

	* DataTableMapping.cs: 2.0 attribute fixes.

	* RowUpdatingEventArgs.cs (BaseCommand): Code alignment.


svn path=/trunk/mcs/; revision=86296
2007-09-25 05:23:45 +00:00
Konstantin Triger 283716cb20 DbEnumerator.cs, DbDataRecord.cs: refactoring; DbDataRecord.cs: GetValue() should return null instead of DBNull
svn path=/trunk/mcs/; revision=86257
2007-09-24 14:44:35 +00:00
Nagappan Alagappan ca43995a30 2007-08-10 Nagappan A <[email protected]>
* DbDataAdapter.cs (Fill): Fixed method signature.


svn path=/trunk/mcs/; revision=83797
2007-08-10 05:17:19 +00:00
Nagappan Alagappan 724a84ebf5 2007-07-26 Nagappan A <[email protected]>
* DbConnection.cs: Removed bogus TODO.


svn path=/trunk/mcs/; revision=82768
2007-07-26 13:06:23 +00:00
Nagappan Alagappan 5c266b32df 2007-07-22 Nagappan A <[email protected]>
* DbConnection.cs: 2.0 missing features.

	* DbDataAdapter.cs: 2.0 missing features.


svn path=/trunk/mcs/; revision=82422
2007-07-22 06:42:40 +00:00
Gert Driesen 53332a431f * DbDataAdapter.cs: Marked ICloneable.Clone obsolete to match MS.
svn path=/trunk/mcs/; revision=81108
2007-06-30 13:58:00 +00:00
Nagappan Alagappan 354842e304 2007-06-21 Nagappan A <[email protected]>
* DbConnectionStringBuilder.cs (Init): Modified the dictionary to
	use StringComparer.InvariantCultureIgnoreCase.
	(Add, ContainsKey): Checks whether argument is null or empty string.


svn path=/trunk/mcs/; revision=80465
2007-06-21 13:09:49 +00:00
Adar Wesley b9fcdffeb5 2007-05-08 Adar Wesley <[email protected]>
* DbProviderFactory.cs: minor refactoring for throwing exceptions

        * OleDbCommandBuilder.cs: added missing methods QuoteIdentifier,
        UnquoteIdentifier.

        * OleDbConnection.cs: added missing method ResetState.

        * OleDbDataReader.cs: added missing method GetData.

        * OleDbError.cs: added missing method ToString.

        * OleDbErrorCollection.cs: added missing method strongly typed
        CopyTo.

        * OleDbFactory.cs: added missing method CreatePermission.

        * OleDbParameter.cs: added missing methods ResetOleDbType,
        ResetDbType.

        * OleDbParameterCollection.cs: added missing methods strongly
        typed AddRange, IndexOf.



svn path=/trunk/mcs/; revision=76940
2007-05-08 15:14:49 +00:00
Marek Habersack d105ea0838 2007-04-30 Marek Habersack <[email protected]>
* ConnectionStringsExpressionBuilder.cs: support expressions with
	suffixes .ProviderName and .ConnectionString (case-insensitie) and
	generate a call to GetConnectionStringProviderName in the former
	case. Fixes bug #81490

2007-04-30  Marek Habersack  <[email protected]>

	* SqlDataSource.cs: do not catch the exception if ProviderName is
	not null or empty (as per docs and what MS.NET does).

2007-04-30  Marek Habersack  <[email protected]>

	* DbProviderFactories.cs: throw the same exception MS.NET does.

svn path=/trunk/mcs/; revision=76486
2007-04-30 11:02:24 +00:00
Gert Driesen e86ef7ce8d * app_test_2.0.config: Modified DbProviderFactories to allow testing
of clear and remove nodes.
* DbProviderFactoriesConfigurationHandler.cs: Added support for
clear node.
* DbProviderFactoriesConfigurationHandlerTest.cs: Changed test to also
verify behavior for clear and remove nodes.

svn path=/trunk/mcs/; revision=73663
2007-03-03 20:15:49 +00:00
Gert Driesen a789895532 * DbProviderFactoriesConfigurationHandlerTest.cs: Fixed tests to
pass on MS. Added NotWorking test to check whether DbProviderFactories
that are defined on machine config are available.
* ConnectionStringsSectionHandler.cs: Removed since the 2.0 config
API is in place.
* DbProviderFactoriesConfigurationHandler.cs: Fixed name of DataSet
to match MS. Removed SupportedClasses column since this is no longer
part of 2.0 profile (removed during beta). Throw
ConfigurationErrorsException for unrecognized elements. Mark methods
private, and refactor them. Added FIXMEs for missing checks for
unrecognized attributes.
* DbProviderFactories.cs: Marked constants internal. Replaced spaces
with tabs. Use ConfigurationManager.GetSection instead of deprecated
ConfigurationSettings.GetConfig.
* app_test_2.0.config: Fixed assembly qualified names of config
handler. Removed usage of ConnectionStringsSectionHandler, since
this is now handled by 2.0 config system. Spaces to tabs.
* System.Data.dll.sources: Removed ConnectionStringsSectionHandler.

svn path=/trunk/mcs/; revision=73659
2007-03-03 15:09:07 +00:00