Operating System - OpenVMS
1828483 Members
2790 Online
109978 Solutions
New Discussion

Re: numeric sorting script

 
SOLVED
Go to solution
nipun_2
Regular Advisor

numeric sorting script

Hi,
Does OpenVMs (I have V7.3-1) have some form of sort command.

I want to get numbers from users and sort them out in ascending order and write to a file.

Getting a number and writing is fine. But if there is a sort command that is efficient and easy to use I would like to know.

Thanks in Advance.

Nipun
7 REPLIES 7
labadie_1
Honored Contributor

Re: numeric sorting script

the command sort is available, check the help

$ help sort

you can specify keys and so on
Hein van den Heuvel
Honored Contributor
Solution

Re: numeric sorting script

As labdie replies, the command to sort on vms is... sort!

However, it may be worth pointing out that the VMS sort is strictly column based, and expect piced columns data.
The Unix sorts think in terms of 'fields' and may be easier to use for some problems.

If you can't figure it out from the sort help or the vms sort documentation in the VMS USers manual, then be sure to re-reply here with some sample data attached in a text file. You need to attach it, and not jsut include, in order to preserve the spaces and such.

Sort: http://h71000.www7.hp.com/doc/731FINAL/6489/6489pro_contents_002.html#toc_chapter_9

hth,
Hein.
nipun_2
Regular Advisor

Re: numeric sorting script

Hi Hein,
Here is the operator log file.
Today morning I tried to again boot Sat2 but in the following sequence
Main server (completely up and running)
boot Sat2 (same error as before boostrap failure)

boot Sat1 (sucessfully booted)

I am attaching the log file
nipun_2
Regular Advisor

Re: numeric sorting script

Hi,
sorry for the mixup. This was supposed to go somewhere else.

The sort command worked fine for me and I got my work done. Thanks a lot
Anton van Ruitenbeek
Trusted Contributor

Re: numeric sorting script

Nipun,

You should actualy check your DTSS settings. If not needed create the logical so DTSS is disabled (in SYS$STARTUP:NET$LOGICALS.COM - not later because DECNet is started very early in the sequence) or make sure you have a node DTSS serving !
If not found, a SYS$STARTUP:NET$LOGICALS.TEMPLATE should help you to create the NET$LOGICALS.COM !

AvR
NL: Meten is weten, maar je moet weten hoe te meten! - UK: Measuremets is knowledge, but you need to know how to measure !
comarow
Trusted Contributor

Re: numeric sorting script

I should point out that hypersort is also an option. In most cases it is faster than sort.

Performance is highly dependent on the data and working sets. We have found cases where larger working sets actually had slower sorts.

Finally, make sure that pagefilequota is larger than wsextent (which includes pql_mwsextent) or it will abort.

Often people think their wsextent is the UAF entry, but autogen set's pql_mwsextent equal to wsmax.
nipun_2
Regular Advisor

Re: numeric sorting script

Thanks for the info.