Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC

Activities of "manojreddy"

Hi,

I'm not able to debug test, Run Test is working fine, But Debug Test is existing with the following error.

My projects were targeting to .net standard 1.0, now I am targeting to .net standard 2.0 with the same code.

Starting: MyCompany.MyProject.Tests [12/20/2017 6:57:51 AM Error] The active test run was aborted. Reason: Unable to communicate with test host process.

Hi, I'm getting too many warnings when running dotnet build, Please help me in solving these warnings. My projects were targeting to .net standard 1.0, now I am targeting to .net standard 2.0 with the same code.

c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Application\MyCompany.MyProject.Application.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Dto\MyCompany.MyProject.Business.Dto.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Data\MyCompany.MyProject.Business.Repositories.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Services\MyCompany.MyProject.Business.Services.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Core\MyCompany.MyProject.Core.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.EntityFrameworkCore\MyCompany.MyProject.EntityFrameworkCore.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.MasterDataFiles\MyCompany.MyProject.Business.MasterDataFiles.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors.Core\MyCompany.MyProject.Processors.Core.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors\MyCompany.MyProject.Processors.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors\MyCompany.MyProject.Processors.csproj : warning NU1701: Package 'Microsoft.AspNet.WebApi.Client 5.2.2' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Web.Core\MyCompany.MyProject.Web.Core.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Web.Core\MyCompany.MyProject.Web.Core.csproj : warning NU1701: Package 'Abp.AspNetZeroCore.Web 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. [c:\Work\Source\MyProject\aspnet-core\MyCompany.MyProject.sln] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Core\MyCompany.MyProject.Core.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Core\MyCompany.MyProject.Core.csproj] c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Web.Core\MyCompany.MyProject.Web.Core.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Web.Core\MyCompany.MyProject.Web.Core.csproj : warning NU1701: Package 'Abp.AspNetZeroCore.Web 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Application\MyCompany.MyProject.Application.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.EntityFrameworkCore\MyCompany.MyProject.EntityFrameworkCore.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.MasterDataFiles\MyCompany.MyProject.Business.MasterDataFiles.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Services\MyCompany.MyProject.Business.Services.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Dto\MyCompany.MyProject.Business.Dto.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors.Core\MyCompany.MyProject.Processors.Core.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Data\MyCompany.MyProject.Business.Repositories.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors\MyCompany.MyProject.Processors.csproj : warning NU1701: Package 'Abp.AspNetZeroCore 1.0.14' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors\MyCompany.MyProject.Processors.csproj : warning NU1701: Package 'Microsoft.AspNet.WebApi.Client 5.2.2' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETStandard,Version=v2.0'. This package may not be fully compatible with your project. C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.EntityFrameworkCore\MyCompany.MyProject.EntityFrameworkCore.csproj] C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Application\MyCompany.MyProject.Application.csproj] C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Dto\MyCompany.MyProject.Business.Dto.csproj] C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Data\MyCompany.MyProject.Business.Repositories.csproj] C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.MasterDataFiles\MyCompany.MyProject.Business.MasterDataFiles.csproj] C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors.Core\MyCompany.MyProject.Processors.Core.csproj] C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Business.Services\MyCompany.MyProject.Business.Services.csproj] C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors\MyCompany.MyProject.Processors.csproj] C:\Program Files\dotnet\sdk\2.1.2\Microsoft.Common.CurrentVersion.targets(2041,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed. [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Web.Core\MyCompany.MyProject.Web.Core.csproj] C:\Users\mreddy.nuget\packages\microsoft.net.sdk.functions\1.0.7\build\netstandard1.0\Microsoft.NET.Sdk.Functions.Build.targets(32,5): warning : [c:\Work\Source\MyProject\aspnet-core\src\MyCompany.MyProject.Processors\MyCompany.MyProject.Processors.csproj] Tests\TestAppService_Tests.cs(148,27): warning xUnit1013: Public method 'Should_Create_TestPrice_With_Valid_Arguments' on test class 'TestAppService_Test' should be marked as a Fact. [c:\Work\Source\MyProject\aspnet-core\test\MyCompany.MyProject.Tests\MyCompany.MyProject.Tests.csproj] 36 Warning(s) 0 Error(s)

Running dotnet build from the command prompt and getting an error.

Welcome to .NET Core!

Learn more about .NET Core @ <a class="postlink" href="https://aka.ms/dotnet-docs">https://aka.ms/dotnet-docs</a>. Use dotnet --help to see available commands or go to <a class="postlink" href="https://aka.ms/dotnet-cli-docs">https://aka.ms/dotnet-cli-docs</a>.

Telemetry

The .NET Core tools collect usage data in order to improve your experience. The data is anonymous and does not include command-line arguments. The data is collected by Microsoft and shared with the community. You can opt out of telemetry by setting a DOTNET_CLI_TELEMETRY_OPTOUT environment variable to 1 using your favorite shell. You can read more about .NET Core tools telemetry @ <a class="postlink" href="https://aka.ms/dotnet-cli-telemetry">https://aka.ms/dotnet-cli-telemetry</a>. Microsoft (R) Build Engine version 15.5.179.9764 for .NET Core Copyright (C) Microsoft Corporation. All rights reserved.

C:\Users\MyName\source\repos\MyProject\aspnet-core\src\MyCompany.MyProject.Core\MyCompany.MyProject.Core.csproj : error NU1003: PackageTargetFallback and AssetTargetFallback cannot be used together. Remove PackageTargetFallback(deprecated) references from the project environment. [C:\Users\MyName\source\repos\MyProject\aspnet-core\MyCompany.MyProject.sln]

Build FAILED.

C:\Users\MyName\source\repos\MyProject\aspnet-core\src\MyCompany.MyProject.Core\MyCompany.MyProject.Core.csproj : error NU1003: PackageTargetFallback and AssetTargetFallback cannot be used together. Remove PackageTargetFallback(deprecated) references from the project environment. [C:\Users\MyName\source\repos\MyProject\aspnet-core\MyCompany.MyProject.sln] 0 Warning(s) 1 Error(s)

Time Elapsed 00:00:04.73

When I'm running this code, I have started getting the below error, It was working fine before upgrading to 2.0.

await InsertAsync(ObjectMapper.Map<Test>(input));


[AutoMap(typeof(Test)]
    public  class TestInput
    {
        public int Id { get; set; }
        public  string TestCode { get; set; }
    }
	
	
[Table("Test")]
public class Test : FullAuditedEntity
{
	[Required]
	[MaxLength(250)]
	public string TestCode { get; set; }
}

AutoMapper.AutoMapperConfigurationException: Unmapped members were found. Review the types and members below. Add a custom mapping expression, ignore, add a custom resolver, or modify the source/destination type For no matching constructor, add a no-arg ctor, add optional arguments, or map all of the constructor parameters

TestInput -> Test (Destination member list) MyCompany.MyProject.Business.Dto.Tests.TestInput -> MyCompany.MyProject.Business.Model.Tests.Test (Destination member list)

Unmapped properties: IsDeleted DeleterUserId DeletionTime LastModificationTime LastModifierUserId CreationTime CreatorUserId

I have taken the latest code based on 2.0 and tried to merge it with old code.

I'm getting too many errors on build solution, please help.

Severity Code Description Project File Line Suppression State Error CS0117 'AppSettings' does not contain a definition for 'HostManagement' Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 169 Active Error CS0117 'AppSettings' does not contain a definition for 'HostManagement' Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 170 Active Error CS1061 'IModuleConfigurations' does not contain a definition for 'AspNetZero' and no extension method 'AspNetZero' accepting a first argument of type 'IModuleConfigurations' could be found (are you missing a using directive or an assembly reference?) Test.ABCD.Web.Public C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Public\Startup\ABCDWebFrontEndModule.cs 28 Active Error CS0006 Metadata file 'C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\bin\Debug\netcoreapp1.1\Test.ABCD.Application.dll' could not be found Test.ABCD.Web.Public C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Public\CSC 1 Active Error CS0006 Metadata file 'C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Business.Data\bin\Debug\netcoreapp1.1\Test.ABCD.Business.Repositories.dll' could not be found Test.ABCD.Web.Public C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Public\CSC 1 Active Error CS0006 Metadata file 'C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Business.Dto\bin\Debug\netcoreapp1.1\Test.ABCD.Business.Dto.dll' could not be found Test.ABCD.Web.Public C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Public\CSC 1 Active Error CS0006 Metadata file 'C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Business.Services\bin\Debug\netcoreapp1.1\Test.ABCD.Business.Services.dll' could not be found Test.ABCD.Web.Public C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Public\CSC 1 Active Error CS0006 Metadata file 'C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Core\bin\Debug\netcoreapp1.1\Test.ABCD.Web.Core.dll' could not be found Test.ABCD.Web.Public C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Public\CSC 1 Active Error NU1201 Project Test.ABCD.Application.Shared is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Project Test.ABCD.Application.Shared supports: netstandard2.0 (.NETStandard,Version=v2.0) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Test.ABCD.Application.csproj 1 Error NU1201 Project Test.ABCD.Application.Shared is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Project Test.ABCD.Application.Shared supports: netstandard2.0 (.NETStandard,Version=v2.0) Test.ABCD.ConsoleApiClient C:\Users\myname\source\repos\ABCD\aspnet-core\test\Test.ABCD.ConsoleApiClient\Test.ABCD.ConsoleApiClient.csproj 1 Error NU1201 Project Test.ABCD.Application.Shared is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Project Test.ABCD.Application.Shared supports: netstandard2.0 (.NETStandard,Version=v2.0) Test.ABCD.Business.Dto C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Business.Dto\Test.ABCD.Business.Dto.csproj 1 Error NU1201 Project Test.ABCD.Application.Shared is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Project Test.ABCD.Application.Shared supports: netstandard2.0 (.NETStandard,Version=v2.0) Test.ABCD.Business.Repositories C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Business.Data\Test.ABCD.Business.Repositories.csproj 1 Error NU1201 Project Test.ABCD.Application.Shared is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Project Test.ABCD.Application.Shared supports: netstandard2.0 (.NETStandard,Version=v2.0) Test.ABCD.Business.Services C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Business.Services\Test.ABCD.Business.Services.csproj 1 Error NU1201 Project Test.ABCD.Application.Shared is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Project Test.ABCD.Application.Shared supports: netstandard2.0 (.NETStandard,Version=v2.0) Test.ABCD.Web.Core C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Core\Test.ABCD.Web.Core.csproj 1 Error NU1201 Project Test.ABCD.Application.Shared is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Project Test.ABCD.Application.Shared supports: netstandard2.0 (.NETStandard,Version=v2.0) Test.ABCD.Tests C:\Users\myname\source\repos\ABCD\aspnet-core\test\Test.ABCD.Tests\Test.ABCD.Tests.csproj 1 Error NU1201 Project Test.ABCD.Application.Shared is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Project Test.ABCD.Application.Shared supports: netstandard2.0 (.NETStandard,Version=v2.0) Test.ABCD.Web.Host C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Host\Test.ABCD.Web.Host.csproj 1 Error CS0103 The name 'DatabaseCheckHelper' does not exist in the current context Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 112 Active Error CS0103 The name 'DefaultLanguagesCreator' does not exist in the current context Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 86 Active Error CS0103 The name 'SeedHelper' does not exist in the current context Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 56 Active Error CS0234 The type or namespace name 'AspNetZeroCore' does not exist in the namespace 'Abp' (are you missing an assembly reference?) Test.ABCD.Web.Public C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Web.Public\Startup\ABCDWebFrontEndModule.cs 1 Active Error CS0234 The type or namespace name 'EntityFrameworkCore' does not exist in the namespace 'Test.ABCD' (are you missing an assembly reference?) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 20 Active Error CS0234 The type or namespace name 'EntityFrameworkCore' does not exist in the namespace 'Test.ABCD' (are you missing an assembly reference?) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 20 Active Error CS0246 The type or namespace name 'HostBillingSettingsEditDto' could not be found (are you missing a using directive or an assembly reference?) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 167 Active Error CS0234 The type or namespace name 'Migrations' does not exist in the namespace 'Test.ABCD' (are you missing an assembly reference?) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 23 Active Error CS0234 The type or namespace name 'Migrations' does not exist in the namespace 'Test.ABCD' (are you missing an assembly reference?) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 23 Active Error CS0234 The type or namespace name 'Migrations' does not exist in the namespace 'Test.ABCD' (are you missing an assembly reference?) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 24 Active Error CS0234 The type or namespace name 'Migrations' does not exist in the namespace 'Test.ABCD' (are you missing an assembly reference?) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 24 Active Error CS0246 The type or namespace name 'ABCDDbContext' could not be found (are you missing a using directive or an assembly reference?) Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 34 Active Error CS0305 Using the generic type 'AbpZeroDbMigrator<TDbContext>' requires 1 type arguments Test.ABCD.Application C:\Users\myname\source\repos\ABCD\aspnet-core\src\Test.ABCD.Application\Install\InstallAppService.cs 38 Active

Question

Hi in abp When I delete record its soft delete by default, because it FullAuditedEntity inherits from ISoftDelete, Is it possible to implement hard deleted anyway?

One solution I thought that not to use FullAuditedEntity in the model class, but I will lose AuditedEntity<TPrimaryKey>, IFullAudited, IAudited, ICreationAudited, IHasCreationTime, IModificationAudited, IHasModificationTime, IDeletionAudited feature.

Or shall I have an abstract class similar to abstract class FullAuditedEntity<TPrimaryKey> and not inherit from, IHasDeletionTime, ISoftDelete?

Please provide your suggestions.

Thanks

Hi,

I was working on the previous version, I have just started upgradation to .net core 2.0. So I have two projects now old one and the new one. We have already started development on previous version 3-4 months back. So now to upgrade the old working project to the new framework I have to make changes in the existing project.

I 'm thinking to manually compare files by files by some comparator tool and It's taking too much time and it could to error-prone too.

So could you please suggest some good and easy way to do the same.

Thanks in advance.

I'm getting the error while trying to acces web application on browser. npm start is not giving any error

I have download .net core 2.0 and followed [https://aspnetzero.com/Documents/Getting-Started-Angular]) .

core.js:1350 ERROR Error: Cannot find module './en-US.js'. at webpackAsyncContext (eval at ../../../common/locales lazy recursive ^./..js$ (main.bundle.js:797), <anonymous>:4134:25) at eval (root.module.ts:63) at ZoneDelegate.invoke (zone.js:392) at Object.onInvoke (core.js:4629) at ZoneDelegate.invoke (zone.js:391) at Zone.run (zone.js:142) at eval (zone.js:844) at ZoneDelegate.invokeTask (zone.js:425) at Object.onInvokeTask (core.js:4620) at ZoneDelegate.invokeTask (zone.js:424) defaultErrorLogger @ core.js:1350 ErrorHandler.handleError @ core.js:1411 (anonymous) @ core.js:5561 ZoneDelegate.invoke @ zone.js:392 Zone.run @ zone.js:142 NgZone.runOutsideAngular @ core.js:4577 (anonymous) @ core.js:5561 ZoneDelegate.invoke @ zone.js:392 onInvoke @ core.js:4629 ZoneDelegate.invoke @ zone.js:391 Zone.run @ zone.js:142 (anonymous) @ zone.js:844 ZoneDelegate.invokeTask @ zone.js:425 onInvokeTask @ core.js:4620 ZoneDelegate.invokeTask @ zone.js:424 Zone.runTask @ zone.js:192 drainMicroTaskQueue @ zone.js:602 ZoneTask.invokeTask @ zone.js:503 invokeTask @ zone.js:1427 globalZoneAwareCallback @ zone.js:1445 XMLHttpRequest.send (async) scheduleTask @ zone.js:2744 ZoneDelegate.scheduleTask @ zone.js:411 onScheduleTask @ zone.js:301 ZoneDelegate.scheduleTask @ zone.js:405 Zone.scheduleTask @ zone.js:236 Zone.scheduleMacroTask @ zone.js:259 (anonymous) @ zone.js:2769 proto.(anonymous function) @ zone.js:1274 (anonymous) @ http.js:1605 Observable._trySubscribe @ Observable.js:172 Observable.subscribe @ Observable.js:160 MapOperator.call @ map.js:57 Observable.subscribe @ Observable.js:157 CatchOperator.call @ catchError.js:80 Observable.subscribe @ Observable.js:157 MergeMapOperator.call @ mergeMap.js:92 Observable.subscribe @ Observable.js:157 CatchOperator.call @ catchError.js:80 Observable.subscribe @ Observable.js:157 (anonymous) @ Observable.js:286 ZoneAwarePromise @ zone.js:861 Observable.toPromise @ Observable.js:284 (anonymous) @ app-session.service.ts:52 ZoneAwarePromise @ zone.js:861 AppSessionService.init @ app-session.service.ts:51 (anonymous) @ root.module.ts:36 (anonymous) @ LocalizedResourcesHelper.ts:8 fire @ index.js:3 fireWith @ index.js:3 (anonymous) @ index.js:3 fire @ index.js:3 fireWith @ index.js:3 (anonymous) @ index.js:3 fire @ index.js:3 fireWith @ index.js:3 done @ index.js:3 (anonymous) @ index.js:3 wrapFn @ zone.js:1075 ZoneDelegate.invokeTask @ zone.js:425 onInvokeTask @ core.js:4620 ZoneDelegate.invokeTask @ zone.js:424 Zone.runTask @ zone.js:192 ZoneTask.invokeTask @ zone.js:499 invokeTask @ zone.js:1427 globalZoneAwareCallback @ zone.js:1445 XMLHttpRequest.send (async) scheduleTask @ zone.js:2744 ZoneDelegate.scheduleTask @ zone.js:411 onScheduleTask @ zone.js:301 ZoneDelegate.scheduleTask @ zone.js:405 Zone.scheduleTask @ zone.js:236 Zone.scheduleMacroTask @ zone.js:259 (anonymous) @ zone.js:2769 proto.(anonymous function) @ zone.js:1274 send @ index.js:3 ajax @ index.js:3 jQuery.(anonymous function) @ index.js:3 getScript @ index.js:3 LocalizedResourcesHelper.loadLocalizedScripts @ LocalizedResourcesHelper.ts:44 LocalizedResourcesHelper.loadResources @ LocalizedResourcesHelper.ts:7 (anonymous) @ AppPreBootstrap.ts:148 fire @ index.js:3 fireWith @ index.js:3 deferred.(anonymous function) @ index.js:3 handleResponse @ index.js:3 (anonymous) @ index.js:3 fire @ index.js:3 fireWith @ index.js:3 done @ index.js:3 (anonymous) @ index.js:3 wrapFn @ zone.js:1075 ZoneDelegate.invokeTask @ zone.js:425 onInvokeTask @ core.js:4620 ZoneDelegate.invokeTask @ zone.js:424 Zone.runTask @ zone.js:192 ZoneTask.invokeTask @ zone.js:499 invokeTask @ zone.js:1427 globalZoneAwareCallback @ zone.js:1445 XMLHttpRequest.send (async) scheduleTask @ zone.js:2744 ZoneDelegate.scheduleTask @ zone.js:411 onScheduleTask @ zone.js:301 ZoneDelegate.scheduleTask @ zone.js:405 Zone.scheduleTask @ zone.js:236 Zone.scheduleMacroTask @ zone.js:259 (anonymous) @ zone.js:2769 proto.(anonymous function) @ zone.js:1274 send @ index.js:3 ajax @ index.js:3 (anonymous) @ index.js:3 Deferred @ index.js:3 abp.ajax @ index.js:3 AppPreBootstrap.getUserConfiguration @ AppPreBootstrap.ts:122 (anonymous) @ AppPreBootstrap.ts:35 (anonymous) @ AppPreBootstrap.ts:68 fire @ index.js:3 fireWith @ index.js:3 deferred.(anonymous function) @ index.js:3 (anonymous) @ index.js:3 fire @ index.js:3 fireWith @ index.js:3 done @ index.js:3 (anonymous) @ index.js:3 wrapFn @ zone.js:1075 ZoneDelegate.invokeTask @ zone.js:425 onInvokeTask @ core.js:4620 ZoneDelegate.invokeTask @ zone.js:424 Zone.runTask @ zone.js:192 ZoneTask.invokeTask @ zone.js:499 invokeTask @ zone.js:1427 globalZoneAwareCallback @ zone.js:1445 XMLHttpRequest.send (async) scheduleTask @ zone.js:2744 ZoneDelegate.scheduleTask @ zone.js:411 onScheduleTask @ zone.js:301 ZoneDelegate.scheduleTask @ zone.js:405 Zone.scheduleTask @ zone.js:236 Zone.scheduleMacroTask @ zone.js:259 (anonymous) @ zone.js:2769 proto.(anonymous function) @ zone.js:1274 send @ index.js:3 ajax @ index.js:3 (anonymous) @ index.js:3 Deferred @ index.js:3 abp.ajax @ index.js:3 AppPreBootstrap.getApplicationConfig @ AppPreBootstrap.ts:45 AppPreBootstrap.run @ AppPreBootstrap.ts:15 (anonymous) @ root.module.ts:33 ZoneAwarePromise @ zone.js:861 (anonymous) @ root.module.ts:32 ApplicationInitStatus.runInitializers @ core.js:3451 (anonymous) @ core.js:5379 _callAndReportToErrorHandler @ core.js:5558 (anonymous) @ core.js:5377 ZoneDelegate.invoke @ zone.js:392 onInvoke @ core.js:4629 ZoneDelegate.invoke @ zone.js:391 Zone.run @ zone.js:142 NgZone.run @ core.js:4446 PlatformRef.bootstrapModuleFactory @ core.js:5368 (anonymous) @ core.js:5447 ZoneDelegate.invoke @ zone.js:392 Zone.run @ zone.js:142 (anonymous) @ zone.js:844 ZoneDelegate.invokeTask @ zone.js:425 Zone.runTask @ zone.js:192 drainMicroTaskQueue @ zone.js:602 Promise resolved (async) scheduleMicroTask @ zone.js:585 ZoneDelegate.scheduleTask @ zone.js:414 Zone.scheduleTask @ zone.js:236 Zone.scheduleMicroTask @ zone.js:256 scheduleResolveOrReject @ zone.js:842 ZoneAwarePromise.then @ zone.js:932 setDriver @ localforage.js:2360 LocalForage @ localforage.js:2173 4.3 @ localforage.js:2422 s @ localforage.js:7 e @ localforage.js:7 (anonymous) @ localforage.js:7 i @ localforage.js:7 (anonymous) @ localforage.js:7 (anonymous) @ localforage.js:2428 ../../../../localforage/dist/localforage.js @ vendor.bundle.js:2051 webpack_require @ inline.bundle.js:55 (anonymous) @ local-storage.service.ts:3 ../../../../../src/shared/utils/local-storage.service.ts @ main.bundle.js:728 webpack_require @ inline.bundle.js:55 (anonymous) @ utils.module.ts:10 ../../../../../src/shared/utils/utils.module.ts @ main.bundle.js:752 webpack_require @ inline.bundle.js:55 (anonymous) @ app.module.ts:22 ../../../../../src/app/app.module.ts @ main.bundle.js:60 webpack_require @ inline.bundle.js:55 (anonymous) @ root.module.ts:11 ../../../../../src/root.module.ts @ main.bundle.js:536 webpack_require @ inline.bundle.js:55 (anonymous) @ main.ts:6 ../../../../../src/main.ts @ main.bundle.js:504 webpack_require @ inline.bundle.js:55 0 @ main.bundle.js:805 webpack_require @ inline.bundle.js:55 webpackJsonpCallback @ inline.bundle.js:26 (anonymous) @ main.bundle.js:1 zone.js:661 Unhandled Promise rejection: Cannot find module './en-US.js'. ; Zone: <root> ; Task: Promise.then ; Value: Error: Cannot find module './en-US.js'. at webpackAsyncContext (eval at ../../../common/locales lazy recursive ^./..js$ (main.bundle.js:797), <anonymous>:4134:25) at eval (root.module.ts:63) at ZoneDelegate.invoke (zone.js:392) at Object.onInvoke (core.js:4629) at ZoneDelegate.invoke (zone.js:391) at Zone.run (zone.js:142) at eval (zone.js:844) at ZoneDelegate.invokeTask (zone.js:425) at Object.onInvokeTask (core.js:4620) at ZoneDelegate.invokeTask (zone.js:424) Error: Cannot find module './en-US.js'. at webpackAsyncContext (eval at ../../../common/locales lazy recursive ^./.*.js$ (<a class="postlink" href="http://localhost:4200/main.bundle.js:797:1">http://localhost:4200/main.bundle.js:797:1</a>), <anonymous>:4134:25) at eval (webpack-internal:///../../../../../src/root.module.ts:80:102) at ZoneDelegate.invoke (webpack-internal:///../../../../zone.js/dist/zone.js:392:26) at Object.onInvoke (webpack-internal:///../../../core/esm5/core.js:4825:33) at ZoneDelegate.invoke (webpack-internal:///../../../../zone.js/dist/zone.js:391:32) at Zone.run (webpack-internal:///../../../../zone.js/dist/zone.js:142:43) at eval (webpack-internal:///../../../../zone.js/dist/zone.js:844:57) at ZoneDelegate.invokeTask (webpack-internal:///../../../../zone.js/dist/zone.js:425:31) at Object.onInvokeTask (webpack-internal:///../../../core/esm5/core.js:4816:33) at ZoneDelegate.invokeTask (webpack-internal:///../../../../zone.js/dist/zone.js:424:36)

I have a table which has a column as nvarchar(255), I want to change the length to nvarchar(250), But When I run update-database I get the following error.

Each package is licensed to you by its owner. NuGet is not responsible for, nor does it grant any licenses to, third-party packages. Some packages may include dependencies which are governed by additional licenses. Follow the package source (feed) URL to determine any dependencies.

Package Manager Console Host Version 4.3.0.4339

Type 'get-help NuGet' to see all available NuGet commands.

PM> Update-Database Executed DbCommand (56ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT OBJECT_ID(N'__EFMigrationsHistory'); Executed DbCommand (3ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT OBJECT_ID(N'__EFMigrationsHistory'); Executed DbCommand (7ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT [MigrationId], [ProductVersion] FROM [__EFMigrationsHistory] ORDER BY [MigrationId]; Applying migration '20171201072435_Updating DataTypes for Currencies based on SBO'. Executed DbCommand (108ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var0 sysname; SELECT @var0 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'CurrencyDetails') AND [c].[name] = N'NoOfDecimal'); IF @var0 IS NOT NULL EXEC(N'ALTER TABLE [CurrencyDetails] DROP CONSTRAINT [' + @var0 + '];'); ALTER TABLE [CurrencyDetails] ALTER COLUMN [NoOfDecimal] tinyint; Executed DbCommand (21ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var1 sysname; SELECT @var1 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'CurrencyDetails') AND [c].[name] = N'CurrencySymbol'); IF @var1 IS NOT NULL EXEC(N'ALTER TABLE [CurrencyDetails] DROP CONSTRAINT [' + @var1 + '];'); ALTER TABLE [CurrencyDetails] ALTER COLUMN [CurrencySymbol] nvarchar(3); Executed DbCommand (45ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var2 sysname; SELECT @var2 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'CurrencyDetails') AND [c].[name] = N'CurrencyDesc'); IF @var2 IS NOT NULL EXEC(N'ALTER TABLE [CurrencyDetails] DROP CONSTRAINT [' + @var2 + '];'); ALTER TABLE [CurrencyDetails] ALTER COLUMN [CurrencyDesc] nvarchar(40) NOT NULL; Executed DbCommand (2ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion]) VALUES (N'20171201072435_Updating DataTypes for Currencies based on SBO', N'1.1.2'); Done. PM> Update-Database Executed DbCommand (214ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT OBJECT_ID(N'__EFMigrationsHistory'); Executed DbCommand (9ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT OBJECT_ID(N'__EFMigrationsHistory'); Executed DbCommand (12ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT [MigrationId], [ProductVersion] FROM [__EFMigrationsHistory] ORDER BY [MigrationId]; Applying migration '20171201104545_Changing Defination for Test based on SBO'. Executed DbCommand (3,345ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var0 sysname; SELECT @var0 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'Test') AND [c].[name] = N'DescShort'); IF @var0 IS NOT NULL EXEC(N'ALTER TABLE [Test] DROP CONSTRAINT [' + @var0 + '];'); ALTER TABLE [Test] ALTER COLUMN [DescShort] nvarchar(40) NOT NULL; Executed DbCommand (1,356ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var1 sysname; SELECT @var1 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'Test') AND [c].[name] = N'DescLong'); IF @var1 IS NOT NULL EXEC(N'ALTER TABLE [Test] DROP CONSTRAINT [' + @var1 + '];'); ALTER TABLE [Test] ALTER COLUMN [DescLong] nvarchar(40) NOT NULL; Executed DbCommand (269ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var2 sysname; SELECT @var2 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'Test') AND [c].[name] = N'CurrencyCode'); IF @var2 IS NOT NULL EXEC(N'ALTER TABLE [Test] DROP CONSTRAINT [' + @var2 + '];'); ALTER TABLE [Test] ALTER COLUMN [CurrencyCode] nvarchar(3); Executed DbCommand (261ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var3 sysname; SELECT @var3 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'Test') AND [c].[name] = N'TestParent'); IF @var3 IS NOT NULL EXEC(N'ALTER TABLE [Test] DROP CONSTRAINT [' + @var3 + '];'); ALTER TABLE [Test] ALTER COLUMN [TestParent] nvarchar(255); Executed DbCommand (72ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion]) VALUES (N'20171201104545_Changing Defination for Test based on SBO', N'1.1.2'); Applying migration '20171201123035_Checking Unique Key Constrains'. Executed DbCommand (401ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DROP INDEX [IX_Article_ArticleName_IsDeleted] ON [Article]; Executed DbCommand (2ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion]) VALUES (N'20171201123035_Checking Unique Key Constrains', N'1.1.2'); Applying migration '20171201123219_Adding back Unique Constrains'. Executed DbCommand (1,021ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] CREATE UNIQUE INDEX [IX_Article_ArticleName_IsDeleted] ON [Article] ([ArticleName], [IsDeleted]); Executed DbCommand (9ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion]) VALUES (N'20171201123219_Adding back Unique Constrains', N'1.1.2'); Applying migration '20171201124913_Changing coloumn name for PromoPackResultsArticles'. Executed DbCommand (689ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] ALTER TABLE [PromoPackResultsArticles] DROP CONSTRAINT [FK_PromoPackResultsArticles_Article_ArticleId]; Executed DbCommand (195ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var4 sysname; SELECT @var4 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'PromoPackResultsArticles') AND [c].[name] = N'PromoPackArticleId'); IF @var4 IS NOT NULL EXEC(N'ALTER TABLE [PromoPackResultsArticles] DROP CONSTRAINT [' + @var4 + '];'); ALTER TABLE [PromoPackResultsArticles] DROP COLUMN [PromoPackArticleId]; Executed DbCommand (52ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DROP INDEX [IX_PromoPackResultsArticles_ArticleId] ON [PromoPackResultsArticles]; DECLARE @var5 sysname; SELECT @var5 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'PromoPackResultsArticles') AND [c].[name] = N'ArticleId'); IF @var5 IS NOT NULL EXEC(N'ALTER TABLE [PromoPackResultsArticles] DROP CONSTRAINT [' + @var5 + '];'); ALTER TABLE [PromoPackResultsArticles] ALTER COLUMN [ArticleId] int NOT NULL; CREATE INDEX [IX_PromoPackResultsArticles_ArticleId] ON [PromoPackResultsArticles] ([ArticleId]); Executed DbCommand (10ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] ALTER TABLE [PromoPackResultsArticles] ADD CONSTRAINT [FK_PromoPackResultsArticles_Article_ArticleId] FOREIGN KEY ([ArticleId]) REFERENCES [Article] ([Id]); Executed DbCommand (2ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion]) VALUES (N'20171201124913_Changing coloumn name for PromoPackResultsArticles', N'1.1.2'); Done. PM> Add-Migration cmdlet Add-Migration at command pipeline position 1 Supply values for the following parameters: Name: ChangeDatatypeLengthto250 An operation was scaffolded that may result in the loss of data. Please review the migration for accuracy. To undo this action, use Remove-Migration. PM> Update-Database Executed DbCommand (205ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT OBJECT_ID(N'__EFMigrationsHistory'); Executed DbCommand (116ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT OBJECT_ID(N'__EFMigrationsHistory'); Executed DbCommand (136ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT [MigrationId], [ProductVersion] FROM [__EFMigrationsHistory] ORDER BY [MigrationId]; Applying migration '20171203065419_ChangeDatatypeLengthto250'. Executed DbCommand (223ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var0 sysname; SELECT @var0 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'Test') AND [c].[name] = N'TestParent'); IF @var0 IS NOT NULL EXEC(N'ALTER TABLE [Test] DROP CONSTRAINT [' + @var0 + '];'); ALTER TABLE [Test] ALTER COLUMN [TestParent] nvarchar(250); Executed DbCommand (171ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] DECLARE @var1 sysname; SELECT @var1 = [d].[name] FROM [sys].[default_constraints] [d] INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id] WHERE ([d].[parent_object_id] = OBJECT_ID(N'Test') AND [c].[name] = N'TestCode'); IF @var1 IS NOT NULL EXEC(N'ALTER TABLE [Test] DROP CONSTRAINT [' + @var1 + '];'); ALTER TABLE [Test] ALTER COLUMN [TestCode] nvarchar(250) NOT NULL; System.Data.SqlClient.SqlException: The object 'IX_TestCode' is dependent on column 'TestCode'. ALTER TABLE ALTER COLUMN TestCode failed because one or more objects access this column. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async, Int32 timeout, Boolean asyncWrite) at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource1 completion, Boolean sendToPipe, Int32 timeout, Boolean asyncWrite, String methodName) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at Microsoft.EntityFrameworkCore.Storage.Internal.RelationalCommand.Execute(IRelationalConnection connection, String executeMethod, IReadOnlyDictionary2 parameterValues, Boolean closeConnection) at Microsoft.EntityFrameworkCore.Storage.Internal.RelationalCommand.ExecuteNonQuery(IRelationalConnection connection, IReadOnlyDictionary2 parameterValues) at Microsoft.EntityFrameworkCore.Migrations.Internal.MigrationCommandExecutor.ExecuteNonQuery(IEnumerable`1 migrationCommands, IRelationalConnection connection) at Microsoft.EntityFrameworkCore.Migrations.Internal.Migrator.Migrate(String targetMigration) at Microsoft.EntityFrameworkCore.Design.Internal.MigrationsOperations.UpdateDatabase(String targetMigration, String contextType) at Microsoft.EntityFrameworkCore.Design.OperationExecutor.UpdateDatabase.<>c__DisplayClass0_1.<.ctor>b__0() at Microsoft.EntityFrameworkCore.Design.OperationExecutor.OperationBase.Execute(Action action) ClientConnectionId:550138fa-3c27-4b75-86b8-55485492bcf9 Error Number:5074,State:1,Class:16 The object 'IX_TestCode' is dependent on column 'TestCode'. PM>

In old migration I have a file.

migrationBuilder.CreateTable(
                name: "Test",
                columns: table => new
                {
                    Id = table.Column&lt;int&gt;(nullable: false)
                        .Annotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn),
                    TestCode = table.Column&lt;string&gt;(maxLength: 255, nullable: false),
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_Test", x => x.Id);
                    table.UniqueConstraint("IX_TestCode", x => x.TestCode);
                });

New Migration class.

public partial class ChangeDatatypeLengthto250 : Migration
    {
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.AlterColumn&lt;string&gt;(
                name: "TestParent",
                table: "Test",
                maxLength: 250,
                nullable: true,
                oldClrType: typeof(string),
                oldMaxLength: 255,
                oldNullable: true);

            migrationBuilder.AlterColumn&lt;string&gt;(
                name: "TestCode",
                table: "Test",
                maxLength: 250,
                nullable: false,
                oldClrType: typeof(string),
                oldMaxLength: 255);
        }

        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.AlterColumn&lt;string&gt;(
                name: "TestParent",
                table: "Test",
                maxLength: 255,
                nullable: true,
                oldClrType: typeof(string),
                oldMaxLength: 250,
                oldNullable: true);

            migrationBuilder.AlterColumn&lt;string&gt;(
                name: "TestCode",
                table: "Test",
                maxLength: 255,
                nullable: false,
                oldClrType: typeof(string),
                oldMaxLength: 250);
        }
    }

I'm trying to use primeng fileupload. But I'm not able to find out how to save the uploaded image on some given path.

<p-fileUpload multiple="multiple"
                                  name="DefaultFileUploadFileInput[]"
                                  [url]="uploadUrl"
                                  accept="image/*"
                                  maxFileSize="1000000"
                                  (onUpload)="onUpload($event)">

                        <ng-template pTemplate="content">
                            <ul *ngIf="uploadedFiles.length">
                                <li *ngFor="let file of uploadedFiles">{{file.name}} - {{file.size}} bytes</li>
                            </ul>
                        </ng-template>
                    </p-fileUpload>
uploadUrl: string;
    uploadedFiles: any[] = [];

    constructor(
        injector: Injector,
        private demoUiComponentsService: DemoUiComponentsServiceProxy
    ) {
        super(injector);
        this.uploadUrl = AppConsts.remoteServiceBaseUrl + '/DemoUiComponents/UploadFiles';
    }

    // upload completed event
    onUpload(event): void {
        for (let file of event.files) {
            this.uploadedFiles.push(file);
        }
    };
Showing 41 to 50 of 68 entries