Hi All,
I have used exiting dnn child portal template file and added some extra tabs in the portal. then when i go for importing template file via
program..then i get the following error:
Error parsing Portal TemplateViolation of UNIQUE KEY constraint 'IX_FolderPermission'. Cannot insert duplicate key in object 'dbo.FolderPermission'. The statement has been terminated. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) at System.Data.SqlClient.SqlDataReader.ConsumeMetaData() at System.Data.SqlClient.SqlDataReader.get_MetaData() at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) at System.Data.SqlClient.SqlCommand.ExecuteScalar() at Microsoft.ApplicationBlocks.Data.SqlHelper.ExecuteScalar(SqlConnection connection, CommandType commandType, String commandText, SqlParameter[] commandParameters) at Microsoft.ApplicationBlocks.Data.SqlHelper.ExecuteScalar(String connectionString, CommandType commandType, String commandText, SqlParameter[] commandParameters) at Microsoft.ApplicationBlocks.Data.SqlHelper.ExecuteScalar(String connectionString, String spName, Object[] parameterValues) at DotNetNuke.Data.SqlDataProvider.AddFolderPermission(Int32 FolderID, Int32 PermissionID, Int32 roleID, Boolean AllowAccess, Int32 UserID, Int32 createdByUserID) at DotNetNuke.Security.Permissions.PermissionProvider.SaveFolderPermissions(FolderInfo folder) at DotNetNuke.Security.Permissions.FolderPermissionController.SaveFolderPermissions(FolderInfo folder) at DotNetNuke.Entities.Portals.PortalController.AddFolderPermissions(Int32 PortalId, Int32 folderId) at DotNetNuke.Entities.Portals.PortalController.ParseTemplate(Int32 PortalId, String TemplatePath, String TemplateFile, Int32 AdministratorId, PortalTemplateModuleAction mergeTabs, Boolean IsNewPortal) at DotNetNuke.Entities.Portals.PortalController.CreatePortal(String PortalName, UserInfo objAdminUser, String Description, String KeyWords, String TemplatePath, String TemplateFile, String HomeDirectory, String PortalAlias, String ServerPath, String ChildPath, Boolean IsChildPortal)
Here Point to noted :
1) My template file location is in another web directory excluding DNN website.
2) I am importing template via another application using DNN application page via HTTPWeb Request object. I am getting this error in my HTTPResponse object .
3) child portal folder is created successfully and also in portals directory , also portal directory is created as new portalID.
One entry is added in Portals table but not added in PortalAlias table.
If anyone did this type of work previously, creating child portal in dnn application via another web application.
then please let me know the clue and idea about the process.
Thanks
Vyom Dixit
|