PC Review


Reply
Thread Tools Rate Thread

DB2 IBM OleDB Provider

 
 
Parking Meters
Guest
Posts: n/a
 
      12th Jan 2005

Today I managed to get the OleDB provider to let me put datasets from an
as400 using sql.

Great, the provider string I used is:

Provider=IBMDA400.DataSource.1;User ID=XXXXX;Password=XXXX;Data
Source=nnn.nnn.nnn.nnn;"/>


Question:

What is /IBMDA400.DataSource.1/ ?

Is that an ODBC driver?

Is it built into .net 1.1 ? Or do I have to install something else?

Is it part of the IBM CAE ( Client Access Express ) Utilities?

Does CAE have to be installed on the client to be able to use
IBMDA400.DataSource.1 ?



--

incognito () Updated Almost Daily
http://kentpsychedelic.blogspot.com
 
Reply With Quote
 
 
 
 
Carlos J. Quintero [.NET MVP]
Guest
Posts: n/a
 
      12th Jan 2005
> What is /IBMDA400.DataSource.1/ ?

Introduction: .NET uses .NET Data Providers.

- You have "native" .NET Data Providers for Oracle, SQL Server (provided by
MS) and maybe for IBM (provided by IBM, if any).

- There is a special .NET Data Provider: The Microsoft .NET Data Provider
for OLEDB, which on the contrary to "native" .NET Data Providers, needs an
old OLEDB Provider to work, and should be used when no native .NET Data
Providers is available for a database.

So:

"Provider=IBMDA400.DataSource.1" specifies the OLEDB Provider that the
Microsoft .NET Data Provider for OLEDB must use. In this case, it specifies
that you want to use the OLEDB Provider for IBM. For example,
Provider=MSDAORA would specify the Microsoft OLEDB Provider for Oracle.
Technically it is the ProgID of the COM class exposed by the OLEDB provider.
The .1 specifies the version-depending ProgID.
"Provider=IBMDA400.DataSource" would be the version-independent ProgID.

> Is that an ODBC driver?


No.

> Is it built into .net 1.1 ? Or do I have to install something else?


The Microsoft .NET Data Provider for OLEDB is supplied by the .NET
Framework. This provider is a .NET-OLEDB bridge which needs an OLEDB
Provider. Some OLEDB Providers for Oracle and SQL Server are supplied by
Microsoft in Microsoft Data Access Components (MDAC), but for IBM you have
to get it presumably from IBM Corp.

> Is it part of the IBM CAE ( Client Access Express ) Utilities?


It could be, check with IBM docs.

> Does CAE have to be installed on the client to be able to use
> IBMDA400.DataSource.1 ?


It's very likely, since .NET Data Providers, OLEDB Providers or ODBC drivers
need the native client DLLs to connect to the database.

Notice that you are using the Microsoft .NET Data Provider for OLEDB with
an OLEDB Provider for IBM. Another approach is to avoid OLEDB and use a
"native" .NET Data Provider for IBM, if IBM offers it. Since you avoid the
bridge component, the performance can be better.

--

Carlos J. Quintero

MZ-Tools 4.0: Productivity add-ins for Visual Studio .NET
You can code, design and document much faster.
http://www.mztools.com



 
Reply With Quote
 
Keith
Guest
Posts: n/a
 
      12th Jan 2005
Carlos J. Quintero [.NET MVP] wrote:

> Notice that you are using the Microsoft .NET Data Provider for OLEDB with
> an OLEDB Provider for IBM. Another approach is to avoid OLEDB and use a
> "native" .NET Data Provider for IBM, if IBM offers it. Since you avoid the
> bridge component, the performance can be better.
>


There is a provider up on IBM's site, but it's still in beta. I will
try it though.

I have tried ODBC and OleDb.

The time to do a connection in OleDb is /significantly/ longer than when
using ODBC -- but with OleDb I don't have to do any configuration in the
CAE to create the ODBC source.

I'd really like to get away from the CAE since there are versioning
problems with other apps, and I'd like to stay as pure .net as possible.

Thanks for the info on OleDb.

--

incognito...updated almost daily
http://kentpsychedelic.blogspot.com
 
Reply With Quote
 
Frans Bouma [C# MVP]
Guest
Posts: n/a
 
      13th Jan 2005
Keith wrote:
> Carlos J. Quintero [.NET MVP] wrote:
>
>> Notice that you are using the Microsoft .NET Data Provider for OLEDB
>> with an OLEDB Provider for IBM. Another approach is to avoid OLEDB and
>> use a "native" .NET Data Provider for IBM, if IBM offers it. Since you
>> avoid the bridge component, the performance can be better.
>>

>
> There is a provider up on IBM's site, but it's still in beta. I will
> try it though.


search for: Redistributable DB2 Run-Time Client Lite

on IBM's site. That's the .NET provider and it's not beta anymore.

Frans.

--
------------------------------------------------------------------------
Get LLBLGen Pro, productive O/R mapping for .NET: http://www.llblgen.com
My .NET blog: http://weblogs.asp.net/fbouma
Microsoft MVP (C#)
------------------------------------------------------------------------
 
Reply With Quote
 
Carlos J. Quintero [.NET MVP]
Guest
Posts: n/a
 
      13th Jan 2005

"Keith" <(E-Mail Removed)> escribió en el mensaje
news:L3dFd.5460$(E-Mail Removed)...
> The time to do a connection in OleDb is /significantly/ longer than when
> using ODBC -- but with OleDb I don't have to do any configuration in the
> CAE to create the ODBC source.


You can use ODBC DSN-less connections, no need to create ODBC data sources
in the Control Panel, etc. You use "Driver={...};...". Search the concept on
Google or visit
http://www.able-consulting.com/MDAC/...BC_DSNLess.htm

--

Carlos J. Quintero

MZ-Tools 4.0: Productivity add-ins for Visual Studio .NET
You can code, design and document much faster.
http://www.mztools.com



 
Reply With Quote
 
C.E.O. Gargantua
Guest
Posts: n/a
 
      14th Jan 2005

I downloaded and installed the DB2 Run Time Client Lite Installer, US
English.

After running this install, two entries in the start menu appeared:
Command Line Window and Command Line Processor.

I did not see any documentation.

What are the DB2 Client Merge Modules ?

Do I need to install those as well?

Just by installing the Run Time Client Lite Installer, can I now use
OleDb for .NET using the IBM?

Is the provider still "IBMDA400.DataSource.1"




Frans Bouma [C# MVP] wrote:
> Keith wrote:
>
>> Carlos J. Quintero [.NET MVP] wrote:
>>
>>> Notice that you are using the Microsoft .NET Data Provider for OLEDB
>>> with an OLEDB Provider for IBM. Another approach is to avoid OLEDB
>>> and use a "native" .NET Data Provider for IBM, if IBM offers it.
>>> Since you avoid the bridge component, the performance can be better.
>>>

>>
>> There is a provider up on IBM's site, but it's still in beta. I will
>> try it though.

>
>
> search for: Redistributable DB2 Run-Time Client Lite
>
> on IBM's site. That's the .NET provider and it's not beta anymore.
>
> Frans.
>



--

incognito () Updated Almost Daily
http://kentpsychedelic.blogspot.com
 
Reply With Quote
 
Frans Bouma [C# MVP]
Guest
Posts: n/a
 
      14th Jan 2005
C.E.O. Gargantua wrote:
> I downloaded and installed the DB2 Run Time Client Lite Installer, US
> English.
>
> After running this install, two entries in the start menu appeared:
> Command Line Window and Command Line Processor.
>
> I did not see any documentation.


Also not in vs.net? The .NET provider has an integrated help addition
for vs.net and vs.net designers.

> What are the DB2 Client Merge Modules ?


those are for when you create an application using teh DB2 provider and
you want to include the provider in your installer. I.o.w.: you don't
need them to access a db2 system

> Do I need to install those as well?
>
> Just by installing the Run Time Client Lite Installer, can I now use
> OleDb for .NET using the IBM?


You can use the IBM.Data.DB2.dll assembly, which is the native .NET
provider, so you don't need OleDb anymore. (located in X:\Program
Files\IBM\SQLLIB\BIN\netf11 )

> Is the provider still "IBMDA400.DataSource.1"


however! I see you use the AS/400 OleDb driver here (if I'm not
mistaken) and the .NET provider for DB2 doesn't support AS/400
(according to the docs, haven't tried it myself, I don't have an as/400
box )

Frans.

>
>
>
>
> Frans Bouma [C# MVP] wrote:
>
>> Keith wrote:
>>
>>> Carlos J. Quintero [.NET MVP] wrote:
>>>
>>>> Notice that you are using the Microsoft .NET Data Provider for
>>>> OLEDB with an OLEDB Provider for IBM. Another approach is to avoid
>>>> OLEDB and use a "native" .NET Data Provider for IBM, if IBM offers
>>>> it. Since you avoid the bridge component, the performance can be
>>>> better.
>>>>
>>>
>>> There is a provider up on IBM's site, but it's still in beta. I will
>>> try it though.

>>
>>
>>
>> search for: Redistributable DB2 Run-Time Client Lite
>>
>> on IBM's site. That's the .NET provider and it's not beta anymore.
>>
>> Frans.
>>

>
>



--
------------------------------------------------------------------------
Get LLBLGen Pro, productive O/R mapping for .NET: http://www.llblgen.com
My .NET blog: http://weblogs.asp.net/fbouma
Microsoft MVP (C#)
------------------------------------------------------------------------
 
Reply With Quote
 
C.E.O. Gargantua
Guest
Posts: n/a
 
      14th Jan 2005
Frans Bouma [C# MVP] wrote:

> Also not in vs.net? The .NET provider has an integrated help
> addition for vs.net and vs.net designers.


Mmm...I searched for IBM and DB2 in Visual Studio and and don't see
anything specific to IBM.Data.DB2

Can you tell me what the location is?

> You can use the IBM.Data.DB2.dll assembly, which is the native .NET
> provider, so you don't need OleDb anymore. (located in X:\Program
> Files\IBM\SQLLIB\BIN\netf11 )


Ok, I found this, and added as a reference.

But I'm still left with the detail of what I should put in for, say
..ConnectionString

DB2Connection db2 = new DB2Connection();
db2.ConnectionString= ... ?

> however! I see you use the AS/400 OleDb driver here (if I'm not
> mistaken) and the .NET provider for DB2 doesn't support AS/400
> (according to the docs, haven't tried it myself, I don't have an as/400
> box )


Well, it's an iSeries. Isn't DB2 the same across IBM's hardware product
lines?




--

incognito () Updated Almost Daily
http://kentpsychedelic.blogspot.com
 
Reply With Quote
 
C.E.O. Gargantua
Guest
Posts: n/a
 
      14th Jan 2005

ok, here's the api reference:

http://publib.boulder.ibm.com/infoce...ClassTopic.htm

C.E.O. Gargantua wrote:
> Frans Bouma [C# MVP] wrote:
>
>> Also not in vs.net? The .NET provider has an integrated help
>> addition for vs.net and vs.net designers.

>
>
> Mmm...I searched for IBM and DB2 in Visual Studio and and don't see
> anything specific to IBM.Data.DB2
>
> Can you tell me what the location is?
>
>> You can use the IBM.Data.DB2.dll assembly, which is the native
>> .NET provider, so you don't need OleDb anymore. (located in X:\Program
>> Files\IBM\SQLLIB\BIN\netf11 )

>
>
> Ok, I found this, and added as a reference.
>
> But I'm still left with the detail of what I should put in for, say
> .ConnectionString
>
> DB2Connection db2 = new DB2Connection();
> db2.ConnectionString= ... ?
>
>> however! I see you use the AS/400 OleDb driver here (if I'm not
>> mistaken) and the .NET provider for DB2 doesn't support AS/400
>> (according to the docs, haven't tried it myself, I don't have an
>> as/400 box )

>
>
> Well, it's an iSeries. Isn't DB2 the same across IBM's hardware product
> lines?
>
>
>
>



--

incognito () Updated Almost Daily
http://kentpsychedelic.blogspot.com
 
Reply With Quote
 
C.E.O. Gargantua
Guest
Posts: n/a
 
      14th Jan 2005

According to :

http://publib.boulder.ibm.com/infoce...ClassTopic.htm

The DB2 .NET Data Provider allows your .NET applications to access the
following database management systems:

* DB2 Universal Database Version 8 for Windows, UNIX, and
Linux-based computers
* DB2 Universal Database Version 6 (or later) for OS/390 and z/OS,
through DB2 Connect

* DB2 Universal Database Version 5, Release 1 (or later) for AS/400
and iSeries, through DB2 Connect


* DB2 Universal Database Version 7.3 (or later) for VSE & VM,
through DB2 Connect




Frans Bouma [C# MVP] wrote:

>
> however! I see you use the AS/400 OleDb driver here (if I'm not
> mistaken) and the .NET provider for DB2 doesn't support AS/400
> (according to the docs, haven't tried it myself, I don't have an as/400
> box )




--

incognito () Updated Almost Daily
http://kentpsychedelic.blogspot.com
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Set OLEDB Provider Timeout? =?Utf-8?B?RWQgQXJkemluc2tp?= Microsoft Access External Data 1 30th May 2007 04:18 PM
OLEDB Provider Paul Ilacqua Microsoft Dot NET Compact Framework 2 17th Jan 2005 08:16 PM
DB2 IBM OleDB Provider Parking Meters Microsoft ADO .NET 12 17th Jan 2005 09:07 AM
DB2 IBM OleDB Provider Parking Meters Microsoft Dot NET 12 17th Jan 2005 09:07 AM
Missing OLEDB Provider =?iso-8859-1?Q?Alfons_Str=F6bele?= Microsoft ADO .NET 1 4th Oct 2003 06:39 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:01 AM.