Access the database and mysql database

Source: Internet
Author: User

Access the database and mysql database
Improve system performance: Starting from Data Access

1. The using statement has two functions:

① As a keyword, using can import namespaces

② As a C # statement, using can release the memory resources occupied by objects.

 

2. Since using can release objects, is it possible to use using to limit all objects?

This is not the case because:

① The IDisable interface must be implemented for all objects that can be released by using.

② Even if all the IDisable interfaces are implemented, there is no need to use using all.

We only limit the using of objects that have an important impact on the system, while other objects can be handed over to the Garbage Collector for processing.

 

3. common attributes of the SqlParameter class

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.