Opened 16 years ago
Closed 8 years ago
#482 closed defect (fixed)
Friendly message when trying to delete a permission that is being used by a group or user
| Reported by: | Mark J. Millard | Owned by: | bweaver |
|---|---|---|---|
| Priority: | major | Milestone: | Release Candidate 2 |
| Component: | Admin Tool | Version: | 1.5.1348 |
| Severity: | Keywords: | permission delete | |
| Cc: | Database Engine: | N/A | |
| Operating System: | N/A |
Description
I tried to delete a permission and I did not realize that it was being used by a group and/or a user. I got this exception. There should be a friendly message and if possible it should tell you what to do first so that the permission can be deleted.
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
Exception Text
System.Data.SqlClient.SqlException: The DELETE statement conflicted with the REFERENCE constraint "fk_sgpm_sp". The conflict occurred in database "gringlobal", table "dbo.sys_group_permission_map", column 'sys_permission_id'.
The statement has been terminated.
at GrinGlobal.Business.SecureData.DeletePermission(Int32 permID)
at GrinGlobal.Admin.AdminHostProxy.DeletePermission(Int32 permID)
at GrinGlobal.Admin.mdiParent.deletePermissionMenuItem_Click(Object sender, EventArgs e)
at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
Loaded Assemblies
mscorlib
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4952 (win7RTMGDR.050727-4900)
CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
GrinGlobal.Admin
Assembly Version: 1.5.1352.0
Win32 Version: 1.5.1352.0
CodeBase: file:///C:/Program%20Files%20(x86)/GRIN-Global/GRIN-Global%20Admin/GrinGlobal.Admin.exe
System.Windows.Forms
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
System
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
System.Drawing
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
Assembly Version: 1.5.1335.0
Win32 Version: 1.5.1335
CodeBase: file:///C:/Program%20Files%20(x86)/GRIN-Global/GRIN-Global%20Admin/GrinGlobal.InstallHelper.DLL
GrinGlobal.Core
Assembly Version: 1.5.1333.0
Win32 Version: 1.5.1333
CodeBase: file:///C:/Program%20Files%20(x86)/GRIN-Global/GRIN-Global%20Admin/GrinGlobal.Core.DLL
GrinGlobal.Business
Assembly Version: 1.5.1348.0
Win32 Version: 1.5.1348
CodeBase: file:///C:/Program%20Files%20(x86)/GRIN-Global/GRIN-Global%20Admin/GrinGlobal.Business.DLL
System.Configuration.Install
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Configuration.Install/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.Install.dll
System.Xml
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
System.Configuration
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
System.Data
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_32/System.Data/2.0.0.0__b77a5c561934e089/System.Data.dll
System.Transactions
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_32/System.Transactions/2.0.0.0__b77a5c561934e089/System.Transactions.dll
System.EnterpriseServices
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_32/System.EnterpriseServices/2.0.0.0__b03f5f7f11d50a3a/System.EnterpriseServices.dll
System.Web
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
CodeBase: file:///C:/Windows/assembly/GAC_32/System.Web/2.0.0.0__b03f5f7f11d50a3a/System.Web.dll
GrinGlobal.Interface
Assembly Version: 1.5.1333.0
Win32 Version: 1.5.1333
CodeBase: file:///C:/Program%20Files%20(x86)/GRIN-Global/GRIN-Global%20Admin/GrinGlobal.Interface.DLL
System.Core
Assembly Version: 3.5.0.0
Win32 Version: 3.5.30729.4926 built by: NetFXw7
CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Core/3.5.0.0__b77a5c561934e089/System.Core.dll
JIT Debugging
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.
For example:
<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>
When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.
Change History (3)
comment:1 by , 16 years ago
| Status: | new → addressed |
|---|
comment:2 by , 16 years ago
| Status: | addressed → released |
|---|
comment:3 by , 8 years ago
| Resolution: | → fixed |
|---|---|
| Status: | released → closed |
I tested on 1.10.2 version of the admin tool and I was able to delete policies that were used by users or groups. If groups were using a policy, I got a prompt that the policy was being used by this group do you want to proceed.

(In [1354]) - fixes #482, now prompts when permission is in use by group(s) or user(s)