Thursday, March 29, 2012

error: identifier stored proc name is out of scope

Does anyone know what this error message is telling me.

Thanks in advance everyone.

RBCan you show us the code that is generating this error?

Terri|||Terri,

Public Shared Function GetSelectedFunds() As DataTable
'Dim GlobalConnString As String = System.Configuration.ConfigurationSettings.AppSettings("ConnectionString")
'Dim SelectedCenter As Integer = ddlCenters.SelectedItem.Value

Try

Return ExecuteDataset(SqlHelper.GlobalConnString, CommandType.StoredProcedure, "GetSelectedFOIFunds", New SqlParameter("@.ParentFund", Test.SelectedCenter)).Tables(0)

Catch Ex As Exception
Throw New ApplicationException("An error occurred while executing GetSelectedFunds", Ex)
End Try
End Function

Sub subCenterListChange(ByVal S As Object, ByVal E As EventArgs)

SelectedCenter = ddlCenters.SelectedItem.Value

ddlFOI.DataSource = GetSelectedFunds()
ddlFOI.DataBind()
End Sub

What i'm trying to do is once a user makes a selection on the first dropdown list then I want to fire off the second drop down list and fill it with a result set that is based on the first selection.

For some reason it is not firing off and it is saying the following:

''error: identifier 'stored procedure name' is out of scope'

Any help is appricated:

Thanks again

RB

Error: Heterogeneous queries require the ANSI_NULLS and ANSI_WARNINGS options

Hi,
SQLServer 2000, using an OPENDATASOURCE command within a stored procedure to
access data on another Server running 2000. I get the following error, whe
n I exececute the Stored Procedure in Query Analyzer:
Heterogeneous queries require the ANSI_NULLS and ANSI_WARNINGS options to be
set for the connection. This ensures consistent query semantics. Enable the
se options and then reissue your query.
Interestingly, when I issue the identicl select statement within Query Analy
zer, it works fine.
I tried issuing a "Set ANSI_NULLS OFF" etc commands prior, to no avail.
THanks for any help.
JimReview the information in BOL regarding "set ansi_nulls" - pay special
attention to the information about stored procedures. Then review the notes
for "create procedure" - it reiterates the previous point and adds some
additional information. Then - go fix your procedure. Note that using EM
to do this makes the process that much more difficult, since it tends to
hide important details (like this). Instead, use QA and a script to create
the procedure. Of course, you should be using scripts of some sort since
all code for the database (schema, stored procedures, UDFs, triggers, etc)
are as important to the entire system as your application code.
BTW - you want to set ansi_nulls ON, not OFF. Generally, something that is
"set" means it is set "on".|||Generally the error is due to needing to set the properties
when you create the stored procedure. Try recreating your
stored procedure using:
SET ANSI_NULLS ON
GO
SET ANSI_WARNINGS ON
GO
CREATE PROCEDURE YourStoredProc...etc.
-Sue
On Thu, 21 Sep 2006 14:58:30 -0700, "Jim Fox"
<jim.fox@.emailhdi.com> wrote:

>Hi,
>SQLServer 2000, using an OPENDATASOURCE command within a stored procedure t
o access data on another Server running 2000. I get the following error, wh
en I exececute the Stored Procedure in Query Analyzer:
>Heterogeneous queries require the ANSI_NULLS and ANSI_WARNINGS options to b
e set for the connection. This ensures consistent query semantics. Enable th
ese options and then reissue your query.
>Interestingly, when I issue the identicl select statement within Query Anal
yzer, it works fine.
>I tried issuing a "Set ANSI_NULLS OFF" etc commands prior, to no avail.
>THanks for any help.
>Jim|||Thanks - Much appreciated!
"Scott Morris" <bogus@.bogus.com> wrote in message
news:%23VbpjNk3GHA.5092@.TK2MSFTNGP04.phx.gbl...
> Review the information in BOL regarding "set ansi_nulls" - pay special
> attention to the information about stored procedures. Then review the
> notes for "create procedure" - it reiterates the previous point and adds
> some additional information. Then - go fix your procedure. Note that
> using EM to do this makes the process that much more difficult, since it
> tends to hide important details (like this). Instead, use QA and a script
> to create the procedure. Of course, you should be using scripts of some
> sort since all code for the database (schema, stored procedures, UDFs,
> triggers, etc) are as important to the entire system as your application
> code.
> BTW - you want to set ansi_nulls ON, not OFF. Generally, something that
> is "set" means it is set "on".
>|||Along these lines, I am calling a trigger that runs an
insert/update/delete on a linked server table, and am running into the
same issues. However, setting ANSI_NULLS or ANSI_WARNINGS in the
trigger itself does not help out at all...
I've been on the phone with MS all day, and am looking for a fresh
perspective...
My trigger is this:
CREATE TRIGGER opsCompany_Insert ON [dbo].[RM00101]
FOR INSERT
AS
SET ANSI_DEFAULTS ON
-- SET THE DB NAME / DO THIS FOR EACH COMPANY DB --
DECLARE @.CompanyDB CHAR(5)
SELECT @.CompanyDB = (SELECT 'TWO')
-- Set Company Number
DECLARE @.CompanyNumber CHAR(15)
SELECT @.CompanyNumber = (SELECT CUSTNMBR FROM INSERTED)
-- Set Company Name
DECLARE @.CompanyName CHAR(65)
SELECT @.CompanyName = (SELECT CUSTNAME FROM INSERTED)
-- Set Currency ID
DECLARE @.CurrencyID CHAR(15)
SELECT @.CurrencyID = (SELECT CURNCYID FROM INSERTED)
-- Set GovernmentID
DECLARE @.GovernmentID CHAR(25)
SELECT @.GovernmentID = (SELECT TXRGNNUM FROM INSERTED)
-- DEX_ROW_ID
DECLARE @.MstrID INT
SELECT @.MstrID = (SELECT DEX_ROW_ID FROM INSERTED)
-- Push to Cranberry
INSERT INTO SQLSVR.TESTDATA.dbo.Company (GPCompanyID, CompanyNumber,
CompanyName, CurrencyID, GovernmentID, CompanyDB, AddedBy, AddedOn)
VALUES (@.MstrID, @.CompanyNumber, @.CompanyName, @.CurrencyID,
@.GovernmentID, @.CompanyDB, user, getdate())
I can run the trigger fine to a local database, but to the linked
server, I get the same 'Heterogeneous' error... I ahve set it up from
QA with
SET ANSI_NULLS, ANSI_WARNINGS ON
GO
Create Trigger ...
And also setting it within the trigger right after 'AS'
However still no luck...
Any thoughts?
Thanks!
Jim Fox wrote:[vbcol=seagreen]
> Thanks - Much appreciated!
> "Scott Morris" <bogus@.bogus.com> wrote in message
> news:%23VbpjNk3GHA.5092@.TK2MSFTNGP04.phx.gbl...|||> Along these lines, I am calling a trigger that runs an
> insert/update/delete on a linked server table, and am running into the
> same issues. However, setting ANSI_NULLS or ANSI_WARNINGS in the
> trigger itself does not help out at all...
These are connection level settings - for the most part. Stored procedures
have their own wrinkle to this. Ultimately, the issue is the same. You
must use the appropriate connection-level settings for this architecture to
work. Ideally, your client application should be designed to enforce the
appropriate settings. If you can't do that, then the only other option
that I can see is to put your logic for accessing the remote DB into a
procedure. Your procedure must be created with the "sticky" settings that
are needed and can set the others that are needed within the body of the
procedure. I think that approach will work, but I've not investigated all
of the issues to know for certain. Note - your trigger code does not
support mult-row inserts, making the use of a stored procedure much easier
(and as technically flawed the trigger).
Some other alternatives you might want to consider.
* Some form of replication.
* Some form of asynchronous queueing of updates.sql

Error: Heterogeneous queries require the ANSI_NULLS and ANSI_WARNINGS options

Hi,
SQLServer 2000, using an OPENDATASOURCE command within a stored procedure to access data on another Server running 2000. I get the following error, when I exececute the Stored Procedure in Query Analyzer:
Heterogeneous queries require the ANSI_NULLS and ANSI_WARNINGS options to be set for the connection. This ensures consistent query semantics. Enable these options and then reissue your query.
Interestingly, when I issue the identicl select statement within Query Analyzer, it works fine.
I tried issuing a "Set ANSI_NULLS OFF" etc commands prior, to no avail.
THanks for any help.
Jim
Review the information in BOL regarding "set ansi_nulls" - pay special
attention to the information about stored procedures. Then review the notes
for "create procedure" - it reiterates the previous point and adds some
additional information. Then - go fix your procedure. Note that using EM
to do this makes the process that much more difficult, since it tends to
hide important details (like this). Instead, use QA and a script to create
the procedure. Of course, you should be using scripts of some sort since
all code for the database (schema, stored procedures, UDFs, triggers, etc)
are as important to the entire system as your application code.
BTW - you want to set ansi_nulls ON, not OFF. Generally, something that is
"set" means it is set "on".
|||Generally the error is due to needing to set the properties
when you create the stored procedure. Try recreating your
stored procedure using:
SET ANSI_NULLS ON
GO
SET ANSI_WARNINGS ON
GO
CREATE PROCEDURE YourStoredProc...etc.
-Sue
On Thu, 21 Sep 2006 14:58:30 -0700, "Jim Fox"
<jim.fox@.emailhdi.com> wrote:

>Hi,
>SQLServer 2000, using an OPENDATASOURCE command within a stored procedure to access data on another Server running 2000. I get the following error, when I exececute the Stored Procedure in Query Analyzer:
>Heterogeneous queries require the ANSI_NULLS and ANSI_WARNINGS options to be set for the connection. This ensures consistent query semantics. Enable these options and then reissue your query.
>Interestingly, when I issue the identicl select statement within Query Analyzer, it works fine.
>I tried issuing a "Set ANSI_NULLS OFF" etc commands prior, to no avail.
>THanks for any help.
>Jim
|||Thanks - Much appreciated!
"Scott Morris" <bogus@.bogus.com> wrote in message
news:%23VbpjNk3GHA.5092@.TK2MSFTNGP04.phx.gbl...
> Review the information in BOL regarding "set ansi_nulls" - pay special
> attention to the information about stored procedures. Then review the
> notes for "create procedure" - it reiterates the previous point and adds
> some additional information. Then - go fix your procedure. Note that
> using EM to do this makes the process that much more difficult, since it
> tends to hide important details (like this). Instead, use QA and a script
> to create the procedure. Of course, you should be using scripts of some
> sort since all code for the database (schema, stored procedures, UDFs,
> triggers, etc) are as important to the entire system as your application
> code.
> BTW - you want to set ansi_nulls ON, not OFF. Generally, something that
> is "set" means it is set "on".
>
|||Along these lines, I am calling a trigger that runs an
insert/update/delete on a linked server table, and am running into the
same issues. However, setting ANSI_NULLS or ANSI_WARNINGS in the
trigger itself does not help out at all...
I've been on the phone with MS all day, and am looking for a fresh
perspective...
My trigger is this:
CREATE TRIGGER opsCompany_Insert ON [dbo].[RM00101]
FOR INSERT
AS
SET ANSI_DEFAULTS ON
-- SET THE DB NAME / DO THIS FOR EACH COMPANY DB --
DECLARE @.CompanyDB CHAR(5)
SELECT @.CompanyDB = (SELECT 'TWO')
-- Set Company Number
DECLARE @.CompanyNumber CHAR(15)
SELECT @.CompanyNumber = (SELECT CUSTNMBR FROM INSERTED)
-- Set Company Name
DECLARE @.CompanyName CHAR(65)
SELECT @.CompanyName = (SELECT CUSTNAME FROM INSERTED)
-- Set Currency ID
DECLARE @.CurrencyID CHAR(15)
SELECT @.CurrencyID = (SELECT CURNCYID FROM INSERTED)
-- Set GovernmentID
DECLARE @.GovernmentID CHAR(25)
SELECT @.GovernmentID = (SELECT TXRGNNUM FROM INSERTED)
-- DEX_ROW_ID
DECLARE @.MstrID INT
SELECT @.MstrID = (SELECT DEX_ROW_ID FROM INSERTED)
-- Push to Cranberry
INSERT INTO SQLSVR.TESTDATA.dbo.Company (GPCompanyID, CompanyNumber,
CompanyName, CurrencyID, GovernmentID, CompanyDB, AddedBy, AddedOn)
VALUES (@.MstrID, @.CompanyNumber, @.CompanyName, @.CurrencyID,
@.GovernmentID, @.CompanyDB, user, getdate())
I can run the trigger fine to a local database, but to the linked
server, I get the same 'Heterogeneous' error... I ahve set it up from
QA with
SET ANSI_NULLS, ANSI_WARNINGS ON
GO
Create Trigger ...
And also setting it within the trigger right after 'AS'
However still no luck...
Any thoughts?
Thanks!
Jim Fox wrote:[vbcol=seagreen]
> Thanks - Much appreciated!
> "Scott Morris" <bogus@.bogus.com> wrote in message
> news:%23VbpjNk3GHA.5092@.TK2MSFTNGP04.phx.gbl...
|||> Along these lines, I am calling a trigger that runs an
> insert/update/delete on a linked server table, and am running into the
> same issues. However, setting ANSI_NULLS or ANSI_WARNINGS in the
> trigger itself does not help out at all...
These are connection level settings - for the most part. Stored procedures
have their own wrinkle to this. Ultimately, the issue is the same. You
must use the appropriate connection-level settings for this architecture to
work. Ideally, your client application should be designed to enforce the
appropriate settings. If you can't do that, then the only other option
that I can see is to put your logic for accessing the remote DB into a
procedure. Your procedure must be created with the "sticky" settings that
are needed and can set the others that are needed within the body of the
procedure. I think that approach will work, but I've not investigated all
of the issues to know for certain. Note - your trigger code does not
support mult-row inserts, making the use of a stored procedure much easier
(and as technically flawed the trigger).
Some other alternatives you might want to consider.
* Some form of replication.
* Some form of asynchronous queueing of updates.

Error: Generating Instances in SQL Server is disabled...

Use sp_configure 'user instances enabled' to generate user instances.

I get the above error when I attempt to add an SQL Database item into my VS (C#) project. I do not understand what needs to be done to correct the problem.

Any help is appreciated.

Thank You,

Klaus

From SQL Server 2005 Books Onlinetopic:

user instances enabled Option

http://msdn2.microsoft.com/en-us/library/ms187513.aspx

The user instance enabled option that you can access through sp_configure is not supported in Microsoft SQL Server 2005. This option works only with SQL Server 2005 Express Edition (SQL Server Express).

For more information about how user instances work, see User Instances for Non-Administrators.

User Instances for Non-Administrators

http://msdn2.microsoft.com/en-us/library/ms143684.aspx

Error: Forward dependencies are not valid

I want to set a Report Parameter on a field. The Report Parameter is called 'filter'. In the statement I put the Report Parameter in the WHERE-part:
WHERE ([DatabaseName$TableName].[FieldName] = @.filter). After this I set the 'Available values' on the Report Parameter in the lay-out to Non-queried.
When the report is running, no problems.

But.....

Now I want to set 'Available values' on 'From Query' and refer to the data set, so the user can choose on which value he want to filter. But now, after running the preview the following error displays:
Error1[rsInvalidReportParameterDependency]The report parameter ‘filter’ has a DefaultValue or a ValidValue that depends on the report parameter “filter”. Forward dependencies are not valid.

Why can't I set the Report Parameter to 'From Query'? Anyone any suggestions?

(you can see the rest of my statement here: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1098540&SiteID=1)

Thx a lot of helping me out with this topic.....

Hi,

If I get it right, you have a dataset that you want to filter by a parameter 'FILTER' and the possible values for the filter also from the same dataset?

This is not possible since if you are requesting the possible values for the filter he will execute the query in the dataset. Since this dataset requires a parameter filter to be able to execute, you are having a loop.

What you should do is to make the 'From Query' property refer to a different dataset.

NOTE: Reporting Services first performs the queries in the same order as the Parameters have been set. Therefor, if the dataset of a given parameter needs the value of a second parameter, you need to make sure that this second parameter is standing above the first parameter in the parameter list.

Greetz,

Geert

Geert Verhoeven
Consultant @. Ausy Belgium

My Personal Blog

|||

Geert,

thx for your support. I've found a solution for my specific situation. I will drop it here for others with the same problem:

1. Report Parameter, Available non-queried.
- At Label I've filled in the options that I want to see in the pulldown menu.
- At Value I've filled in the values form my table (in this case only 4 or 5)
2. At the table properties, tab filtering I've made a filterlist called
- expression: =Fields!FieldName.Value
- operator: '='
- value : =Parameters!ParameterName.Value

This solution is only usefull if you don't have too much options to choose (because you have to fill in all the options manually..... )

Error: File /iisHelp/common/500-100.asp Line 0 Out of memory.

Hi
i am getting the this error now a days. can help me out
because my IIS server geting very slow & also i have to
restart the IIS Server every time also when this DLHOST
coming that time My IIS server get Problem.
can help me out & give us what could be the problem it is
very urg for us i am facing very Big problem
here i am sending the error Log from eventViewr
Error: File /iisHelp/common/500-100.asp Line 0 Out of
memory. Unable to allocate required memory..
For additional information specific to this message please
visit the Microsoft Online Support site located at:
http://www.microsoft.com/contentredirect.asp.What does this have to do with SQL Server?
--
http://www.aspfaq.com/
(Reverse address to reply.)
"sanjaypawar@.hotmail.com" <anonymous@.discussions.microsoft.com> wrote in
message news:731e01c47641$2a233a00$a401280a@.phx.gbl...
> Hi
> i am getting the this error now a days. can help me out
> because my IIS server geting very slow & also i have to
> restart the IIS Server every time also when this DLHOST
> coming that time My IIS server get Problem.
> can help me out & give us what could be the problem it is
> very urg for us i am facing very Big problem
> here i am sending the error Log from eventViewr
>
> Error: File /iisHelp/common/500-100.asp Line 0 Out of
> memory. Unable to allocate required memory..
> For additional information specific to this message please
> visit the Microsoft Online Support site located at:
> http://www.microsoft.com/contentredirect.asp.sql

Error: File /iisHelp/common/500-100.asp Line 0 Out of memory.

Hi
i am getting the this error now a days. can help me out
because my IIS server geting very slow & also i have to
restart the IIS Server every time also when this DLHOST
coming that time My IIS server get Problem.
can help me out & give us what could be the problem it is
very urg for us i am facing very Big problem
here i am sending the error Log from eventViewr
Error: File /iisHelp/common/500-100.asp Line 0 Out of
memory. Unable to allocate required memory..
For additional information specific to this message please
visit the Microsoft Online Support site located at:
http://www.microsoft.com/contentredirect.asp.What does this have to do with SQL Server?
http://www.aspfaq.com/
(Reverse address to reply.)
"sanjaypawar@.hotmail.com" <anonymous@.discussions.microsoft.com> wrote in
message news:731e01c47641$2a233a00$a401280a@.phx.gbl...
> Hi
> i am getting the this error now a days. can help me out
> because my IIS server geting very slow & also i have to
> restart the IIS Server every time also when this DLHOST
> coming that time My IIS server get Problem.
> can help me out & give us what could be the problem it is
> very urg for us i am facing very Big problem
> here i am sending the error Log from eventViewr
>
> Error: File /iisHelp/common/500-100.asp Line 0 Out of
> memory. Unable to allocate required memory..
> For additional information specific to this message please
> visit the Microsoft Online Support site located at:
> http://www.microsoft.com/contentredirect.asp.

Error: File /iisHelp/common/500-100.asp Line 0 Out of memory.

Hi
i am getting the this error now a days. can help me out
because my IIS server geting very slow & also i have to
restart the IIS Server every time also when this DLHOST
coming that time My IIS server get Problem.
can help me out & give us what could be the problem it is
very urg for us i am facing very Big problem
here i am sending the error Log from eventViewr
Error: File /iisHelp/common/500-100.asp Line 0 Out of
memory. Unable to allocate required memory..
For additional information specific to this message please
visit the Microsoft Online Support site located at:
http://www.microsoft.com/contentredirect.asp.
What does this have to do with SQL Server?
http://www.aspfaq.com/
(Reverse address to reply.)
"sanjaypawar@.hotmail.com" <anonymous@.discussions.microsoft.com> wrote in
message news:731e01c47641$2a233a00$a401280a@.phx.gbl...
> Hi
> i am getting the this error now a days. can help me out
> because my IIS server geting very slow & also i have to
> restart the IIS Server every time also when this DLHOST
> coming that time My IIS server get Problem.
> can help me out & give us what could be the problem it is
> very urg for us i am facing very Big problem
> here i am sending the error Log from eventViewr
>
> Error: File /iisHelp/common/500-100.asp Line 0 Out of
> memory. Unable to allocate required memory..
> For additional information specific to this message please
> visit the Microsoft Online Support site located at:
> http://www.microsoft.com/contentredirect.asp.

Error: fcb::close-flush: Operating system error 21(The device is not ready.) encountered

We are using sql server 2005 Enterprise Edition with service pack1

I got the following error messages in the SQL log

    The operating system returned error 21(The device is not ready.) to SQL Server during a read at offset 0x00000000090000 in file '....mdf'. Additional messages in the SQL Server error log and system event log may provide more detail. This is a severe system-level error condition that threatens database integrity and must be corrected immediately. Complete a full database consistency check (DBCC CHECKDB). This error can be caused by many factors; for more information, see SQL Server Books Online. fcb::close-flush: Operating system error 21(The device is not ready.) encountered.

I got these errors for about 2 hrs and after that I see these messages in the sql log

Starting up database ' ' 1 transactions rolled forward in database '' (). This is an informational message only. No user action is required. 0 transactions rolled back in database ' ' (). This is an informational message only. No user action is required. Recovery is writing a checkpoint in database ' ' ( ). This is an informational message only. No user action is required. CHECKDB for database '' finished without errors on (local time). This is an informational message only; no user action is required.

Can anyone please help me in troubleshooting this issue. Why this migh have happened.

any help would be appreciated.

Thanks

This sounds like an IO subsystem issue, i.e. SQL Server is having difficulty talking to one of your drives. Are you using direct attached storage or a SAN?|||

Thanks for the reply. We have Netapp SCSI disk storage. Could you please tell me how do I troubleshoot this so that I wont get such errors in future.

Thanks

|||Based on this and what you describe in your other post, you really ought to give Microsoft PSS a call.|||

Do read this kb before contacting PSS. You might be running on an unsupported device.

http://support.microsoft.com/kb/304261

ERROR: Failure to compile WMI file

I received this error at the end of the "Reporting Services" setup.

I checked WMI process in Services and everything is OK, it's running.

So far I was able to install Designer Tools only (unchecking Report Manager and Report server).

All system components are up to date and SQL Server SP3 is installed.

I would highly appreciate it if somebody could help me out. It's now matter of survival to me.

Thanks in advance,

Confused Virginian

You also need SP3a to install Reporting Services. Hope this helps.|||

Caddre,

Thank you for your help. I already have SP3 installed.

Eventually I found the fix, right there:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/reinstalling_wmi.asp

This article explains how to recreate corrupted WMI repository.

Virginian

Error: Failed to load script task

I have an email script that keeps failing to load when I execute my script task. I have the precompileintobinarycode set to true. Anyone know why it won't load the script? I would use the Send Mail task but it can't find my smtp connection or something.

Thanks,

Mike

This error can spontaneously appear for no apparent reason. It seems that if you have the PreCompile property set to True, but you have precompiled script in the package, which is what spontaneously disappears, this error will be raised. To resolve this issue:

a. Open the package

b. Open the Script Task editor

c. Click Design Script

d. Close the VSA Editor

e. Close the Script Task Editor

f. Save and close the package.

|||

didn't work I still get the same error.

sql

Error: Failed to load script task

I have an email script that keeps failing to load when I execute my script task. I have the precompileintobinarycode set to true. Anyone know why it won't load the script? I would use the Send Mail task but it can't find my smtp connection or something.

Thanks,

Mike

This error can spontaneously appear for no apparent reason. It seems that if you have the PreCompile property set to True, but you have precompiled script in the package, which is what spontaneously disappears, this error will be raised. To resolve this issue:

a. Open the package

b. Open the Script Task editor

c. Click Design Script

d. Close the VSA Editor

e. Close the Script Task Editor

f. Save and close the package.

|||

didn't work I still get the same error.

Error: Failed to generate a user instance...

Hello,

When trying to add a new SQL database to a VS 2005 project I get this error:

Failed to generate a user instance of SQL server due to a failure in starting the process for the user instance. The connection will be closed. [CLIENT: <local machine>]

Any ideas what is causing this error and how to fix it?

Thanks

Tom

Hi Tom,

This question has been discussed several times in this forum, you should do a search and read other discussions to see if they address your issue.

The first step in troubleshooting this is to look at the User Instance error log located at C:\Documents and Settings\<user>\Local Settings\Application Data\Microsoft\Microsoft SQL Server Data\<main instance name> (The default instance name is SQLEXPRESS) and see if it give any clues to the cause of the error.

Regards,

Mike Wachal
SQL Express team

-
Please mark your thread as Answered when you get your solution.

Error: Expected End of Statement

I just don't see it (SSRS 2005 Expression Syntax Error):

=((Fields!PostedAmount_InHouse.Value + Fields!NewPDs_Check.Value + Fields!NewCCs_Check.Value) / Fields!CurrentPostingDay.Value) * (Fields!TotalPostingDays.Value - Fields!CurrentPostingDay.Value) + (Fields!PostedAmount_InHouse.Value + Fields!OldPDs_Check.Value + Fields!NewPDs_Check.Value + Fields!OldCCs_Check.Value + Fields!NewCCs_Check.Value) * Fields!FeeSchedule.Value)) / 100

Error: Expected End of Statement

4( + 6) = Error: Expected Endof Statement

Error: Event id: 208 @ Copy Database Wizard

Can anyone help me?

When i Use the copy database wizard @.sql 2005 at the last step

i get these 2 Error's in the log's

Event Type: Warning
Event Source: SQLSERVERAGENT
Event Category: Job Engine
Event ID: 208
Date: 14-8-2006
Time: 13:28:40
User: N/A
Computer: SERVER01

Description:
SQL Server Scheduled Job 'CDW_NAME_0' (0x883C948F64FCAA49BEA22068F4C7E15A) - Status: Failed - Invoked on: 2006-08-14 13:28:19 - Message: The job failed. The Job was invoked by User Domain\Administrator. The last step to run was step 1 (CDW_NAME_0_Step).

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.


Event Type: Error
Event Source: SQLISPackage
Event Category: None
Event ID: 12291
Date: 14-8-2006
Time: 13:28:40
User: Domain\Administrator
Computer: SERVER01
Description:
Package "CDW_NAME_0" failed.

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

I have the same error on SQL 2005 enterprise, am trying to copy a 2000 database into 2005. Should work but fails on copy.|||

I'm moving this over to the tools forum since they have more experience with CDW.

Thanks,
Sam

|||DID YOU FIND ANYTHING ON THIS PROBLEM|||

what is the service pack on this box. You should apply SP2 and also check whether SSIS (Integration Service) is installed or not

Madhu

|||THERE IS SP2 AND THE INTEGRATION SERVICE IS STARTED AS ADMNISTRATOR

Error: Event id: 208 @ Copy Database Wizard

Can anyone help me?

When i Use the copy database wizard @.sql 2005 at the last step

i get these 2 Error's in the log's

Event Type: Warning
Event Source: SQLSERVERAGENT
Event Category: Job Engine
Event ID: 208
Date: 14-8-2006
Time: 13:28:40
User: N/A
Computer: SERVER01

Description:
SQL Server Scheduled Job 'CDW_NAME_0' (0x883C948F64FCAA49BEA22068F4C7E15A) - Status: Failed - Invoked on: 2006-08-14 13:28:19 - Message: The job failed. The Job was invoked by User Domain\Administrator. The last step to run was step 1 (CDW_NAME_0_Step).

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.


Event Type: Error
Event Source: SQLISPackage
Event Category: None
Event ID: 12291
Date: 14-8-2006
Time: 13:28:40
User: Domain\Administrator
Computer: SERVER01
Description:
Package "CDW_NAME_0" failed.

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

I have the same error on SQL 2005 enterprise, am trying to copy a 2000 database into 2005. Should work but fails on copy.|||

I'm moving this over to the tools forum since they have more experience with CDW.

Thanks,
Sam

|||DID YOU FIND ANYTHING ON THIS PROBLEM|||

what is the service pack on this box. You should apply SP2 and also check whether SSIS (Integration Service) is installed or not

Madhu

|||THERE IS SP2 AND THE INTEGRATION SERVICE IS STARTED AS ADMNISTRATORsql

Error: Email Subscription to Report (Sharepoint Integrated Mode) Options

I encounter this error when user try to subscribe using email delivery
to one of the report. I have configured the Reporting Services to use
Sharepoint integrated mode. This user is a regular user that has read
access to the report item.

Below is the message detail:

A subscription delivery error has occurred. (rsDeliveryError)
A subscription delivery error has occurred. (rsDeliveryError)
One of the extension parameters is not valid for the following reason:
The account you are using does not have administrator privileges. A
subscription cannot be created for [emailaddress].
(rsInvalidExtensionParameter)

Is it true that user needs to have administrator privilege in order to
subscribe for report? I don't think so, right?

Regards,
Gunady Ng

Hi Gunady,

Non-admin users can only send a report to an email address that is specified in the SharePoint user profile for that user. Can you check the "TO" field and ensure that the email address is that of the user as seen in the SharePoint user profile?

Thanks,

Sharmila

|||

Thank you for the answer. Is this restriction apply to cc or bcc as well?

Regards,

Gunady Ng

|||

Yes, it applies to all.

Thanks,
Sharmila

|||

is there a way around this?

Is there a way to setup on per-report basis?

I'm using reporting services within sharepoint as a content delivery solution, I need teh users to be able ost chedule reports and have them delivered by email to thair sharpoint drop box and/or to their customers staright from teh subscripton interface

I'm able to do this as admin but I need teh users to be able to do the same

I tried looking in the rsreportsever.config but can not figure out how to do this, I set <sendemailtouseralias>False but still nothing,

I also dont have the otion for CC: or BCC: when I'm loged in with nonadministrative account.

There must be an option for this but I'm not finding it in any documentation

I'm running Reporting Services SP2 in WSS3 integrated mode

Please advice and help...

Thanks

Nik

Error: Email Subscription to Report (Sharepoint Integrated Mode) Options

I encounter this error when user try to subscribe using email delivery
to one of the report. I have configured the Reporting Services to use
Sharepoint integrated mode. This user is a regular user that has read
access to the report item.

Below is the message detail:

A subscription delivery error has occurred. (rsDeliveryError)
A subscription delivery error has occurred. (rsDeliveryError)
One of the extension parameters is not valid for the following reason:
The account you are using does not have administrator privileges. A
subscription cannot be created for [emailaddress].
(rsInvalidExtensionParameter)

Is it true that user needs to have administrator privilege in order to
subscribe for report? I don't think so, right?

Regards,
Gunady Ng

Hi Gunady,

Non-admin users can only send a report to an email address that is specified in the SharePoint user profile for that user. Can you check the "TO" field and ensure that the email address is that of the user as seen in the SharePoint user profile?

Thanks,

Sharmila

|||

Thank you for the answer. Is this restriction apply to cc or bcc as well?

Regards,

Gunady Ng

|||

Yes, it applies to all.

Thanks,
Sharmila

|||

is there a way around this?

Is there a way to setup on per-report basis?

I'm using reporting services within sharepoint as a content delivery solution, I need teh users to be able ost chedule reports and have them delivered by email to thair sharpoint drop box and/or to their customers staright from teh subscripton interface

I'm able to do this as admin but I need teh users to be able to do the same

I tried looking in the rsreportsever.config but can not figure out how to do this, I set <sendemailtouseralias>False but still nothing,

I also dont have the otion for CC: or BCC: when I'm loged in with nonadministrative account.

There must be an option for this but I'm not finding it in any documentation

I'm running Reporting Services SP2 in WSS3 integrated mode

Please advice and help...

Thanks

Nik

Error: Email Subscription to Report (Sharepoint Integrated Mode) Options

I encounter this error when user try to subscribe using email delivery
to one of the report. I have configured the Reporting Services to use
Sharepoint integrated mode. This user is a regular user that has read
access to the report item.

Below is the message detail:

A subscription delivery error has occurred. (rsDeliveryError)
A subscription delivery error has occurred. (rsDeliveryError)
One of the extension parameters is not valid for the following reason:
The account you are using does not have administrator privileges. A
subscription cannot be created for [emailaddress].
(rsInvalidExtensionParameter)

Is it true that user needs to have administrator privilege in order to
subscribe for report? I don't think so, right?

Regards,
Gunady Ng

Hi Gunady,

Non-admin users can only send a report to an email address that is specified in the SharePoint user profile for that user. Can you check the "TO" field and ensure that the email address is that of the user as seen in the SharePoint user profile?

Thanks,

Sharmila

|||

Thank you for the answer. Is this restriction apply to cc or bcc as well?

Regards,

Gunady Ng

|||

Yes, it applies to all.

Thanks,
Sharmila

|||

is there a way around this?

Is there a way to setup on per-report basis?

I'm using reporting services within sharepoint as a content delivery solution, I need teh users to be able ost chedule reports and have them delivered by email to thair sharpoint drop box and/or to their customers staright from teh subscripton interface

I'm able to do this as admin but I need teh users to be able to do the same

I tried looking in the rsreportsever.config but can not figure out how to do this, I set <sendemailtouseralias>False but still nothing,

I also dont have the otion for CC: or BCC: when I'm loged in with nonadministrative account.

There must be an option for this but I'm not finding it in any documentation

I'm running Reporting Services SP2 in WSS3 integrated mode

Please advice and help...

Thanks

Nik

Error: duplicate key row

What might cause the following error when inserting rows in tables that have primary keys defined as IDENTITY (1,1)?

duplicate key row in object 'aa' with unique index 'aa'

I have seen this happen frequently when data has been bulk loaded sometime in the past into a table that has an IDENTITY key. This is especially common when you have a test environment in which some production data was bulk loaded to give some "good test data." To me it means that an identity number has "already been used" as a record key.


Dave

|||The rows are inserted one at a time using the parent IDENTITY key as a FK constraint in the child table which also has an IDENTITY KEY. However, this scenario does not sound like it would cause an error.|||

Can you post the table structures? That would help us to see what your problem might be.

If you can post a few statements that cause the duplicates, that would even be better.

|||

If you have the property NOT FOR REPLICATION enabled for the identity column.

Merging changes would allow the exact id values to be inserted rather than a new value that would give the error if same id value exists in the participating server.

similarly, if you are trying to insert manually using SET IDENTITY_INSERT table ON...

error: 'Dts' does not exist in the namespace 'Microsoft.Sqlserver'

I tried to create a package from a C# program, and I copied this from SQL server online book:

using Microsoft.Sqlserver.Dts.Runtime;

But I got compilation error:
The type or namespace name 'Dts' does not exist in the namespace 'Microsoft.Sqlserver'(are you missing an asssembly reference?)
What am I missing?

Thanks a lot

Have you, in fact, set a reference to Microsoft.SqlServer.ManagedDTS ? This is the assembly that contains the Dts.Runtime namespace.

-Doug
|||How do I set a reference to ManagedDTS? by writting:
using Microsoft.SqlServer.ManagedDTS
?

In this case ManagedDTS can not be found by compiler

Thanks for the hint
|||Please consult the Books Online for support. For example, the following article mentions what DLLs need to be registered:

ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/dtsref9/html/e44bcc70-32d3-43e8-a84b-29aef819d5d3.htm
regards,
ash|||found the solution: from visual studio, click Project->Add reference, then browse the assembly ManagedDTS.dll at directory c:\program files\microsoft sql server\90\SDK\Assemblies, this willl add ManagedDTS.dll to the project and solve the problem.

Thanks everyone!|||

Hello,

if you get this problem on your server. build your site in release mode and then you have this dll in your bin\release folder.

Either find this DLL and upload that in your server bin directory manually

error: 'Dts' does not exist in the namespace 'Microsoft.Sqlserver'

I tried to create a package from a C# program, and I copied this from SQL server online book:

using Microsoft.Sqlserver.Dts.Runtime;

But I got compilation error:
The type or namespace name 'Dts' does not exist in the namespace 'Microsoft.Sqlserver'(are you missing an asssembly reference?)
What am I missing?

Thanks a lotHave you, in fact, set a reference to Microsoft.SqlServer.ManagedDTS ? This is the assembly that contains the Dts.Runtime namespace.

-Doug|||How do I set a reference to ManagedDTS? by writting:
using Microsoft.SqlServer.ManagedDTS
?

In this case ManagedDTS can not be found by compiler

Thanks for the hint|||Please consult the Books Online for support. For example, the following article mentions what DLLs need to be registered:

ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/dtsref9/html/e44bcc70-32d3-43e8-a84b-29aef819d5d3.htm
regards,
ash|||found the solution: from visual studio, click Project->Add reference, then browse the assembly ManagedDTS.dll at directory c:\program files\microsoft sql server\90\SDK\Assemblies, this willl add ManagedDTS.dll to the project and solve the problem.

Thanks everyone!|||

Hello,

if you get this problem on your server. build your site in release mode and then you have this dll in your bin\release folder.

Either find this DLL and upload that in your server bin directory manually

Error: Decision Trees found no splits for model

Hi,

I am trying to run one of the mining models from the book "Delivering BI using SQl Server 2005" but I am running into "Decision Trees found no splits for model". The mining structure has 4 columns, the fourth one being marked as "Predict Only". My Cube slice for the model has sufficient data in the cube. I am lost.. Help!!

Regards

I'm not familiar with the DM section of that book. Could you give more descriptions of the data and the problem? What does the root node of the tree look like? Are you predicting a continuous or discrete value? Etc.

If you want to see the data the data mining is using, turn Drillthrough on for the model and then do

SELECT * FROM <model name>.CASES

To see the cases that were used for training the model. If this shows anything odd, you may see what's wrong.

|||

The mining model was created using Customer Dimension and Sales Fact. Following are the details of the mining model

Data Mining Technique: Microsoft Decision Trees
Dimension: Customer
Case Key: Customer.CustomerName
Attributes Used: Gender, Num Of Cars Owned, Num of Childer at home
Mining Model Column Usage: All the above columns except Num of Childeren at Home are Input and Num of Childeren at Home is defined as Predicatble only
Content and Data Type: All the above three columns are defined as discrete and text

Please note that I am new to DM stuff and I might have missed something obvoious. From what I see, when I try to explore the mining model viewer in BI studio, I see only 2 levels and histogram only shows two values, "Missing" and the "", the later having all the values. Ideally, it should have the customer in the root, then split to Gender and then to Num Of Cars Owned. "The num of children at home" should have come fromthe mining prediction.

Thanks for your reply.

|||

When you create the mining model, select the Allow Drillthrough option on the final page of the data mining wizard. When you view the model, right click on the root node and select "Drillthrough". This will show you the data that was used to train the model. It seems that the data that is being used for your model likely isn't the same as was in the book. I am unfamiliar with the book, but if you browse the data and see that maybe Num Children doesn't have the values you expect, it may show you why the model doesn't look like the book's.

You may try e-mailing the book's author as well.

HTH

sql

Error: Data source name not found and No default driver specified

Hello all,
I have an application which was written in VB6. I used
DSNless connection for the odbc connection to access sql 8.0. The
application works fine on one machine and when I try to run the appl.
on another machine I got this error. Any idea why' Here is my
connection string:
DSNName = "Driver={SQL Server};" & _
"Server=dummy;" & _
"Database=sql_data;" & _
"Uid=crystal"
The user id does not require a password.. Thank you.
SherryThis is a question for a VB group, not a SQL server group, but it sounds
like your DSNName is empty. Are you getting this value from an INI file,
the registry, or is it hardcoded in your app? You will most likely find
that this value is missing, wherever you define it.
Put in a message box that shows DSNName just prior to creating the
connection, and confirm that it is actually populated (I don't think it is).
<sunpalozzi@.gmail.com> wrote in message
news:1138811193.427214.282490@.g43g2000cwa.googlegroups.com...
> Hello all,
> I have an application which was written in VB6. I used
> DSNless connection for the odbc connection to access sql 8.0. The
> application works fine on one machine and when I try to run the appl.
> on another machine I got this error. Any idea why' Here is my
> connection string:
> DSNName = "Driver={SQL Server};" & _
> "Server=dummy;" & _
> "Database=sql_data;" & _
> "Uid=crystal"
> The user id does not require a password.. Thank you.
> Sherry
>|||Maybe the other machine doesn't have MDAC installed?
http://www.aspfaq.com/2057
Once you have the most recent version installed, an OLEDB connection string
will be better in most cases:
ConnectionString = _
"Provider=SQLOLEDB.1; " & _
"Data Source=dummy; " & _
"Initial Catalog=sql_data; " & _
"User ID=crystal; " & _
"Password="
<sunpalozzi@.gmail.com> wrote in message
news:1138811193.427214.282490@.g43g2000cwa.googlegroups.com...
> Hello all,
> I have an application which was written in VB6. I used
> DSNless connection for the odbc connection to access sql 8.0. The
> application works fine on one machine and when I try to run the appl.
> on another machine I got this error. Any idea why' Here is my
> connection string:
> DSNName = "Driver={SQL Server};" & _
> "Server=dummy;" & _
> "Database=sql_data;" & _
> "Uid=crystal"
> The user id does not require a password.. Thank you.
> Sherry
>|||thank you for all replies.. I did post in the vb group as well.. The
wire part is the same application is work on one pc but not the
another... I will try to find out if there a MDAC install on the
problem pc.. thanks.
Sherry

Error: Data Mining message

This may well be embarrasingly simple but....

I get this massage from Management Studion when I try to run any MDX

Error (Data mining): Either the user, LEONARD\Will Riley, does not have permission to access the referenced mining model, Contribution_Interest, or the object does not exist.

Is there something really simple I have missed?

Most likely you made syntax error in your MDX up tp a degree that it actually looks more like DMX than MDX, so AS tries to find mining model instead of cube. If you will paste your MDX statement, the forum should be able to help and fix it.|||

Yep, you got it

Once I plugged in what I knew to be some correctly structured MDX, the issue went away.

Cheers, Will

error: Cursor not returned from query

I'm a really beginner about sql2000.
During my test I have created the following query. It's works ok until I
do't add the code included in section A, when I add it the i obtain the
error: Cursor not returned from query

Anyone can help me?

Thanks Carlo M.

set nocount on

IF OBJECT_ID('storico_big') IS NULL -- section A begin
create table storico_big( data datetime,
bcarrier varchar(20),
bda CHAR(30),
bzone char(50),
bdur int) ;
insert into storico_big -- section A
end

select top 10000
adetdate,bcarrier,bda,bzone,bdur
from pp_cdr (nolock)
where
adetdate < :data_fin and adetdate > :data_in order by adetdate
set nocount off

-- end of queryIW2FIV (carlo.merlini[NONROMPERE]@.libero.it) writes:
> I'm a really beginner about sql2000.
> During my test I have created the following query. It's works ok until I
> do't add the code included in section A, when I add it the i obtain the
> error: Cursor not returned from query

Apparently you are using some environment unknown to me. At least I
don't recognize the message.

> IF OBJECT_ID('storico_big') IS NULL -- section A begin
> create table storico_big( data datetime,
> bcarrier varchar(20),
> bda CHAR(30),
> bzone char(50),
> bdur int) ;
> insert into storico_big -- section A
> end

Since there are several apparent syntax errors here, it would have been nice
if you environment had returned the errors from SQL Server, rather than
bitching about the missing cursor.

It can be a good to run the query from Query Analyzer to get better
error diagnostics.

I don't really want to suggest a correction, because I can't understand
what you are trying to do. It appears that in the same batch that you first
want to create a table, insert into it, and then select data from another
table.

Possibly you want to insert the data from the SELECT statement into
storico_big, but in such case you should

1) get rid of that extraneous end
2) add an explicit column list to the INSERT statement.

However, I have a feeling that if you insert data into the table, the
client environment will still complain about a missing cursor...

--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx|||Erland Sommarskog wrote:
> IW2FIV (carlo.merlini[NONROMPERE]@.libero.it) writes:
> > I'm a really beginner about sql2000.
> > During my test I have created the following query. It's works ok until I
> > do't add the code included in section A, when I add it the i obtain the
> > error: Cursor not returned from query
> Apparently you are using some environment unknown to me. At least I
> don't recognize the message.
I would suspect that it's some data layer (such as ADO, ADO.NET, DAO,
etc), which has at least two different methods of performing work in
the database - one for performing data retrieval and another (possibly
on another object, if the layer is object oriented) which allows data
manipulation.

For instance, ADO.NET has ExecuteReader and ExecuteNonQuery methods on
it's command object.

Damien|||Damien (Damien_The_Unbeliever@.hotmail.com) writes:
> I would suspect that it's some data layer (such as ADO, ADO.NET, DAO,
> etc), which has at least two different methods of performing work in
> the database - one for performing data retrieval and another (possibly
> on another object, if the layer is object oriented) which allows data
> manipulation.
> For instance, ADO.NET has ExecuteReader and ExecuteNonQuery methods on
> it's command object.

Obviously IWZFIV is not using ADO .Net. ADO .Net does work with cursors
at all, as far as a I know. A more substantial clue is the condition:

adetdate < :data_fin and adetdate > :data_in order by adetdate

Apparently IWZFIV is using some form of embedded SQL.

Anyway, I would not really describe ADO .Net as providing different methods
for different purposes. If all you want is minimalism, you can do every-
thing with ExecuteReader. The other methods, ExecuteNonQuery, ExecuteScalar
and DataAdapter.Fill can be seen as convenience methods implemented on
top of ExecuteReader. (OK, this is not really true. There are some
fine differences when there are multiple error messages and result sets
interleaved.)
--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx

Error: CrystalDecisions.CrystalReports.Engine.FormulaException: Error in File C:\DOCUME~1\

Hello,

I am having a crystal report using datastored in a dataset. When I select one of items in a dropdownlist, it gives me this error message. Note that I used that code before in another web page using a different crystal report and a different dataSet and it worked successfully, but this time it doesn't work...anyone can tell me what causes this error and how to solve it?

NOTE: I am using a vb code behind in my .aspx page

Error in File C:\DOCUME~1\AM-TK-~1\ASPNET\LOCALS~1\Temp\temp_03ca344b-568e-4ea1-bea8-94f3ef92bbcd.rpt: Error in formula <Record_Selection>. '{StProd2.ItemDescription}' The result of selection formula must be a boolean.

Description:An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details:CrystalDecisions.CrystalReports.Engine.FormulaException: Error in File C:\DOCUME~1\AM-TK-~1\ASPNET\LOCALS~1\Temp\temp_03ca344b-568e-4ea1-bea8-94f3ef92bbcd.rpt: Error in formula <Record_Selection>. '{StProd2.ItemDescription}' The result of selection formula must be a boolean.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


Stack Trace:

[FormulaException: Error in File C:\DOCUME~1\AM-TK-~1\ASPNET\LOCALS~1\Temp\temp_03ca344b-568e-4ea1-bea8-94f3ef92bbcd.rpt:Error in formula <Record_Selection>. '{StProd2.ItemDescription}'The result of selection formula must be a boolean.]  . F(String  , EngineExceptionErrorID  )  . A(Int16   , Int32   )  . @.(Int16  ) CrystalDecisions.CrystalReports.Engine.FormatEngine.GetPage(PageRequestContext reqContext) CrystalDecisions.ReportSource.LocalReportSourceBase.GetPage(PageRequestContext pageReqContext) CrystalDecisions.Web.ReportAgent.u(Boolean  N) CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e) System.Web.UI.Control.PreRenderRecursiveInternal() System.Web.UI.Control.PreRenderRecursiveInternal() System.Web.UI.Control.PreRenderRecursiveInternal() System.Web.UI.Page.ProcessRequestMain()

Dear Frnd',

It will nice if you provied more info, like in drop you are selecting which report to get or some value on which parameter it get the dataset.

or what are the datatype in database & on report.

Some more detail need to get it root.

Error: CREATE ASSEMBLY for assembly

I am trying to deploy a Database Project with Visual Studio 2005 and SQL Server 2005 Standard.

I import “System.IO” and have therefore set the permission levels to EXTERNAL_ACCESS.

I am receiving the same error message that many folks have received.

CREATE ASSEMBLY for assembly 'Images' failed because assembly 'Images' is not authorized for PERMISSION_SET = EXTERNAL_ACCESS.

The assembly is authorized when either of the following is true: the database owner (DBO) has EXTERNAL ACCESS ASSEMBLY permission and the database has the TRUSTWORTHY database property on; or the assembly is signed with a certificate or an asymmetric key that has a corresponding login with EXTERNAL ACCESS ASSEMBLY permission. If you have restored or attached this database, make sure the database owner is mapped to the correct login on this server. If not, use sp_changedbowner to fix the problem. Images.

My CLR access is “on”

I have tried

1) From master run: GRANT EXTERNAL ACCESS ASSEMBLY to [Builtin\Administrators].

2) From master run: GRANT EXTERNAL ACCESS ASSEMBLY to “My Windows Authentication ID”.

3) Run ALTER DATABASE MYDATABASE SET TRUSTWORTHY ON

4) In Visual Studio .NET 2005 Set the permission levels to ‘external’

5) Tried Builtin\Administrators and my SQL Server Windows Authenticated Login ID for the ASSEMBLY OWNER.

I can compile BUT NOT DEPLOY

Any help would be greatly appreciated.

Regards Steve

Who is the owner of the database ?

Jens K. Suessmeyer.

http://www.sqlserver2005.de
|||

Hi Thanks for the reply.

I am running with Windows Authentication at the present moment , under the ID Administrator1 (running under windows Vista.(still would like to get reporting services to run Smile ) . I did read the article on "Opening up the Administrator ID in Vista and installing SQL Server 2005 under that ID."

Re my current problem....

I managed to get it to deploy. I assigned Administrator1 as an "owner" of the database and gave the ID security administrator rights. I did the same with Builtin/Administrator.

I found something very interesting. I am able to deploy CLR stored precedures from the Visual Studio environment but not CLR functions. (EXTERNAL ACCESS) In order to deply functions I must compile the Dll and create SQL to CREATE the ASSEMBLYfrom within the SQL Server Environment. Any ideas why.?

Once again thanks for the help? Very much appreciated.

Steve

|||

OK Folks this took me about 3 hours to do BUT I have resolved the problem and it WORKS!!!

BTW I am using SQL Server 2005 Standard and Visual Studio.NET Enterprise

First create a Strong key as described in“The secret of strong naming”

DO NOT DODELAY SIGNING !!!!!!

http://www.ondotnet.com/pub/a/dotnet/2003/04/28/strongnaming.html

Sn – k MyKeyFile.snk

FIND OUT WHERE THE SNK FILE WAS COMPILED.

Go into VS2005 .NET and under project / properties in the signing page click the Sign the Assembly check box and browse to find MyKeyFile.snk

The database page

Mark the assembly for external access and leave the owner blank

Now we must go to the article

http://sqljunkies.com/WebLog/ktegels/archive/2006/08/14/safetydancelite.aspx

The text below comes from this article....Smile

A kinder, lighter Safety Dance for the SQLCLR

A few months ago, I published a step-by-step procedure for using certificate to sign an assembly so an external access or unsafe assembly could be run without having to set the hosting database to trustworthy. The major problem with that process was its weight: a lot of steps and some still requirements in terms of certificate management. Turns out that yes, there is an easier way to make it work.

Part one -- preparing the master database

1. As needed, start a series of queries against the MASTER database.

2. Create the target database (meaning execute a CREATE DATABASE query).

3. Code and compile the assembly you want to deploy. Make sure you sign the assembly with a strong name key file. This can be done with a PFX file generated by Visual Studio.

4. Create an asymmetric key from from the compiled assembly using a statement like this: create asymmetric key <key_name> from executable file = '<path_to_dll_file>'

USE Master

GO

create asymmetric key imageskeyFile from executable file = 'C:\YEAR 2007\Images\Images\bin\Debug\Images.dll'

5. Create a login based on that asymmetric key using a statement like this: create login <login_name> from asymmetric key <key_name>

Use Master

Go

create login ImageMaker from asymmetric key imageskeyFile

6. Grant that login the right to create either or both an unsafe or external access assembly (as needed) using: grant unsafe assembly to <login_name>

Use Master

Go

grant EXTERNAL ACCESS assembly to ImageMaker

Part two -- preparing the hosting database

1. As needed, start a series of queries against the desired user database.

2. Create a user in that database mapped to the login created in part, step 5. (e.g. create user <db_user> from login <login_name>)

3. Give that user the right to catalog an assembly, e.g.: grant create assembly to <db_user>

4. Catalog the desired assembly using the now trusted asymmetric key with a statement like: create assembly <assembly_name> authorization <db_user> from '<path_to_dll_file>' with permission_set = unsafe or external access as shown below

SET QUOTED_IDENTIFIER OFF

USE YEAR2007

GO

CREATE ASSEMBLY Images

AUTHORIZATION ImageMaker

FROM "C:\YEAR 2007\Images\Images\bin\Debug\Images.dll"

WITH PERMISSION_SET = EXTERNAL_ACCESS

GO

Error: Could not get a list of SSIS packages from the project.

Hello,

I have a SSIS package and I am trying to build it using devenv.com from command line. It gives me this error:

Error: Could not get a list of SSIS packages from the project.

However if I open the project in Visual Studio it builds properly. In project property I have set CreateDeploymentUtility=true.

This is what I do from command line:

devenv.com MySSIS.sln /Build "Development|Default"

Any idea what I should do ?

Thanks

Deval

Hello,

There is no solution to it as far as I know if we set CreateDeploymentUtility=true. If you uncheck it then it will work fine.

Thanks

Deval

Error: Could not find stored procedure !!

Hi,

Error: Could not find stored procedure.

I Installed the SQL Server SP2 and the error still occurs when ever I call the stored procedure from my windows app!!

Any Help ?

what's the name of SP you want to call?|||

In design window its : GetMonthRecord;1

in code window its: GetMonthRecord_1

I tried to rename it to : GetMonthRecord

the same error occurs !!

|||

Would you mind running this query and posting the results so that we can get some more information related to the object:

select uid,
left ([name], 30) as [name]
from sysobjects
where [name] like 'GetMonthRecord%'

|||

I run this query:

select uid,

left ([name], 30) as [name]

from sysobjects

where [name] like 'ThisMonthRecords%'

the result is:

1 ThisMonthRecords

|||

Now try:

exec ThisMonthRecords

and post the results

|||

executed succecfully the result is integer:

2

//

I'm facing the problem only with VS2005, when I add the procedure as queryTableAdapter, no error in code, but the error uccours after calling the SP.

error: Could not find SP upd.sp_MSrepl_xxx_xxxxxx_1

Trying to set up replication as follows:

SQL2000 publisher , acting as it's own distributor (v8.0.760)

Transactional Replication with updateable subscriptions

SQL2005 subscriber (v9.00.3042)

Push subscription with immediate updating from distributor to subscriber and queued updating from subscriber to distributor

The set-up went smoothly and changes in the publication db flow down to the subscriber as expected. However, changes at the subscriber fail to flow up to the publisher.

The Queue Reader agent reports the error "Server MyServer, Database publisher_db : ODBC Error: Could not find stored procedure "upd.sp_MSrepl_ins_mytable_1"

The SP 'sp_MSrepl_ins_mytable_1' exists in the publisher db but the owner is 'dbo' not 'upd' (there is no such login as 'upd' on the server)

The only useful article I have found on the net suggests that this could be caused by a bug (jn SP3?) but the situation described in that article and the fix/workaround for it don't seem to apply for me.

The problem and fix in that article was: table MSsubscription agents in the subscriber db had a queue_id value of 'mssqlqueue' and the fix was to set it to 'mssqlqueuev2'.
However, it is already ''mssqlqueuev2' in my subscription db so I'm at a loss to explain why it's still generating calls looking for SPs owned by 'upd'.


other info:

Just to see if it would work around my immediate peoblem I tried creating a user called 'upd' and duplicating the SPs.
This worked up to a point. Changes replicated up to my publisher ok. However, when I created a conflict (changed same row on publisher and subscriber at same time)
the Queue Reader fell over with error: "Server MyServer, Database publisher_db : ODBC Error: Could not find stored procedure "upd.1".
-


Investigated the stored procdure sys.sp_replqueuemonitor in my subscription database and found statements like this:
select publisher, publisher_db, publication, queue_server, queue_id
from dbo.MSsubscription_agents
where
publisher = case when @.publisher is NULL then publisher else UPPER(@.publisher) end AND
publisher_db = case when @.publisherdb is NULL then publisher_db else @.publisherdb end AND
publication = case when @.publication is NULL then publication else @.publication end AND
update_mode IN (2,3) AND
queue_id != N'mssqlqueue'
note that the queue_id is is looking for is 'mssqlqueue'.
If I manually run sys.sp_replqueuemonitor I get no results (unsurprising since the data in dbo.MSsubscription_agents has queue_id='mssqlqueuev2'.

It looks to me as if some of the SPs created when the publication and/or subscription was set up are incorrect...?
--

Any advice or suggestions on how to approach this problem?


Check your article properties, somehow the destination owner must have been changed to "upd" along the way. You can also query sysarticles in your published database to see if this owner exists anywhere. Please let me know if this is not the case.|||

The owner for each article is set to 'dbo'. When it first happened there wasn't a login (or schema) called 'upd' in existence on the either of the publication or subscriber servers.

I'm just trialling this with a very small test db (2 tables) so no one else would be playing around with it. I've also recreated the database and publication from scratch several times with the same result.

I'm thinking it may be a bug or an incorrectly applied service pack (the servers are not under our control, I don't even know who maintains them) .

It's bound to be probably related to the fact that I'm trying to replicate between SQL2000 and SQL2005 servers. I know that merge replication with a SQL2000 publisher and a SQL2005 subscriber is not supported but transactional replication is supported (though I'm not 100% sure that encompases transactional replication with updateable subscribers...)

|||sorry, i totally missed the updatable subscriber part, let me reread your thread and dig in some more.|||

The plot thickens...

If I create a subscriber on the same box as the publisher (i.e. publisher & subscriber are both SQL2000) it all works fine.

If the subscriber is SQL2005 it errors looking for SPs owned by 'upd'...

|||it's most likely a bug then. You're going to have to call customer support and open a case on this one if you want to get this type of scenario to work.|||

Thanks for the help. We've abandoned replication for now (we were trying to retrofit it into an existing legacy tas a temporary workaround which is really more trouble than it's worth)

If we do need to get it working I'll raise it with customer support...

Cheers

Tony

|||My opinion would be to upgrade the SQL 2000 node to SQL 2005 and look into merge replication or transactional replication using Peer to Peer.

Error: Could not find an entry for table or index with partition ID xxxxxx in database & Ser

Hello! guys

I am using sql server 2005 enterprise edition (x64) with sp1

Periodically, the sql server is crashing. Before crashing i am getting these messages in the error log

1) During undoing of a logged operation in database 'msdb', an error occurred at log record ID (). Typically, the specific failure is logged previously as an error in the Windows Event Log service. Restore the database or file from a backup, or repair the database.

2) Could not find an entry for table or index with partition ID xxxxxx in database 2. This error can occur if a stored procedure references a dropped table, or metadata is corrupted. Drop and re-create the stored procedure, or execute DBCC CHECKDB.

3) Unable to drop worktable with partition ID xxxxx after repeated attempts. Worktable is marked for deferred drop. This is an informational message only. No user action is required.

4) Error occurred while attempting to drop worktable with partition ID xxxxx.

5) SQL Server must shut down in order to recover a database (database ID 1). The database is either a user database that could not be shut down or a system database. Restart SQL Server. If the database fails to recover after another startup, repair or restore the database.

6)The log for database 'msdb' is not available. Check the event log for related error messages. Resolve any errors and restart the database.

Usually i get (2),(3),(4) (5) error message. But last time i also got (1) and (6)
Why msdb database is mentioned in error messages? Whats wrong with msdb dattabase?

Can someone tell me how to fix this issue?

I have seen this hotfix -

http://support.microsoft.com/kb/916086
( FIX: Errors may be generated in the tempdb database when you create and then drop many temporary tables in SQL Server 2005 BUG #: 518 sql )

Should i apply this hotfix? or should apply SP2? I checked SP2 bug list but i dont see anywhere about above bug. Does that mean it is not included in SP2?

Has anyone experienced such an issue? How you have resolved it?

Please any help would be apprecited.

Thanks

Database id:1 is master, :2 is tempdb. msdb database id should be 4.

It's a good thing to apply that hotfix. Also, please post the sql log. It gives us a lot more info than windows event log.

|||
Thanks so much for the reply.

All the above errors are from sql log only. I looked at the event log and it shows the same error messages.

Also that hotfix says-

This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next SQL Server 2005 service pack that contains this hotfix.

So is it safe to apply that hotfix? and if not does sp2 includes this hotfix bug?

Also wondering why the error message showing msdb database?

Thanks

|||

All hotfixes have that disclaimer. Basically, hotfixes are released to customers who truly need the fix before a formal release of a service pack (which they could wait for a long time for).

Sql2k5 sp2 does have this fix included. You can tell by looking at the build number (hotfix: 1533 and sp2: 3042).

The "missing log for msdb" error implies your sqlserver can't get to the log file (*.ldf) which implies a storage problem. Please check system event log for any indication of hardware failure.

sql

Error: Could not find an entry for table or index with partition ID xxxxxx in database & Ser

Hello! guys

I am using sql server 2005 enterprise edition (x64) with sp1

Periodically, the sql server is crashing. Before crashing i am getting these messages in the error log

1) During undoing of a logged operation in database 'msdb', an error occurred at log record ID (). Typically, the specific failure is logged previously as an error in the Windows Event Log service. Restore the database or file from a backup, or repair the database.

2) Could not find an entry for table or index with partition ID xxxxxx in database 2. This error can occur if a stored procedure references a dropped table, or metadata is corrupted. Drop and re-create the stored procedure, or execute DBCC CHECKDB.

3) Unable to drop worktable with partition ID xxxxx after repeated attempts. Worktable is marked for deferred drop. This is an informational message only. No user action is required.

4) Error occurred while attempting to drop worktable with partition ID xxxxx.

5) SQL Server must shut down in order to recover a database (database ID 1). The database is either a user database that could not be shut down or a system database. Restart SQL Server. If the database fails to recover after another startup, repair or restore the database.

6)The log for database 'msdb' is not available. Check the event log for related error messages. Resolve any errors and restart the database.

Usually i get (2),(3),(4) (5) error message. But last time i also got (1) and (6)
Why msdb database is mentioned in error messages? Whats wrong with msdb dattabase?

Can someone tell me how to fix this issue?

I have seen this hotfix -

http://support.microsoft.com/kb/916086
( FIX: Errors may be generated in the tempdb database when you create and then drop many temporary tables in SQL Server 2005 BUG #: 518 sql )

Should i apply this hotfix? or should apply SP2? I checked SP2 bug list but i dont see anywhere about above bug. Does that mean it is not included in SP2?

Has anyone experienced such an issue? How you have resolved it?

Please any help would be apprecited.

Thanks

Database id:1 is master, :2 is tempdb. msdb database id should be 4.

It's a good thing to apply that hotfix. Also, please post the sql log. It gives us a lot more info than windows event log.

|||
Thanks so much for the reply.

All the above errors are from sql log only. I looked at the event log and it shows the same error messages.

Also that hotfix says-

This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next SQL Server 2005 service pack that contains this hotfix.

So is it safe to apply that hotfix? and if not does sp2 includes this hotfix bug?

Also wondering why the error message showing msdb database?

Thanks

|||

All hotfixes have that disclaimer. Basically, hotfixes are released to customers who truly need the fix before a formal release of a service pack (which they could wait for a long time for).

Sql2k5 sp2 does have this fix included. You can tell by looking at the build number (hotfix: 1533 and sp2: 3042).

The "missing log for msdb" error implies your sqlserver can't get to the log file (*.ldf) which implies a storage problem. Please check system event log for any indication of hardware failure.

Error: Could not create an acceptable cursor.

I'm trying to run a stored proc on a SQL 2005 SP1 box to return info to a SQL 2000 SP4 box, as a linked server. Both boxes have the latest service packs, and run Windows 2003 Server, again with the latest service packs.

The error I get is:

OLE DB provider "SQLNCLI" for linked server "192.168.0.126" returned message "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.".
Msg 16955, Level 16, State 2, Line 1
Could not create an acceptable cursor.

The full script I am running is:


CREATE procedure [dbo].[proc_AuditServer]
as

/*
** Auditing Script for SQL Servers.
**
** D Maxwell, June 2007
**
** This script takes configuration and job status information
** and writes it to a designated logging server. I'll describe
** each section in detail, below. We write to the local box first,
** Then upload everything to the logging server.
**
** This is the SQL 2005 version.
*/

/*
** We want to know exactly what server this is, so
** we get the server name, instance name, as well as
** SQL Version, Edition, and Service Pack level.
*/


truncate table admin.dbo.sql_servers

insert into admin.dbo.sql_servers
select convert(varchar(15), serverproperty('ServerName')),
convert(varchar(25), serverproperty('InstanceName')),
convert(char(9), serverproperty('ProductVersion')),
convert(varchar(4), serverproperty('ProductLevel')),
convert(varchar(20), serverproperty('Edition')),
getdate()

/*
** Now, having that, we get the list of databases,
** as well as thier creation dates and file names.
*/

truncate table admin.dbo.databases

insert into admin.dbo.databases
select
convert(varchar(15), serverproperty('ServerName')),
dbid,
name,
crdate,
filename
from master..sysdatabases
where dbid > 4
order by dbid

/*
** We need to know how the server is configured, so we
** can compare it to a list of preferred configuration
** values, as well as the defaults. I cut this out of
** sp_configure.
*/

truncate table admin.dbo.server_config

insert into admin.dbo.server_config
select
convert(varchar(15), serverproperty('ServerName')),
name,
config_value = c.value,
run_value = master.dbo.syscurconfigs.value
from master.dbo.spt_values, master.dbo.sysconfigures c, master.dbo.syscurconfigs
where type = 'C'
and number = c.config
and number = master.dbo.syscurconfigs.config

and
((c.status & 2 <> 0 )
OR
(c.status & 2 = 0)
)
order by lower(name)

/*
** The next configuration item we want to get is the
** list of jobs that run on the server. We're looking
** specifically for backup and other maintenance jobs.
** (Which will hopefully be named appropriately...)
** We use Neil Boyle's job report script for this.
** My comments and changes prefaced by a 'DM:'
*/

truncate table admin.dbo.jobs

insert into admin.dbo.jobs
select
convert(varchar(15), serverproperty('ServerName')), --DM: Needed since we'll have lots of servers reporting
j.job_id, -- DM: More unique than a name.
convert(varchar(22), j.name) as job_name,
case freq_type -- Daily, weekly, Monthly
when 1 then 'Once'
when 4 then 'Daily'
when 8 then 'Wk ' -- For weekly, add in the days of the week
+ case freq_interval & 2 when 2 then 'M' else '' end -- Monday
+ case freq_interval & 4 when 4 then 'Tu' else '' end -- Tuesday
+ case freq_interval & 8 when 8 then 'W' else '' end -- etc
+ case freq_interval & 16 when 16 then 'Th' else '' end
+ case freq_interval & 32 when 32 then 'F' else '' end
+ case freq_interval & 64 when 64 then 'Sa' else '' end
+ case freq_interval & 1 when 1 then 'Su' else '' end
when 16 then 'Mthly on day ' + convert(varchar(2), freq_interval) -- Monthly on a particular day
when 32 then 'Mthly ' -- The most complicated one, "every third Friday of the month" for example
+ case freq_relative_interval
when 1 then 'Every First '
when 2 then 'Every Second '
when 4 then 'Every Third '
when 8 then 'Every Fourth '
when 16 then 'Every Last '
end
+ case freq_interval
when 1 then 'Sunday'
when 2 then 'Monday'
when 3 then 'Tuesday'
when 4 then 'Wednesday'
when 5 then 'Thursday'
when 6 then 'Friday'
when 7 then 'Saturday'
when 8 then 'Day'
when 9 then 'Week day'
when 10 then 'Weekend day'
end
when 64 then 'Startup' -- When SQL Server starts
when 128 then 'Idle' -- Whenever SQL Server gets bored
else 'Err' -- This should never happen
end as schedule

, case freq_subday_type -- FOr when a job funs every few seconds, minutes or hours
when 1 then 'Runs once at:'
when 2 then 'every ' + convert(varchar(3), freq_subday_interval) + ' seconds'
when 4 then 'every ' + convert(varchar(3), freq_subday_interval) + ' minutes'
when 8 then 'every ' + convert(varchar(3), freq_subday_interval) + ' hours'
end as frequency

-- All the subsrings are because the times are stored as an integer with no leading zeroes
-- i.e. 0 means midnight, 13000 means half past one in the morning (01:30:00)

, substring (right (stuff (' ', 1, 1, '000000') + convert(varchar(6),active_start_time), 6), 1, 2)
+ ':'
+ substring (
right (stuff (' ', 1, 1, '000000') + convert(varchar(6), active_start_time), 6) ,3 ,2)
+ ':'
+ substring (
right (stuff (' ', 1, 1, '000000') + convert(varchar(6),active_start_time), 6) ,5 ,2) as start_at

,case freq_subday_type
when 1 then NULL -- Ignore the end time if not a recurring job
else substring (right (stuff (' ', 1, 1, '000000') + convert(varchar(6), active_end_time), 6), 1, 2)
+ ':'
+ substring (
right (stuff (' ', 1, 1, '000000') + convert(varchar(6), active_end_time), 6) ,3 ,2)
+ ':'
+ substring (
right (stuff (' ', 1, 1, '000000') + convert(varchar(6), active_end_time), 6) ,5 ,2) end as end_at
from msdb.dbo.sysjobs j, msdb.dbo.sysJobSchedules s, msdb.dbo.sysschedules c
where j.job_id = s.job_id and s.schedule_id = c.schedule_id
order by j.name, start_at

/*
** Now that we know what jobs we have, let's find out
** how they did recently.
*/

truncate table job_status

insert into job_status
select convert(varchar(15), serverproperty('ServerName')),
job_id, run_status, run_date,
run_time, run_duration
from msdb..sysjobhistory
where step_name = '(job outcome)' -- The last 90 days' worth.
and run_date > (select replace(convert(varchar(10), (getdate() - 90), 120), '-', ''))
order by run_date desc


/*
** If this server is already known to the audit server,
** we need to remove the existing data from the audit
** tables.
*/


declare @.known bit
set @.known =
(select count(*)
from [192.168.0.126].AUDITDB.dbo.sql_servers
where server_name =
(select convert(varchar(15), serverproperty('servername'))))

/*
** Now we remove the existing information from the audit tables,
** if need be.
*/

if @.known = 1
begin

delete from [192.168.0.126].AUDITDB.dbo.sql_servers
where server_name = (select convert(varchar(15), serverproperty('ServerName')))

delete from [192.168.0.126].AUDITDB.dbo.databases
where server_name = (select convert(varchar(15), serverproperty('ServerName')))

delete from [192.168.0.126].AUDITDB.dbo.server_config
where server_name = (select convert(varchar(15), serverproperty('ServerName')))

delete from [192.168.0.126].AUDITDB.dbo.jobs
where server_name = (select convert(varchar(15), serverproperty('ServerName')))

delete from [192.168.0.126].AUDITDB.dbo.job_status
where server_name = (select convert(varchar(15), serverproperty('ServerName')))

end



/*
** Finally, we upload the new info from here to the audit server.
*/

insert into [192.168.0.126].AUDITDB.dbo.sql_servers
select * from admin.dbo.sql_servers

insert into [192.168.0.126].AUDITDB.dbo.server_config
select * from admin.dbo.server_config

insert into [192.168.0.126].AUDITDB.dbo.databases
select * from admin.dbo.databases

insert into [192.168.0.126].AUDITDB.dbo.jobs
select * from admin.dbo.jobs

insert into [192.168.0.126].AUDITDB.dbo.job_status
select * from admin.dbo.job_status



This works fine for other boxes of the same service pack levels. I've already read KB302477, which doesn't appear to apply, since I'm already several revisions beyond that. I'm unable to duplicate this in test.

Any ideas as to what I should look at next? Thanks.

-D.Check DB_option to see whether local and global cursors are default, SP1 for SQL2005 is older one and latest is SP2.

Also see this http://support.microsoft.com/kb/302477 that talks about hotfix.|||OK, I went back and read that article again. It says this happens "If a cursor is created on a system stored procedure that returns schema information from a remote server..." I'm sorry, but I'm still learning to program in SQL and I don't see where I'm doing that. Is it in the DELETE FROM statement? And that article talks about SQL 2000 SP2. I'm running SQL 2000 SP4 on that box. Would I still need the hotfix?

I tried this with a server running SQL2005 SP2 (Version 9.00.3159), and got the same error.

I also tried setting the cursor option on the databases involved on both servers, to both global and local, in all 4 configurations. Still getting the same error.

Any other ideas?

Error: Could not connect to database

The following error is encountered while trying to Host the site from IIS ..
" The Assembly Version ([ASSEMBLY VERSION]) does not match the Database Version ([DATABASE VERSION]).
"Error: Could not connect to the database specified in the connection string for SqlDataProvider. "

We have 2 different machines, over which we have 2 different SQL Server.
In Web.Config, if we give server=server1 it works well and there is no problem at all...
if we give server=server2, and executehttp://localhost/application, the above mentioned error occurs..

and yes the application is hosted on 3rd machine......

Can anyone throw some light on this regard.
Its urgent.

You're using DotNetNuke, right? Try this search on the Forums to see other threads on this topic:
http://forums.asp.net/search/SearchResults.aspx?q=ASSEMBLY+VERSION+match+DATABASE+VERSION&o=Relevance

error: copy database wizard

SQL SERVER SERVICE IS RUNNING UNDER THE LOCAL SYSTEM
ACCOUNT.
YOU NEED TO CHANGE YOUR SQL SERVER SERVICE ACCOUNT TO
HAVE THE RIGHTS TO COPY FILES OVER THE NETWORK.
Hi,
Yes, The copy database wizard requires the write permissions in destination
server folder. So you should start the SQL Server in both the servers using
domain user which got write access to the destination server folder.
How to change the startup SQL server account:-
1. Go to Control Panel -- Admin tools -- Services
2, Double click MSSQL server services
3. Go to Log on option and change the start up account and password to a
domain user.
4. Do the same for both servers
5. restart both sql servers.
(I feel like you are starting SQL server in Local system account.)
Thanks
Hari
MCDBA
"new" <anonymous@.discussions.microsoft.com> wrote in message
news:a8ce01c4368d$098b76c0$a401280a@.phx.gbl...
> SQL SERVER SERVICE IS RUNNING UNDER THE LOCAL SYSTEM
> ACCOUNT.
> YOU NEED TO CHANGE YOUR SQL SERVER SERVICE ACCOUNT TO
> HAVE THE RIGHTS TO COPY FILES OVER THE NETWORK.

Error: Contains more than the maximum number of prefixes. The max

I am running an update statement in query analyzer to update a database with
data from another database on another server.
I am running into the error : Error: Contains more than the maximum number
of prefixes. Maximum is 3
How do I overcome this error. I am the admin on both servers.http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=44062
DishanF
*** Sent via Developersdex http://www.examnotes.net ***
Don't just participate in USENET...get rewarded for it!|||I was trying to do something similar by doing an update and "pushing" the da
ta across to a linked server with the following:
update ServerName.AAD.dbo.t_employee
set ServerName.AAD.dbo.t_employee.work_shift = wa.work_shift
from t_employee wa
where ServerName.AAD.dbo.t_employee.id = wa.id
and wa.id = '105'
I was also getting the following:
Server: Msg 117, Level 15, State 2, Line 4
The number name 'ServerName.AAD.dbo.t_employee' contains more than the maxim
um number of prefixes. The maximum is 3.
It's a simple, but not obvious, answer. Put the table you are updating in th
e FROM clause with an alias and update the alias, as follows:
update la
set la.work_shift = wa.work_shift
from ServerName.AAD.dbo.t_employee la, t_employee wa
where la.id = wa.id
and wa.id = '105'
You have to love simple answers. Finding them is the challenging part. :)sql