In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article introduces the relevant knowledge of "ADO.NET feature example Analysis". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!
After Mysql is installed, click the properties, then click to find the target, and click to go up to the directory.
Find Binaries\. Net 2.0 and copy this file to your project directory. Usually, such DLL files will be saved to the bin directory. Type the ADO.NET feature in the code page; then write MysqlConnection in the Page_Load function, and the prompt comes out in the middle of the word, so you don't have to write the following? Have already appeared "code intelligence is completed", just write a piece of code to try, just like Sqlserver.
The following provides two pieces of code for reference, one code page and one HTML page: ADO.NET connection MySQL code under default2.aspx.cs:
Untitled page
The above results pass the test under visualwebDeveloper2005 (express version)! I believe it can also be passed in visualstudio2005! Connector/NET5.0 download address: you need to install Mysqlconnector/net5.0 before working on the project, then find MySql.Data.dll in the installation directory, copy this file to the project's bin directory, and write the red statement usingMySql.Data.MySqlClient; below the using lines. Just do it! The right way to get started quickly is to change the previously written SQLserver code from the ADO.NET feature to mysql, and the rewriting is rare, because the two formats are almost the same.
Various .net platform development languages to develop database applications generally do not directly operate on the database (except directly calling stored procedures in the program, etc.), but first complete the data connection and fill the DataSet object through the data adapter, and then the client gets the needed data by reading DataSet. Similarly, to update the data in the database is to update the DataSet first, and then update the corresponding data in the database through DataSet.
It can be seen that to understand and master ADO.NET, we must first understand and master DataSet. DataSet has three main ADO.NET features:
1. Independence. DataSet is independent of various data sources. When Microsoft launched DataSet, it considered the diversity and complexity of various data sources. In .net, regardless of the type of data source, it provides a consistent relational programming model, and this is DataSet.
two。 Offline (disconnected) and connected. DataSet can manipulate data in the database either offline or with a real-time connection. This is a bit like RecordSet in ADO.
3. The DataSet object is a data view that can be represented in the form of XML, and the ADO.NET feature is a data relational view.
This is the end of the content of "ADO.NET feature example Analysis". Thank you for reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.