Check in to ClearCase fails - clearcase

I am trying to add a file into ClearCase, but I am getting the following error:
Error adding 'C:\PATH\file.dbc' to source control.
Changed Protection on "C:\PATH\file.dbc".
Created branch "C:\PATH\file.dbc" version "\main\0".
Type manager "text_file_delta" failed create_version operation.
Checked the following:
There are lines that have over 8000 characters and they must stay that way, so it can not use the "text_file_delta" as the type manager. I changed the type of one file to "compressed_file" and I was able to check it in.
I tried to add dbc compressed_file -name "*.[dD][bB][cC]" ; to the default.magic file. Then, I tried to check it with ct file test.dbc and it said that it is a compressed_file, but when I try to add an actual .dbc file to source control, it still gives me the error about the "text_file_delta" failing.
Is there something that I am missing with this? Maybe I put the line in the wrong part of the default.magic file?
Note: the only default.magic file that I am able to find is on the server side, is this correct? (I would rather it check here instead of everyone having to make one on their client.)

Make sure the default.magic file is taken into account, and is in the right directory, as mentioned in "About the ClearCase Magic file".
Make sure you did add the new rule in the right place in that magic file: see "How file types are determined when creating a new element"
Note: This is the first section in the default.magic file.
Example:
# Match by name without examining data
core file : -name "core" ;
compressed_file : -name "*.[nN][eE][wW]";
Note: The new file-typing rule that you add must come before the following line in the magic file:
text_file : -printable ;
compressed_file : !-printable ;
Use a personal magic file rather than modifying the default one:
Caution: It is highly recommended that you not modify the default.magic file directly as the next time an upgrade is performed, a new default.magic file will be created and your changes will be lost.
Creating a personal magic file with a name that is alphabetically before the "d" in the default.magic file name (such as cc.magic) will allow ClearCase to parse this file before the default.
It is better to create a personal magic file and possibly setting the MAGIC_PATH variable instead.

Related

In Mule , how to check two files exists or not

how to check two files exists or not. I mean two file patterns i.e. File* and errorFile*, if they exist then trigger a flow.
I am using File Connector (Mule 3.8) to start with one file with pattern File*, after that, I want to check for the second file exist i.e. errorFile* to continue with my process.
Maybe you should elaborate more about what you have attempted till now.
Following steps should help you go through:
Get a list of files at the location using 'List' element of the SFTP connector (Mule 4).
Parse this list and if you find the required filename, set a flow variable to a certain value.
Make use of the Choice element to trigger a subflow based on the value of the variable.

How do I reference a bibtex file from directory other than current project?

What I am trying to do is create a "Master" bibtex bibliography (organized via JabRef) in a convenient directory so that I do not need to copy new references from every project I work on into my master database. The issue I am coming up against is that while I can reference another file easily enough (e.g. for STATA regression table output), even if it is not in the same directory, the bibliography does not want to cooperate.
For the purposes of this example I have created a dummy directory in
My Documents/Course/Paper.
The Tex file in under
My Documents/Course/Paper/MasterTexFile.tex
and the example Tex file referenced in the code (simply called Text) is under
My Documents/Course/Text.tex.
My ideal is to have the bibliography in a more general directory altogether, but I have placed it just above the working tex file for illustrative purposes. Document code is as follows:
\documentclass[12pt,titlepage]{article}
\usepackage[round,longnamesfirst]{natbib}
\usepackage{setspace}
\doublespacing
\usepackage[margin=1in]{geometry}
\usepackage{hyperref}
\hypersetup{
pdftitle={TITLE},
pdfauthor={AUTHOR},
pdfsubject={SUBJECT},
pdfkeywords={KEYWORD} {KEYWORD} {KEYWORD},
colorlinks=true,
linkcolor=blue,
citecolor=blue,
filecolor=magenta,
urlcolor=blue
}
\begin{document}
\title{TITLE}
\date{\today}
\author{AUTHOR\\STUDENT NUMBER}
\maketitle
%Begin Document Text
\pagestyle{headings}
\section{Introduction}
\cite{Shapiro2015} %Example citation from my database
\input{../Text} %this comes from the directory ABOVE that of the current file.
%\input{../00 Master Bibliography} %This was inputted using the user interface (Texmaker). I have it here just to demonstrate that it is truly in the directory.
%References
\newpage
\bibliographystyle{plainnat}
\bibliography{../00 Master Bibliography}
%\bibliography{00_Master_Bibliography} %If the database is in the directory, everything works fine.
\end{document}
The document compiles (I use PdfLatex, BibTex, PdfLatex x2, sequentially), and properly references the Text document (which just contains the word "Text"), but I get the following errors:
Package natbib Warning: Citation `Shapiro2015' on page 1 undefined on input line 40.
Package natbib Warning: Empty `thebibliography' environment on input line 8.
Package natbib Warning: There were undefined citations.
Note: I have removed some lines of comments for brevity, so if you copy this into your editor the line numbers will be different.
These are to be expected if the database wasn't found, but I have no idea why it wouldn't be found. Does it have anything to do with natbib? Is it a feature of the natbib package that it cannot reference a database from any directory other than that of the current file? This seems unlikely.
Any help would be greatly appreciated!
Well, turns our there was a simple solution. I am not sure whether it is the '00' I had before the bibliography name (I added '00' to make sure it was at the top of the list of files in its folder), or the space between these and the word 'Bibliography', but changing the name of the file to simply `Bibliography' worked.

Why doesn't my SSIS File System Task recognize my destination path?

I've set up a File System path inside a ForEachFile enumerator in SSIS 2012. I'm iterating over a directory, loading each file, archiving that file, then processing the next file, etc. I've set the Destination folder via an expression that uses a Project Param value, and I get the source file from the variable set in the ForEachFile enumerator. The File System task says it can't find my Destination folder:
Here's the File System Task:
And proof that the destination folder exists:
Why am I getting this error? I'd swear I've used the exact same technique in SSIS 2008 and 2005. This is 2012, but it should work the same way.
I met the same problem and to resolve it i create a variable and i put something like this in the path.Be carefull you must put double "\ \".
So the path must be like this:"\ \ \ \ad1hfdalhp001\ \d$\ \data\ \Archive\ \"
The DestinationConnection field must contain a reference to a flat file connection. The error is saying that you have no Flat file connection manager with that name.
DestinationConnection should not be a free text field. You should be able to open a drop down in the DestinationConnection field and select or create a connection manager.
You will need to configure your output file path as the ConnectionString property on the file connection manager referenced in the DestinationConnection field.
Using a UNC is still an option. Similar to as you've done with the Source, on your Destination, set IsDestinationPathVariable = True and then push \server\path into a Variable User::ArchivePath or similar.
Otherwise, it is as user3922917 indicates: if IsDestinationPathVariable is false, then you need to use a File Connection manager.
In your comments, you indicate that you're building the UNC path based on an Expression in the File System Task. I find I have a better experience when I build my expressions in SSIS Variables and then simply assign that Variable into the Task's Expression. While this step may seem to provide another layer of maintenance, put a break point on the Task and tell me what the expression evaluates to. And you can't. It's only available to the object to use and you are unable to inspect it so you're left high and dry if your formula is off. Which never happens when you're having to deal with escaping a UNC path

SPSS permissions to write to file

I am using file handles to write my datasets to file in spss, which worked fine the first time.
FILE HANDLE directoryPath /NAME='D:\XX\Dropbox\XX\' .
FILE HANDLE write_data /NAME='directoryPath/dataset_1.sav' .
SAVE OUTFILE='write_data '
Now I get the following error:
>Error # 5332 in column 26. Text: write_data
>The specified file or directory is read-only and cannot be written to. The
>file will not be saved. Save the file with another name or to a different
>location or change the access permissions first.
>Execution of this command stops.
If I specify the full path rather than the file handle:
SAVE OUTFILE='D:\XX\Dropbox\XX\dataset_1.sav'
/COMPRESSED.
It works fine. As you can see, i am writing to a dropbox folder. I am not sure if this interferes with the permissions. Is there anyone that knows how to make my file handle example work by changing overall permissions, or do I need to revert back to changing my syntax manually?
File handles are not cumulative. Only the first portion can be interpreted as a file handle.

Clearcase issue while "add file to source control"

I am facing a following issue while adding a file to clearcase (UCM)
---------------------------
Rational ClearCase Explorer
---------------------------
Error adding 'M:\Myviename\Myvob\Myproj\Implementation\DataSource\Deployment\BOM\SupportFiles\Service.config' to source control.
Created branch "Tm6-Proj-Dev2" from M:\Myviename\Myvob\Myproj\Implementation\DataSource\Deployment\BOM\SupportFiles\Service.config' version "\main\0".
Type manager "text_file_delta" failed create_version operation.
I tried rebase and deleted and added the file again. But facing the same. Why this occured and how to solve it?
You will find all the know cases for this error message in this technote "Knowledge Collection: Type manager <text_file_delta> failed create_version operation"
Type manager size limitation - File too large
Text files that contain binary data - Contains a '\000'
Line exceeding 8000 bytes
Corrupt source container - not the highest on its branch
The main cause is a content incompatible with a text file (line too long, or binary content).
The OP Samselvaprabu adds:
Our IT guys used the following command "chtype Compressed_file".
After that it allowed to check-in.
As they did it in my collegue system, I was not able to ask what does this mean and how it solved the issue?
It does solve the issue (and it has nothing to do with UCM): since the text_manager doesn't recognized the content of the file as text (as illustrated, for instance, in this technote), you need to instruct ClearCase to treat it as binary content.
cleartool chtype compressed_file <filename>
Pro: it allows for checkin/checkouts
Cons: you won't be able to "compare with previous version" anymore.
You might need to instruct that compressed_file to be always copied over instead of merged (see "Clearcase UCM is trying to merge pdf files")
For certain set of files, you could also modify the magic file to automate that process: see "Check in to ClearCase fails".
Which type of view are you using ? Static(Snapshot) or Dynamic ?
check if file is already there on the main.
If the file is already there on main (which means file is Versioned file) then before editing you should check-out file and then after making changes you need to check in.
If you are using versioned file and you if made changes to this versioned file then it will be a hijacked file, (you will see red+green mark for on the file in clear case explorer).
Try out once.

Resources