ODBC (Open Database Connectivity)
DSN (data source name)
The ODBC Data Source manager provides three DSN types: User DSN, system DSN, and file DSN.
1. the user DSN will save the corresponding configuration information in the Windows registry, but it can only be used by login users who create the DSN.
2. The system DSN also saves the related configuration information in the system registry. However, different from the user DSN, the system DSN allows all users who log on to the server to use it.
3. The file DSN stores the specific configuration information in a specific file on the hard disk. The file DSN allows all users who log on to the server to access the database DSN even if no user logs on to the server. In addition, because the file DSN is saved in the hard disk file, it can be easily copied to other machines (files can be shared within the network ). In this way, you can directly use the DSN created on other machines without making any changes to the system registry.
The difference between a user DSN and a system DSN is that the user DSN is saved under HKEY_CURRENT_USER in the registry, and the system DSN is saved under HKEY_LOCAL_MACHINE.