当前位置:软件学习 > 其它软件 >>

有没有人能详细说明下notes如何读取sql server数据库中的数据

我在odbc里添加了数据源,然后打开了notes数据库的dcr,后面应该怎么做
--------------------编程问答-------------------- 你可以看一下ODBCConnection这个类,帮助里面说的很详细的。
Create a new ODBCConnection object with "Dim New" or "Set = New." Once the object exists, you can get:
Software revision string with the GetLSDOMasterRevision property 
Available data sources with the ListDataSources method 
Connect to an external data source with the ConnectTo method of the ODBCConnection object. The external source must be defined in the ODBC Driver Manager at the operating system level. You can test the connection with the IsConnected method.
If the data source requires a user name and a password, you can supply these as arguments to ConnectTo or let the data source prompt the user. You can suppress prompts from the data source by setting the SilentMode property to True, although intermediate software may still prompt.
After you connect to a data source, you can query and update the external tables with the ODBCQuery and ODBCResultSet objects, and can get the following information:
Name of the data source with the DataSourceName property
Names of the tables for the data source with the ListTables method
Names of the fields (columns) in a table with the ListFields method 
Names of the stored procedures for the data source with the ListProcedures method 
Status of options for the data source with the IsSupported method 
When you are done using a data source to which you connected, disconnect from it with the Disconnect method. --------------------编程问答-------------------- 最好不要通过odbc读取,否则需要安装odbc数据源。采取ado的方式,或者jdbc都比较好。一下给出ado的例子:
http://topic.csdn.net/u/20100308/10/18eaf72a-9329-4968-91bd-f08f5f4c5d0b.html?89960
补充:企业软件 ,  Lotus
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,