Board index » delphi » General SQL Error Help Please

General SQL Error Help Please

NT 4.0 Server SP4, MSSQL Server 6.5 SP5a Delphi 4.03 BDE5.01 and 5.10.

I need suggestions please.  I have a bunch of apps which run against MSSQL
database fine from other PC's but fail with a general sql error when running
on the server where the MSSQL database resides.

I have tried completely removing the BDE from the registry and disk and
reinstalling.  Permissions are correct.

The SQL trace shows the connect works fine but fails on any TQuery ExecSQL
or Open.

Enterprise Manager and ISQL_W work fine on the server.  Database Explorer
fails the same way when I try to expand the Tables or Procedures folder.

Help!

Patrick

 

Re:General SQL Error Help Please


Patrick,
I had similar problems with SQL 7.0 recently. I found that the problems were two
fold. Firstly, I had "security problems". By that I mean that when developing I
use NT 4 and logon as Administrator. Validation on the server was set to NT and
SQL Server. Now this means that if you logon as Administraotr (which I do) then
you can insert nay user name and any pass word when connecting to the Server,
and you will be logged on anyway. I switched to SQL Authentiction only and now
have a predictable environment both at the shop and at the client.
I found also that some of my TTable and TQuery components TableName property was
not prefixed with dbo. Every one failed on Open with the following error
message:
"Table is not indexed".
All the time, both Enterprise Manager and ISQL_w worked perfectly.
Reagrds,

Quote
"Patrick W. O'Brien" wrote:
> NT 4.0 Server SP4, MSSQL Server 6.5 SP5a Delphi 4.03 BDE5.01 and 5.10.

> I need suggestions please.  I have a bunch of apps which run against MSSQL
> database fine from other PC's but fail with a general sql error when running
> on the server where the MSSQL database resides.

> I have tried completely removing the BDE from the registry and disk and
> reinstalling.  Permissions are correct.

> The SQL trace shows the connect works fine but fails on any TQuery ExecSQL
> or Open.

> Enterprise Manager and ISQL_W work fine on the server.  Database Explorer
> fails the same way when I try to expand the Tables or Procedures folder.

> Help!

> Patrick

  normanm.vcf
< 1K Download

Re:General SQL Error Help Please


Thanks for the response.

I found it last night.  I applied MDAC 2.1.1... latest version and lo and
behold everything worked.  I had MDAC 2.1 before.  I suspect that my backup
program which uses MDAC as well might have hosed something on install.  All
I got from the traces were a failure to allocate a handle for an SQL
statement.

P

Other Threads