All SELECT INTO's (inline SQL) causing SQL errors with PB11.5 (SQLOLEDB) on Vista/SQL 2000

Hello all-

I recently migrated a PowerBuilder app to 11.5 on a box
running Vista and SQL Server 2000.  I believe the DB Profile
is correctly set up since I can use the Database painter and
query the tables with no issue.  However, if I open any
script that contains any inline SQL (SELECT/INTO's), the
scripts won't compile and the SQL error 42000 is thrown.

Strangely, the app runs fine and the inline SQL seems to
execute successfully at run-time, but in the script views,
something appears to be wrong.

Here is my db profile I have setup for development:

// Profile <profile name>
SQLCA.DBMS = "OLE DB"
SQLCA.LogPass = <*******>
SQLCA.LogId = "sa"
SQLCA.AutoCommit = False
SQLCA.DBParm =
"PROVIDER='SQLOLEDB',DATASOURCE='<datasourcename>',PROVIDERSTRING='DATABASE=<databasename>;
PbMaxBlobSize=0'"

Is this the result of some kind of Vista/SQL 2000
incompatibility?  Is there an updated OLEDB (SQLOLEDB)
driver for Vista that I'm lacking?  (I haven't installed any
hotfixes since the PB 11.5 install; however, Vista SP2 was
applied just prior to the install)

Any thoughts/insights would be greatly appreciated.

Thanks,
Dave
0
DMY
9/14/2009 7:28:59 PM
sybase.powerbuilder.connection 3893 articles. 0 followers. Follow

5 Replies
859 Views

Similar Articles

[PageSpeed] 57

<DMY> wrote in message news:4aae997b.3cf7.1681692777@sybase.com...
> Hello all-
>
> I recently migrated a PowerBuilder app to 11.5 on a box
> running Vista and SQL Server 2000.  I believe the DB Profile
> is correctly set up since I can use the Database painter and
> query the tables with no issue.  However, if I open any
> script that contains any inline SQL (SELECT/INTO's), the
> scripts won't compile and the SQL error 42000 is thrown.

You are more likely to get useful responses if you post the complete error 
message, as well as some code that produces the error.  This particular 
error number is a generic value (the "state" isn't particularly useful 
without the actual message).  In addition, any time you mention "upgrade", 
it often helps to know the prior version/build (and in this case, the type 
of connection used - MSS, ODBC, etc.).   Note that there are two possible 
interpretations of "select/into" - one is into a table in the server, the 
other is into a local variable.

>
> Strangely, the app runs fine and the inline SQL seems to
> execute successfully at run-time, but in the script views,
> something appears to be wrong.

I would use the MS Profiler to see exactly what PB is trying to execute when 
this occurs.  That may give you some insight.

>
> Here is my db profile I have setup for development:
>
> // Profile <profile name>
> SQLCA.DBMS = "OLE DB"
> SQLCA.LogPass = <*******>
> SQLCA.LogId = "sa"
> SQLCA.AutoCommit = False
> SQLCA.DBParm =
> "PROVIDER='SQLOLEDB',DATASOURCE='<datasourcename>',PROVIDERSTRING='DATABASE=<databasename>;
> PbMaxBlobSize=0'"
>
> Is this the result of some kind of Vista/SQL 2000
> incompatibility?  Is there an updated OLEDB (SQLOLEDB)
> driver for Vista that I'm lacking?  (I haven't installed any
> hotfixes since the PB 11.5 install; however, Vista SP2 was
> applied just prior to the install)

Is sql server 2000 even supported on Vista?  Not to beat a dead horse, but 
you've upgraded everything except sql server - which is a decade old and no 
longer actively supported. 


0
Scott
9/14/2009 8:19:02 PM
Trace results:

SET NO_BROWSETABLE ON
-- 'password' was found in the text of this event.
-- The text has been replaced with this comment for security
reasons.

I've never seen the SET NO_BROWSEABLE command before.  Can
this be the culprit?  And the actual SQL statement that was
compiling wasn't even submitted to Profiler.

Does this help?

Thanks,
Dave


> <DMY> wrote in message
> > news:4aae997b.3cf7.1681692777@sybase.com... Hello all-
> >
> > I recently migrated a PowerBuilder app to 11.5 on a box
> > running Vista and SQL Server 2000.  I believe the DB
> > Profile is correctly set up since I can use the Database
> > painter and query the tables with no issue.  However, if
> > I open any script that contains any inline SQL
> > (SELECT/INTO's), the scripts won't compile and the SQL
> error 42000 is thrown.
>
> You are more likely to get useful responses if you post
> the complete error  message, as well as some code that
> produces the error.  This particular  error number is a
> generic value (the "state" isn't particularly useful
> without the actual message).  In addition, any time you
> mention "upgrade",  it often helps to know the prior
> version/build (and in this case, the type  of connection
> used - MSS, ODBC, etc.).   Note that there are two
> possible  interpretations of "select/into" - one is into a
> table in the server, the  other is into a local variable.
>
> >
> > Strangely, the app runs fine and the inline SQL seems to
> > execute successfully at run-time, but in the script
> > views, something appears to be wrong.
>
> I would use the MS Profiler to see exactly what PB is
> trying to execute when  this occurs.  That may give you
> some insight.
>
> >
> > Here is my db profile I have setup for development:
> >
> > // Profile <profile name>
> > SQLCA.DBMS = "OLE DB"
> > SQLCA.LogPass = <*******>
> > SQLCA.LogId = "sa"
> > SQLCA.AutoCommit = False
> > SQLCA.DBParm =
> > "PROVIDER='SQLOLEDB',DATASOURCE='<datasourcename>'
> > ,PROVIDERSTRING='DATABASE=<databasename>;
> PbMaxBlobSize=0'" >
> > Is this the result of some kind of Vista/SQL 2000
> > incompatibility?  Is there an updated OLEDB (SQLOLEDB)
> > driver for Vista that I'm lacking?  (I haven't installed
> > any hotfixes since the PB 11.5 install; however, Vista
> > SP2 was applied just prior to the install)
>
> Is sql server 2000 even supported on Vista?  Not to beat a
> dead horse, but  you've upgraded everything except sql
> server - which is a decade old and no  longer actively
> supported.
>
>
0
DMY
9/15/2009 1:52:22 AM
Problem is solved.  I uninstalled SQL Anywhere (installed
with PB 11.5) and that took care of it.

Dave
0
DMY
9/15/2009 1:23:57 PM
There must be something else that addressed this issue... SQL Anywhere 
should not have had causes the behaviour you were seeing.

DMY wrote:
> Problem is solved.  I uninstalled SQL Anywhere (installed
> with PB 11.5) and that took care of it.
> 
> Dave
0
Chis
9/15/2009 1:58:25 PM
<DMY> wrote in message news:4aaef356.484b.1681692777@sybase.com...
> Trace results:
>
> SET NO_BROWSETABLE ON
> -- 'password' was found in the text of this event.
> -- The text has been replaced with this comment for security
> reasons.
>
> I've never seen the SET NO_BROWSEABLE command before.  Can
> this be the culprit?  And the actual SQL statement that was
> compiling wasn't even submitted to Profiler.
>
> Does this help?

No.  The <no_browse> statement happens frequently.  Apparently you did not 
start the profiler with the appropriate events selected.  Try again.  This 
is what I see after setting up a test using sql server 2005 and PB 11.2 and 
OLE:

declare @p1 int
set @p1=-1
exec sp_prepare @p1 output,NULL,N'SELECT ACTIVITY_LOG.ACTIVITY_LOG_ID FROM 
ACTIVITY_LOG WHERE ACTIVITY_LOG.ACTIVITY_LOG_ID =95732 ',1
select @p1
Error: 208, Severity: 16, State: 1
Invalid object name 'ACTIVITY_LOG'.

So what is the actual and complete error message?  Is it something like:

(14bc068): *** ERROR 208 ***(rc -1) : SQLSTATE = 42S02
Microsoft OLE DB Provider for SQL Server
Invalid object name 'ACTIVITY_LOG'.

If it is, then the problem should be obvious.  You are not connected to the 
correct database.  Most likely, you are connected to the default database of 
the userid - probably master.  Quite understandable since you are using the 
SA account.  Note that this happens to me when I compile a script.  You said 
in your OP that it occured in "script views" - I can view the window 
containing this script (event script, if it matters) without problem.

If it is not, what is the complete error message? You might also want to 
trace your connection from PB (System tab, Generate Trace) to see the actual 
value PB is using for dbparm.  It may be that something isn't quite right 
with it.

One other thing - I can guarantee you that putting PBMaxBlobSize inside of 
the provider string will do nothing for you.  For a development profile, 
this is set on the Transaction tab, not the extended properties field on the 
connection tab (but it does wind up in dbparm). 


0
Scott
9/15/2009 2:21:33 PM
Reply:

Similar Artilces:

2008 IIS7 connection to SQL Server 2000 on Web Server 2000: Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection.
I am setting up a windows 2008 IIS7 web server, and trying to connect to a windows 2000 sql server 2000 database. I have an IIS6 Windows 2000 web server activately connected just fine. I have anonymous and windows authentication enabled. And in my web.config I have identity impersonate="true" My sql server 2000 typically uses the IISUSER anonymous user set up in IIS6 on my original windows 2000 web server. But this new IIS7 is giving me grief. I can't seem to setup the IUSR or IISUSER or anything in it. I can't even use sql server credentials in my connection string altho...

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not all #5
An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)   <sessionState mode="SQLServer"sqlConnectionString="data source=LHX00CNU7401SQG\Session; integrated security=true"/>   I have done all the settings: --> enabling the protocols --> Starting teh SQlbrowser but still no luck. Pleas...

Connecting to sql server 2000 on Godaddy error: (provider: Named Pipes Provider, error: 40
Facts:1. I am using my account on Godaddy trying to connect to my sql server db.2. I can get into my db using user id and password.3. Godaddy's help file shows this for a connection string: connectstr = "Driver={SQL Server};SERVER=" & db_server & ";DATABASE=" &db_name & ";UID=" & db_username & ";PWD=" & db_userpassword4. My connection string: "Server=whsql-v09.prod.mesa1.secureserver.net;uid=dbasolutions;pwd=***;database=DB_87972;"  & _                    "Trusted_Connecti...

Uploading SQL Express to SQL Server 2005
I am very frustrated.  Everything works on the local host but when I upload to server I can login to the admin role I created, but when I try to access pages that have role priveleges I get the following error:  The SSE Provider did not find the database file specified in the connection string. At the configured trust level (below High trust level), the SSE provider can not automatically create the database file. The ASPNETDB.MDF database was uploaded using the Database Publishing Wizard. Please help! Hi, Does your application show such error message while lunched from I...

Error : An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does
Hi All, i am using tha conncetion string in web.config. <add name="MyLocalSqlConnection" connectionString="Data Source=.\SqlExpress;AttachDbFilename=|DataDirectory|\SqlServer\OC00003SQL.mdf;User Instance=false" providerName="System.Data.SqlClient"/>  Instance=false and true both i have used  but i am getting error like that. on my web hosting site  Error : An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Serv...

connecting to SQL 2000 Server gives SQL 2005 error message
Hi, Here is the syntax of the connection string within the web.config file:<connectionStrings><clear /> <add name="MyConnectionString" connectionString="Data Source=000.000.000;Initial Catalog=Database Name;Persist Security Info=True;User ID=XXXXXX;Password=XXXXXX;" providerName="System.Data.SqlClient" /> </connectionStrings>  The test page has a GridView in it which uses the connectionstring fron the web.config file. Error Message: An error has occurred while establishing a connection to the server.  When connecti...

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not all
When i enter log in, I get the following error page.    Server Error in '/' Application. An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified) Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the err...

[Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection.
Hello All, I'm Getting the following error when calling a dll from my vb.net application. [Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection. The dll was written in vb6 and accesses a sql db using the following connection string. Public Const GLOBAL_DNS As String = "DSN=TransSrvFinal;UID=sa;PWD=admin;" This DLL works fine when called from other Windows Apps. However I'm now trying to call this dll from with in an asp.net application. I'm using vb.net as the codebehind. I'm a...

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allo
My site works fine in VWD2008 express, but I get this error when I try to use it on my live website. An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections.  According to this article: http://support.microsoft.com/kb/914277  I am supposed to: 1. Click Start, point to Programs, point to Microsoft SQL Server 2005, point to Configuration Tools, and then click SQL Server Surface Area Configuration. Ok, th...

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not all #4
Hi,I have SQL Server Express Edition. I tried working out some ASP.NET Labs in my local system. Here is the link of the Virtual Lab which I tried. http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?EventID=1032286906&EventCategory=3&culture=en-US&CountryCode=USI recieve this error in my local system. An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Cou...

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not all #2
I get the following error and have been trying to figure out why I keep getting it.  Initially, I had placed my project under wwwroot folder and ran it under IIS and it gave this error.  Then I moved it to my local C drive and same thing.  I am sharing this project with two other co-workers and all our config files and code files are same...they don't get this error but I do.  I checked that SQL Server Client Network Utility has TCP/IP and the 'Named Pipes' enabled.  I thought maybe I have setting in the Visual Studio 2005 that I'm not aware of that&#...

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not all #3
An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, Hi  I think you are trying to connect with remote server using windows authentication mode.Sql won't allow this ,so try to connect with server using sql authentication mode with(username and password)Happy ProgrammingShashi.  Check if this thread on the same discussion can help.http://forums.asp.net/p/1193329/2062685.aspx...

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not all #6
hi there! I've uploaded my website at online server. which has its database on its local server. Now whenever Im trying to open the website. I get the following message instead of website. "An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) " Im using sql server 2000 for database. Asp.net 2.0 Please hel...

what's difference between Accesss DataBase and Sql Sever about Sql String(or Command),Sql StoreProcedure ?
i am being dirty to Access DataBase from Sql Sever Database for my new work.But the sql string of Access sounds like a little different,can i use  the sql string of SqlSever for Access database,too?another question is: Does Access DataBase support Sql StoreProcedure??? when i worked in Access2000 ,did not see any about StoreProcedure,but i download a file named AccessHelper.cs  , some function of it looks like support StoreProcedure,Does it?  i want to fly ... Hi dkzeng ,Your first question     The string of both sqlsever and acce...

Web resources about - All SELECT INTO's (inline SQL) causing SQL errors with PB11.5 (SQLOLEDB) on Vista/SQL 2000 - sybase.powerbuilder.connection

Resources last updated: 12/30/2015 1:36:23 AM