Oracle|visual downloaded odt for. Net, Discover that Oracle-provided Oracle browsers that are integrated into vs.net are good to use, and this tool is similar to the Vs.net Server Resource Manager's data connection, and the VS-Self resource manager can connect to SQL Server to support drag and drop of SQL Server database tables , but does not support drag-and-drop of Oracle database tables, Oracle's tool compensates for vs.net deficiencies.
The use process is as follows,
1, the first is to download Oracle Developer Tools for Visual Studio. NET,
2, and then extract EXE file, do not know what is the reason, installation needs in the command line environment to run Setup.exe can enter the installation interface.
3, after the installation is completed, the Oraclehome\network\admin\tnsnames.ora file is copied to the Product\10.1.0\client_1\network\admin location of the ODT installation directory, The database connection alias becomes available, and when you add a data connection to. NET, the previously configured connection is available in the system.
4, VS. NET, point menu "tool" = "Connect to Oracle Database", select the data source from the data source name, this data source is the database connection alias previously configured in OEM, enter username, password, data connection alias, OK, the system prompts the connection to be successful.
5, the successful connection in the Oracle browser to browse the database, and can drag and drop database tables and other modes, and can directly operate the database, can add tables, views, stored procedures and so on.
I dragged a tbllog table onto the Web form and automatically generated a TbllogOracleDataAdapter1 class, which is used in the code as follows:
DataSet ds= new DataSet ();
Tbllogoracledataadapter1.fill (DS);
DataGrid1.DataSource = ds. Tables[0];
Datagrid1.databind ();