It's all about the answers!

Ask a question

Two questions about "Deleting file content from the repository"


Jean-Michel Athane (671212) | asked Jul 25 '12, 9:37 a.m.
edited Jul 25 '12, 10:52 a.m.
This feature is available (if you are repository administrator) in the Eclipse interface.
I have 2 questions :
  - Does this feature remove completely and physically the file contents from the repository (impossible to hack)?
  - Is it available in command line (for scripted mass destructions)
Thanks !

Accepted answer


permanent link
Rolf Nelson (617159) | answered Jul 25 '12, 11:31 a.m.
JAZZ DEVELOPER
Yes,  delete will remove the file contents permanently.  The content is not accessible after deletion.   There is also a command line option for delete as well.   If you run scm.exe -help it will list all of the commands available in a given release.
Ralph Schoon selected this answer as the correct answer

6 other answers



permanent link
Ginny Ghezzo (33311117) | answered Jul 26 '12, 12:35 a.m.
JAZZ DEVELOPER
Jean-Michel, have you looked at this video, and in particular around minute 8:31 :
 http://www.youtube.com/watch?v=vFMiEanEELo

I looks like Chris lays out the three commands you will need.  

permanent link
Ginny Ghezzo (33311117) | answered Jul 26 '12, 4:18 p.m.
JAZZ DEVELOPER
Look at this hot off the presses :

"Deleting Content From Source Control in Rational Team Concert"
https://jazz.net/library/article/1006

permanent link
Jean-Michel Athane (671212) | answered Jul 25 '12, 12:17 p.m.
Thanks a lot, Rolf, for answering so quickly.. and positively !
I already looked at the command line of the 4.0.
I guess that the command to delete file contents is the command "scm delete state-content" but the documentation is very short - this is a general remark about scm - .. it says that it "deletes states of an item" .. which "state" of which "item" do I have to refer to in my case ?
More completely, I want to delete all file versions in a component which contains critical technology - after it has been transfered to a new server in a protected zone. What is the sequence of commands I should use to get finally to the data I want to delete ? I see that it is possible to get the list of all the changes sets of a component. Should I start from that point ?


permanent link
Jean-Michel Athane (671212) | answered Jul 26 '12, 3:39 a.m.
Oh YES ! It looks very simple (and "states" are more clear to me now). Thanks for your efficiency.

Comments
Ginny Ghezzo commented Jul 26 '12, 11:03 a.m.
JAZZ DEVELOPER

Yes Chris does a good job at providing clarity.


permanent link
Jean-Michel Athane (671212) | answered Jul 26 '12, 12:54 p.m.
Thanks to your help, I could develop my script that deletes all file contents in a component.

In my first tests, I did not use the --force option so, on some change sets, I got the message below :
For a better understanding of the consequences of this option, I wonder what kind of dependence it is and by which user situation it is generated.

>  ./scm delete state-content -r https://jazz-server:9443/jazz -u jazzy -P jazzy 1168 1169
The state "1169" content is referenced by 12 items:
  /net.jazz.uws.squawk/license.html
  /net.jazz.uws.build.scripts/license.html
  /net.jazz.uws.squawk.ui/license.html
  /net.jazz.uws.squawk.doc/license.html
  /net.jazz.uws.squawk.ui.tests/license.html
  ...
Rerun with --force option to delete the content. Deleting this content will also remove this content from all files that reference it.
Problem running 'delete state-content':
Failed to delete content.


Comments
John Camelon commented Jul 31 '12, 11:54 a.m.
JAZZ DEVELOPER

Please raise a work item to help us track this.
Thanks

JohnC SCM Lead



permanent link
Jean-Michel Athane (671212) | answered Jul 31 '12, 8:05 a.m.
edited Jul 31 '12, 11:06 a.m.
I got some problems while running my script on a "real life" example.
"list changesets" apparently returns invalid change set UUIDs and the content deletion cannot be completed.
For more information (script used, error description ..) , you can follow the WI 219646 on jazz.net
https://jazz.net/jazz/web/projects/Rational%20Team%20Concert#action=com.ibm.team.workitem.viewWorkItem&id=219646

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.