![]() |
|
| 网站首页 | 数据库教程 | web编程 | 服务器 | 程序设计 | | ||
![]() |
||
|
||
|
||||||||||||||||||||||||||||||||||||||||||||||||
PB连接Microsoft SQL Server | ||||||||||||||||||||||||||||||||||||||||||||||||
作者:佚名 文章来源:不详 点击数: 更新时间:2007-7-3 ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||
Connecting to Microsoft SQL Server from PowerBuilder
Document:Overview This document is designed to provide assistance in making your connection to Microsoft SQL Server 6.0 or 6.5 using the native driver interface from PowerBuilder on the Intel platforms. PowerBuilder's native interface is compliant with SQL Server 7.0 but has not been enhanced to provide access to new features of SQL Server 7.0. For PowerBuilder 7.0 and later, the recommended interface for accessing SQL Server 7.0 and subsequent releases is the OLE-DB interface. This document is a supplement to the information provided in the PowerBuilder Documentation Microsoft SQL Server Client Software Microsoft Client software needs to be installed for the proper platform, 16-bit, 32 -bit, or both before any connections can be made with PowerBuilder and your target database. Verifying your Microsoft SQL Server Connection Once you have installed the necessary client-side software provided by Microsoft, make sure that you can connect outside of PowerBuilder before you attempt to connect from within PowerBuilder. This is necessary to determine that you can establish a connection from your workstation using the client software. From this point it should be easy to connect from PowerBuilder. Matching the drivers at connect time You select a specific PowerBuilder native driver when you supply the DBMS value in the Database profile. This entry is used to populate the DBMS property of the transaction object. In order to connect using the specified DBMS value, you must have installed the associated PowerBuilder native driver and the related Microsoft client side network support dlls. The following table shows the relationship between the DBMS value and the related PowerBuilder and Microsofts DLLs. If one of the DLLs associated with the DBMS specification is missing, you will not be able to connect. This template describes the 16- and 32-bit scheme for PowerBuilder 5.0, 6.0, 7.0 interfaces and SQL Server 6.x DLL'S:
DEBUGGING When PowerBuilder connects to a Microsoft 6.x database, the transaction object and the values passed in may not be set properly and giving you a problem. If in your DBProfile or transaction object in the "DBMS" line your place "trace MSS" and try to connect, a trace log will be started. The file name "PBTRACE.LOG" will be created and located in the windows home directory. When you first run the application and try to connect a message box will appear and state the PBTRACE.LOG is being created in your windows directory (e.g., C:\WINDOWS). If the message box does not appear, recheck your steps to verify you placed the word "trace" in front of MSS, with a space between. Common Problems 1.Many of the common problems customers have is with using a mixture of 16 and 32-bit platform products together and/or setting improper pathing to cause connection conflicts. 2.A common problem is to have multiple copies of the above dll's and improper pathing that can cause a host of problems with version and platform conflicts and mismatch errors. 3.You cannot connect from 16-bit PowerBuilder (versions 5.0 or 6.0) if you've only installed the 32-bit Microsoft client-side software and visa-versa. Common Errors
DBMS MSS (Msoft) SQL Server 6.0 not supported in current installation This error can occur under any of the following circumstances: 1. You have not installed the proper version or platform of SQL Server 6.x DLLs
b) Check the registry settings for valid entries. (Applies to: MS Sql Server 6.5 client software and 32-bit PowerBuilder). c) Check the path environment variable and make sure that the \sql60\bin directory (MS SQL Server 6.0 ) or \mssql\bin directory (MS SQL Server 6.5) is in the path. (applies to 16-bit only).
5. A 16-bit PowerBuilder development application or executable application attempted to connect via a 32-bit SQL Server 6.x client. Unable to connect: SQL Server is unavailable or does not exist. Specified SQL Sever not found. This error can occur under the following circumstances: 1. You supplied incorrect information in the profile for the Server name option
Dynamic Link Library <dll name> could not be found in the specified path. This error can occur under any of the following circumstances: 1.(16/32-bit ) DLL is missing. 2.Directory containing the DLL is not in the path. (If a search has found a copy) 3.If a search finds multiple copies, the pathing may be result in an invalid 16/32Bit version being used for your connection. 9
7
3
1
2
4
8
:
|
||||||||||||||||||||||||||||||||||||||||||||||||
文章录入:admin 责任编辑:admin | ||||||||||||||||||||||||||||||||||||||||||||||||
【发表评论】【加入收藏】【告诉好友】【打印此文】【关闭窗口】 |
网友评论:(只显示最新10条。评论内容只代表网友观点,与本站立场无关!) |
| 设为首页 | 加入收藏 | 联系站长 | 友情链接 | 版权申明 | 网站公告 | 网站地图 | 管理登录 | | |||
|