dsx is 0 kb after changing read-only from 1 to 0

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
SandhyaShetty21
Premium Member
Premium Member
Posts: 17
Joined: Wed Nov 30, 2011 1:16 am

dsx is 0 kb after changing read-only from 1 to 0

Post by SandhyaShetty21 »

Hi All,

I have encountered a wierd issue during an import/export.

We had to refresh the QA code with that in production. We took the export from Production.
We modified the .dsx with the read only '1' to '0' to make it writeable.
But after doing that .dsx size changed to 0KB (i.e it was empty).

Anybody has any idea what could be the reason for this?
asorrell
Posts: 1707
Joined: Fri Apr 04, 2003 2:00 pm
Location: Colleyville, Texas

Post by asorrell »

Bad edit?

Can you reproduce the problem?
Andy Sorrell
Certified DataStage Consultant
IBM Analytics Champion 2009 - 2020
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Re: dsx size changing to 0kb after changng read only from 1

Post by chulett »

SandhyaShetty21 wrote:But after doing that .dsx size changed to 0KB (i.e it was empty).
If you edit a file and it's empty afterwards, I'm going to have to side with Andy. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
SandhyaShetty21
Premium Member
Premium Member
Posts: 17
Joined: Wed Nov 30, 2011 1:16 am

Post by SandhyaShetty21 »

Thanks All for your prompt replies. :)

What we did was, Since it was a huge export, we replaced all the read-only from '1' to '0'.

Do you think this is an incorrect way to make a job writeable.
Is there any other way?

As a workaround we just imported it without changing the read-only from 1 to 0. But not quite sure if may have problems. So can you please let me know if its really required to change read only from 1 to 0 before importing.
asorrell
Posts: 1707
Joined: Fri Apr 04, 2003 2:00 pm
Location: Colleyville, Texas

Post by asorrell »

You have to change both job level attributes and stage level attributes.

Of course, modifying the dsx is not supported, and you do so at your own risk, but for more details, check out the description of the "manual" method in this post:
viewtopic.php?t=130036
Andy Sorrell
Certified DataStage Consultant
IBM Analytics Champion 2009 - 2020
SandhyaShetty21
Premium Member
Premium Member
Posts: 17
Joined: Wed Nov 30, 2011 1:16 am

Post by SandhyaShetty21 »

Agreed modifying the dsx is not a recommended approach to make the dsx writeable. But i am unaware of any other approach.

Can you please suggest what needs to be done to make the dsx writeable.
If I am directly importing the code without making any changes to read-only parameter what problems can i expect.
arunkumarmm
Participant
Posts: 246
Joined: Mon Jun 30, 2008 3:22 am
Location: New York
Contact:

Post by arunkumarmm »

SandhyaShetty21 wrote:If I am directly importing the code without making any changes to read-only parameter what problems can i expect.
I don't think that will give you a problem but all you can do is, view or run the job. You will not be able to edit it.
Arun
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

If the size of the DSX file is now 0 bytes you have managed to empty it of content, probably by using the wrong command in whatever editor you're using.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Welcome to last week, Ray. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
SandhyaShetty21
Premium Member
Premium Member
Posts: 17
Joined: Wed Nov 30, 2011 1:16 am

Post by SandhyaShetty21 »

ray.wurlod wrote:If the size of the DSX file is now 0 bytes you have managed to empty it of content, probably by using the wrong command in whatever editor you're using.
We have just replaced the read only = 1 field wherever present to read only = 0.
roy
Participant
Posts: 2598
Joined: Wed Jul 30, 2003 2:05 am
Location: Israel

Post by roy »

Hi,
I was wondering, was the read only attribute the product of importing to a protected project?
Might be worth while to protect and unprotect (via Administrator client) turn your jobs to editable?
(just thinking, cause I don't have DS V7 available)

P.S.
If you want to be able to edit your jobs you want the read only attribute set to 0 :wink:

IHTH (I Hope This Helps),
Roy R.
Time is money but when you don't have money time is all you can afford.

Search before posting:)

Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
Image
SandhyaShetty21
Premium Member
Premium Member
Posts: 17
Joined: Wed Nov 30, 2011 1:16 am

Post by SandhyaShetty21 »

Thanks all for your responses. However, I have been able to narrow down the issue to the Editor I used .. That was NOTEPAD++. Using Wordpad/Notepad for replacing the ReadOnly field works perfectly fine.
Post Reply