You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ibatis.apache.org by "Ron Grabowski (JIRA)" <ib...@incubator.apache.org> on 2005/05/25 22:03:52 UTC
[jira] Commented: (IBATISNET-62) Allow SqlClient, OleDb, Odbc, and OracleClient providers to be specified without needing providers.config file
[ http://issues.apache.org/jira/browse/IBATISNET-62?page=comments#action_66295 ]
Ron Grabowski commented on IBATISNET-62:
----------------------------------------
In Providers.cs, if you change this snipper of code:
assembly = Assembly.Load(_assemblyName);
To this:
if (_assemblyName.IndexOf(',') > 0)
{
assembly = Assembly.Load(_assemblyName);
}
else
{
assembly = Assembly.LoadWithPartialName(_assemblyName);
}
Then you can use this style of naming:
<provider
name="OleDb"
enabled="true"
description="OleDb"
assemblyName="System.Data"
connectionClass="System.Data.OleDb.OleDbConnection"
commandClass="System.Data.OleDb.OleDbCommand"
parameterClass="System.Data.OleDb.OleDbParameter"
parameterDbTypeClass="System.Data.OleDb.OleDbType"
parameterDbTypeProperty="OleDbType"
dataAdapterClass="System.Data.OleDb.OleDbDataAdapter"
commandBuilderClass="System.Data.OleDb.OleDbCommandBuilder"
usePositionalParameters = "true"
useParameterPrefixInSql = "false"
useParameterPrefixInParameter = "false"
parameterPrefix = "" />
Which should work on 1.0 and 1.1 of the Framework. Could we include just OleDb, Odbc, and SqlClient as default providers?
> Allow SqlClient, OleDb, Odbc, and OracleClient providers to be specified without needing providers.config file
> --------------------------------------------------------------------------------------------------------------
>
> Key: IBATISNET-62
> URL: http://issues.apache.org/jira/browse/IBATISNET-62
> Project: iBatis for .NET
> Type: Improvement
> Reporter: Ron Grabowski
> Assignee: Gilles Bayon
> Priority: Trivial
>
> This is a follow up to my post on the mailing list:
> http://tinyurl.com/cej2y
> http://www.mail-archive.com/ibatis-user-cs@incubator.apache.org/msg00352.html
> It would be nice if IBatisNet allowed the user to specify one of the 4 built-in .Net providers that ship with .Net:
> SqlClient
> OleDb
> Odbc
> OracleClient
> without having to have an external providers.config file.
> The Data Mapper Guide PDF file talks about the 4 built-in providers in table 3.5 (page 34) when it describes if their types are supported.
> IBatisNet already uses built-in aliases for some things. Page 33 of the Data Mapper Guide talks about using resultClass aliases for int, map, hashmap, etc. IBatisNet.DataMapper.Configuration.Cache.CacheModel uses the following aliases:
> _cacheControllerAliases.Add("MEMORY","IBatisNet.DataMapper.Configuration.Cache.Memory.MemoryCacheControler");
> _cacheControllerAliases.Add("LRU","IBatisNet.DataMapper.Configuration.Cache.Lru.LruCacheController");
> _cacheControllerAliases.Add("FIFO","IBatisNet.DataMapper.Configuration.Cache.Fifo.FifoCacheController");
> A providers.config file could be embedded into IBatisNet.Common and loaded before a providers.config file on the hard drive is loaded. A provider having the same name as one of the default providers would overwrite the default provider.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira