View previous topic :: View next topic
|
Author |
Message |
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
Hi,
I am trying to connect direct one file from mainframe to unix platform with STRIP.BLANKS=YES and datatype=text. My file has 3 records. 1st record is some data with trailing space. 2nd record is just one blank space. 3rd record is same as 1st record. When it reaches destination node the trailing spaces in 1st and 3rd records get removed. But the blank space in 2nd record doesn't get removed. Could you advise how to remove the space in 2nd record so that only one line feed remains in 2nd record once it reaches destination node.
Regards,
Saikat |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
you are looking for a connect direct option that deletes blank lines? |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
Hi,
Normally STRIP.BLANKS=YES removes blank spaces which is happening correctly for 1st and 3rd records in my file. But it's not behaving as expected for 2nd record. So please advise if there is any limitation for STRIP.BLANKS=YES in case only one space is there in whole record.
Regards,
Saikat |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello,
Why did you not answer DBZ's question? You might have believed you did, but unfortunately not directly.
I suspect that connect direct deletes trailing spaces, not entire records. This will be mentioned in the documentation. I don't use connect direct (other than some canned processes) and i'm not familiar with all of the options. |
|
Back to top |
|
|
Craq Giegerich
Senior Member
Joined: 19 May 2007 Posts: 1512 Location: Virginia, USA
|
|
|
|
saikat wrote: |
Hi,
Normally STRIP.BLANKS=YES removes blank spaces which is happening correctly for 1st and 3rd records in my file. But it's not behaving as expected for 2nd record. So please advise if there is any limitation for STRIP.BLANKS=YES in case only one space is there in whole record.
Regards,
Saikat |
Are you sure it a blank (space) character? |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
Hi,
I am not sure if I have made my point clear. Let me give you the scenario. My file has 3 records in mainframe. 1st record is some data with trailing space. 2nd record is just one space(hex value 40). 3rd record is same as 1st record and I am trying to connect direct the file from mainframe to unix platform with STRIP.BLANKS=YES and datatype=text. Please advise what should I expect to see in destination node for the file in 2nd record. Should it be space with line feed (hex value 40 25) or just line feed(hex value 25)? Hope this clarifies.
Regards,
Saikat |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2454 Location: Hampshire, UK
|
|
|
|
If you have already tried it then the result you get is what happens. Asking someone if it happens differently is a waste of time, time tht could be better spent looking up the manual to see what strip.blanks does and what restrictions there are on it. Probably worth looking up the manual at the same time to see what it does with zero length records. |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
Hi,
Lets not waste time then. I can see space with line feed (hex value 40 25) in destination node. I would rather expect just line feed(hex value 25) for 2nd record in destination node. I have gone thru several manuals but can't find the answer I am looking for. Can you advise how should I proceed to get desired result.
Regards,
Saikat |
|
Back to top |
|
|
Pete Wilson
Active Member
Joined: 31 Dec 2009 Posts: 590 Location: London
|
|
|
|
Here's an idea, why not pre-process the file to remove what you don't want using SORT and then just send the modified file.
I very much doubt CD is designed to remove a record, unless there is some exit it can call where that function can be executed by a separate program. |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
Hi,
I can pre-process the file to remove blank space but it will need a big change. I think CD can remove record because when I CD the same file to other server without any SYSOPT I can see the entire record to be removed in destination node. But the node where I want to cd my file I cant remove the blank space with or without sysopt.
Regards,
Saikat |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2454 Location: Hampshire, UK
|
|
|
|
If what you are trying to remove is a record that should not be there then the program that creates the dataset is in error and should be fixed. you should not be trying to provide a work-around for bad data. Why is running a sort step before the transfer tep a big change? 1 step, 5 or 6 JCL sttements (+comments) and a couple (or so) sysin cards. |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
Hi,
Lets not divert my concern from cd to change in program or jcl. I know this how to do. But this is not bad data. The data in file is correct and I have been using these kind of files for years because my existing destination node removes blank line which is expected. So it's not ideal to mess around with data which works fine for years. But now the problem is I am going to change the destination node with another node where I can't remove blank line using cd. Please think with respect to cd only and advise if its achievable using any sysopts.
Regards,
Saikat |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
well, probably suggestions for other solutions where made
when it became obvious that you were to lazy/stupid (whatever)
to determine why at
your site
when you change node, something in your process fails.
CD has 'procs', which define what can and can not be done.
i know that you can have a 'proc' that allows you to transfer 1 file
and you create another 'proc' to transfer 2 files during a session.
so, there is something in the 'proc' used for the original node allows you to do what ever you are doing that you like,
and there is something missing/included in the 'proc' used for the new node
that prohibits your desired behavior.
I really think that it is your responsibility to determine why,
especially since it is at your site and we do not have access. |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
Hello,
During the entire communication you couldn't suggest me which I don't know or which probably may help to overcome this cd issue. This suggests you are as lazy/stupid (whatever) as me. Anyway if anyone has some better knowledge on cd is most welcome to suggest me on this issue and I am also ready to furnish relevant information if required.
Regards,
Saikat |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
hey!
if you can do what you want going to one node but not to another,
what are the differences in the two processes? |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
hello fool!
Go thru the previous communication, you will get the answer. Don't brainstorm as you don't have anything to sugegst me. |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2454 Location: Hampshire, UK
|
|
|
|
Well, no. You have not said what is different between the 2 processes. You have mentioned the different results. You need to find the cause of the different results which will, probably, be due to a difference in setup of the two processes which only your Connect:Direct support staff can identify as has previously been mentioned. Maybe they overlooked something when setting up the other node or maybe they did it deliberatley. Whatever, we do not know as we are not your support staff. Now, I must get back to my pig farming. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
Anyway if anyone has some better knowledge on cd is most welcome to suggest me on this issue |
Suggest you open issue with Connect Direct Support. They can probably can tell you why this is happening.
My guess is that there is a difference in the setup on the destination nodes (assuming the exact same process is used. |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
I know we can remove trailing blank characters by using strip.blanks=yes, but is it possible to remove entire blank line using this? If not is there any option which we can use in connct direct to remove blank line? |
|
Back to top |
|
|
PeterHolland
Global Moderator
Joined: 27 Oct 2009 Posts: 2481 Location: Netherlands, Amstelveen
|
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
I can't see proper desciption for solution. |
|
Back to top |
|
|
PeterHolland
Global Moderator
Joined: 27 Oct 2009 Posts: 2481 Location: Netherlands, Amstelveen
|
|
|
|
Resolution Summary:
The Connect:Direct Server Adapter correctly strips blank
characters from inbound text documents, including lines
consisting of a single space character.
Delivered In:
B2B Integrator 5.2.3 iFix 9
What dont you understand from above? Ask your C support people. |
|
Back to top |
|
|
saikat
New User
Joined: 23 Jun 2008 Posts: 26 Location: pune
|
|
|
|
How can we install any new customized translation table in UNIX? |
|
Back to top |
|
|
PeterHolland
Global Moderator
Joined: 27 Oct 2009 Posts: 2481 Location: Netherlands, Amstelveen
|
|
|
|
Ask your Unix support people. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
How can we install any new customized translation table in UNIX? |
How does this relate to removing blank lines or is this a new question? |
|
Back to top |
|
|
|