: 17 April 2014 05:48
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Sorting CSV data that begins with an IP address
This serves as another tool for the job example. The sort in *nux is as
simple as:
sort -n -t . -k 1,1 -k 2,2 -k 3,3 -k 4,4 ipaddress.file How easy is that ?.
Even OMVS has sort
On 17 April 2014 08:18, Sankaranarayanan, Vignesh
vignesh.v.sankaranaraya...@marks-and-spencer.com wrote:
I bet APL's solution to this would be like 2 weird symbols.
I was just introduced to it by my senior colleague today, and it's ... dense.
Like Perl, it's been called a write-only language.
APL has perhaps attracted more fanatic enthusiasts than any other
statement-level language. Over the years I have used it and still use
it for throwaway routines for which matrix algebra is the obvious,
appropriate formalism. (It does execution-time bound matrix algebra
superbly, but not much
On Thu, 17 Apr 2014 15:16:30 -0400, Farley, Peter x23353 wrote:
TSO Rexx does not support multiple tasks executing simultaneously. The
ATTACH* functions do attach a new task, but your attaching Rexx waits
synchronously for the attached task to complete.
I know! Dammit; that sucks!
The
On Thu, 17 Apr 2014 17:41:12 -0500, Norbert Friemel wrote:
On Thu, 17 Apr 2014 19:26:17 +, Sankaranarayanan, Vignesh wrote:
Ok.. Is it possible to fire off other REXXes repetitively (let's say 2 or 3,
each doing one function) that will not RETURN to the main, but write their
output to a
Gilmartin
Sent: 18 April 2014 00:02
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Sorting CSV data that begins with an IP address
On Thu, 17 Apr 2014 17:41:12 -0500, Norbert Friemel wrote:
On Thu, 17 Apr 2014 19:26:17 +, Sankaranarayanan, Vignesh wrote:
Ok.. Is it possible to fire off other REXXes
While not a MF solution, there is a add-in available for Excel called IP Tools
for Excel' that has a function that will allow you to sort IP addresses
correctly. You can get it at http://checkthenetwork.com/ip-tools-for-excel
There is a free trial period and then you need to pay $34.95 for a
First thing to do is check what the result of INREC looks like. Second is
to consider ICETOOL DATASORT to avoid sorting the header / trailer (or
else use OUTFIL to recreate them.
Cheers, Martin
From: Sankaranarayanan, Vignesh
vignesh.v.sankaranaraya...@marks-and-spencer.com
To:
On Wed, 16 Apr 2014 09:01:28 +, Sankaranarayanan, Vignesh wrote:
I need help sorting some 5000 lines based on the first entry in a CSV - IP
address. When sorting, I need the whole record to be involved in the sort, not
just the IP's.
I long ago gave up trying to decipher the runes to make
2014 12:30
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Sorting CSV data that begins with an IP address
On Wed, 16 Apr 2014 09:01:28 +, Sankaranarayanan, Vignesh wrote:
I need help sorting some 5000 lines based on the first entry in a CSV - IP
address. When sorting, I need the whole record
Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On
Behalf Of Shane Ginnane
Sent: 16 April 2014 12:30
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Sorting CSV data that begins with an IP address
On Wed, 16 Apr 2014 09:01:28 +, Sankaranarayanan, Vignesh wrote:
I need help sorting some 5000 lines
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Sorting CSV data that begins with an IP address
You ought to be able to do the +1 in DFSORT, by the way. In case that changes
the problem into a better one. :-)
Cheers, Martin
Martin Packer,
zChampion, Principal Systems Investigator, Worldwide Banking
Possibly the DFSORT INREC PARSE= feature might be usable to create your
static-length, zone-decimal value field for the sort of a 'typical' IP address
data-string in your CSV-format file.
Scott Barry
SBBWorks, Inc.
--
For
: Sorting CSV data that begins with an IP address
Possibly the DFSORT INREC PARSE= feature might be usable to create your
static-length, zone-decimal value field for the sort of a 'typical' IP address
data-string in your CSV-format file.
Scott Barry
SBBWorks, Inc
: MartinPacker
Blog:
https://www.ibm.com/developerworks/mydeveloperworks/blogs/MartinPacker
From: Sankaranarayanan, Vignesh
vignesh.v.sankaranaraya...@marks-and-spencer.com
To: IBM-MAIN@listserv.ua.edu
Date: 16/04/2014 14:56
Subject:Re: Sorting CSV data that begins with an IP address
Sent
Just a few of questions
1) is the file being shipped from MF to PC or PC to MF as CSV?
2) Does the sort need to be done on the MF?
3) If the data will be in Excel - why not do the sort there?
4) What version of Excel?
You have been given a lot of good suggestions. However, a better
on the
mainframe.
4) What version of Excel?
2013
- Vignesh
Mainframe Admin
-Original Message-
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf
Of Lizette Koehler
Sent: 16 April 2014 15:11
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Sorting CSV data that begins
@LISTSERV.UA.EDU
Subject: Re: Sorting CSV data that begins with an IP address
Possibly the DFSORT INREC PARSE= feature might be usable to create your
static-length, zone-decimal value field for the sort of a 'typical' IP address
data-string in your CSV-format file.
Scott Barry
SBBWorks, Inc
This thread is giving me a bit of trouble.
An IPA is internally a four-byte unsigned binary integer. By
convention it is formatted externally as a sequence of four unsigned
decimal integers separated by dots and with 'insignificant' leading,
leftmost zeros suppressed. Each byte can of course
Subject: Re: Sorting CSV data that begins with an IP address
Yup.
I used this but the file gets all messed up. I'm sure it's not the right SYSIN
for what I need to do.
INREC IFTHEN=(WHEN=INIT,
PARSE=(%01=(ENDBEFR=C'.',FIXLEN=3),
%02=(ENDBEFR=C'.',FIXLEN=3),
%03=(ENDBEFR=C
On Wed, 16 Apr 2014 10:26:17 -0400, John Gilmore wrote:
InN order to make it sortable lexicographically just one operation is
required: any and all short, less that three-digit, byte values need
to be padded out on the left to three digits with zeros.
Be quite careful doing that. I once did
On Wed, 16 Apr 2014 09:01:28 +, Sankaranarayanan, Vignesh wrote:
Hello,
I need help sorting some 5000 lines based on the first entry in a CSV - IP
address. When sorting, I need the whole record to be involved in the sort, not
just the IP's.
Sample data:
On Wed, 16 Apr 2014 14:17:42 +, Sankaranarayanan, Vignesh wrote:
It's FB.
- Vignesh
Mainframe Admin
With LRECL=133 try:
INREC PARSE=(%01=(ENDBEFR=C'.',FIXLEN=3),
%02=(ENDBEFR=C'.',FIXLEN=3),
%03=(ENDBEFR=C'.',FIXLEN=3),
Sankaranarayanan, Vignesh wrote:
Hello,
I need help sorting some 5000 lines based on the first entry in a CSV - IP
address. When sorting, I need the whole record to be involved in the sort, not
just the IP's.
Sample data:
IP,MAC,Make-Model,SEPINFO,Type,Ping,Status,Printer,GRPNAME Warehouse
Vignesh,
The following DFSORT/ICETOOL JCL will give you the desired results. I
assumed that you have 1 header record which you want to retain as is
//STEP0100 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN DD *
If the data is processed by a REXX routine after the sort anyway,
why not do this transformation before the sort with another REXX routine?
Should be a piece of cake ...
Then the sort ...
and if the leading zeroes indeed need to be removed again, you can do this
in the REXX routine which runs
Bernd,
The REXX processing after sort is not as much a transformation as it is a
search for the next available value from an IP block.
- Vignesh
Mainframe admin
On Apr 16, 2014 6:24:08 PM, Bernd Oppolzer bernd.oppol...@t-online.de wrote:
If the data is processed by a REXX routine after the
Vignesh.V.Sankaranarayanan@MARKS-
AND-SPENCER.COM
To: IBM-MAIN@listserv.ua.edu,
Date: 04/16/2014 10:29 AM
Subject: Re: Sorting CSV data that begins with an IP address
Sent by: IBM Mainframe Discussion List IBM-MAIN@listserv.ua.edu
Bernd,
The REXX processing after sort is not as much
vignesh.v.sankaranaraya...@marks-and-spencer.com
To: IBM-MAIN@listserv.ua.edu
Date: 16/04/2014 18:29
Subject:Re: Sorting CSV data that begins with an IP address
Sent by:IBM Mainframe Discussion List IBM-MAIN@listserv.ua.edu
Bernd,
The REXX processing after sort is not as much
The solution that someone finds to a given problem depends on
- the problem, of course
- the tools or skills he or she has available
For me, doing this task with DFSORT would involve long time of manual
reading, and maybe in the end I would find the solution.
With my given skills and tools,
This serves as another tool for the job example. The sort in *nux is as
simple as:
sort -n -t . -k 1,1 -k 2,2 -k 3,3 -k 4,4 ipaddress.file
How easy is that ?. Even OMVS has sort that should handle that.
For the real output required, I'd pipe the output of that to gawk and use an
associative
31 matches
Mail list logo