Quantcast
Channel: MSBuild Extension Pack
Viewing all articles
Browse latest Browse all 1211

New Post: Receiving Access is Denied Error at the File System Level when Executing Create Task of MSBuild.ExtensionPack.Sql2008.Database

$
0
0
<?xml version="1.0" encoding="utf-8" ?>
<Project
xsi:schemaLocation="http://schemas.microsoft.com/developer/msbuild/2003 ..\Schemas\Microsoft.Build.xsd">

<Target Name="Conversion_GenerateStagingDB">

<Message Text="Check to see if $(ConversionStagingDatabase) Exists"/>
<MSBuild.ExtensionPack.Sql2008.Database
TaskAction="CheckExists"
MachineName="$(ConversionStagingServerName)"
DatabaseItem="$(ConversionStagingDatabase)">
<Output
TaskParameter="Exists"
PropertyName="DoesExist"/>
</MSBuild.ExtensionPack.Sql2008.Database>
<Message Text="Database Exists: $(DoesExist)"/>
<Message Text="Set staging database offline..."/>
<MSBuild.ExtensionPack.Sql2008.Database
Condition="'$(DoesExist)'=='True'"
TaskAction="SetOffline"
MachineName="$(ConversionStagingServerName)"
DatabaseItem="$(ConversionStagingDatabase)"
/>
<Message Text="Set staging database online..."/>
<MSBuild.ExtensionPack.Sql2008.Database
Condition="'$(DoesExist)'=='True'"
TaskAction="SetOnline"
MachineName="$(ConversionStagingServerName)"
DatabaseItem="$(ConversionStagingDatabase)"
/>

<Message Text="Deleting staging database..."/>
<MSBuild.ExtensionPack.Sql2008.Database
Condition="'$(DoesExist)'=='True'"
TaskAction="Delete"
MachineName="$(ConversionStagingServerName)"
DatabaseItem="$(ConversionStagingDatabase)"
/>
<Message Text="Staging Database delete..."/>

<Message Text="Start create database..."/>
<MSBuild.ExtensionPack.Sql2008.Database
TaskAction="Create"
MachineName="$(ConversionStagingServerName)"
DatabaseItem="$(ConversionStagingDatabase)"
DataFilePath="$(ConversionStagingDataFilePath)"
LogFilePath="$(ConversionStagingLogFilePath)"
UserName="$(ConversionStagingServerUserName)"
UserPassword="$(ConversionStagingServerPassword)"
/>
<Message Text="Database created..."/>

<Message Text="Execute table scripts..."/>
<ItemGroup>
<CreateTableScriptsToRun Include="$(MSBuildProjectDirectory)/Project Outputs/CV GUI/Staging Database/Creation Scripts/*.sql"/>
</ItemGroup>

<Message Text="Get item count"/>
<MSBuild.ExtensionPack.Framework.MSBuildHelper TaskAction="GetItemCount" InputItems1="@(CreateTableScriptsToRun)">
<Output TaskParameter="ItemCount" PropertyName="CreateTableScriptsCount"/>
</MSBuild.ExtensionPack.Framework.MSBuildHelper>
<Message Text="CreateTableScriptsCount = $(CreateTableScriptsCount)"/>
<Message Text="Starting Threaded SQL Runner..."/>
<ThreadedSQLRunner SQLFilesToRun="@(CreateTableScriptsToRun)" TargetConnectionString="$(ConversionStagingDBConnectionString)" MaxThreadPoolSize="$(MaxProcessThreads)" Condition="'$(CreateTableScriptsCount)'>'0'"/>
<Message Text="Completed Threaded SQL Runner"/>
<Message Text="Table scripts created..."/>

</Target>
</Project>
-------------------
Jason Cusati



On Thu, Aug 2, 2012 at 1:28 PM, mikefourie <notifications@codeplex.com> wrote:

From: mikefourie

Ok, can you post the Xml you are using.

Read the full discussion online.

To add a post to this discussion, reply to this email (MSBuildExtensionPack@discussions.codeplex.com)

To start a new discussion for this project, email MSBuildExtensionPack@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com



Viewing all articles
Browse latest Browse all 1211

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>