I created a bunch of views in one module and propagated them to numerous other modules using the excellent CopyView DXL. However, I was a bit too enthusiastic and now have several unrequired views that need to be deleted from all modules.
Has anyone developed a DXL that can do this, preferably one with a nice interface that allows you to pick the modules and views. I could hack CopyView, but I hate to re-invent the wheel...
Many thanks,
Ken.
mcnairk - Fri Apr 16 10:59:12 EDT 2010 |
|
Re: Deleting multiple views from multiple modules Bob_Swan - Wed Apr 21 03:12:57 EDT 2010
Attached is my effort for this task. It may make a starter for you.
It was written to delete specific views from modules being shared with stakeholders.
Sorry there is no 'nice interface', it was a one off for a dedicated task.
You have to detail the views within the code, it then deletes them from all modules in the current project.
It shouldn't be too hard to add some code to exclude specific modules.
Attachments
attachment_14458674_Kill_Views.txt
|
|
Re: Deleting multiple views from multiple modules mcnairk - Wed Apr 21 13:50:43 EDT 2010 Bob_Swan - Wed Apr 21 03:12:57 EDT 2010
Attached is my effort for this task. It may make a starter for you.
It was written to delete specific views from modules being shared with stakeholders.
Sorry there is no 'nice interface', it was a one off for a dedicated task.
You have to detail the views within the code, it then deletes them from all modules in the current project.
It shouldn't be too hard to add some code to exclude specific modules.
Bob,
With the following tweaks, I was able to get your DXL to do exactly what I needed.
-
Hard code killist of views to be deleted (obviously)
-
Comment out procedure "MakeMinView" (not needed by me)
-
Only process modules in current folder rather than entire project
I noted the following issues:
-
User must be logged on as the Administrator so they have write access to all views
-
The comment describing "ReportRemainingViews" seems incorrect; this procedure actually reports the remaining views in the module
I added the following to the wish list:
-
offer option to only process current folder (hard coded in my version)
-
create new log file for each run (e.g. append date/time stamp) rather than overwriting it
-
explicitly state in log if the view does not exist
-
explicitly state in log if the view could not be deleted
Many thanks,
Ken.
|
|
Re: Deleting multiple views from multiple modules llandale - Wed Apr 21 15:43:02 EDT 2010 mcnairk - Wed Apr 21 13:50:43 EDT 2010
Bob,
With the following tweaks, I was able to get your DXL to do exactly what I needed.
-
Hard code killist of views to be deleted (obviously)
-
Comment out procedure "MakeMinView" (not needed by me)
-
Only process modules in current folder rather than entire project
I noted the following issues:
-
User must be logged on as the Administrator so they have write access to all views
-
The comment describing "ReportRemainingViews" seems incorrect; this procedure actually reports the remaining views in the module
I added the following to the wish list:
-
offer option to only process current folder (hard coded in my version)
-
create new log file for each run (e.g. append date/time stamp) rather than overwriting it
-
explicitly state in log if the view does not exist
-
explicitly state in log if the view could not be deleted
Many thanks,
Ken.
Its not just that the Administrator can delete views, its also that the Administrator can even SEE them. 'Private' views are invisible to everybody except the user and the Administrator.
|
|
Re: Deleting multiple views from multiple modules mcnairk - Wed Apr 21 16:10:09 EDT 2010 llandale - Wed Apr 21 15:43:02 EDT 2010
Its not just that the Administrator can delete views, its also that the Administrator can even SEE them. 'Private' views are invisible to everybody except the user and the Administrator.
Thanks for the clarification.
|
|
Re: Deleting multiple views from multiple modules mcnairk - Wed Apr 21 16:16:15 EDT 2010 mcnairk - Wed Apr 21 16:10:09 EDT 2010
Thanks for the clarification.
I forgot to mention that if you provide an empty kill list, this DXL will simply log all views in all formal modules, which is useful in itself. I found a lot of junk views that I was not aware of...
|
|
Re: Deleting multiple views from multiple modules SystemAdmin - Tue Dec 18 14:15:59 EST 2012 mcnairk - Wed Apr 21 16:16:15 EDT 2010
I forgot to mention that if you provide an empty kill list, this DXL will simply log all views in all formal modules, which is useful in itself. I found a lot of junk views that I was not aware of...
Ken,
Thank you for providing notes on your edits. Is it possible to post your new version? I realize I am responding to messages that are two years old, however, it is worth asking. :)
|
|
Re: Deleting multiple views from multiple modules mcnairk - Wed Dec 19 08:26:53 EST 2012 SystemAdmin - Tue Dec 18 14:15:59 EST 2012
Ken,
Thank you for providing notes on your edits. Is it possible to post your new version? I realize I am responding to messages that are two years old, however, it is worth asking. :)
Here it is; I didn't develop it much since I don't use it that much and I don't have time to add bells and whistles.
Ken.
|
|
Re: Deleting multiple views from multiple modules mcnairk - Wed Dec 19 08:27:46 EST 2012 mcnairk - Wed Dec 19 08:26:53 EST 2012
Here it is; I didn't develop it much since I don't use it that much and I don't have time to add bells and whistles.
Ken.
Posted prematurely...
Attachments
attachment_14921532_Copy_of_Kill_Views_folder.dxl
|
|