|
|
Data access in .Net
This archived discussion is "read only".
» viperxp - Data(base) access in C# / .Net - help needed! In VB6, there's a DataGrid control which I can use to easily hook up to a MS Access database, and I can read and display the contents of a table in the grid. I know database access in C#, or even .Net in general is different from back then.. I have even read the basics of data access in .Net, so I have rough ideas on things like DataSet and DataAdapters.My question is: how can I do the same thing with C# specifically, and .Net in general? And what if my database is a Mysql database residing on localhost? I have MySQL 3.23.54 & IIS 5.1 installed. Wherever possible, I want to work only with Access / Mysql databases, since I am not familiar with MS SQL server. Right now, I have only managed to establish connection to an Access DB with ODBC drivers, but even with that, I cannot display / manipulate it from my program written in C#. Help needed. Thanks in advance. -- posted by viperxp » Jose_Aniceto - Re: Data(base) access in C# / .Net - help needed! In response to message posted by viperxp:There's a lot of ground to cover here. Basically, the preferred method of data access in .Net is through ADO.Net. Then there's the different options available to you. With .Net you have the xxxDataAdapter where you have Sql for SQLServer and Ora for Oracle, depending on which Data Adapter you are using. So, if MsSql supports .Net, it should provide something like MySDataAdapter class. Since this is not likely to be available yet, you might want to explore OleDBDataAdapter. OleDB has ODBC facilities and this will allow you to use MS Access and MySQL. If you are able to connect to the database, then you've solved half of the problem. The next thing you should try and do is create DataTables. Hope this helps. -- posted by Jose_Aniceto
Please follow the guidelines set forth in the Suite101 Posting Etiquette when adding to the discussion. |
|
|
|
|
|
|
|