Showing posts with label project. Show all posts
Showing posts with label project. Show all posts

Thursday, March 29, 2012

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: 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

Tuesday, March 27, 2012

Error: Application for .reportproj not installed

Getting error when try to open report project:
The application for D:\Documents and Settings\Administrator\My
Documents\Visual Studio Projects\WinfundsReports.rptproj is not installed.
Make surethe application for the project type (.rptproj) is installed.
Everything had been working fine for a year!
Note: Busuness Intelligence Projects no longer appears in the list of
available project types when setting up new project.
Is this controlled by something in the config files, or will I have to
reinstall Rptg Services?
Thanks.
AlanFollowup Question:
Is there a file that will re-register reporting services withou a complete
re-install?
Thanks.
Alan

Sunday, February 26, 2012

Error with Data Flow Task

I am having problems with the Data Flow task. It does not even show up in the list of items to drop into the SSIS project.

If I go to the Data Flow tab and hit create, I get the follow error. I have tried repairing and reinstalling, but nothing seems to clear up the error. Without rebuilding my machine, is there anyone who knows how to get the Data Flow Task reinstalled properly?

Thanks

Wayne

TITLE: Microsoft Visual Studio


Registration information about the Data Flow task could not be retrieved. Confirm that this task is installed properly on the computer.


ADDITIONAL INFORMATION:

TaskHost "{C3BF9DC1-4715-4694-936F-D3CFDA9E42C5}"' is not installed correctly on this computer. (Microsoft.DataTransformationServices.Design)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft%u00ae+Visual+Studio%u00ae+2005&ProdVer=8.0.50727.762&EvtSrc=Microsoft.DataTransformationServices.Design.SR&EvtID=TaskHostNotInstalled&LinkId=20476


BUTTONS:

OK


Did you search the forum?

it looks like that has been asked before:

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=898604&SiteID=1

error with calculation tab

currently using the SQL Server Business Intelligence tools to develop my project. After the cube creation, i clicked on the Calculation tab and it just automatically quit the whole software. When i open back the software and the project and click on the Calculation tab again, it won't quit the whole software but had this error message "Error with application" and on the left panel "error loading meta data, could not access to the database" something like that......

izit the software corrupted or there's any setting that i should change? the connection to the database is fine as i test run it and it succeeded.

plz help........

Hey there,

Check out this thread, follow the links a couple of posts down and you should be able to solve this problem.

C

Friday, February 24, 2012

Error while trying to create a new connection in Visual C# Express 2005

Hi, the other day i decided to download and install C# Express and SQL Server Express 2005. I created a new project in C# Express then I decided to practice with database connectivity so I tried to create a new connection, in the wizard I specified SQL Server Authentication, typed the user name and password and when I pushed the button "Test Connection" I recieve this error message "Failed to generate a user instance of SQL Server. Only an integrated connection can generate a user instance. The connection will be closed". I also have tried Windows Autentication, but it displays a more complex error that says something about the database file being used by other process. I have been trying to solve this problem, but nothing works. I think I need some help.Tongue TiedSad

While adding a Data Source in VB2005EE I also got this error which you received:

"Failed to generate a user instance of SQL server. Only an integrated connection can generate a user instance. The connection will be closed."

Solution that worked for me:

On the "Add Connection" Dialog, click the "Advanced" Button. Go to the Property "User Instance" under "Source". Change the value to "False" & you are done.

Error while trying to create a new connection in Visual C# Express 2005

Hi, the other day i decided to download and install C# Express and SQL Server Express 2005. I created a new project in C# Express then I decided to practice with database connectivity so I tried to create a new connection, in the wizard I specified SQL Server Authentication, typed the user name and password and when I pushed the button "Test Connection" I recieve this error message "Failed to generate a user instance of SQL Server. Only an integrated connection can generate a user instance. The connection will be closed". I also have tried Windows Autentication, but it displays a more complex error that says something about the database file being used by other process. I have been trying to solve this problem, but nothing works. I think I need some help.Tongue TiedSad

While adding a Data Source in VB2005EE I also got this error which you received:

"Failed

to generate a user instance of SQL server. Only an integrated

connection can generate a user instance. The connection will be closed."

Solution that worked for me:

On

the "Add Connection" Dialog, click the "Advanced" Button. Go to the

Property "User Instance" under "Source". Change the value to "False"

& you are done.

Wednesday, February 15, 2012

Error while executing SSIS package from other SSIS package

Hi,

In our project we have two SSIS package.

And there is a task (Execute SSIS package) in First package that calls the execution of second package.

I m continuously receiving an error "Failed to decrypt protected XML node "PackagePassword" with error 0x8009000B "Key not valid for use in specified state.". You may not be authorized to access this information. This error occurs when there is a cryptographic error. Verify that the correct key is available."

As we are running first package by job, job runs successfully logging above error

The protection level of second package is set to "EncryptSensitiveWithUserKey"

Can anybody please suggest how to handle it?

If these DTSX has been saved on the MSDB you could use 'Server Storage' as protection level.

EncryptSensitive.. is the default protection level for the packages.

|||

If protection level property of the package has EncryptSensitive WithUSerKey means that only the author of the package is allowed to run it. This KB offers diffrent alternatives to solve your issue:

An SSIS package does not run when you call the SSIS package from a SQL Server Agent job step:

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

|||

Admin,

This topic is a good candidate for a "sticky" for the forum.

This question is asked once a day... we could come up with a synopsis on package encryption

|||

The DTSX is not saved in the MSDB,

its at disk only.

Error While Depoloying Report Model Project

Hi,

I am trying to deploy my report model project to remote server which is our QA environment using Visual Studio. In my Project Property I have set the Traget Data source folder and model folder and URL. But I am getting this error any idea?

===================================

A connection could not be made to the report server "ReportServer URL for my remote server"

. (Microsoft Semantic Model Designer)

===================================

Client found response content type of '', but expected 'text/xml'.
The request failed with an empty response. (Microsoft.ReportingServices.SemanticQueryDesign)


Program Location:

at Microsoft.SqlServer.ReportingServices2005.RSConnection.GetSecureMethods()
at Microsoft.SqlServer.ReportingServices2005.RSConnection.IsSecureMethod(String methodname)
at Microsoft.SqlServer.ReportingServices2005.RSConnection.GetItemType(String Item)
at Microsoft.ReportingServices.ModelDesigner.Project.ReportServiceClient.GetItemType(String item)
at Microsoft.ReportingServices.ModelDesigner.Project.ReportServiceClient.CheckAuthorized()
at Microsoft.ReportingServices.ModelDesigner.Project.ModelClientManager.GetCredentials(String url)
at Microsoft.ReportingServices.ModelDesigner.Project.ModelProjectDeployer.PrepareDeploy()

What kind of permission/role do I need to have inorder to deploy report model project on to the server. I am able to deploy same project on my local machine using visual studio.

Thanks!!!

You are not using the right address for the report server or the Report WebService is not working properly, you will have to provide the adress of the Report Server WebService address which is by default http://localhost/ReportServer (on the localhost). browse to this address in your IE to see if the address is working and Reporting Server is responding.

Jens K. Suessmeyer

http://www.sqlserver2005.de

|||

Hi,

I found the solution actually the issue is how the folders structure.

In our QA environment we have different folders for different projects.

This is how I was trying before:

Target DataSourceFolder: Data Sources

Target ModelsFolder: Models

TargetURL: http://servername/reportserver/CRAS1

Notice the folder name at the end of the URL.(thats the project folder I wanted this Model project to be in)

This is how its now and its working:

Target DataSourceFolder: CRAS1/Data Sources

Target ModelsFolder: CRAS1/Models

TargetURL: http://servername/reportserver

I hope this helps to someone like me who does this kind of stupid mistake.

Thanks

Ashwini