Databases ... which way is the best?

  • Thread starter Thread starter Luke Vogel
  • Start date Start date
L

Luke Vogel

Hi all.

This is a bit of a newbie type question.

I am trying to figure out what is the best way to connect to a database;
ado.net, odic others?

I've found a couple of examples that show you how to connect to the
"Northwind" database, using oledb??

Do these actually query the database files directly or do they use a
database engine like Access, MS SQL Server, or MySQLD?

I'm eventually trying to interface with the MySQL server (or at least a
MySQL database) as opposed to the MS SQL Server ...

I totally confused as to what is the best way and why.
 
Hi Luke,

This is more a question for the newsgroup

Microsoft.public.dotnet.framework.adonet

My opinion is that
If you have a native connector: use that (SQLconnection by instance)
A point for the choise of this connector is if it will always be a database
using this connector

If not and you can use OleDb than OleDb
(if you look at this links you will see there are it seems an endless part
of connectors, but when you have a special it sometimes is not)

http://www.connectionstrings.com/

http://www.able-consulting.com/ADO_Conn.htm

And than if you needs another approach ODBC

I hope this helps.

Cor
 
Cor said:
Hi Luke,

This is more a question for the newsgroup

Microsoft.public.dotnet.framework.adonet

Noted. I will lurk on that group for a while.

I spose I was more wondering which was better in terms of performance
etc.

as well as implementation.

Thanks for the links.

Luke.
 
Hey Luke,
Luke Vogel said:
Hi all.

This is a bit of a newbie type question.

I am trying to figure out what is the best way to connect to a database;
ado.net, odic others?

ADO.NET allows you to easily manipulate data from a variety of data
providers, the package just happens to include oledb,odbc,sql,and oracle
drivers
I've found a couple of examples that show you how to connect to the
"Northwind" database, using oledb??

Oledb is used quite often with Microsoft because not everyone has SQL
Server, and with 3 major data engines (Access, MSSQL, MSDE) they provide a
way for the same codebase to commuincate with different engines. Thats why
you see oledb a lot.
Do these actually query the database files directly or do they use a
database engine like Access, MS SQL Server, or MySQLD?

Well, with access I'm not sure, because I don't understand exactly how
access works from a query/driver level. (You read an mdb, but not sure
where the data engine comes from)

MSSQL and MySQL you query the database engine itself.
I'm eventually trying to interface with the MySQL server (or at least a
MySQL database) as opposed to the MS SQL Server ...

With mysql you'll end up using oledb/odbc because there is no direct support
from microsoft on mysql. But there are numerous drivers out there for MySQL
(there is one that does MySQL and PostGreSQL, pretty nice.)
I totally confused as to what is the best way and why.
I do'nt know if there is a "best way"
 
CJ Taylor said:
Hey Luke,


ADO.NET allows you to easily manipulate data from a variety of data
providers, the package just happens to include oledb,odbc,sql,and oracle
drivers

Ok,I know what SQL and Oracle are .... what does oledb and odbc stand
for?

If I understand correctly, odbc is used as a kind of proxy
adapter/filter to interface between the app and the datasource. Does
that mean there would be a performance hit or reduced capability for
multiple users?

Oledb is used quite often with Microsoft because not everyone has SQL
Server, and with 3 major data engines (Access, MSSQL, MSDE) they provide a
way for the same codebase to communicate with different engines. That's why
you see oledb a lot.

I was just reading that oledb is used for just about any data source
whereas the sqlclient namespace classes are optimised for MS SQL Server
2000 databases.

Well, with access I'm not sure, because I don't understand exactly how
access works from a query/driver level. (You read an mdb, but not sure
where the data engine comes from)

MSSQL and MySQL you query the database engine itself.

Ok,so you must have the appropriate dbms installed for the app to work.
Someone told me you only need to copy the database file and the .net
framework would do the rest ... clearly wrong.

With mysql you'll end up using oledb/odbc because there is no direct support
from Microsoft on mysql. But there are numerous drivers out there for MySQL
(there is one that does MySQL and PostGreSQL, pretty nice.)

Yep, I found one on the MySQL site and there was another mature project
on sourceforge.net

I don't know if there is a "best way"

lol, I'm starting to think you're right.

Thanks for your response, it was helpful.

Luke.
 
Luke Vogel said:
Ok,I know what SQL and Oracle are .... what does oledb and odbc stand
for?

OLEDB = Object Linking and Embedding Data Base connectivity... I'm pretty
sure thats right.

ODBC - Open DataBase Connectivity.

Both of em are micrisoft standards for interacting with Databases to a
common source. ODBC was the first one, and now OLEDB is quickly taking over
as a more stable/speedy infrastructure.

Personally, I only use SQL, thats because I hate access, and don't really
have a need for mySQL (No Stored Procedures, no thank you.) and last time I
used the PostGres drivers I wasn't impressed (this was over a year ago
though.. so a lot has changed, I just bought a copy of SQL Server and went
from there. i was content)

And i can't really afford oracle. Have done some Sybase work, but that was
in Java.
If I understand correctly, odbc is used as a kind of proxy
adapter/filter to interface between the app and the datasource. Does
that mean there would be a performance hit or reduced capability for
multiple users?

Yeah, its what it does. Its a set of rules basically that both DB Vendors
and product vendors have to follow so that everyone is "guarunteed" to work.

Second, Databases are always going to have a performance hit of some kind.
Especially with more than one user accessing it (unless you have multiple
processors, and even then, once you reach that threshold of user/processor
ratio (or hell, even user/task) your having a "perfomance hit", the question
is, what is the users toleration level. =)

Isn't CS fun? =)
I was just reading that oledb is used for just about any data source
whereas the sqlclient namespace classes are optimised for MS SQL Server
2000 databases.

Yep, and your correct.
Ok,so you must have the appropriate dbms installed for the app to work.
Someone told me you only need to copy the database file and the .net
framework would do the rest ... clearly wrong.

In a pipe dream. MSSQL for example has some of the most advanced Data
mining routines ever conceived (no, they didn't make them, they bought them,
integerated them, paid other people, other people didn't like it after
awhile so they sued them.

Whoops, slipped into Rant mode.. my apologies.

So no, .NET framework doesn't take care of it, would kinda defeat the purpse
of selling SQL Server for $1400 and giving away the framework wouldn't it?
=)

Good luck to you, it's a good time. =)
 
I don't know... I just read about them and a law suit that happened like 6-8
months ago regarding it. I'm googling right now if I can find the case.

But here is what I remember of the article (I think it was CNET), some
company in California or Washington State had developed some really slick
data mining routines for SQL Server or something like it.

Like many microsoft products, Microsoft bought these routines and used them
in SQL 2k from what I understand but only licensed Microsoft itself, not
microsoft and its customers... So there was all these rumors/happenings
going on that this other company was going to sue all MS customers...

So in the mix, there was a few articles about the fact it was over Data
Mining routines.. And how advanced they were. hence my comments. =)

Here is an article that is sorta about it.. doesn't go into depth about the
issue though.. wlel, I've read 3 paragraphs.

http://www.control.com/1026168741/index_html
 
"MSSQL for example has some of the most advanced Data mining routines
ever conceived ..."


Will Dwinnell asked:
"What algorithms are those?"


"CJ Taylor" <[email protected]> responded:
"I don't know... I just read about them and a law suit that happened
like 6-8
months ago regarding it. ... Here is an article that is sorta about
it.. doesn't go into depth about the issue though.. wlel, I've read 3
paragraphs.

http://www.control.com/1026168741/index_html"



The article to which you refer only uses the term "data mining" once,
and then in a rather vague way ("Some of the descriptions sounded like
the type of data mining which I think is being used on historical data
in large scale SCADA systems..."). I am actually less interested in
the lawsuit than in how advanced the algorithms are. Do you have any
other references?

-Will Dwinnell
http://will.dwinnell.com
 
I'll try to find some, I just use that article for reference to "Generally"
describe what I was talking about. I am not saying I know anything about
the algorithms just what I've heard (my fisherman's story if you will.. .
"Data mining Algortihms THIS BIG! Jaws like a shark and fins like a
turtle..." =)

I am in no way claiming to be an expert of the SQL File structure, just
thinking with the amount of information that is stored in a SQL database
within a single file, there has to be some pretty advanced sh*t going on
there to make it that fast. Same with Oracle.

As stated before, I will try to find stuff on them, but no guaruntees...
 
Back
Top