Integration Services Project won't run unless Business Intelligence Development Studio is ran as administrator - sql-server-2008-r2

The error is "Unable to bulk copy data. You may need to run this package as an Administrator"
Same problem when I use the Execute Package Utility. I scheduled it as a job SSMS and it also fails, I assume because of the permissions issue.
The package grabs data and writes in to a database table

I switched from "SQL Server Destination" to "OLEDB Destination"

Related

"Update Model from Database" as build step

I am working on an application that utilizes a database that often has tables added to it or modified. Is there a way I can regenerate the .edmx file as a build step or during compile time to add these new tables/modifications without manually running the wizard?
You can try to run sql scripts to insert/modify tables during build process.
Related extension:
ExecuteSqlScript
Run SQL Server Scripts Task
Or directly use PowerShell to Execute .SQL Files from Directory.
Reference below articles to change the database during build/release:
Build​ ​and​ ​Release​ ​Process​ ​for​ ​SQL​ ​Server​ ​Database​
​Scripts​ ​using​ ​Online​ ​TFS​
Continuous Deployment of SQL Server Database Changes using Visual
Studio & TFS Release Manager
UPDATE:
Choosing the Update Model from Database is the best method for updating your EDMX. There are certain properties that don't get updated on the Conceptual layer.
See How do you update an edmx file with database changes?
Seems there isn't a good way to achieve that, however if the actions can be executed in command line, then we can add a step to run the command or script.

How do I change an entity framework project to use Microsoft SQL Server

I am trying to debug a program using Entity Framework code first on my personal (work) computer.
We have recently had a domain migration, meaning that the user I log in as now is not the same that I used before. This caused me to loose access to the databases I had on the computer. To get around this, I have uninstalled everything to do with Microsoft SQL Server on the computer, and installed the latest version of Microsoft SQL Server, 2014 - 12.0.4213.0 . I then restored the database I need.
When I first tried to run the program, Visual Studio complained that the project is set up to use SQL Server Express, which was not installed. The recommended solution is to change the project to use SQL Server instead. To do this, I must click on "the database file" and follow the instructions. I have looked through the entire solution. There is a great many files, but I found no good candidate for "the database file."
It seems that my Google fu is not strong enough to find anything about this. So my question is: how do I change the project to use SQL Server?
I also have a second, related question. I tried to solve the problem by installing SQL Server Express. However, when I try to restore the database to this, no base appears in the drop down list. When I try to run the program now, I get another error:
Unable to create the file 'c:\Program Files\Microsoft SQL Server\MSSQL11.SQLEXPRESS\MSSQL\DATA\Timelønsblanket.mdf' because it already exists.
I guess that this is also why I cannot restore the database. What I have found in websearches warns that I should not manually delete .mdf files.
Any advice on what to do?
I have solved the problem. All that was needed was a correct connection string. No need to find a "database file".

Creating new Team Projects with TFS Power Tools on server fails

I'm trying to create a powershell script, which creates new Team Projects in a given Team Project Collection. This script will have to run on the Team Foundation Server.
I'm using Team Foundation Server 2012, Visual Studio Team Explorer 2012 and TFS Power Tools 2012.
The script (based on this):
$tpcUrl = "http://localhost:8080/tfs/mycollection";
$teamproject = "TestProject"
tfpt.exe createteamproject /collection:$tpcUrl /teamproject:$teamproject /processtemplate:"Microsoft Visual Studio Scrum 2.2" /sourcecontrol:"New" /noportal /noreports
This works if I only run it once (if I only have to add one project), but when I run it again (with a different project name, of course), it gives an exception:
System.InvalidOperationException: Unexpected error occurred
when Visual Studio tried to load Team Foundation Server client application.
at Microsoft.TeamFoundation.PowerTools.CommandLine.TeamProjectCreator.CreateProject()
I found only one solution for this exception here, but it did not help, because I'm not running TFS Admin tool while the exception occurs.
I could only make this work if I manually (in TfsMgmt.exe) restart the collection (stop and start collection, not detach and attach). After that, the script worked, but again only for one new project. However, this is not a good solution, since I cannot restart a collection from script, so the project creation would require manual actions, which defeats its purpose.
This only occurs when I run this script on the Team Foundation Server, it works if I try to run it from my development PC. The problem is that I have to run it on the server.
Has anyone met this exception? Is there a way to fix it? Or is there a way I can restart a collection from script?
Edit:
There are no error messages on Logs page in TFS Administrator Console, or in the Event Viewer.

NServiceBus not creating queues automatically (MSMQ)

I'm doing the examples from the NServiceBus website (http://docs.particular.net/samples/step-by-step/) and when I run in Visual Studio everything works and the queues are created automatically (even if I delete them and re-run the solution than they get created automatically). The dev machine runs Windows 8.
I have an emulated Windows 2008 RC2 - when I take my solution bin folder to the server machine and try to run NServiceBus.Host.exe it eventually crashes and the reason is: "The queue does not exist or you do not have sufficient permissions to perform the operation" - even when I run with administrative privileges. When looking the the queue I see that they were not created, and if I manually create the queues than it works.
Why doesn't queues get created automatically when I run on a different machine?
Update
If I run NServiceBus.Host.exe /install than it creates the queues, and also installs it a s windows service. But what I would like to do is run it regularly. If I just run the exe, is it considered as self hosted?
You can run the NServiceBus.Host.Exe with NServiceBus.Integration argument, that should create your queues...
For more info on profiles take a look here
and here
HTH

TFS to VisualStudio Online Migration - Access to directory is denied

I'm trying the new OpsHub TFS to Visual Studio Online migration tool and have run into a snag. After successfully setting up the migration configuration, I begin the migration.
On the first changeset of the migration, I receive the error:
"OH_SCM_009: Error occurred while sync. Access to the path 'O:\w15_2\ProjectName'"
Where ProjectName is the name of my project.
Through deletion and recreation of the project in VSOnline, I found that the folder 'w15_2' would change, an indication that this path (and subsequent access failure) is in VSOnline. I have confirmed the user I am using for migration is a project collection admin, project admin, and project collection service account (per the OpsHub help page).
I'm not really sure where to go from here... any ideas how to get around this access denied error?
The error indicates that the utility does not have ability to write at location at :\Program Files\OpsHub Visual Studio Online Migration Utility\TFS_Temp which is used by the utility for temp work space. (It is aliased to O drive). Please check to make sure that this location is writeable.