Re: [U2] Multi-threaded phantom processing

2014-03-05 Thread Rick Nuckolls
As elegant as some of these ideas are, it might be possible, depending on the 
number and nature of the transactions, to batch them up every n seconds and use 
rcp to copy them to an "in" box on the remote machine. 

-Rick

> On Mar 5, 2014, at 4:19 PM, "Horacio Pellegrino"  
> wrote:
> 
> Why don't you have one port listening for requests, and as soon as they
> come in, you create a new phantom to answer that request ( liberating the
> listener immediately for the next request ), then when the phantom finishes
> it could log off.
> 
> Might be you want to keep a "pool" of phantoms alive for a while, on the
> assumption they might be reused. That way you are sill using one license
> per request, but you have the benefit of "pooling"... You can always set
> min-max limit for those phantom-workers.
> 
> Horacio Pellegrino
> 
> 
> 
> 
> On Tue, Mar 4, 2014 at 11:30 PM, Peter Cheney
> wrote:
> 
>> Thanks David. As they say "Bigger than Ben-Hur"!
>> 
>> That's a great idea. The server I have is listening on a predetermined
>> port. I trolled through /etc/services and a netstat on the remote host to
>> select something that looked unused.
>> 
>> So then if it the main phantom spawns 1-n children (presumably more
>> phantoms?), it would also need to select 1-n ports which I suppose must
>> also be predetermined? Or is there a call to the OS that can return an
>> unused port? We're on AIX but the remote host is HPUX.
>> 
>> Cheers
>> Peter
>> 
>> 
>> 
>> Peter Cheney
>> Ultracs Developer
>> t 07 3017 8837 | f 07 3002 8400
>> e peter.che...@firstmac.com.au
>> w firstmac.com.au
>> 
>> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org [mailto:
>> u2-users-boun...@listserver.u2ug.org] On Behalf Of David A. Green
>> Sent: Wednesday, 5 March 2014 13:01
>> To: 'U2 Users List'
>> Subject: Re: [U2] Multi-threaded phantom processing
>> 
>> Peter, first of all let me congratulate you on this achievement.  Having
>> just finished a similar feat using UniData I understand the complexities
>> that went into it.
>> 
>> The system I'm current working with will be relatively low traffic.  But I
>> was pondering on the method of having a server socket that would just spawn
>> a transfer server socket and send the socket address to the calling client.
>> Then the client disconnects from the main server and just uses the
>> transfer server to complete the task.
>> 
>> Having 10 open phantoms with sockets will use up 10 licenses.
>> 
>> David A. Green
>> (480) 201-7953
>> DAG Consulting
>> 
>> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org [mailto:
>> u2-users-boun...@listserver.u2ug.org] On Behalf Of Peter Cheney
>> Sent: Tuesday, March 04, 2014 6:18 PM
>> To: U2 Users List (u2-users@listserver.u2ug.org)
>> Subject: [U2] Multi-threaded phantom processing
>> 
>> Hi Everyone,
>> 
>> A project that I'm currently working on requires transmission of
>> transactional and ancillary data from one UV site to site to another.
>> I have the communications all set up and it is working very well via the
>> UV socket functions with a client at one end and a server at the other.
>> Both the client and the server both run as a UV phantom processes written
>> in UV basic and the data being transferred (also encrypted) is more or less
>> real time with various UV file triggers on the client end creating queue
>> items for transmission based on the data content / transaction type.
>> 
>> This set up is a single threaded affair and I am wondering how it will
>> cope and what options I'll have as the volume of data increases.
>> 
>> Multi-threading my server process to dish out some of the load might be
>> one possibility and I've seen examples in the past where the last digit of
>> a numeric key (i.e. 0-9) is used to determine which one of 10 phantoms to
>> call thus providing an effective distribution of the work.
>> 
>> But even then, reading/writing processing data to a file for each child
>> process seems to me to be the only way to achieve parent <-> child phantom
>> communications at either end. Is there another way perhaps? It may be that
>> I will need 2 sets of phantoms, 1 for the transactions and one for the
>> ancillary data. Although we run UV on AIX the only other requirement is
>> that I must be able to do it within UV Basic.
>> 
>> Does anyone out there on the list know of a better way or any
>> alternatives/advice so I can get a better appreciation of what else might
>> be possible please?
>> 
>> Many thanks in advance,
>> Peter
>> 
>> 
>> Peter Cheney
>> Ultracs Developer
>> t 07 3017 8837 | f 07 3002 8400
>> e peter.che...@firstmac.com.au
>> w firstmac.com.au
>> 
>> 
>> 
>> ---
>> Note:
>> This email (inc all attachments) is for the use of the intended
>> recipient(s) only.
>> Privileged or confidential information may be contained in this
>> communication. If you have received this email in error, please

Re: [U2] Self Deadlatch error on device 655372, inode 610205, group 11460608, latch 80000 to WRITE.

2014-02-02 Thread Rick Nuckolls
I thought that I responded earlier -- but cannot find the rest of the thread.

Ken,
Generally, this would be caused by a secondary index that accesses the primary 
file via a subroutine.

You can verify the file (in Unix) by using 

ls -i |grep 610205   or find . -ls |grep 610205

Group WR locks are exclusive, so any attempt to access either the same record 
being updated in the primary file, or another record in the same group will 
fail when the group lock is encountered.

Good luck,
Rick Nuckolls
Lynden Inc.

From: u2-users-boun...@listserver.u2ug.org 
[u2-users-boun...@listserver.u2ug.org] On Behalf Of Ken Ford 
[ken.f...@firstmac.com.au]
Sent: Sunday, February 02, 2014 6:25 PM
To: 'u2-users@listserver.u2ug.org'
Subject: [U2] Self Deadlatch error on device 655372, inode 610205, group 
11460608, latch 8 to WRITE.

We are getting the error in the subject line in a 3rdParty program (no 
sourcecode).  We have recreated the file, resized the file and rebuilt its 
secondary indices, and still get the error.  There is a group lock when it 
occurs.  A search of the archives has not produced anything useful.  Any ideas 
would be appreciated.

Thanks.

Ken Ford
Firstmac Ltd
Brisbane QLD
Australia

 ---
Note:
This email (inc all attachments) is for the use of the intended recipient(s) 
only.
Privileged or confidential information may be contained in this communication. 
If you have received this email in error, please notify the sender immediately 
and then delete all copies of this message from your computer network. If you 
are not the intended recipient, you must not keep, use, disclose, copy or 
distribute this email without the author's prior permission. If you are the 
intended recipient and you do not wish to receive similar electronic messages 
from us in future, then please respond to the sender to this effect.
We have taken precautions to minimise the risk of transmitting software 
viruses, but advise you to carry out your own virus checks on this email and 
its attachments. We do not accept liability for any loss or damage caused by 
software viruses and do not represent that this transmission is free from 
viruses or other defects.
Firstmac Limited (ABN 59 094 145 963) (AFSL 290600)
 ---
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UV/Net usage and licensing

2013-12-12 Thread Rick Nuckolls
They will fail.  This may be trapped with an ON ERROR clause in the io 
statement.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Peter Cheney
Sent: Thursday, December 12, 2013 2:38 PM
To: 'U2 Users List'
Subject: Re: [U2] UV/Net usage and licensing

Hi again,

Just on this remote file access, can anyone advise what happens if the remote 
host is off air such as communications outage or server failure?

Do the read/writes queue somehow? Or do they simply fail requiring further 
coding to accommodate?

Many thanks again.
Cheers
Peter



Peter Cheney
Ultracs Developer
t 07 3017 8837 | f 07 3002 8400
e peter.che...@firstmac.com.au
w firstmac.com.au


-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Peter Cheney
Sent: Thursday, 12 December 2013 17:10
To: 'U2 Users List'
Subject: Re: [U2] UV/Net usage and licensing

Thanks David,

There was some confusion about if both hosts need the license and if only one 
then which? Based on what you've written re the setup below, and from what our 
VAR has advised I think the remote host will require a UVnet licence which it 
does not currently have.

I am now going to re-check the alignment of the actual UID and GID's as you 
mentioned below and perhaps turn on logging too.

Thanks again for the other tips. Most appreciated.

Regards,
Peter



Peter Cheney
Ultracs Developer
t 07 3017 8837 | f 07 3002 8400
e peter.che...@firstmac.com.au
w firstmac.com.au


-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Hona, David
Sent: Thursday, 12 December 2013 16:45
To: U2 Users List
Subject: Re: [U2] UV/Net usage and licensing

Hi Peter,

It's been a while since I've used/played around with UV/Net, but this may 
help...

1. Setup
You only need a ensure UniRPC is active and you license for UV/Net on the 
server you wish to access. I don't recall you need to anything other than the 
UniRPC Daemon listening for requests and it will invoke uvnet for your client 
request.

2. Security
I can't recall if you're using UNIX or not...(it is supposed to OS independent)

Although, UV/Net is supposed to set the effective user (UID numer) and group 
(GID numer) for the remote users connecting to the remote UV server...if 
required. Plus if specified - as you're doing so. My experience with similar DB 
product tools is it is far better to have the UID and GIDs directly aligned. 
Specifically: make sure the UID and GID for the same named accounts are exactly 
the same on both servers. Or if you use SET.REMOTE.ID that the account locally 
has sufficient rights or in fact it exists.

I have issues with the same accounts and groups on different users have 
different UIDs and GIDs on the different client and servers - causing grief/ 
havoc on similar products to UV/Net, etc.

Also - check if you have UniVerse Dynamic Type30 files, that your UNIX file 
ownerships, group ownership and Other are set exactly the same. This includes 
the hidden file.Type30. Having different settings are recipe for lots of grief!

Finally, be forewarned that allowing testers/developers access to your 
production server via UV/Net is an EXTREMELY bad idea! (Career terminating if 
things go pear shaped when they have write/delete rights!). It is far too easy 
for these types of users to be unaware their test account is in fact pointing 
to your production service and there access is write/delete.

Did you try the UVNETRID environment variable in place of SET.REMOTE.ID? If you 
are still having issues, you may have to enabled UniRPC debugging which is very 
extensive and generate logs of data - but is useful for seeing exactly where 
things are going wrong.

Cheers,
David



-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Peter Cheney
Sent: Thursday, 12 December 2013 2:23 PM
To: U2 Users List (u2-users@listserver.u2ug.org)
Subject: [U2] UV/Net usage and licensing

Hi Everyone,

We’re looking at doing some remote file mangling and was wondering if there are 
any gotchas when using UV/Net to do this?

In my scenario if I am on host A and want to read/write files on host B. Host B 
only needs to read/write files on host B but not on host A. Do I need UV/Net on 
host A as well as host B or just on host A? Host A is running UV 10.3.4 and 
host B is running UV 10.2.6.

Local testing on host A to host A/DR shows record locking is working OK but if 
the remote file does not have read/write on ‘other’ (e.g. 660) then all writes 
fail regardless of how I spec the credentials via SET.REMOTE.ID. Setting the 
permissions to 666 is the only way I can get this to work even when using the 
same login and group membership at each end.

Also does anyone know if firewall ports other than standard unirpc port 31438 
need to be

Re: [U2] List of display control @ variables for UVBasic

2013-11-19 Thread Rick Nuckolls
The ATFUNCTIONS.H record in UNIVERSE.INCLUDE file has equates and descriptions.

Rick Nuckolls
Lynden Inc

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Jeff Schasny
Sent: Tuesday, November 19, 2013 1:54 PM
To: U2-Users@listserver.u2ug.org
Subject: [U2] List of display control @ variables for UVBasic

Anyone know where the list of @ variables for display control ( @(-1) = 
clear screen) is in the Universe documentation? I can't seem to find it.

Thanks

-- 

Jeff Schasny - Denver, Co, USA
jschasny at gmail dot com

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Web Services at Universe 11.n

2013-10-30 Thread Rick Nuckolls
Is there any security on the target url?  You might need a "Host" header, if 
the url/ db is checking.

-Rick



-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Richard Lewis
Sent: Wednesday, October 30, 2013 4:17 PM
To: U2 Users List
Subject: Re: [U2] Web Services at Universe 11.n

Tried that already, but thanks for the suggestion.  By the way, the curl
solution doesn't require that header to get a successful response.

Richard Lewis

On Wed, Oct 30, 2013 at 5:01 PM, Rick Nuckolls  wrote:

> If you have not done so yet, try adding the header for Content-Type before
> making the request.
>
> ie. setRequestHeader(handle, 'Content-Type', 'text/html')
>
> Rick Nuckolls
> Lynden
>
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org [mailto:
> u2-users-boun...@listserver.u2ug.org] On Behalf Of Richard Lewis
> Sent: Wednesday, October 30, 2013 3:43 PM
> To: U2 Users List
> Subject: Re: [U2] Web Services at Universe 11.n
>
> Yes, as I said, I've tested with curl and it works perfectly.  The problem
> I have is not being able to clearly/cleanly see the raw text being sent by
> the uv functions, in order to determine the difference in what curl sends
> (success) and what the uv functions send (failure).  There may be certain
> idiosyncratic parsing involved in the service I am trying to consume, but I
> have no control over that.  With curl I can see the entire conversation if
> the logging is set correctly.  With the uv functions, even with the highest
> logging level, it doesn't appear that the logging is actually that complete
> and exact.  I have never had the impression that it was.
>
> I would love to be able to do it all in uv, but I only have control over
> half of the conversation, and with the uv functions, I seem to have a bit
> less than half.
>
> Richard
>
>
> On Wed, Oct 30, 2013 at 2:12 PM, Symeon Breen  wrote:
>
> > That means you where probably missing a header.   http is just a text
> > conversation, if the same headers are passed as passed with curl it will
> > work. You can test using curl, or even better with telnet.
> >
> > -Original Message-
> > From: u2-users-boun...@listserver.u2ug.org
> > [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Richard Lewis
> > Sent: 30 October 2013 20:03
> > To: U2 Users List
> > Subject: Re: [U2] Web Services at Universe 11.n
> >
> > I've recently been tasked with accessing a webservice, and couldn't get a
> > valid response from the webservice.  It kept not recognizing the headers
> > that were sent, and with the maximum logging set on the uv side, it
> looked
> > like everything was being sent just fine, but the webservice still failed
> > it.  I switched to using curl, and it all worked perfectly.
> >
> > Richard Lewis
> >
> >
> >
> > On Wed, Oct 30, 2013 at 1:00 PM, Oaks, Harold
> > wrote:
> >
> > > I've been telling my boss that if we upgraded to Universe 11.23, we can
> > > implement web services.   (We're currently on 10.2)
> > > But,  finally looking in detail at the appropriate manual  (Universe
> > > Web Services Developer) it seems that one can publish a web service
> > > easily enough so that Universe data can be gotten, but I don't see
> > > that the other side is implemented, where one accesses an external web
> > > service and brings back data into Universe.  Am I missing the
> something?
> > >
> > > What are any of you using to fully implement web services with an
> > > underlying Universe environment?
> > > Thanks-
> > > Harold Oaks
> > > Sr. Analyst/Programmer
> > > Clark County, WA
> > >
> > > This e-mail and related attachments and any response may be subject to
> > > public disclosure under state law.
> > > ___
> > > U2-Users mailing list
> > > U2-Users@listserver.u2ug.org
> > > http://listserver.u2ug.org/mailman/listinfo/u2-users
> > >
> > ___
> > U2-Users mailing list
> > U2-Users@listserver.u2ug.org
> > http://listserver.u2ug.org/mailman/listinfo/u2-users
> >
> > ___
> > U2-Users mailing list
> > U2-Users@listserver.u2ug.org
> > http://listserver.u2ug.org/mailman/listinfo/u2-users
> >
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Web Services at Universe 11.n

2013-10-30 Thread Rick Nuckolls
If you have not done so yet, try adding the header for Content-Type before 
making the request.

ie. setRequestHeader(handle, 'Content-Type', 'text/html')

Rick Nuckolls
Lynden

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Richard Lewis
Sent: Wednesday, October 30, 2013 3:43 PM
To: U2 Users List
Subject: Re: [U2] Web Services at Universe 11.n

Yes, as I said, I've tested with curl and it works perfectly.  The problem
I have is not being able to clearly/cleanly see the raw text being sent by
the uv functions, in order to determine the difference in what curl sends
(success) and what the uv functions send (failure).  There may be certain
idiosyncratic parsing involved in the service I am trying to consume, but I
have no control over that.  With curl I can see the entire conversation if
the logging is set correctly.  With the uv functions, even with the highest
logging level, it doesn't appear that the logging is actually that complete
and exact.  I have never had the impression that it was.

I would love to be able to do it all in uv, but I only have control over
half of the conversation, and with the uv functions, I seem to have a bit
less than half.

Richard


On Wed, Oct 30, 2013 at 2:12 PM, Symeon Breen  wrote:

> That means you where probably missing a header.   http is just a text
> conversation, if the same headers are passed as passed with curl it will
> work. You can test using curl, or even better with telnet.
>
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Richard Lewis
> Sent: 30 October 2013 20:03
> To: U2 Users List
> Subject: Re: [U2] Web Services at Universe 11.n
>
> I've recently been tasked with accessing a webservice, and couldn't get a
> valid response from the webservice.  It kept not recognizing the headers
> that were sent, and with the maximum logging set on the uv side, it looked
> like everything was being sent just fine, but the webservice still failed
> it.  I switched to using curl, and it all worked perfectly.
>
> Richard Lewis
>
>
>
> On Wed, Oct 30, 2013 at 1:00 PM, Oaks, Harold
> wrote:
>
> > I've been telling my boss that if we upgraded to Universe 11.23, we can
> > implement web services.   (We're currently on 10.2)
> > But,  finally looking in detail at the appropriate manual  (Universe
> > Web Services Developer) it seems that one can publish a web service
> > easily enough so that Universe data can be gotten, but I don't see
> > that the other side is implemented, where one accesses an external web
> > service and brings back data into Universe.  Am I missing the something?
> >
> > What are any of you using to fully implement web services with an
> > underlying Universe environment?
> > Thanks-
> > Harold Oaks
> > Sr. Analyst/Programmer
> > Clark County, WA
> >
> > This e-mail and related attachments and any response may be subject to
> > public disclosure under state law.
> > ___
> > U2-Users mailing list
> > U2-Users@listserver.u2ug.org
> > http://listserver.u2ug.org/mailman/listinfo/u2-users
> >
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Updated UV 11.2 Public Beta (Windows)

2013-10-14 Thread Rick Nuckolls
Dan,

I am looking for documentation as to what has changed since previous build.  
The install script refers me to 

"Please access the RLink site for information regarding the UniVerse v11.2 beta 
project."

Could you be a bit more specific? :-)

I attempted to play with auditing on the previous build, but was not licensed. 
I am working on getting a Linux machine, since we are a Sparc shop.

-Rick Nuckolls
Lynden

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Daniel McGrath
Sent: Sunday, October 13, 2013 2:09 PM
To: U2 Users List (u2-users@listserver.u2ug.org)
Subject: [U2] Updated UV 11.2 Public Beta (Windows)

Hi all,

Just letting you know that updated PE versions of the UniVerse UV 11.2 Public 
Beta are now available. How many people have played with the new features so 
far?

32bit: 
https://myshare.rocketsoftware.com/myshare/d/555135C514A743F98153DA45C722C866

64bit: 
https://myshare.rocketsoftware.com/myshare/d/0BB8ECAAFD8F4FCA8842053BAF5DB7FD

Cheers,
Dan McGrath
Managing Director, U2 Servers Lab
Rocket Software

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Recommended 11.1.point release to upgrade to.

2013-09-25 Thread Rick Nuckolls
Brian,

I agree with you on all points.  The local (same file) subroutine 
implementation in 11.2 is not quite as ambitious as I would like; but, it also 
did not go down any particularly verbose byway.  Having the capability to 
easily replace some "gosub" structures with subroutines & functions is huge, 
however, imho.  (It would be nice if the DEFFUN was assumed for internal 
functions.)

I think classes and instances are very desirable, but I can appreciate that it 
would probably provoke a major review of Uv's garbage collection mechanism, 
which would make it a difficult sale.  Also, have pity for the support staff 
that would need to support the crowd of Basic programmers during the transition!

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Brian Leach
Sent: Wednesday, September 25, 2013 4:58 AM
To: 'U2 Users List'
Subject: Re: [U2] Recommended 11.1.point release to upgrade to.

Hmm,

That approach is understandable in offering a backwardly compatible solution
but I wish they had been a bit braver with it..

If they had looked at what OpenQM did with creating a more class-oriented
structure in their version of basic, which makes for better surfacing of
methods (especially with my unit testing hat on), that would potentially
have offered a lot more options. I'm guessing it's the same low-impact
mindset that stopped them from doing UDO's as first class citizens of the
language, instead hiding them behind an ugly function library that obscures
the structure (which is surely the whole point of JSON style objects?)

Brian

-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
Sent: 25 September 2013 00:16
To: 'U2 Users List'
Subject: Re: [U2] Recommended 11.1.point release to upgrade to.

Chuck,

I agree that they took a simple (but fine) route on the local scoping.  What
is funny is that the interpretation of it seems to be that it allows the
overriding of the production version of subroutines rather than simply
creation of a "safe" version of gosub.  It should work for both; I just
never pictured it that way.

Be sure to read the install notes on 11, in particular, the "NUSERS" config
item is new & important.  Fixtool finally seems to work well.  I know that a
lot of work has gone into that over the previous couple of years.

Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles Stevenson
Sent: Tuesday, September 24, 2013 3:53 PM
To: U2 Users List
Subject: Re: [U2] Recommended 11.1.point release to upgrade to.

Thanks, Rick.

They're finally getting in your desired variable scoping into 11.2, too.
>From what I read, I like how they did it.

My prejudice against being an early adopter of major releases kicks in & 
makes me not want 11.2.0.   11.2.4 maybe.  Also, if I wait until 
November, my window closes.

The vast majority of the issues listed in the 11.1 release notes have to do
with stuff we don't use at all (DR, DARE, MQ, etc), or use so minimally that
complete regression testing is easy (XML, callHTTP, etc.)

There were several issues having to do with indexing.   I think if I 
validate the indexes after regression tests, that should suffice.

Issues that involve locking are trickier.  It will require load testing and
lock contention.
I am not looking forward to that.

The only time in my whole career that I recall having any problem with
backward compatibility after a UV upgrade is also the only time I've seen a
day's worth of work for an entire company abandoned and the previous night's
backups restored.  There was an undocumented change to 
FMT  was made that ended up truncating out data, if I recall.   It's in 
the U2-list archives.  Some of the same people who suffered through that are
with me now.

cds

On 9/25/2013 12:53 AM, Rick Nuckolls wrote:
> Chuck,
>
> We currently have one machine running 11.1.12 with no real problems.
11.1.13 is basically a one, only-on-severe-load, bug fix, and even then,
unlikely.
>
> There is at least one thing that I am expecting in 11.2 that is worth
waiting for, assuming it shows up.  I did not see it in the public beta. I
think that 11.2 is supposed to be out around Nov 1.
>
> -Rick
>
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles Stevenson
> Sent: Tuesday, September 24, 2013 2:28 PM
> To: U2 Users List
> Subject: [U2] Recommended 11.1.point release to upgrade to.
>
> We're finally going to upgrade from 10.2.10 to 11.1.[something].
>
> But which point release?
>
> We're on Win2003.  (Linux next year.  Baby steps.)
>

Re: [U2] Recommended 11.1.point release to upgrade to.

2013-09-24 Thread Rick Nuckolls
Chuck,

I agree that they took a simple (but fine) route on the local scoping.  What is 
funny is that the interpretation of it seems to be that it allows the 
overriding of the production version of subroutines rather than simply creation 
of a "safe" version of gosub.  It should work for both; I just never pictured 
it that way.

Be sure to read the install notes on 11, in particular, the "NUSERS" config 
item is new & important.  Fixtool finally seems to work well.  I know that a 
lot of work has gone into that over the previous couple of years.

Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles Stevenson
Sent: Tuesday, September 24, 2013 3:53 PM
To: U2 Users List
Subject: Re: [U2] Recommended 11.1.point release to upgrade to.

Thanks, Rick.

They're finally getting in your desired variable scoping into 11.2,  
too.  From what I read, I like how they did it.

My prejudice against being an early adopter of major releases kicks in & 
makes me not want 11.2.0.   11.2.4 maybe.  Also, if I wait until 
November, my window closes.

The vast majority of the issues listed in the 11.1 release notes have to 
do with stuff we don't use at all (DR, DARE, MQ, etc), or use so 
minimally that complete regression testing is easy (XML, callHTTP, etc.)

There were several issues having to do with indexing.   I think if I 
validate the indexes after regression tests, that should suffice.

Issues that involve locking are trickier.  It will require load testing 
and lock contention.
I am not looking forward to that.

The only time in my whole career that I recall having any problem with 
backward compatibility after a UV upgrade is also the only time I've 
seen a day's worth of work for an entire company abandoned and the 
previous night's backups restored.  There was an undocumented change to 
FMT  was made that ended up truncating out data, if I recall.   It's in 
the U2-list archives.  Some of the same people who suffered through that 
are with me now.

cds

On 9/25/2013 12:53 AM, Rick Nuckolls wrote:
> Chuck,
>
> We currently have one machine running 11.1.12 with no real problems.  11.1.13 
> is basically a one, only-on-severe-load, bug fix, and even then, unlikely.
>
> There is at least one thing that I am expecting in 11.2 that is worth waiting 
> for, assuming it shows up.  I did not see it in the public beta. I think that 
> 11.2 is supposed to be out around Nov 1.
>
> -Rick
>
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles Stevenson
> Sent: Tuesday, September 24, 2013 2:28 PM
> To: U2 Users List
> Subject: [U2] Recommended 11.1.point release to upgrade to.
>
> We're finally going to upgrade from 10.2.10 to 11.1.[something].
>
> But which point release?
>
> We're on Win2003.  (Linux next year.  Baby steps.)
>
> ReleaseDate   Issues
> 11.1.13   Sept 2013 3 brand new.
> 11.1.12   June 201338  rescinded
> 11.1.11   Mar 201330 Metadata Manager  introduced.
> 11.1.10   Dec 2012 66
> 11.1.9 May2012 75
> 11.1.8 ?  2
> 11.1.7Dec 2011 3
> 11.1.6?   4
> 11.1.5Nov 2011  42
> 11.1.4Aug 2011  17
> 11.1.3Jun 2011   17
> 11.1.2May 2011 29
> 11.1.1Feb  2011  45
> 11.1.0? 23
>
> I generally tend to not be an early adopter when the major release first
> comes out unless it has a new functionality that I have a strong
> business need for.
> The later point releases tend to be bug fixes, so I am more prone to get
> them sooner rather than wait.
>
> In this case though, we have new functionality, Metadata Manager,
> introduced at 11.1.11.
> Are many users on 11.1.11?  Happy?
>
> If i understand correctly, 11.1.12 was pulled off the market because of
> a bug that was fixed in 11.1.13, which just came out.  So not much
> experience in the wild with these 2.
>
> Which one  did / would  you choose to upgrade to 11.1?
>
>
> TIA
> Chuck Stevenson
>
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Recommended 11.1.point release to upgrade to.

2013-09-24 Thread Rick Nuckolls
Chuck,

We currently have one machine running 11.1.12 with no real problems.  11.1.13 
is basically a one, only-on-severe-load, bug fix, and even then, unlikely.

There is at least one thing that I am expecting in 11.2 that is worth waiting 
for, assuming it shows up.  I did not see it in the public beta. I think that 
11.2 is supposed to be out around Nov 1.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles Stevenson
Sent: Tuesday, September 24, 2013 2:28 PM
To: U2 Users List
Subject: [U2] Recommended 11.1.point release to upgrade to.

We're finally going to upgrade from 10.2.10 to 11.1.[something].

But which point release?

We're on Win2003.  (Linux next year.  Baby steps.)

ReleaseDate   Issues
11.1.13   Sept 2013 3 brand new.
11.1.12   June 201338  rescinded
11.1.11   Mar 201330 Metadata Manager  introduced.
11.1.10   Dec 2012 66
11.1.9 May2012 75
11.1.8 ?  2
11.1.7Dec 2011 3
11.1.6?   4
11.1.5Nov 2011  42
11.1.4Aug 2011  17
11.1.3Jun 2011   17
11.1.2May 2011 29
11.1.1Feb  2011  45
11.1.0? 23

I generally tend to not be an early adopter when the major release first 
comes out unless it has a new functionality that I have a strong 
business need for.
The later point releases tend to be bug fixes, so I am more prone to get 
them sooner rather than wait.

In this case though, we have new functionality, Metadata Manager, 
introduced at 11.1.11.
Are many users on 11.1.11?  Happy?

If i understand correctly, 11.1.12 was pulled off the market because of 
a bug that was fixed in 11.1.13, which just came out.  So not much  
experience in the wild with these 2.

Which one  did / would  you choose to upgrade to 11.1?


TIA
Chuck Stevenson

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Read and Writing binary files with UOJ

2013-09-02 Thread Rick Nuckolls
I am not a UniData user, but thought that I had found the answer with OSBREAD 
-- reading a block,  then noticed the note about OSBREAD converting a char(0) 
to char(128).  Ouch.  

If you are on on Unix, you might use uuencode to convert it to base64 and then 
read that in pass it in a subroutine, and then convert it back in Java.

-Rick

On Sep 2, 2013, at 4:51 PM, Doug Averch  wrote:

> Rick,
> 
> It looks like you can do this with Universe UniBasic ReadBlk and we have
> working code.  I have been unable to find any equivalent in Unidata.
> 
> Thanks,
> Doug
> www.u2logic.com
> 
> 
> On Fri, Aug 30, 2013 at 6:15 PM, Rick Nuckolls  wrote:
> 
>> Doug,
>> 
>> Looking at my old code, I call a subroutine on the backend to do the
>> readblk, and then use the default reverse conversion on the return
>> argument's UniString. ( byte[] myBinary = myUnistring.toString().getBytes()
>> )..
>> 
>> UOJ, in its wisdom, does not expose the raw byte array that it gets from
>> the back end before it converts it to Java characters in a UniString, hence
>> the code above. This might even work if you use the UniSequentialFile
>> readBlk() function.
>> 
>> Technically, it might be better to specify the character encoding, as in
>> byte[] myBinary = myUnistring.toString().getBytes("ISO-8859_1"), but this
>> assumes that one are sure of what UOJ used to convert the bytes received
>> from the server to characters, and that the conversion is 100% reversible.
>> It is unclear that UOJ even defines an encoding, and if Localization is in
>> use, UniStrings may not reverse to an equal byte array.
>> 
>> Because of that uncertainty, it would be best to call a subroutine on the
>> UDT server that did a block read of the file, a base64 encoding of it using
>> ENCODE(...), and then, after passing it back to UOJ, use
>> sun.misc.BASE64Decoder to convert
>> the UniString return argument back to a byte[].  (After, of course, you
>> convert the UniString to a String.) -- For a total of 4 conversions per
>> source byte.
>> 
>> Several years ago, I pointed out  to Rocket (IBM?, Ardent?) that it might
>> be more appropriate for the UniSequentialFile readBlk method to return a
>> byte[] rather than a UniString. Obviously, it was too late for that, but it
>> does not appear that U2  has added a readBytes() method, which is no
>> surprise, as I recollect the conversation. (Obviously, there needs to be a
>> writeBlk( byte[] ) or writeBytes( byte[] ) method too.)
>> 
>> Good luck,
>> 
>> Rick Nuckolls
>> 
>> 
>> On Aug 30, 2013, at 2:30 PM, Doug Averch  wrote:
>> 
>>> I was at a U2U in 2010, I think, and somebody showed us how to read and
>>> write files such as tiffs using UniObjects.  The example was storing them
>>> in Unidata and send them out to the web using UOJ.
>>> 
>>> Does anybody know what lecture that was?  Or how to do it?
>>> 
>>> Regards,
>>> Doug
>>> www.u2logic.com
>>> ___
>>> U2-Users mailing list
>>> U2-Users@listserver.u2ug.org
>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Read and Writing binary files with UOJ

2013-08-30 Thread Rick Nuckolls
Doug,

Looking at my old code, I call a subroutine on the backend to do the readblk, 
and then use the default reverse conversion on the return argument's UniString. 
( byte[] myBinary = myUnistring.toString().getBytes()  )..

UOJ, in its wisdom, does not expose the raw byte array that it gets from the 
back end before it converts it to Java characters in a UniString, hence the 
code above. This might even work if you use the UniSequentialFile readBlk() 
function.

Technically, it might be better to specify the character encoding, as in byte[] 
myBinary = myUnistring.toString().getBytes("ISO-8859_1"), but this assumes that 
one are sure of what UOJ used to convert the bytes received from the server to 
characters, and that the conversion is 100% reversible. It is unclear that UOJ 
even defines an encoding, and if Localization is in use, UniStrings may not 
reverse to an equal byte array.

Because of that uncertainty, it would be best to call a subroutine on the UDT 
server that did a block read of the file, a base64 encoding of it using 
ENCODE(...), and then, after passing it back to UOJ, use sun.misc.BASE64Decoder 
to convert 
the UniString return argument back to a byte[].  (After, of course, you convert 
the UniString to a String.) -- For a total of 4 conversions per source byte.

Several years ago, I pointed out  to Rocket (IBM?, Ardent?) that it might be 
more appropriate for the UniSequentialFile readBlk method to return a byte[] 
rather than a UniString. Obviously, it was too late for that, but it does not 
appear that U2  has added a readBytes() method, which is no surprise, as I 
recollect the conversation. (Obviously, there needs to be a writeBlk( byte[] ) 
or writeBytes( byte[] ) method too.) 

Good luck,

Rick Nuckolls


On Aug 30, 2013, at 2:30 PM, Doug Averch  wrote:

> I was at a U2U in 2010, I think, and somebody showed us how to read and
> write files such as tiffs using UniObjects.  The example was storing them
> in Unidata and send them out to the web using UOJ.
> 
> Does anybody know what lecture that was?  Or how to do it?
> 
> Regards,
> Doug
> www.u2logic.com
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Select from one file with save-list from another file

2013-08-27 Thread Rick Nuckolls
Your response supposes that the ORDER.ID IS is in the CUSTOMERS file/table, 
which is not the criteria of the original problem.

The problem presented is a bit difficult to work around in RETRIEVE, and even 
harder if you are restricted to not programming, as Brandon evidently is.

We wrote a utility that will take a preselected list and create a new list 
based on the values of an alternate key, which would functions as

SELECT CUSTOMERS WITH STATE = 'AZ'

SELECTINDEX ORDERS CUSTOMER.ID ## use the CUSTOMER.ID index of ORDERS to 
find those orders related to customers within the list; return a list of ORDERS 
ids.

Alternately, in Brandon's example, it might work to create a translate field 
from the Y.INFO file to the Y.INFO status field, but that would probably 
involve a less efficient overall selection, and would not be practical if the 
data common to the two tables (packet.id), is the primary key to neither, in 
which case:

SELECT X.INFO WITH status = 'ccc' SAVING [UNIQUE] packet.id

SELECTINDEX Y.INFO packet.id

Sorry that I am unable to send out the code for SELECTINDEX, but, a simple 
version is straightforward to program using the BASIC "SELECTINDEX" function.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Jo Lester
Sent: Tuesday, August 27, 2013 2:54 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] Select from one file with save-list from another file

SELECT CUSTOMERS WITH STATE = 'AZ' SAVING ORDER.ID

LIST ORDERS

> From: r...@lynden.com
> To: u2-users@listserver.u2ug.org
> Date: Tue, 27 Aug 2013 14:42:34 -0700
> Subject: Re: [U2] Select from one file with save-list from another file
> 
> I found an old example on line that might get you started
> 
> SELECT TO SLIST 0 FROM CUSTOMERS WHERE STATE = 'AZ';
> SAVE.LIST CUSTOMER.LIST
> 
> SELECT * FROM ORDERS WHERE CUSTOMER.ID IN (SELECT EVAL "  RECORD" FROM
> &SAVEDLISTS& 'CUSTOMER.LIST');
> 
> The extra syntax that might help is
> 
> SELECT TO SLIST  FROM ORDERS 
> 
> If CUSTOMER.LIST is your X.INFO and ORDERS is your Y.INFO...
> 
> Rick
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Hilk, Brandon
> Sent: Tuesday, August 27, 2013 1:24 PM
> To: u2-users@listserver.u2ug.org
> Subject: [U2] Select from one file with save-list from another file
> 
> Hello! 
> 
>  
> 
> UniVerse 10.1, HP/UX, Pick.
> 
>  
> 
> Is there a way I can build a save-list from a selection from one file
> X.INFO (where the record ID is an 8 digit number) and use that list to
> select from file Y.INFO (where that 8 digit number is not the record ID
> but does exist as a "foreign key" elsewhere in the file). In SQL this
> would be considered a join and would look something like this:
> 
>  
> 
> select *
> 
> from X.INFO, Y.INFO
> 
> where X.INFO.packet.id=Y.INFO.packet.id
> 
> and X.INFO.status='ccc';
> 
>  
> 
> I can run this in TCL and have it return the results I want but can't
> build a save-list from it because I don't know the UniVerse/SQL syntax
> to do so.
> 
>  
> 
> So to summarize, is there a way to use a save-list built from X.INFO to
> make another save-list comprised of the record ID's from Y.INFO?
> 
>  
> 
> Thanks for any advice you can give.
> 
>  
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
  
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Select from one file with save-list from another file

2013-08-27 Thread Rick Nuckolls
I found an old example on line that might get you started

SELECT TO SLIST 0 FROM CUSTOMERS WHERE STATE = 'AZ';
SAVE.LIST CUSTOMER.LIST

SELECT * FROM ORDERS WHERE CUSTOMER.ID IN (SELECT EVAL "  RECORD" FROM
&SAVEDLISTS& 'CUSTOMER.LIST');

The extra syntax that might help is

SELECT TO SLIST  FROM ORDERS 

If CUSTOMER.LIST is your X.INFO and ORDERS is your Y.INFO...

Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Hilk, Brandon
Sent: Tuesday, August 27, 2013 1:24 PM
To: u2-users@listserver.u2ug.org
Subject: [U2] Select from one file with save-list from another file

Hello! 

 

UniVerse 10.1, HP/UX, Pick.

 

Is there a way I can build a save-list from a selection from one file
X.INFO (where the record ID is an 8 digit number) and use that list to
select from file Y.INFO (where that 8 digit number is not the record ID
but does exist as a "foreign key" elsewhere in the file). In SQL this
would be considered a join and would look something like this:

 

select *

from X.INFO, Y.INFO

where X.INFO.packet.id=Y.INFO.packet.id

and X.INFO.status='ccc';

 

I can run this in TCL and have it return the results I want but can't
build a save-list from it because I don't know the UniVerse/SQL syntax
to do so.

 

So to summarize, is there a way to use a save-list built from X.INFO to
make another save-list comprised of the record ID's from Y.INFO?

 

Thanks for any advice you can give.

 

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Universe Configuration --

2013-08-18 Thread Rick Nuckolls
Peter,

Thanks for digging for more information.  It sounds to me like RLOWNER was set 
to the RLTABSZ, effectively saying that every read lock associated with a given 
semaphore group could be a READL lock.  Since every READL lock would displace a 
possible READU lock, you could, with 300 separate processes accessing the same 
record in the same file, make it impossible anyone to get a READU lock in the 
same semaphore group.

Likewise, by having a smaller number of processes perform READL's on multiple 
files, but coincidently use the same semaphore group, you could obtain the same 
blocked condition.

Admittedly, both conditions seem unlikely, and if you are running a system with 
that many READL locks routinely active, "why bother?", no one is ever going to 
be updating anything!

I would think that a better rule would be to limit the value of RLOWNER to 50% 
of RLTABSZ, just to keep some room for quasi-normal function if some developer 
decided to create an application that used a READL on a specific file/record to 
communicate to other processes in ill-considered ways.

Cheers,
Rick


On Aug 15, 2013, at 5:19 PM, Peter Cheney  wrote:

>> From my UV9.4 internals manual in the UV data structures chapter...
> 
> Sizing lock tables...
> 
> -   The file lock table has FSEMNUM (default 23) rows, each with FLTABSZ 
> (default 11) entries.
> 
> -   The group lock table has GSEMNUM (default 23) rows, each with GLTABSZ 
> (default 300) entries.
> 
> -   The record update lock table has GSEMNUM (default 23) rows, each with 
> RLTABSZ (default 300) entries
> 
> Each row in each table has a semaphore associated with it.
> 
> 
> 
> The whole chapter talks about semaphore collisions and retries etc when 
> dealing with locks. Further on is another section also called Sizing lock 
> tables that says...
> 
> Increasing GSEMNUM spreads the concurrent group locks across more rows, 
> reducing the average count of group locks per semaphore. The shorter list 
> reduces the amount of time the semaphore needs to be held to process the 
> tables. This reduced time not only reduces the probability of collision but 
> also reduces the number of retries before the semaphore becomes available.
> 
> Reducing the processing time also reduces the probability that the time slice 
> will expire while the user owns the semaphore. If the time slice expires 
> while the semaphore is held, other users may put significant load on the 
> system trying to get the semaphore.
> 
> 
> 
> Further on it says...
> 
> Shared file locks and shared record locks are handled as linked lists
> 
> 
> 
>> From the UV9.3 system administration manual...
> 
> RLOWNER - Sets the number of lock owner entries that are maintained for 
> shared (READL) locks in a group lock semaphore set. Great care should be 
> exercised when changing this parameter. The performance of the disk i/o 
> subsystem may be profoundly affected.
> 
> 
> 
> I've always been advised that the default RLOWNER value of 300 is too big and 
> should be reduced to about 120.
> 
> 
> 
> So does the above mean that RLOWNER controls the number of entries in a 
> semaphore?
> 
> HTH
> 
> Cheers
> 
> Peter
> 
> 
> 
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
> Sent: Friday, 16 August 2013 2:33 AM
> To: 'U2 Users List'
> Subject: Re: [U2] Universe Configuration --
> 
> 
> 
> More research than anything else. We are having an occasional performance 
> problem with one file, and I was checking the lock tables and tuneables.  And 
> realized that I might be misinterpreting "RLOWNER", since "smat-a" does not 
> list out a separate table for it, at least that I could see.
> 
> 
> 
> On some earlier versions of Solaris & UV, it is possible to configure the 
> lock tables to be too large for the memory segment, and uvregen will balk. I 
> have not played with this at the current releases.  I agree that the default 
> for RLOWNER of 300 does not sound very taxing, but if it really is 300 table 
> entries for each group semaphore x 40 bytes or so, that could add up to a 
> chunk of wasted space.
> 
> 
> 
> + Okay, I tested a couple of these changes:  Changing RLOWNER from 300
> 
> + to 400 has no effect on the segment size output of uvregen. Changing
> 
> + RLOWNER to 2000 also has no effect. Changing the RLTABSZ by 100 upped
> 
> + the usage by 1.7 M ( GSEMNUM=97). Likewise, bumping GSEMNUM by 10 to
> 
> + 107 bumped the segment size by 0.52 M.  (No units, since it is not
> 
> + reported by uvregen.  It could be bytes or words.)

Re: [U2] Universe Configuration --

2013-08-15 Thread Rick Nuckolls
More research than anything else. We are having an occasional performance 
problem with one file, and I was checking the lock tables and tuneables.  And 
realized that I might be misinterpreting "RLOWNER", since "smat-a" does not 
list out a separate table for it, at least that I could see.

On some earlier versions of Solaris & UV, it is possible to configure the lock 
tables to be too large for the memory segment, and uvregen will balk. I have 
not played with this at the current releases.  I agree that the default for 
RLOWNER of 300 does not sound very taxing, but if it really is 300 table 
entries for each group semaphore x 40 bytes or so, that could add up to a chunk 
of wasted space.

+ Okay, I tested a couple of these changes:  Changing RLOWNER from 300 to 400 
has no effect on the segment size output of uvregen. Changing RLOWNER to 2000 
also has no effect. Changing the RLTABSZ by 100 upped the usage by 1.7 M ( 
GSEMNUM=97). Likewise, bumping GSEMNUM by 10 to 107 bumped the segment size by 
0.52 M.  (No units, since it is not reported by uvregen.  It could be bytes or 
words.)

>From this, I deduce that RLOWNER, does not affect the size of any tables, 
>rather it might be a limit on the number of users that can concurrently lock a 
>single record using the READL statement.  Not sure what else it could be.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Aaron Titus
Sent: Thursday, August 15, 2013 7:20 AM
To: U2 Users List
Subject: Re: [U2] Universe Configuration --

I wouldn't be concerned about the default value being too high.  The main
reason to modify the tunables is to increase them when you are hitting a
limit.  Years ago, when kernels had very little shared memory in their
out-of-the-box configuration, the tunables were set quite low so that
Universe would function after installation.  With decent sized concurrent
users (or lots of phantoms) it would frequently need to be increased.  The
defaults now are more reasonable.  smat -a will show all the lock tables;
with that you can see where you are at a given point in time.  Increase it
if you are reaching the limit but there is no reason to lower them if you
are not.


*Aaron Titus*
Senior Software Engineer
F.W. Davison & Company, Inc.
508-747-7261 x245
ati...@fwdco.com



On Wed, Aug 14, 2013 at 6:23 PM, Rick Nuckolls  wrote:

> The link to SQL makes some sense.
>
> My original thought was RLOWNER was to Shared Locks (RL) as RLTABSZ is to
> Exclusive (RU) locks, but the default (300) seemed a little high for
> tracking RL locks, especially if that is 300 x GSEMNUM. Also, the only
> reporting that I can find is as a "RL" entry in the LIST.READU output, with
> multiple locks on a single record appearing as a single record lock in the
> "Active Group Locks" list.  Interestingly, "smat -r" shows the user info
> for the shared locks, but not the exclusive locks.  This makes me wonder if
> the configuration value is still relevant, or if the tables have been
> combined.
>
> In that there seem to be very minimal uses for shared locks outside of
> SQL, 300 seems a bit high for the average Legacy PI/OPEN install.
>
> Thanks,
> Rick
>
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org [mailto:
> u2-users-boun...@listserver.u2ug.org] On Behalf Of Phil Walker
> Sent: Wednesday, August 14, 2013 2:00 PM
> To: U2 Users List
> Subject: Re: [U2] Universe Configuration --
>
> The RLOWNER parameter relates to record shared locks and were introduced
> to Universe when the SQL syntax was. The value determines the number of
> slots available to hold the user information of the processes holding the
> shared locks. If any shared locks are held against a record an exclusive
> lock, READU or FILELOCK, EXCLUSIVE will fail or take the locked clause. If
> you do not use SQL or specifically request a READL lock in basic then you
> can basically ignore it I believe from memory.
>
> Regards
>
> Phil
>
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org [mailto:
> u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
> Sent: Thursday, 15 August 2013 6:06 a.m.
> To: 'U2 Users List'
> Subject: [U2] Universe Configuration --
>
> Can anyone provide a cogent explanation of the RLOWNER configuration
> parameter in UV?  How does it relate to the GSEMNUM and GLTABSZ/RLTABSZ?
> What are the contents & duration of an associated entry?  Is there any way
> to determine the number in use (as opposed to the configured number)?
>
> The manual's explanation is a bit short.  Thanks,
>
> Rick Nuckolls
>
> ___
> U2-Users ma

Re: [U2] Universe Configuration --

2013-08-14 Thread Rick Nuckolls
The link to SQL makes some sense. 

My original thought was RLOWNER was to Shared Locks (RL) as RLTABSZ is to 
Exclusive (RU) locks, but the default (300) seemed a little high for tracking 
RL locks, especially if that is 300 x GSEMNUM. Also, the only reporting that I 
can find is as a "RL" entry in the LIST.READU output, with multiple locks on a 
single record appearing as a single record lock in the "Active Group Locks" 
list.  Interestingly, "smat -r" shows the user info for the shared locks, but 
not the exclusive locks.  This makes me wonder if the configuration value is 
still relevant, or if the tables have been combined.

In that there seem to be very minimal uses for shared locks outside of SQL, 300 
seems a bit high for the average Legacy PI/OPEN install.

Thanks,
Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Phil Walker
Sent: Wednesday, August 14, 2013 2:00 PM
To: U2 Users List
Subject: Re: [U2] Universe Configuration --

The RLOWNER parameter relates to record shared locks and were introduced to 
Universe when the SQL syntax was. The value determines the number of slots 
available to hold the user information of the processes holding the shared 
locks. If any shared locks are held against a record an exclusive lock, READU 
or FILELOCK, EXCLUSIVE will fail or take the locked clause. If you do not use 
SQL or specifically request a READL lock in basic then you can basically ignore 
it I believe from memory.

Regards

Phil

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
Sent: Thursday, 15 August 2013 6:06 a.m.
To: 'U2 Users List'
Subject: [U2] Universe Configuration --

Can anyone provide a cogent explanation of the RLOWNER configuration parameter 
in UV?  How does it relate to the GSEMNUM and GLTABSZ/RLTABSZ?
What are the contents & duration of an associated entry?  Is there any way to 
determine the number in use (as opposed to the configured number)?

The manual's explanation is a bit short.  Thanks,

Rick Nuckolls

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


[U2] Universe Configuration --

2013-08-14 Thread Rick Nuckolls
Can anyone provide a cogent explanation of the RLOWNER configuration parameter 
in UV?  How does it relate to the GSEMNUM and GLTABSZ/RLTABSZ?
What are the contents & duration of an associated entry?  Is there any way to 
determine the number in use (as opposed to the configured number)?

The manual's explanation is a bit short.  Thanks,

Rick Nuckolls

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] File type 30 (dynamic)

2013-07-09 Thread Rick Nuckolls
For what it is worth:

Glad to hear that someone else mostly uses dynamic files.  There seems to be a 
bit of prejudice against them by ex-Pickers, (and a prejudice for them from on 
PI'ers like me!)

I never resize them.  On the one hand, they are probably a little slower in the 
worst case, but they should never be a lot slower, as a statically hashed file 
can be if it is overloaded.  Dynamic files are a bit more susceptible to 
problems after a system crash, but even that should not be a big problem for a 
log file.

Depending on the volume of logging information, I would suggest the following:

Create the file with a MINIMUM.MODULUS option that is 130% of your estimated 
data / 2000.  This will pre-allocate space and give you performance 
approximating a statically hashed file (slower SELECTS than a new, empty 
dynamic file too).  

Before the first time you purge the file, consider using CONFIGURE.FILE to 
reset the MIMIMUM.MODULUS to the current mod prior to the purge.  You are going 
to reuse that space anyway, so reconfiguring it to not shrink will speed up the 
purge and future adds.

(rhetorically) Doesn't this make it just like a statically hashed file?  Sort 
of, there are internal differences that handle large records better, and you 
are protected from the bane of an undersized static file.

Also, consider using a timestamp instead of a sequential id.  Why pound on that 
"&NEXT.AVAILABLE&" record when you are going to need a date and time anyway. 
There are options in the SYSTEM() function to get the GMT epoch value and 
Milliseconds.  Just increment the milliseconds until you can lock a new record 
in the file. You will need to do this as a separate value from the GMT seconds, 
due to numerical accuracy.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Tuesday, July 09, 2013 10:10 AM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] File type 30 (dynamic)

Your mileage may vary, but almost *all* of our files are type 30's.  Some of 
them grow and are purged annually as you suggest, for example G/L related 
files.  *And* we have never resized them.  Not ever.  Never.

I don't really know why they never need to be resized, some of them have 
100,000 records, some have 1000.
Maybe they should be resized, maybe it's not efficient.  All I know is we never 
do it.

 

 

 

-Original Message-
From: Scott Zachary 
To: u2-users 
Sent: Tue, Jul 9, 2013 9:15 am
Subject: [U2] File type 30 (dynamic)


I have very little experience with using dynamic (type 30) files and I'm
looking for some pointers in that regard. I have a file that I am
considering creating as a dynamic file. The file will be a log file with
sequential numeric keys. The record size will normally range from about 200
to 700 bytes, with a probable maximum size of less than 1,000 bytes. We
expect the file to continually grow without deletions and we will likely
purge it annually. What are the pro's and con's of creating this file as
type 30 verses other file types?

Thanks, 

Scott Zachary
UniVerse Developer
Gardens Alive! Inc



--
View this message in context: 
http://u2-universe-unidata.1073795.n5.nabble.com/File-type-30-dynamic-tp41129.html
Sent from the U2 - Users mailing list archive at Nabble.com.
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

 
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Flip Case command?

2013-07-05 Thread Rick Nuckolls
Strange request...
Although it would be a poor choice on a character by character basis,  the 
CONVERT statement in UV works:

LL = 'abcdefghijklmnopqrstuvwxzy'
UU = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'

FROMSTR = LL:UU
TOSTR = UU:LL

...

INPUT MYSTR
FLIPPED = CONVERT( FROMSTR, TOSTR, MYSTR )

:)


On Jul 5, 2013, at 2:49 PM, Wjhonson  wrote:

> Does anyone know of an internal command of any sort that will allow one to 
> flip the case of some input stream ?  That is, not just make it all lower 
> case or all upper case, but actually make all lower case input upper, AND at 
> the same time all upper case input lower.
> 
> That is truly flip the case of each input character ?
> 
> I'm going to write my own, unless someone has one.
> 
> Thanks
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] SAN?

2013-07-02 Thread Rick Nuckolls
Ty,

We have run 2 good sized Solaris boxes and 1 medium one over paired 1Gb 
switches for a long time ~ 5-600 users, thousands of files. Bandwidth is not a 
problem.  We do run a separate network for SAN access from the servers.  As a 
practical matter, this works.  We are upgrading the switches to 10Gb, but we 
are by no means saturated.

Solaris supports an "llock" or local lock option on NFS mounts which 
circumvents some of the performance issues mentioned in Aaron's message. I 
think that there is a similar solution for Linux boxes. 

rw,bg,vers=3,proto=tcp,hard,intr,rsize=32768,wsize=32768,llock

This may not apply with your SAN.  But if you can move some stuff over and test 
it, it is definitely worth the effort.  Is NFS slower that a local disk?  
Likely so, right up until you have a disk failure, have to restore from tape 
instead of a snapshot, or fsck 500 Gigs.  Is performance very good anyway? Yes. 
If a SAN can handle the average Microsoft product & output, U2's text based 
data cannot be all that difficult. ("hello world" in msword is worth 5 groups 
in UV.) I apologize for the evangelical bent.

There are doubtlessly architectural solutions other than NFS mounts, and some 
may be appropriate to your hardware and applications.  NFS can be quite simple 
and surprisingly robust.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Ty Haller
Sent: Tuesday, July 02, 2013 10:50 AM
To: 'U2 Users List'
Subject: Re: [U2] SAN?

Thanks.

I'm aware of the advantages. I was more concerned with the IO requirements and 
how that would impact shared storage.



Ty Haller
SEFCU
Lead Administrator - System Services
thal...@sefcu.com

> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-
> boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
> Sent: Tuesday, July 02, 2013 11:13 AM
> To: 'u2-users@listserver.u2ug.org'
> Subject: Re: [U2] SAN?
> 
> Ty,
> 
> We have used a NetApps SAN for a number of years with Solaris for Universe
> data.  (For Universe) there is the obvious tweak of allowing direct access to
> NFS, and depending on the type of SAN, there are probably some mount options
> to optimize the throughput.  It also helps to have a fair amount of memory for
> file caching, but it works great and provides many important advantages.  A
> couple of caveats: Do not allow access to snapshots through the same NFS
> mount as the primary data.  For NetApps, at least, the snapshot has the same
> inode as the live data file, so the snapshot tree must be mounted as a 
> separate
> device to avoid confusing (Universe) with conflicting file headers and data.  
> NFS
> mounts work fine, as long as access to a particular directory tree is managed
> by a single data server.
> 
> Oracle supports this same configuration, though I do not think that Rocket has
> much experience with it.
> 
> Although difficult, it is possible to install Universe a SAN, and then run it 
> on a
> VM, which means that you can snapshot almost all of the UV environment at
> once!
> 
> Rick Nuckolls
> Lynden Inc
> 
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-
> boun...@listserver.u2ug.org] On Behalf Of Ty Haller
> Sent: Tuesday, July 02, 2013 6:15 AM
> To: 'u2-users@listserver.u2ug.org'
> Subject: [U2] SAN?
> 
> Morning,
> 
> I am curious if anybody has UniData Accounts running off a Shared Enterprise
> SAN?
> 
> We currently have an Enterprise SAN for our VMware Environment and would
> like to put a handful of UniData Test Accounts on it.
> 
> We are using UniData 7.2 on an IBM P6 running AIX 6.1, the SAN would be 4GB
> Fiber Attached.
> 
> 
> Thoughts?
> 
> Ty Haller | Lead Administrator - System Services | SEFCU | thal...@sefcu.com
> 700 Patroon Creek Blvd. Albany, NY 12206 | Phone: 518-464-5210 | Fax: 518-
> 464-5209
> 
> This message may contain confidential information and is intended for the sole
> purpose of communication with the addressee. Dissemination or publication in
> any format is strictly prohibited. If you have received this communication in
> error please notify SEFCU immediately.
> 
> Help save a tree. Please print this e-mail only if it is truly necessary. 
> Thank you.
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

This message may contain confidential information and is intende

Re: [U2] SAN?

2013-07-02 Thread Rick Nuckolls
Ty,

We have used a NetApps SAN for a number of years with Solaris for Universe 
data.  (For Universe) there is the obvious tweak of allowing direct access to 
NFS, and depending on the type of SAN, there are probably some mount options to 
optimize the throughput.  It also helps to have a fair amount of memory for 
file caching, but it works great and provides many important advantages.  A 
couple of caveats: Do not allow access to snapshots through the same NFS mount 
as the primary data.  For NetApps, at least, the snapshot has the same inode as 
the live data file, so the snapshot tree must be mounted as a separate device 
to avoid confusing (Universe) with conflicting file headers and data.  NFS 
mounts work fine, as long as access to a particular directory tree is managed 
by a single data server.

Oracle supports this same configuration, though I do not think that Rocket has 
much experience with it.

Although difficult, it is possible to install Universe a SAN, and then run it 
on a VM, which means that you can snapshot almost all of the UV environment at 
once!

Rick Nuckolls
Lynden Inc



-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Ty Haller
Sent: Tuesday, July 02, 2013 6:15 AM
To: 'u2-users@listserver.u2ug.org'
Subject: [U2] SAN?

Morning,

I am curious if anybody has UniData Accounts running off a Shared Enterprise 
SAN?

We currently have an Enterprise SAN for our VMware Environment and would like 
to put a handful of UniData Test Accounts on it.

We are using UniData 7.2 on an IBM P6 running AIX 6.1, the SAN would be 4GB 
Fiber Attached.


Thoughts?

Ty Haller | Lead Administrator - System Services | SEFCU | thal...@sefcu.com
700 Patroon Creek Blvd. Albany, NY 12206 | Phone: 518-464-5210 | Fax: 
518-464-5209

This message may contain confidential information and is intended for the sole 
purpose of communication with the addressee. Dissemination or publication in 
any format is strictly prohibited. If you have received this communication in 
error please notify SEFCU immediately.

Help save a tree. Please print this e-mail only if it is truly necessary. Thank 
you.
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] How to copy only @ID from one file to anothers

2013-06-17 Thread Rick Nuckolls
Greg,

I may misunderstand your question, but if you have a field in the child file 
that references the parent, and then create an index for this field on the 
child file, it is fairly easy to create a subroutine to fetch the index values 
from the parent file and translate them into whatever column(s) you want from 
the child.

Then the parent can list values from the child with an itype like:

I
SUBR('*GETINDEXVALUES', childfilename, nameofindex, @ID (parent id) ); TRANS( 
childfilename, childfilefield, @, 'X')
conversion
display name
format
M   * must be "M'

The advantage of using a field and an index in the child file is that there is 
always a way to "resync" the data if there is a problem; just rebuild the index.

The subroutine should use named common to hold on to the values of @time and 
other arguments to buffer the result, since you do not want the returned list 
to change if you are evaluating two+ columns child columns in a single report.  
Also, be sure that the list returned from the subroutine contains value marks 
rather than field/attribute marks.

You could replace the subroutine with a translation to the child file's 
INDEX.nnn file, but such a structure would be much more fragile.

Rick Nuckolls
Lynden Inc


-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of George Gallen
Sent: Monday, June 17, 2013 10:05 AM
To: U2 Users List
Subject: Re: [U2] How to copy only @ID from one file to anothers

I didn't think you could set up a foreign key dependency in UV?

The only thing I can think of would be to setup a trigger on the parent file,
That computes the ID that will be used in the child file and if it doesn't exist
Create in the child file.

This way, the parent file will push the @ID into the child file, whereas if you
Want to pull the @ID from the parent file, maybe setup a PHANTOM that runs every
Minute or so, but that won't guarantee that a record could be added to the 
parent
File while the PHANTOM is sleeping between runs.

George

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Greg Coelho
Sent: Monday, June 17, 2013 12:43 PM
To: U2 Users List
Subject: Re: [U2] How to copy only @ID from one file to anothers

Guys,

I am attempting to create a store computed column data from a 'co' file. 
How do I set this up so the stored computed column file "see" a new record 
from the parent file?  and how do I initially load the ID's?

Thanks,

Greg
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] uvnet node?

2013-06-14 Thread Rick Nuckolls
Found it!  It is the last segment of the origin IP address.  

-Rick

On Jun 14, 2013, at 2:45 PM, "Rick Nuckolls"  wrote:

> Does anyone know an easy way to trace the uvnet  netnode in the lock table 
> back to the original server?
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


[U2] uvnet node?

2013-06-14 Thread Rick Nuckolls
Does anyone know an easy way to trace the uvnet  netnode in the lock table back 
to the original server?
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Relative Path for SET.INDEX in Universe

2013-05-17 Thread Rick Nuckolls
Thanks,

I confirmed this as a problem on Solaris at 10.2.2, and find that it appears to 
work correctly at 11.1.11.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles Stevenson
Sent: Friday, May 17, 2013 10:20 AM
To: U2 Users List
Subject: Re: [U2] Relative Path for SET.INDEX in Universe

At 10.1 (on Windows)  I've run into trouble when "filename" is an 
F-pointer to a relative path that is not just a file resident in that 
account.  e.g.:

VOC XYZ
01: F
02: ABC/XYZ

Rick,
Your INDICES() result will differ depending on whether you invoke the 
function in the account where  "filename" F-pointer is defined locally,  
or from an account where you are referencing it with a Q-pointer.  There 
you'll get the full path.

cds


On 5/15/2013 11:19 PM, Rick Nuckolls wrote:
> Thanks, Jeff.  Someone else did respond, but with caveats that he remembered 
> non-specific issues. One definitely seems to be that INDICES() returns the 
> partial path rather than the full one, so utilities that use that information 
> will have an issue.
>
> -Rick
>
> On May 15, 2013, at 8:56 PM, "Jeff Fitzgerald"  wrote:
>
>> Rick,
>>
>> Don't know if you got your question about relative index answered, but this
>> was from a post I made back in 2007:
>>
>> 
>>
>> IBM tech support just made me aware of an apparently
>> undocumented feature that was added to SET.INDEX in release 10.1
>> allowing a relative path for the index file.
>>
>> SET.INDEX  filename  TO  RELATIVE.PATH
>>
>> This command will set the index pathname to "./I_filename" eliminating
>> the need to reset the index pathname when the files are copied, as long
>> as the data file and index file are copied as a unit.  Similarly:
>>
>> CREATE.INDEX  filename  indexname  AT  RELATIVE.PATH
>>
>> Wanted to share this *very* nice enhancement.
>>
>> Jeff Fitzgerald
>> Fitzgerald & Long, Inc.
>>
>> ---
>>
>> Not too long after my post, Steve O'Neal made this post about a problem.
>> Haven't tested lately to see if it's still a problem or not
>>
>> ---
>>
>> There are, of course, caveats with everything.  You cannot add a second
>> index after you make the first one, AT RELATIVE.PATH, in a typical
>> fashion.  This would be necessary if you wanted indices with different
>> characteristics, for example, with and without NO.NULLS.
>>
>> This behavior occurs on AIX 5.3 and Windows XP at UniVerse 10.2
>>
>> Case 422234*USA has been created.
>>
>> C:\Accounts\bugs\IndexRelative2>C:\ibm\uv\bin\uv
>> This directory is not set up for uniVerse.
>> Would you like to set it up (Y/N)?Y
>> 0. Ideal UniVerse compatibility
>> 1. IN2 compatibility
>> 2. Prime Information compatibility
>> 3. PICK compatibility
>> 4. PI/open compatibility
>> 5. Microdata Reality compatibility
>>
>>
>> Which way do you wish to configure your VOC ? 0
>> Your VOC is configured for Ideal UniVerse compatibility
>> Creating file "VOC" as Type 3, Modulo 23, Separation 4.
>> Creating file "D_VOC" as Type 3, Modulo 2, Separation 1.
>> Loading your "VOC" file.  (Each "*" = 10 records.)
>> 
>> Loading your "D_VOC" file.  (Each "*" = 10 records.)
>> *
>> Creating file "&SAVEDLISTS&" as Type 1.
>> Creating file "D_&SAVEDLISTS&" as Type 3, Modulo 1, Separation 2.
>> Added "@ID", the default record for RetrieVe, to "D_&SAVEDLISTS&".
>> Creating file "VOCLIB" as Type 2, Modulo 7, Separation 4.
>> Creating file "D_VOCLIB" as Type 3, Modulo 1, Separation 2.
>> Added "@ID", the default record for RetrieVe, to "D_VOCLIB".
>> UniVerse Command Language 10.2
>> (c) Copyright IBM Corporation 2006. All rights reserved.
>> IndexRelative2 logged on: Thu May 17 10:16:49 2007
>>
>>> CREATE.INDEX VOC F2 AT RELATIVE.PATH
>>> CREATE.INDEX VOC F1 AT RELATIVE.PATH
>> Unable to open index map "C:\Accounts\bugs\IndexRelative2/VOC/INDEX.MAP"
>> for rea
>> d/write,>CREATE.INDEX VOC F1
>>
>> Unable to open index map "C:\Accounts\bugs\IndexRelative2/VOC/INDEX.MAP"
>> for rea
>> d/write,>
>> ---
>>
>> Hope this helps!
>>
>> Jeff Fitzgerald
>> Fitzgerald & Long, Inc.
>> www.fitzlong.com
>>
>>
>>

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Relative Path for SET.INDEX in Universe

2013-05-15 Thread Rick Nuckolls
Thanks, Jeff.  Someone else did respond, but with caveats that he remembered 
non-specific issues. One definitely seems to be that INDICES() returns the 
partial path rather than the full one, so utilities that use that information 
will have an issue. 

-Rick

On May 15, 2013, at 8:56 PM, "Jeff Fitzgerald"  wrote:

> Rick,
> 
> Don't know if you got your question about relative index answered, but this
> was from a post I made back in 2007:
> 
> 
> 
>IBM tech support just made me aware of an apparently
> undocumented feature that was added to SET.INDEX in release 10.1
> allowing a relative path for the index file.
> 
>SET.INDEX  filename  TO  RELATIVE.PATH
> 
> This command will set the index pathname to "./I_filename" eliminating
> the need to reset the index pathname when the files are copied, as long
> as the data file and index file are copied as a unit.  Similarly:
> 
>CREATE.INDEX  filename  indexname  AT  RELATIVE.PATH
> 
> Wanted to share this *very* nice enhancement.
> 
> Jeff Fitzgerald
> Fitzgerald & Long, Inc.
> 
> ---
> 
> Not too long after my post, Steve O'Neal made this post about a problem.
> Haven't tested lately to see if it's still a problem or not
> 
> ---
> 
> There are, of course, caveats with everything.  You cannot add a second
> index after you make the first one, AT RELATIVE.PATH, in a typical
> fashion.  This would be necessary if you wanted indices with different
> characteristics, for example, with and without NO.NULLS.
> 
> This behavior occurs on AIX 5.3 and Windows XP at UniVerse 10.2
> 
> Case 422234*USA has been created.
> 
> C:\Accounts\bugs\IndexRelative2>C:\ibm\uv\bin\uv
> This directory is not set up for uniVerse.
> Would you like to set it up (Y/N)?Y
> 0. Ideal UniVerse compatibility
> 1. IN2 compatibility
> 2. Prime Information compatibility
> 3. PICK compatibility
> 4. PI/open compatibility
> 5. Microdata Reality compatibility
> 
> 
> Which way do you wish to configure your VOC ? 0
> Your VOC is configured for Ideal UniVerse compatibility
> Creating file "VOC" as Type 3, Modulo 23, Separation 4.
> Creating file "D_VOC" as Type 3, Modulo 2, Separation 1.
> Loading your "VOC" file.  (Each "*" = 10 records.)
> 
> Loading your "D_VOC" file.  (Each "*" = 10 records.)
> *
> Creating file "&SAVEDLISTS&" as Type 1.
> Creating file "D_&SAVEDLISTS&" as Type 3, Modulo 1, Separation 2.
> Added "@ID", the default record for RetrieVe, to "D_&SAVEDLISTS&".
> Creating file "VOCLIB" as Type 2, Modulo 7, Separation 4.
> Creating file "D_VOCLIB" as Type 3, Modulo 1, Separation 2.
> Added "@ID", the default record for RetrieVe, to "D_VOCLIB".
> UniVerse Command Language 10.2
> (c) Copyright IBM Corporation 2006. All rights reserved.
> IndexRelative2 logged on: Thu May 17 10:16:49 2007
> 
>> CREATE.INDEX VOC F2 AT RELATIVE.PATH
>> CREATE.INDEX VOC F1 AT RELATIVE.PATH
> 
> Unable to open index map "C:\Accounts\bugs\IndexRelative2/VOC/INDEX.MAP"
> for rea
> d/write,>CREATE.INDEX VOC F1
> 
> Unable to open index map "C:\Accounts\bugs\IndexRelative2/VOC/INDEX.MAP"
> for rea
> d/write,>
> ---
> 
> Hope this helps!
> 
> Jeff Fitzgerald
> Fitzgerald & Long, Inc.
> www.fitzlong.com
> 
> 
> On Tuesday, May 7, 2013, Rick Nuckolls wrote:
> 
>> Has anyone else used relative paths for Universe indexes?  Perry, if you
>> remember what problems you had, please get back to me!
>> 
>> Thanks,
>> Rick
>> 
>> On May 7, 2013, at 6:38 AM, Perry Taylor 
>> >
>> wrote:
>> 
>>> Tried it at 10.3.9 and there were some problems.  I don't recall exactly
>> what it was but I had to revert back to absolute pathing.
>>> 
>>> Perry
>>> 
>>> -Original Message-
>>> From: u2-users-boun...@listserver.u2ug.org  [mailto:
>> u2-users-boun...@listserver.u2ug.org ] On Behalf Of Rick
>> Nuckolls
>>> Sent: Monday, May 06, 2013 1:59 PM
>>> To: 'U2 Users List'
>>> Subject: [U2] Relative Path for SET.INDEX in Universe
>>> 
>>> I was told, at one point, that it was possible to use a relative path in
>> the SET.INDEX command for UV.
>>> 
>>> If anyone knows that syntax, please advise!
>>> 
>>> Thanks,
>>> Rick Nucko

Re: [U2] Relative Path for SET.INDEX in Universe

2013-05-07 Thread Rick Nuckolls
Has anyone else used relative paths for Universe indexes?  Perry, if you 
remember what problems you had, please get back to me!

Thanks,
Rick

On May 7, 2013, at 6:38 AM, Perry Taylor  wrote:

> Tried it at 10.3.9 and there were some problems.  I don't recall exactly what 
> it was but I had to revert back to absolute pathing.
> 
> Perry
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
> Sent: Monday, May 06, 2013 1:59 PM
> To: 'U2 Users List'
> Subject: [U2] Relative Path for SET.INDEX in Universe
> 
> I was told, at one point, that it was possible to use a relative path in the 
> SET.INDEX command for UV.
> 
> If anyone knows that syntax, please advise!
> 
> Thanks,
> Rick Nuckolls
> Lynden Inc
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> CONFIDENTIALITY NOTICE: This e-mail message, including any 
> attachments, is for the sole use of the intended recipient(s) 
> and may contain confidential and privileged information.  Any
> unauthorized review, use, disclosure or distribution is 
> prohibited. ZirMed, Inc. has strict policies regarding the 
> content of e-mail communications, specifically Protected Health 
> Information, any communications containing such material will 
> be returned to the originating party with such advisement 
> noted. If you are not the intended recipient, please contact 
> the sender by reply e-mail and destroy all copies of the 
> original message.
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


[U2] Relative Path for SET.INDEX in Universe

2013-05-06 Thread Rick Nuckolls
I was told, at one point, that it was possible to use a relative path in the 
SET.INDEX command for UV.

If anyone knows that syntax, please advise!

Thanks,
Rick Nuckolls
Lynden Inc
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] : Evaluating DCOUNT

2013-02-10 Thread Rick Nuckolls
The only way that this could not be an issue is if the compiler and the smarts 
and determined ahead of time that the array was invariant.
My bet is solidly on plan b.

-Rick

On Feb 10, 2013, at 9:14 PM, Peter Cheney  wrote:

> Hi Everyone,
> 
> Does a DCOUNT get evaluated again for each iteration of a loop?
> Or is UniVerse these days intelligent enough to keep track of what's going on?
> 
> e.g.
> 
> for i = 1 to dcount(array,@fm)
>   *commands here
> next i
> 
> versus
> 
> totalattributes = dcount(array,@fm)
> for i = 1 to totalattributes
>   *commands here
> next i
> 
> Apart from readability and perhaps easier debugging is there an actual 
> internal difference?
> I know it was an issue on older pick releases but I cannot remember if it 
> ever affected UV?
> 
> Cheers
> Peter
> 
> 
> ---
> Note: 
> This email (inc all attachments) is for the use of the intended recipient(s) 
> only.
> Privileged or confidential information may be contained in this 
> communication. If you have received this email in error, please notify the 
> sender immediately and then delete all copies of this message from your 
> computer network. If you are not the intended recipient, you must not keep, 
> use, disclose, copy or distribute this email without the author's prior 
> permission. If you are the intended recipient and you do not wish to receive 
> similar electronic messages from us in future, then please respond to the 
> sender to this effect. 
> We have taken precautions to minimise the risk of transmitting software 
> viruses, but advise you to carry out your own virus checks on this email and 
> its attachments. We do not accept liability for any loss or damage caused by 
> software viruses and do not represent that this transmission is free from 
> viruses or other defects. 
> Firstmac Limited (ABN 59 094 145 963) (AFSL 290600) 
> ---
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Mysterious UV Error

2012-08-17 Thread Rick Nuckolls
Starting the COMO from UV might be a trial under the circumstances; but the 
Unix "script" command could fill in.

btw, using .../uv/bin/uvdls "COUNT VOC" gives me

Verb "6" is not in your VOC

Uvdls is the device licensing version of "uv", and it does send a sequence of 
characters (and backspaces) to the terminal, in an attempt to retrieve the 
device IP address. Of course, this only works on wintegrate and Dynamicconnect 
(I think).

The actual resulting visible message seems to have some variance in it, and 
"60" is certainly within scope.

At uv 10.2, the uvdls executable is about 900 bytes longer than the uv 
executable. If the client has device licensing, odds are good that "uv" was 
replaced with the "uvdls" executable.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of John Jenkins
Sent: Friday, August 17, 2012 2:35 PM
To: U2 Users List
Cc: U2 Users List
Subject: Re: [U2] Mysterious UV Error

Try a COMO and see if it's coming from a terminal ENQ response. Also worth 
checking if uvsh has been aliases at the Unix level.

JayJay

Sent from my iPad

On 17 Aug 2012, at 21:33, Rick Nuckolls  wrote:

> I think that Robert made a good guess.
> 
> Any site that has a c program spawning this could also have custom code 
> testing the terminal type.
> 
> What happens if you us /u1/uv/bin/uvsh "COUNT VOC" instead?
> 
> -Rick
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Robert
> Sent: Friday, August 17, 2012 1:25 PM
> To: U2 Users List
> Subject: Re: [U2] Mysterious UV Error
> 
> Are they using terminals or PCs?
> 
> Are they using an ADDS or WYSE emulation regardless of if they are using 
> terminals or PCs?
> 
> The reason why I am asking is because I used to have a similiar error at 
> one place where they had WYSE50 terminals.
> 
> There is a character sequence on those terminals that if printed to the 
> screen causes the terminal to report back the model number of the 
> terminal by entering them into the input buffer. I think it was  
>  .
> 
> If you print this sequence to the screen and you have a WYSE50, it would 
> enter a "50" for you at TCL which would then say "50 is not a verb" or 
> something like that. Same goes for WYSE60.
> 
> This is just a clue. I would rule out control characters at this point.
> 
> Robert Norman
> .
> ROBERT NORMAN AND ASSOCIATES
> 23441 Golden Springs Dr., #289, Diamond Bar, CA 91765
> (951) 541-1668
> i...@keyway.net <mailto:i...@keyway.net>
> http://users.keyway.net/~ice/ <http://users.keyway.net/%7Eice/>
> Affordable UNIVERSE programming services for PICK/BASIC, DATA/BASIC, 
> UniVerse
> Basic, UniBasic, R/BASIC, jBC.
> 
> On 8/17/2012 12:46 PM, Jeff Fitzgerald wrote:
>> I have a client who's seeing a very odd UniVerse error.  Any thoughts about
>> it would be most appreciated!
>> 
>> This is a UNIX server running AIX 5.3 and UniVerse 10.2.7.
>> 
>> The UniVerse home directory is at /u1/uv - the following command is entered
>> at the UNIX prompt:
>> 
>> # /u1/uv/bin/uv "COUNT VOC"
>> 
>> the response is:
>> 
>> Verb "60" is not in your VOC.
>> 
>> Things I've checked:
>> 
>> *  There is no LOGIN record in the account VOC
>> 
>> *  There is no UV.LOGIN record in the uv account VOC
>> 
>> *  Same response when the command is run in various accounts, including uv
>> 
>> *  /u1/uv/bin/uv is an executable file and not a script
>> 
>> This one has me scratching my head.  The actual problem is with a C program
>> that forks a child to execute a UV session - the child dies with the same
>> error...
>> 
>> Probably something obvious that I can't see.  Help me out please!
>> 
>> Jeff Fitzgerald
>> Fitzgerald & Long, Inc.
>> 
>> www.fitzlong.com
>> j...@fitzlong.com
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Mysterious UV Error

2012-08-17 Thread Rick Nuckolls
You might check to make sure that uvsh has not been redirected, since uvsh is 
normally invoked by uv.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
Sent: Friday, August 17, 2012 1:34 PM
To: 'U2 Users List'
Subject: Re: [U2] Mysterious UV Error

I think that Robert made a good guess.

Any site that has a c program spawning this could also have custom code testing 
the terminal type.

What happens if you us /u1/uv/bin/uvsh "COUNT VOC" instead?

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Robert
Sent: Friday, August 17, 2012 1:25 PM
To: U2 Users List
Subject: Re: [U2] Mysterious UV Error

Are they using terminals or PCs?

Are they using an ADDS or WYSE emulation regardless of if they are using 
terminals or PCs?

The reason why I am asking is because I used to have a similiar error at 
one place where they had WYSE50 terminals.

There is a character sequence on those terminals that if printed to the 
screen causes the terminal to report back the model number of the 
terminal by entering them into the input buffer. I think it was  
 .

If you print this sequence to the screen and you have a WYSE50, it would 
enter a "50" for you at TCL which would then say "50 is not a verb" or 
something like that. Same goes for WYSE60.

This is just a clue. I would rule out control characters at this point.

Robert Norman
.
ROBERT NORMAN AND ASSOCIATES
23441 Golden Springs Dr., #289, Diamond Bar, CA 91765
(951) 541-1668
i...@keyway.net <mailto:i...@keyway.net>
http://users.keyway.net/~ice/ <http://users.keyway.net/%7Eice/>
Affordable UNIVERSE programming services for PICK/BASIC, DATA/BASIC, 
UniVerse
Basic, UniBasic, R/BASIC, jBC.

On 8/17/2012 12:46 PM, Jeff Fitzgerald wrote:
> I have a client who's seeing a very odd UniVerse error.  Any thoughts about
> it would be most appreciated!
>
> This is a UNIX server running AIX 5.3 and UniVerse 10.2.7.
>
> The UniVerse home directory is at /u1/uv - the following command is entered
> at the UNIX prompt:
>
> # /u1/uv/bin/uv "COUNT VOC"
>
> the response is:
>
> Verb "60" is not in your VOC.
>
> Things I've checked:
>
> *  There is no LOGIN record in the account VOC
>
> *  There is no UV.LOGIN record in the uv account VOC
>
> *  Same response when the command is run in various accounts, including uv
>
> *  /u1/uv/bin/uv is an executable file and not a script
>
> This one has me scratching my head.  The actual problem is with a C program
> that forks a child to execute a UV session - the child dies with the same
> error...
>
> Probably something obvious that I can't see.  Help me out please!
>
> Jeff Fitzgerald
> Fitzgerald & Long, Inc.
>
> www.fitzlong.com
> j...@fitzlong.com
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Mysterious UV Error

2012-08-17 Thread Rick Nuckolls
I think that Robert made a good guess.

Any site that has a c program spawning this could also have custom code testing 
the terminal type.

What happens if you us /u1/uv/bin/uvsh "COUNT VOC" instead?

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Robert
Sent: Friday, August 17, 2012 1:25 PM
To: U2 Users List
Subject: Re: [U2] Mysterious UV Error

Are they using terminals or PCs?

Are they using an ADDS or WYSE emulation regardless of if they are using 
terminals or PCs?

The reason why I am asking is because I used to have a similiar error at 
one place where they had WYSE50 terminals.

There is a character sequence on those terminals that if printed to the 
screen causes the terminal to report back the model number of the 
terminal by entering them into the input buffer. I think it was  
 .

If you print this sequence to the screen and you have a WYSE50, it would 
enter a "50" for you at TCL which would then say "50 is not a verb" or 
something like that. Same goes for WYSE60.

This is just a clue. I would rule out control characters at this point.

Robert Norman
.
ROBERT NORMAN AND ASSOCIATES
23441 Golden Springs Dr., #289, Diamond Bar, CA 91765
(951) 541-1668
i...@keyway.net 
http://users.keyway.net/~ice/ 
Affordable UNIVERSE programming services for PICK/BASIC, DATA/BASIC, 
UniVerse
Basic, UniBasic, R/BASIC, jBC.

On 8/17/2012 12:46 PM, Jeff Fitzgerald wrote:
> I have a client who's seeing a very odd UniVerse error.  Any thoughts about
> it would be most appreciated!
>
> This is a UNIX server running AIX 5.3 and UniVerse 10.2.7.
>
> The UniVerse home directory is at /u1/uv - the following command is entered
> at the UNIX prompt:
>
> # /u1/uv/bin/uv "COUNT VOC"
>
> the response is:
>
> Verb "60" is not in your VOC.
>
> Things I've checked:
>
> *  There is no LOGIN record in the account VOC
>
> *  There is no UV.LOGIN record in the uv account VOC
>
> *  Same response when the command is run in various accounts, including uv
>
> *  /u1/uv/bin/uv is an executable file and not a script
>
> This one has me scratching my head.  The actual problem is with a C program
> that forks a child to execute a UV session - the child dies with the same
> error...
>
> Probably something obvious that I can't see.  Help me out please!
>
> Jeff Fitzgerald
> Fitzgerald & Long, Inc.
>
> www.fitzlong.com
> j...@fitzlong.com
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Array Types

2012-07-27 Thread Rick Nuckolls
For general information:  In Universe, the SYSTEM(9) function will return the 
number of milliseconds used by the calling process, and while it is not 
necessarily precise, on a multiuser machine, it is probably a better measure of 
cpu work than time().

Nonetheless, the results in Brian's email are roughly what I would expect, 
showing that a MATREAD has a little overhead beyond a straight read, but is 
useful when a significant amount of attribute access is performed.  The payout 
is likely to be larger when a significant number of fields are being updated, 
since each update in a dynamic array mutes any future benefit from the previous 
hint.

-Rick


On Jul 27, 2012, at 9:57 AM, Brian Leach  wrote:

> Here's a quick proggy I've scrudged together to get a rough indication -
> results on my system are:
> 
> Dynamic   Dimensioned
> Read/random access   18.4 14.2
> Read only3.9  4.6
> 
> This is with small records: obviously with larger ones the gaps should
> widen.
> 
> Brian
> 
>  PROGRAM testdim
> 
>  DIM SALESREC(10)
> 
>  Open 'BOOK_SALES' To F.SALES Else STOP
> 
> * Ignore the first run as it loads the file into memory
> 
>  Crt "First dummy run"
> 
>  Fin = @False
>  Select F.SALES
>  Loop
> ReadNext Id Else Fin = @True
>  Until Fin Do
> Read SalesRec From F.SALES, Id Else Null
>  Repeat
> 
> 
> * Now the real one, read and randomly access fields
>  Crt "Dynamic Array"
> 
>  Now = Time()
>  For I = 1 To 100
> Fin = @False
> 
> Select F.SALES
> Loop
>ReadNext Id Else Fin = @True
> Until Fin Do
>Read SalesRec From F.SALES, Id Else
>   SalesRec = ''
>End
>For J = 1 To 100
>   Attr = Rnd(9) + 1
>   Temp = SalesRec
>Next
> Repeat
>  Next
>  Crt "Time taken : ": (Time() - Now)
> 
>  Crt "Dimensioned Array"
>  Now = Time()
>  For I = 1 To 100
> Fin = @False
> 
> Select F.SALES
> Loop
>ReadNext Id Else Fin = @True
> Until Fin Do
>MatRead SALESREC From F.SALES, Id Else
>   Mat SALESREC = ''
>End
>For J = 1 To 100
>   Attr = Rnd(9) + 1
>   Temp = SALESREC(Attr)
>Next
> Repeat
>  Next
> 
>  Crt "Time taken : ": (Time() - Now)
> 
> * Now just read overheads no access to fields
>  Crt "Dynamic Array Read Only"
> 
>  Now = Time()
>  For I = 1 To 100
> Fin = @False
> 
> Select F.SALES
> Loop
>ReadNext Id Else Fin = @True
> Until Fin Do
>Read SalesRec From F.SALES, Id Else
>   SalesRec = ''
>End
> Repeat
>  Next
>  Crt "Time taken : ": (Time() - Now)
> 
>  Crt "Dimensioned Array Read Only"
>  Now = Time()
>  For I = 1 To 100
> Fin = @False
> 
> Select F.SALES
> Loop
>ReadNext Id Else Fin = @True
> Until Fin Do
>MatRead SALESREC From F.SALES, Id Else
>   Mat SALESREC = ''
>End
> Repeat
>  Next
>  Crt "Time taken : ": (Time() - Now)
> 
>  STOP
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of
> jbut...@hampshire.edu
> Sent: 27 July 2012 16:24
> To: U2 Users List
> Cc: U2 Users List
> Subject: Re: [U2] Array Types
> 
> I understand the performance trade off between dynamic and dimensioned
> arrays but I'm curious about quantifying.
> 
> I know the answer will depend on hardware and load, but in general at what
> point (length) do dimensioned arrays become better performing than dynamic?
> 
> 1000?
> 1?
> 10?
> 
> Any examples or benchmarks appreciated.
> 
> Jeff Butera
> Sent from my iPhone
> 
> On Jul 27, 2012, at 11:14 AM, "David L. Wasylenko"  wrote:
> 
>> Speed
>> There is a *long* thread here demonstrating the difference between *DAYS*
> of processing and seconds, using large records for demonstration.
>> 
>> ... david ...
>> 
>> David L. Wasylenko
>> President, Pick Professionals, Inc
>> w) 314 558 1482
>> d...@pickpro.com
>> 
>> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Bill Brutzman
>> Sent: Friday, July 27, 2012 10:16 AM
>> To: U2 Users List
>> Subject: [U2] Array Types
>> 
>> I am surprised that anyone uses dimensioned arrays.  I use dynamic arrays
> for everything.
>> 
>> If there are any advantages that dimension arrays have over dynamic...
> please let me know... without getting sentimental.
>> 
>> --Bill
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 

Re: [U2] RESIZE - dynamic files

2012-07-06 Thread Rick Nuckolls
Logically, the graphed solution to varying the split.load value with an 
x-axis=modulus, y-axis=time_to_select_&_read_the_whole_file is going to be 
parabolic, having very slow performance at modulus=1 and modulus = # of records.

If you actually want to find the precise low point, ignore all this bs, create 
a bunch of files with copies of the same data, but different moduli, restart 
your system (including all disk drives & raid devices) in order to purge all 
buffers, and then run the same program against each file.  I think that we 
would all be curious about the results.

Easier yet, just ignore the bs and use the defaults. :)

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Friday, July 06, 2012 9:56 AM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


So is there a performance increase in BASIC SELECTS by reducing overflow? Some 
people are saying to reduce disk space to speed up the BASIC SELECT
while others say to reduce overflow.. I'm a bit confused. All of our programs 
that read that table use a BASIC SELECT WITH.. 

for a BASIC select do you gain anything by reducing overflow?

Chris


> To: u2-users@listserver.u2ug.org
> From: wjhon...@aol.com
> Date: Thu, 5 Jul 2012 20:12:21 -0400
> Subject: Re: [U2] RESIZE - dynamic files
> 
> 
> A BASIC SELECT cannot use criteria at all.
> It is going to walk through every record in the file, in order.
> And that's the sticky wicket. That whole "in order" business.
> The disk drive controller has no clue on linked frames, but it *will* do 
> optimistic look aheads for you.
> So you are much better off, for BASIC SELECTs having nothing in overflow, at 
> all. :)
> That way, when you go to ask for the *next* frame, it will always be 
> contiguous, and already sitting in memory.
> 
> 
> 
> 
> 
> 
> 
> 
> -Original Message-
> From: Rick Nuckolls 
> To: 'U2 Users List' 
> Sent: Thu, Jul 5, 2012 4:43 pm
> Subject: Re: [U2] RESIZE - dynamic files
> 
> 
> Most disks and disk systems cache huge amounts of information these days, 
> and, 
> epending on 20 factors or so, one solution will be better than another for a 
> iven file.
> For the wholesale, SELECT F WITH, The fewest disk records will almost 
> always 
> in. For files that have ~10 records/group and have ~10% of the groups 
> verflowed, then perhaps 1% of record reads will do a second read for the 
> verflow buffer because the target key was not in the primary group.  Writing 
> a 
> ew record would possibly hit the 10% mark for reading overflow buffers. But 
> owering the split.load will increase the number of splits slightly, and 
> ncrease the total number of groups considerably.  What you have shown is that 
> ou need to increase the the modulus (and select time) of a large file more 
> than 
> 0% in order to decrease the read and update times for you records 0.5% of the 
> ime (assuming, that you have only reduced the number of overflow groups by 
> 50%.)
> As Charles suggests, this is an interesting exercise, but your actual results 
> ill rapidly change if you actually add /remove records from your file, change 
> he load or number of files on your system, put in a new drive, cpu, memory 
> oard, or install a new release of Universe, move to raid, etc.
> -Rick
> -Original Message-
> rom: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] 
> n Behalf Of Wjhonson
> ent: Thursday, July 05, 2012 2:38 PM
> o: u2-users@listserver.u2ug.org
> ubject: Re: [U2] RESIZE - dynamic files
> 
> he hardward "look ahead" of the disk drive reader will grab consecutive 
> frames" into memory, since it assumes you'll want the "next" frame next.
> o the less overflow you have, the faster a full file scan will become.
> t least that's my theory ;)
> 
> 
> Original Message-
> rom: Rick Nuckolls 
> o: 'U2 Users List' 
> ent: Thu, Jul 5, 2012 2:29 pm
> ubject: Re: [U2] RESIZE - dynamic files
> 
> hris,
> or the type of use that you described earlier; BASIC selects and reads, 
> ducing overflow will have negligible performance benefit, especially compared 
>  changing the GROUP.SIZE back to 1 (2048) bytes.  If you purge the file in 
> latively small percentages, then it will never merge anyway (because you will 
> ed to delete 20-30% of the file for that to happen with the mergeload at 50%, 
>  your optimum minimum modulus solution will probably be "how ever large it 
> ows"  The overhead for a group split is not as bad as it sounds unless your 
> dates/sec count is extremely high, such as during

Re: [U2] RESIZE - dynamic files

2012-07-05 Thread Rick Nuckolls
This will be mostly true if the full extent of the file was allocated at one 
time as a contiguous block, which could be a big plus.
As a file grows, sectors will be allocated piecemeal and when the hardware 
reads ahead, it will not necessarily be reading sectors in the same file.
Curiously, an old Pr1me CAM file had a trick around this, though it was late 
coming onto the scene.  Unix also has a few tricks, but they are only partial 
solutions to file fragmentation.  And Windows

Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Thursday, July 05, 2012 5:12 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


A BASIC SELECT cannot use criteria at all.
It is going to walk through every record in the file, in order.
And that's the sticky wicket. That whole "in order" business.
The disk drive controller has no clue on linked frames, but it *will* do 
optimistic look aheads for you.
So you are much better off, for BASIC SELECTs having nothing in overflow, at 
all. :)
That way, when you go to ask for the *next* frame, it will always be 
contiguous, and already sitting in memory.








-Original Message-----
From: Rick Nuckolls 
To: 'U2 Users List' 
Sent: Thu, Jul 5, 2012 4:43 pm
Subject: Re: [U2] RESIZE - dynamic files


Most disks and disk systems cache huge amounts of information these days, and, 
epending on 20 factors or so, one solution will be better than another for a 
iven file.
For the wholesale, SELECT F WITH, The fewest disk records will almost 
always 
in. For files that have ~10 records/group and have ~10% of the groups 
verflowed, then perhaps 1% of record reads will do a second read for the 
verflow buffer because the target key was not in the primary group.  Writing a 
ew record would possibly hit the 10% mark for reading overflow buffers. But 
owering the split.load will increase the number of splits slightly, and 
ncrease the total number of groups considerably.  What you have shown is that 
ou need to increase the the modulus (and select time) of a large file more than 
0% in order to decrease the read and update times for you records 0.5% of the 
ime (assuming, that you have only reduced the number of overflow groups by 
50%.)
As Charles suggests, this is an interesting exercise, but your actual results 
ill rapidly change if you actually add /remove records from your file, change 
he load or number of files on your system, put in a new drive, cpu, memory 
oard, or install a new release of Universe, move to raid, etc.
-Rick
-Original Message-
rom: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] 
n Behalf Of Wjhonson
ent: Thursday, July 05, 2012 2:38 PM
o: u2-users@listserver.u2ug.org
ubject: Re: [U2] RESIZE - dynamic files

he hardward "look ahead" of the disk drive reader will grab consecutive 
frames" into memory, since it assumes you'll want the "next" frame next.
o the less overflow you have, the faster a full file scan will become.
t least that's my theory ;)


Original Message-
rom: Rick Nuckolls 
o: 'U2 Users List' 
ent: Thu, Jul 5, 2012 2:29 pm
ubject: Re: [U2] RESIZE - dynamic files

hris,
or the type of use that you described earlier; BASIC selects and reads, 
ducing overflow will have negligible performance benefit, especially compared 
 changing the GROUP.SIZE back to 1 (2048) bytes.  If you purge the file in 
latively small percentages, then it will never merge anyway (because you will 
ed to delete 20-30% of the file for that to happen with the mergeload at 50%, 
 your optimum minimum modulus solution will probably be "how ever large it 
ows"  The overhead for a group split is not as bad as it sounds unless your 
dates/sec count is extremely high, such as during a copy.
f you do regular SELECT and SCANS of the entire file, then your goal should be 
 reduce the total disk size of the file, and not worry much about common 
erflow. The important thing is that the file is dynamic, so you will never 
counter the issues that undersized statically hashed files develop.
e have thousands of dynamically hashed files on our (Solaris) systems, with an 
tremely low problem rate.
ick
Original Message-
om: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] 
n Behalf Of Chris Austin
nt: Thursday, July 05, 2012 11:21 AM
: u2-users@listserver.u2ug.org
bject: Re: [U2] RESIZE - dynamic files
ick,
ou are correct, I should be using the smaller size (I just haven't changed it 
t). Based on the reading I have done you should
ly use the larger group size when the average record size is greater than 1000 
tes. 
s far as being better off with the defaults that's basically what I'm trying to 
est (as well as learn how linear hashing works). I was able
 reduce my overflow by 1

Re: [U2] RESIZE - dynamic files

2012-07-05 Thread Rick Nuckolls
Most disks and disk systems cache huge amounts of information these days, and, 
depending on 20 factors or so, one solution will be better than another for a 
given file.

For the wholesale, SELECT F WITH, The fewest disk records will almost 
always win. For files that have ~10 records/group and have ~10% of the groups 
overflowed, then perhaps 1% of record reads will do a second read for the 
overflow buffer because the target key was not in the primary group.  Writing a 
new record would possibly hit the 10% mark for reading overflow buffers. But 
lowering the split.load will increase the number of splits slightly, and 
increase the total number of groups considerably.  What you have shown is that 
you need to increase the the modulus (and select time) of a large file more 
than 10% in order to decrease the read and update times for you records 0.5% of 
the time (assuming, that you have only reduced the number of overflow groups by 
~50%.)

As Charles suggests, this is an interesting exercise, but your actual results 
will rapidly change if you actually add /remove records from your file, change 
the load or number of files on your system, put in a new drive, cpu, memory 
board, or install a new release of Universe, move to raid, etc.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Thursday, July 05, 2012 2:38 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


The hardward "look ahead" of the disk drive reader will grab consecutive 
"frames" into memory, since it assumes you'll want the "next" frame next.
So the less overflow you have, the faster a full file scan will become.
At least that's my theory ;)




-Original Message-
From: Rick Nuckolls 
To: 'U2 Users List' 
Sent: Thu, Jul 5, 2012 2:29 pm
Subject: Re: [U2] RESIZE - dynamic files


Chris,
For the type of use that you described earlier; BASIC selects and reads, 
educing overflow will have negligible performance benefit, especially compared 
o changing the GROUP.SIZE back to 1 (2048) bytes.  If you purge the file in 
elatively small percentages, then it will never merge anyway (because you will 
eed to delete 20-30% of the file for that to happen with the mergeload at 50%, 
o your optimum minimum modulus solution will probably be "how ever large it 
rows"  The overhead for a group split is not as bad as it sounds unless your 
pdates/sec count is extremely high, such as during a copy.
If you do regular SELECT and SCANS of the entire file, then your goal should be 
o reduce the total disk size of the file, and not worry much about common 
verflow. The important thing is that the file is dynamic, so you will never 
ncounter the issues that undersized statically hashed files develop.
We have thousands of dynamically hashed files on our (Solaris) systems, with an 
xtremely low problem rate.
Rick
-Original Message-
rom: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] 
n Behalf Of Chris Austin
ent: Thursday, July 05, 2012 11:21 AM
o: u2-users@listserver.u2ug.org
ubject: Re: [U2] RESIZE - dynamic files

ick,
You are correct, I should be using the smaller size (I just haven't changed it 
et). Based on the reading I have done you should
nly use the larger group size when the average record size is greater than 1000 
ytes. 
As far as being better off with the defaults that's basically what I'm trying 
to 
est (as well as learn how linear hashing works). I was able
o reduce my overflow by 18% and I only increased my empty groups by a very 
mall amount as well as only increased my file size
y 8%. This in theory should be better for reads/writes than what I had before. 
To test the performance I need to write a ton of records and then capture the 
utput and compare the output using timestamps. 
Chris

 From: r...@lynden.com
 To: u2-users@listserver.u2ug.org
 Date: Thu, 5 Jul 2012 09:22:02 -0700
 Subject: Re: [U2] RESIZE - dynamic files
 
 Chis,
 
 I still am wondering what is prompting you to continue using the larger group 
ize.
 
 I think that Martin, and the UV documentation is correct in this case; you 
ould be as well or better off with the defaults.
 
 -Rick
 
 On Jul 5, 2012, at 9:13 AM, "Martin Phillips"  
rote:
 coming
 > Hi,
 > 
 > The various suggestions about setting the minimum modulus to reduce overflow 
re all very well but effectively you are turning a
 > dynamic file into a static one, complete with all the continual maintenance 
ork needed to keep the parameters in step with the
 > data.
 > 
 > In most cases, the only parameter that is worth tuning is the group size to 
ry to pack things nicely. Even this is often fine left
 > alone though getting it to match the underlying o/s page size is helpful.
 > 
 > I missed the start of this thread but

Re: [U2] RESIZE - dynamic files

2012-07-05 Thread Rick Nuckolls
Oops, I would of thought that if a file had, say 100,000 bytes, @ 70 percent 
full, there would be 30,000 bytes "empty" or dead. Are you suggesting the there 
would be 70,000 bytes of data and 42,000 bytes of dead space?

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wols Lists
Sent: Thursday, July 05, 2012 3:24 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files

On 05/07/12 16:12, Martin Phillips wrote:
> A file without overflow is not necessarily the best solution. Winding the 
> split load down to 70% means that at least 30% of the file
> is dead space. The implication of this is that the file is larger and will 
> take more disk reads to process sequentially from one end
> to the other.

Whoops Martin, I think you've made the classic percentages mistake here ...

The file is 30/70, or 42% dead space at least. A file with the default
80% split is at least 25% dead space.

Cheers,
Wol
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] RESIZE - dynamic files

2012-07-05 Thread Rick Nuckolls
Chris,

For the type of use that you described earlier; BASIC selects and reads, 
reducing overflow will have negligible performance benefit, especially compared 
to changing the GROUP.SIZE back to 1 (2048) bytes.  If you purge the file in 
relatively small percentages, then it will never merge anyway (because you will 
need to delete 20-30% of the file for that to happen with the mergeload at 50%, 
so your optimum minimum modulus solution will probably be "how ever large it 
grows"  The overhead for a group split is not as bad as it sounds unless your 
updates/sec count is extremely high, such as during a copy.

If you do regular SELECT and SCANS of the entire file, then your goal should be 
to reduce the total disk size of the file, and not worry much about common 
overflow. The important thing is that the file is dynamic, so you will never 
encounter the issues that undersized statically hashed files develop.

We have thousands of dynamically hashed files on our (Solaris) systems, with an 
extremely low problem rate.

Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Thursday, July 05, 2012 11:21 AM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


Rick,

You are correct, I should be using the smaller size (I just haven't changed it 
yet). Based on the reading I have done you should
only use the larger group size when the average record size is greater than 
1000 bytes. 

As far as being better off with the defaults that's basically what I'm trying 
to test (as well as learn how linear hashing works). I was able
to reduce my overflow by 18% and I only increased my empty groups by a very 
small amount as well as only increased my file size
by 8%. This in theory should be better for reads/writes than what I had before. 

To test the performance I need to write a ton of records and then capture the 
output and compare the output using timestamps. 

Chris


> From: r...@lynden.com
> To: u2-users@listserver.u2ug.org
> Date: Thu, 5 Jul 2012 09:22:02 -0700
> Subject: Re: [U2] RESIZE - dynamic files
> 
> Chis,
> 
> I still am wondering what is prompting you to continue using the larger group 
> size.
> 
> I think that Martin, and the UV documentation is correct in this case; you 
> would be as well or better off with the defaults.
> 
> -Rick
> 
> On Jul 5, 2012, at 9:13 AM, "Martin Phillips"  
> wrote:
> coming
> > Hi,
> > 
> > The various suggestions about setting the minimum modulus to reduce 
> > overflow are all very well but effectively you are turning a
> > dynamic file into a static one, complete with all the continual maintenance 
> > work needed to keep the parameters in step with the
> > data.
> > 
> > In most cases, the only parameter that is worth tuning is the group size to 
> > try to pack things nicely. Even this is often fine left
> > alone though getting it to match the underlying o/s page size is helpful.
> > 
> > I missed the start of this thread but, unless you have a performance 
> > problem or are seriously short of space, my recommendation
> > would be to leave the dynamic files to look after themselves.
> > 
> > A file without overflow is not necessarily the best solution. Winding the 
> > split load down to 70% means that at least 30% of the file
> > is dead space. The implication of this is that the file is larger and will 
> > take more disk reads to process sequentially from one end
> > to the other.
> > 
> > 
> > Martin Phillips
> > Ladybridge Systems Ltd
> > 17b Coldstream Lane, Hardingstone, Northampton NN4 6DB, England
> > +44 (0)1604-709200
> > 
> > 
> > 
> > -Original Message-
> > From: u2-users-boun...@listserver.u2ug.org 
> > [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
> > Sent: 05 July 2012 15:19
> > To: u2-users@listserver.u2ug.org
> > Subject: Re: [U2] RESIZE - dynamic files
> > 
> > 
> > I was able to drop from 30% overflow to 12% by making 2 changes:
> > 
> > 1) changed the split from 80% to 70% (that alone reduce 10% overflow)
> > 2) changed the MINIMUM.MODULUS to 118,681 (calculated this way -> [ (record 
> > data + id) * 1.1 * 1.42857 (70% split load)] / 4096 )
> > 
> > My disk size only went up 8%..
> > 
> > My file looks like this now:
> > 
> > File name ..   GENACCTRN_POSTED
> > Pathname ...   GENACCTRN_POSTED
> > File type ..   DYNAMIC
> > File style and revision    32BIT Revision 12
> > Hashing Algorithm ..   GENERAL
> > No. of groups (modulus)    118681 current ( minimum 118681, 140 empty,
> >14431 overflowed, 778 badly )
> > Number of records ..   1292377
> > Large record size ..   3267 bytes
> > Number of large records    180
> > Group size .   4096 bytes
> > Load factors ...   70% (split), 50% (merge) and 63% (actual)
> > Total size .

Re: [U2] RESIZE - dynamic files

2012-07-05 Thread Rick Nuckolls
Chis,

I still am wondering what is prompting you to continue using the larger group 
size.

I think that Martin, and the UV documentation is correct in this case; you 
would be as well or better off with the defaults.

-Rick

On Jul 5, 2012, at 9:13 AM, "Martin Phillips"  
wrote:
coming
> Hi,
> 
> The various suggestions about setting the minimum modulus to reduce overflow 
> are all very well but effectively you are turning a
> dynamic file into a static one, complete with all the continual maintenance 
> work needed to keep the parameters in step with the
> data.
> 
> In most cases, the only parameter that is worth tuning is the group size to 
> try to pack things nicely. Even this is often fine left
> alone though getting it to match the underlying o/s page size is helpful.
> 
> I missed the start of this thread but, unless you have a performance problem 
> or are seriously short of space, my recommendation
> would be to leave the dynamic files to look after themselves.
> 
> A file without overflow is not necessarily the best solution. Winding the 
> split load down to 70% means that at least 30% of the file
> is dead space. The implication of this is that the file is larger and will 
> take more disk reads to process sequentially from one end
> to the other.
> 
> 
> Martin Phillips
> Ladybridge Systems Ltd
> 17b Coldstream Lane, Hardingstone, Northampton NN4 6DB, England
> +44 (0)1604-709200
> 
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
> Sent: 05 July 2012 15:19
> To: u2-users@listserver.u2ug.org
> Subject: Re: [U2] RESIZE - dynamic files
> 
> 
> I was able to drop from 30% overflow to 12% by making 2 changes:
> 
> 1) changed the split from 80% to 70% (that alone reduce 10% overflow)
> 2) changed the MINIMUM.MODULUS to 118,681 (calculated this way -> [ (record 
> data + id) * 1.1 * 1.42857 (70% split load)] / 4096 )
> 
> My disk size only went up 8%..
> 
> My file looks like this now:
> 
> File name ..   GENACCTRN_POSTED
> Pathname ...   GENACCTRN_POSTED
> File type ..   DYNAMIC
> File style and revision    32BIT Revision 12
> Hashing Algorithm ..   GENERAL
> No. of groups (modulus)    118681 current ( minimum 118681, 140 empty,
>14431 overflowed, 778 badly )
> Number of records ..   1292377
> Large record size ..   3267 bytes
> Number of large records    180
> Group size .   4096 bytes
> Load factors ...   70% (split), 50% (merge) and 63% (actual)
> Total size .   546869248 bytes
> Total size of record data ..   287789178 bytes
> Total size of record IDs ...   21539538 bytes
> Unused space ...   237532340 bytes
> Total space for records    546861056 bytes
> 
> Chris
> 
> 
> 
>> From: keith.john...@datacom.co.nz
>> To: u2-users@listserver.u2ug.org
>> Date: Wed, 4 Jul 2012 14:05:02 +1200
>> Subject: Re: [U2] RESIZE - dynamic files
>> 
>> Doug may have had a key bounce in his input
>> 
>>> Let's do the math:
>>> 
>>> 258687736 (Record Size)
>>> 192283300 (Key Size)
>>> 
>> 
>> The key size is actually 19283300 in Chris' figures
>> 
>> Regarding 68,063 being less than the current modulus of 82,850.  I think the 
>> answer may lie in the splitting process.
>> 
>> As I understand it, the first time a split occurs group 1 is split and its 
>> contents are split between new group 1 and new group 2.
> All the other groups effectively get 1 added to their number. The next split 
> is group 3 (which was 2) into 3 and 4 and so forth. A
> pointer is kept to say where the next split will take place and also to help 
> sort out how to adjust the algorithm to identify which
> group matches a given key.
>> 
>> Based on this, if you started with 1000 groups, by the time you have split 
>> the 500th time you will have 1500 groups.  The first
> 1000 will be relatively empty, the last 500 will probably be overflowed, but 
> not terribly badly.  By the time you get to the 1000th
> split, you will have 2000 groups and they will, one hopes, be quite 
> reasonably spread with very little overflow.
>> 
>> So I expect the average access times would drift up and down in a cycle.  
>> The cycle time would get longer as the file gets bigger
> but the worst time would be roughly the the same each cycle.
>> 
>> Given the power of two introduced into the algorithm by the before/after the 
>> split thing, I wonder if there is such a need to
> start off with a prime?
>> 
>> Regards, Keith
>> 
>> PS I'm getting a bit Tony^H^H^H^Hverbose nowadays.
>> 
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.

Re: [U2] RESIZE - dynamic files

2012-07-04 Thread Rick Nuckolls
I believe PiOpen used a directory with two files in it ‘&$0’ and ‘&$1’ 
corresponding to DATA.30 and OVER.30.  If the numbers went up from there, I 
think that they corresponded to alternate keys, ie ‘&$2’ and ‘&$3’ represented 
DATA.30 and OVER.30 for the first alternate key.

I do not think that PiOpen supported statically hashed files.  (Pr1me 
Information did)

All of that is a few years ago

Unidata uses dat001 and over001 with the number increasing to allow for very 
large files (I think).

-Rick

On Jul 4, 2012, at 10:51 AM, Wols Lists wrote:

> On 04/07/12 11:26, Brian Leach wrote:
>>> All the other groups effectively get 1 added to their number
>> Not exactly.
>> 
>> Sorry to those who already know this, but maybe it's time to go over linear
>> hashing in theory ..
>> 
>> Linear hashing was a system devised by Litwin and originally only for
>> in-memory lists. In fact there's some good implementations in C# that
>> provide better handling of Dictionary types. Applying it to a file system
>> adds some complexity but it's basically the same theory.
>> 
>> Let's start with a file that has 100 groups initially defined (that's 0
>> through 99). That is your minimum starting point and should ensure that it
>> never shrinks below that, so it doesn't begin it's life with loads of splits
>> right from the start as you populate the file. You would size this similarly
>> to the way you size a regular hashed file for your initial content: no point
>> making work for yourself (or the database).
>> 
>> As data gets added, because the content is allocated unevenly, some of that
>> load will be in primary and some in overflow: that's just the way of the
>> world. No hashing is perfect. Unlike a static file, the overflow can't be
>> added to the end of the file as a linked list (* why nobody has done managed
>> overflow is beyond me), it has to sit in a separate file.
> 
> I don't know what the definition of "badly overflowed" is, but assuming
> that a badly overflowed group has two blocks of overflow, then those
> file stats seem perfectly okay. As Brian has explained, the distribution
> of records is "lumpy" and as a percentage of the file, there aren't many
> badly overflowed groups.
> 
> You've got roughly 1/3 of groups overflowed - with an 80% split that
> doesn't seem at all out of order - on average each group is 80% full so
> 1/3rd more than 100% full is fine.
> 
> You've got (in thousands) one and a half groups badly overflowed out of
> eighty-three. That's less than two percent. That's nothing.
> 
> As for why no-one has done managed overflow, I think there are various
> reasons. The first successful implementation (Prime INFORMATION) didn't
> need it. It used a peculiar type of file called a "Segmented Directory"
> and while I don't know for certain what PI did, I strongly suspect each
> group had its own normal file so if a group overflowed, it just created
> a new block at the end of the file. Same with large records, it
> allocated a bunch of overflow blocks. This file structure was far more
> evident with PI-Open - at the OS level a dynamic file was a OS directory
> with lots of numbered files in it.
> 
> The UV implementation of "one file for data, one file for overflow" may
> be unique to UV. I don't know. What little I know of UD tells me it's
> different, and others like QM could well be different again. I wouldn't
> actually be surprised if QM is like PI.
> 
> Cheers,
> Wol
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] RESIZE - dynamic files

2012-07-04 Thread Rick Nuckolls
This makes it sound as if you might need to search two groups for a record, 
which is not correct.  If the initial hash is based on the larger modulo, and 
the group exists, then the key will be in the higher number group.  If the 
result of the first hash is larger than the modulus of the of the table, then 
you rehash with the smaller modulus.

And the modulo used for hashing is always a power of two. 

So if the initial hash function on a key is f(x), then the key will either be 
in f(x) mod 2**n or, if that group has not been created, then in f(x) mod 
2**(n-1).  n increases each time that the modulus grows to equal 2**n+1. So

For a modulus of 3 or 4, n = 2; for 5,6,7,8, n =3.

For instance:

If your groups are numbered 0-5 (6 groups), and your hash value is 5, then you 
are in the last (6th) group because the 5 mod 8 is 5.  Likewise 6 mod 8 is 6, 
but this would be beyond the highest group we have (5).  6 mod 4 is 2, and that 
is the group where 6 should fall. Likewise 7 should fall into group 3.  After 
two more splits (of groups 2 & 3) the modulus will be 8, and no rehashing is 
necessary until we next split group 0 and add a 9th group, at which point we 
start with a mod 16, and use 8 if the first result is over 8 (8 would go into 
the 9th group, 9 would hash into the second group, #1 -- 9 mod 4 -> 1.


Admittedly, this is probably at least as confusing as every other explanation 
of the process ;-)

-Rick

On Jul 4, 2012, at 3:26 AM, Brian Leach wrote:

>> All the other groups effectively get 1 added to their number
> 
> Not exactly.
> 
> Sorry to those who already know this, but maybe it's time to go over linear
> hashing in theory ..
> 
> Linear hashing was a system devised by Litwin and originally only for
> in-memory lists. In fact there's some good implementations in C# that
> provide better handling of Dictionary types. Applying it to a file system
> adds some complexity but it's basically the same theory.
> 
> Let's start with a file that has 100 groups initially defined (that's 0
> through 99). That is your minimum starting point and should ensure that it
> never shrinks below that, so it doesn't begin it's life with loads of splits
> right from the start as you populate the file. You would size this similarly
> to the way you size a regular hashed file for your initial content: no point
> making work for yourself (or the database).
> 
> As data gets added, because the content is allocated unevenly, some of that
> load will be in primary and some in overflow: that's just the way of the
> world. No hashing is perfect. Unlike a static file, the overflow can't be
> added to the end of the file as a linked list (* why nobody has done managed
> overflow is beyond me), it has to sit in a separate file.
> 
> At some point the amount of data held in respect of the available space
> reaches a critical level and the file needs to reorganize. Rather than split
> the most heavily populated group - which would be the obvious thing - linear
> hashing works on the basis of a split pointer that moves incrementally
> through the file. So the first split breaks group 0 and adds group 100 to
> the end of the file, hopefully moving around half the content of group 0 to
> this new group. Of course, there is no guarantee that it will (depending on
> key structure) and also no guarantee that this will help anything, if group
> 0 isn't overflowed or populated anyway. So the next write may also cause a
> split, except now to split group 1 into a new group 101, and so forth.
> 
> Eventually the pointer will reach the end and all the initial 100 groups
> will have been split, and the whole process restarts with the split pointer
> moving back to zero. You now have 200 groups and by this time everything
> should in theory have levelled out, but in the meantime there is still
> overloading and stuff will still be in overflow. The next split will create
> group 200 and split half of group 0 into it, and the whole process repeats
> for ever.
> 
> Oversized records (> buffer size) also get moved out because they stuff up
> the block allocation.
> 
> So why this crazy system, rather than hitting the filled groups as they get
> overstuffed? Because it makes finding a record easy. Because linear hashing
> is based on a power of 2, the maths is simple - if the group is after the
> split point, the record MUST be in that group (or its overflow). If it is
> before the split point, it could be in the original group or the split
> group: so you can just rehash with double the modulus to check which one
> without even having to scan the groups.
> 
> What makes the implementation difficult is that Litwin et al were all
> assuming a single threaded access to an in-memory list. Concurrent access
> whilst maintaining the load factor, split pointer and splitting all add a
> lot more complexity, unless you lock the whole file for the duration of an
> IO operation and kill the performance.
> 
> And coming back to the manual, storing la

Re: [U2] RESIZE - dynamic files

2012-07-03 Thread Rick Nuckolls
From the System Description manual:

Important Considerations

Dynamic files are meant to make file management easier for users. The default
parameters are set so that most dynamic files work efficiently. If you decide 
to change
the parameters of a dynamic file, keep the following considerations in mind:

􀂄 Use the SEQ.NUM hashing algorithm only when your record IDs are
numeric, sequential, and consecutive. Nonconsecutive numbers should not
be hashed using the SEQ.NUM hashing algorithm.

􀂄 Use a group size of 2 only if you expect the average record size to be larger
than 1000 bytes. If your record size is larger than 2000 bytes, consider using
a nonhashed file—type 1 or 19.

􀂄 Large record size should generally not be changed. Storing the data of a
large record in the overflow buffer causes that data not to be included in the
split and merge calculations. Also, the extra data length does not slow access
to subsequent records. By choosing a large record size of 0%, all the records
are considered large. In this case, record IDs can be accessed extremely
quickly by commands such as SELECT, but access to the actual data is
much less efficient.

􀂄 A small split load causes less data to be stored in each group buffer, 
resulting
in faster access time and less overflow at the expense of requiring extra
memory. A large split load causes more data to be stored in each group
buffer, resulting in better use of memory at the expense of slower access
time and more overflow. A split load of 100% disables splits.

􀂄 The gap between merge load and split load should be large enough so that
splits and merges do not occur too frequently. The split and merge processes
take a significant amount of processing time. If you make the merge load too
small, memory usage can be very poor. Also, selection time is increased
when record IDs are distributed in more groups than are needed. A merge
load of 0% disables merges.

􀂄 Consider increasing the minimum modulo if you intend to add a lot of initial
data to the file. Much data-entry time can be saved by avoiding the initial
splits that can occur if you enter a lot of initial data. You may want to
readjust this value after

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles Stevenson
Sent: Tuesday, July 03, 2012 3:34 PM
To: U2 Users List
Subject: Re: [U2] RESIZE - dynamic files

Chris,
Let's back way up.   I take it your original question is a general one,  
not specific to one poorly performing problematic file.  Is that right?

If so, generally speaking, you just don't get a lot out of fine-tuning 
dynamic files.
Tweaking the default parameters doesn't usually make a whole lot of 
difference.
Several people have said something similar in this thread.

Other than deciding which hashing algorithm,  I generally use the 
defaults and only tweak things once the file proves problematic, which 
usually means slow I/O.

When a problem erupts, look carefully at how that specific file is used, 
as Susan & others have said.   You might get hold of Fitzgerald&Long's 
paper on how dynamic files work.  If you understand the fundamentals, 
you'll understand how to attack your problem file, applying the ideas 
Rick & others have talked about here.

You may go several years without having to resort to that.

Chuck Stevenson


On 7/2/2012 2:22 PM, Chris Austin wrote:
> I was wondering if anyone had instructions on RESIZE with a dynamic file? For 
> example I have a file called 'TEST_FILE'
> with the following:
>
> 01 ANALYZE.FILE TEST_FILE
> File name ..   TEST_FILE
> Pathname ...   TEST_FILE
> File type ..   DYNAMIC
> File style and revision    32BIT Revision 12
> Hashing Algorithm ..   GENERAL
> No. of groups (modulus)    83261 current ( minimum 31 )
> Large record size ..   3267 bytes
> Group size .   4096 bytes
> Load factors ...   80% (split), 50% (merge) and 80% (actual)
> Total size .   450613248 bytes
>
> How do you calculate what the modulus and separation should be? I can't use 
> HASH.HELP on a type 30 file to see the recommended settings
> so I was wondering how best you figure out the file RESIZE.
>
> Thanks,
>
> Chris
>

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] RESIZE - dynamic files

2012-07-03 Thread Rick Nuckolls
Unless the minimum modulus is configured high enough to artificially lower the 
actual load, the actual load will rise to the designated split.load as the file 
grows. The split.load indicates nothing about the specific load of any given 
group; so if it is set to 90%, then on average, each group will be 90% full, 
and adding a (400byte) record to a group will send it into overflow, but since 
400 bytes is a trivial percentage of your overall file load, many groups will 
be overflowed before the total load factor exceeds 90%.  

Okay, there is a slight distortion with the numbers there, but the idea is that 
all buckets are not loaded equally, so if the average is "almost full" the 
reality is "many overflowed".

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Tuesday, July 03, 2012 2:52 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


I set the split load based on what Dan suggested:

"I'd take the merge down a little, to maybe 30% or even less, and maybe knock 
the split up a bit - say, 90% - to cut down on the splitting."

I thought this would cut down on splitting. Is there a certain formula, or way 
to calculate the split.load? What should my SPLIT.LOAD be around,
and how do you come up with that %?

Chris

> From: r...@lynden.com
> To: u2-users@listserver.u2ug.org
> Date: Tue, 3 Jul 2012 14:45:28 -0700
> Subject: Re: [U2] RESIZE - dynamic files
> 
> 37% is a very low load.  Reading disk records takes much longer than parsing 
> the records out of a disk record.  With variable record size and moderately 
> poor hashing, overflow is inevitable.  So, do you want 80,000 extra groups, 
> or 20,000 overflow buffers? I would go with the smaller number.  But for the 
> love of Knuth, do not set your split.load to 90% unless you have a perfectly 
> hashed file with uniformly sized records.
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
> Sent: Tuesday, July 03, 2012 2:38 PM
> To: u2-users@listserver.u2ug.org
> Subject: Re: [U2] RESIZE - dynamic files
> 
> 
> This is why I'm confused.. Is the goal here to reduce 'overflow' or to 
> keep the 'Total size' of the disk down? If the goal is to keep the total
>  disk size down then it would appear
> you would want your actual load % a lot higher than 37%.. and then ignore 
> 'some' of the overflow..
> 
> Chris
> 
> 
> > But the total size of your file is up 60%.  Reading in 60% more records in 
> > a full select of the file is going to be much slower than a few more 
> > overflows.
> > 
> > 
> > -Original Message-
> > From: u2-users-boun...@listserver.u2ug.org 
> > [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
> > Sent: Tuesday, July 03, 2012 2:15 PM
> > To: u2-users@listserver.u2ug.org
> > Subject: Re: [U2] RESIZE - dynamic files
> > 
> > 
> > Dan,
> > 
> > I changed the MINIMUM.MODULUS to the value of 23 as you suggested and 
> > my Actual Load has really gone down (as well as overflow). See below for 
> > the results:
> > 
> > File name ..   GENACCTRN_POSTED
> > Pathname ...   GENACCTRN_POSTED
> > File type ..   DYNAMIC
> > File style and revision    32BIT Revision 12
> > Hashing Algorithm ..   GENERAL
> > No. of groups (modulus)    23 current ( minimum 23, 5263 empty,
> > 3957 overflowed, 207 badly )
> > Number of records ..   1290469
> > Large record size ..   3267 bytes
> > Number of large records    180
> > Group size .   4096 bytes
> > Load factors ...   90% (split), 50% (merge) and 37% (actual)
> > Total size .   836235264 bytes
> > Total size of record data ..   287394719 bytes
> > Total size of record IDs ...   21508521 bytes
> > Unused space ...   527323832 bytes
> > Total space for records    836227072 bytes
> > 
> > My overflow is now @ 2%
> > My Load is @ 37% (actual)
> > 
> > granted my empty groups are now up to almost 3% but I hope that won't be a 
> > big factor. How does this look?
> > 
> > Chris
> 
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
  
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinf

Re: [U2] RESIZE - dynamic files

2012-07-03 Thread Rick Nuckolls
37% is a very low load.  Reading disk records takes much longer than parsing 
the records out of a disk record.  With variable record size and moderately 
poor hashing, overflow is inevitable.  So, do you want 80,000 extra groups, or 
20,000 overflow buffers? I would go with the smaller number.  But for the love 
of Knuth, do not set your split.load to 90% unless you have a perfectly hashed 
file with uniformly sized records.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Tuesday, July 03, 2012 2:38 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


This is why I'm confused.. Is the goal here to reduce 'overflow' or to 
keep the 'Total size' of the disk down? If the goal is to keep the total
 disk size down then it would appear
you would want your actual load % a lot higher than 37%.. and then ignore 
'some' of the overflow..

Chris


> But the total size of your file is up 60%.  Reading in 60% more records in a 
> full select of the file is going to be much slower than a few more overflows.
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
> Sent: Tuesday, July 03, 2012 2:15 PM
> To: u2-users@listserver.u2ug.org
> Subject: Re: [U2] RESIZE - dynamic files
> 
> 
> Dan,
> 
> I changed the MINIMUM.MODULUS to the value of 23 as you suggested and my 
> Actual Load has really gone down (as well as overflow). See below for the 
> results:
> 
> File name ..   GENACCTRN_POSTED
> Pathname ...   GENACCTRN_POSTED
> File type ..   DYNAMIC
> File style and revision    32BIT Revision 12
> Hashing Algorithm ..   GENERAL
> No. of groups (modulus)    23 current ( minimum 23, 5263 empty,
> 3957 overflowed, 207 badly )
> Number of records ..   1290469
> Large record size ..   3267 bytes
> Number of large records    180
> Group size .   4096 bytes
> Load factors ...   90% (split), 50% (merge) and 37% (actual)
> Total size .   836235264 bytes
> Total size of record data ..   287394719 bytes
> Total size of record IDs ...   21508521 bytes
> Unused space ...   527323832 bytes
> Total space for records    836227072 bytes
> 
> My overflow is now @ 2%
> My Load is @ 37% (actual)
> 
> granted my empty groups are now up to almost 3% but I hope that won't be a 
> big factor. How does this look?
> 
> Chris

  
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] RESIZE - dynamic files

2012-07-03 Thread Rick Nuckolls
I should have said "60% more disk records", to be clear.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
Sent: Tuesday, July 03, 2012 2:24 PM
To: 'U2 Users List'
Subject: Re: [U2] RESIZE - dynamic files

But the total size of your file is up 60%.  Reading in 60% more records in a 
full select of the file is going to be much slower than a few more overflows.


-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Tuesday, July 03, 2012 2:15 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


Dan,

I changed the MINIMUM.MODULUS to the value of 23 as you suggested and my 
Actual Load has really gone down (as well as overflow). See below for the 
results:

File name ..   GENACCTRN_POSTED
Pathname ...   GENACCTRN_POSTED
File type ..   DYNAMIC
File style and revision    32BIT Revision 12
Hashing Algorithm ..   GENERAL
No. of groups (modulus)    23 current ( minimum 23, 5263 empty,
3957 overflowed, 207 badly )
Number of records ..   1290469
Large record size ..   3267 bytes
Number of large records    180
Group size .   4096 bytes
Load factors ...   90% (split), 50% (merge) and 37% (actual)
Total size .   836235264 bytes
Total size of record data ..   287394719 bytes
Total size of record IDs ...   21508521 bytes
Unused space ...   527323832 bytes
Total space for records    836227072 bytes

My overflow is now @ 2%
My Load is @ 37% (actual)

granted my empty groups are now up to almost 3% but I hope that won't be a big 
factor. How does this look?

Chris


> From: dangf...@hotmail.com
> To: u2-users@listserver.u2ug.org
> Date: Tue, 3 Jul 2012 16:57:34 -0400
> Subject: Re: [U2] RESIZE - dynamic files
>
>
> One rule of thumb is to make sure that you have an average of 10 or less 
> items in each group. Going by that, you'd want a minimum mod of 130k or more. 
> I've also noticed that files approach the "sweet spot" for minimizing 
> overflow without having excessive empty groups when the total size is pretty 
> nearly twice the data size.
>
> The goal can vary according to your situation. I'm personally not all that 
> afraid of making the modulus a little too large, as overflow is a pretty bad 
> performance hit (overflow means at least two disk reads to retrieve your 
> data, "badly" means at least 2 extra disk reads, and I've seen files where 
> that was thousands (this file isn't that bad, but 20% of your data is forcing 
> at least one extra disk read). Empty groups contribute to overhead on a 
> sequential search, so you'd want to consider how often you do a sequential 
> search on a file - usually, that's a pretty inefficient way to retrieve data, 
> but, again, your mileage may vary.
>
> To me, 20% is too much overflow, and 114 empty groups is trivial; much less 
> than 0.2%. I'd be tempted to go to 23 as a minimum Mod, just to see what 
> it looks like there. That'll give you an average of 6 records per group, not 
> unreasonably shallow, and it's likely to be a while before you have to resize 
> again.
>
> > From: cjausti...@hotmail.com
> > To: u2-users@listserver.u2ug.org
> > Date: Tue, 3 Jul 2012 15:23:23 -0500
> > Subject: Re: [U2] RESIZE - dynamic files
> >
> >
> > I guess what I need to know is what's an acceptable % of overflow for a 
> > dynamic file? For example, when I change the SPLIT LOAD to 90% (while using 
> > the calculated min modulus)
> > I'm still left with ~ 20% of overflow (see below). Is 20% overflow 
> > considered acceptable on average or should I keep tinkering with it to 
> > reach a lower overflow %?
> >
> > Correct me if I'm wrong but it seems the goal here is to REDUCE the 
> > overflow % while not creating too many modulus (groups).
> >
> > Chris
> >
> >
> > File name ..   GENACCTRN_POSTED
> > Pathname ...   GENACCTRN_POSTED
> > File type ..   DYNAMIC
> > File style and revision    32BIT Revision 12
> > Hashing Algorithm ..   GENERAL
> > No. of groups (modulus)    105715 current ( minimum 103889, 114 empty,
> > 21092 overflowed, 1452 badly )
> > Number of records ..   1290469
> > Large record size ..   3267 bytes
> > Number of large records    180
> > Group size .

Re: [U2] RESIZE - dynamic files

2012-07-03 Thread Rick Nuckolls
But the total size of your file is up 60%.  Reading in 60% more records in a 
full select of the file is going to be much slower than a few more overflows.


-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Tuesday, July 03, 2012 2:15 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


Dan,

I changed the MINIMUM.MODULUS to the value of 23 as you suggested and my 
Actual Load has really gone down (as well as overflow). See below for the 
results:

File name ..   GENACCTRN_POSTED
Pathname ...   GENACCTRN_POSTED
File type ..   DYNAMIC
File style and revision    32BIT Revision 12
Hashing Algorithm ..   GENERAL
No. of groups (modulus)    23 current ( minimum 23, 5263 empty,
3957 overflowed, 207 badly )
Number of records ..   1290469
Large record size ..   3267 bytes
Number of large records    180
Group size .   4096 bytes
Load factors ...   90% (split), 50% (merge) and 37% (actual)
Total size .   836235264 bytes
Total size of record data ..   287394719 bytes
Total size of record IDs ...   21508521 bytes
Unused space ...   527323832 bytes
Total space for records    836227072 bytes

My overflow is now @ 2%
My Load is @ 37% (actual)

granted my empty groups are now up to almost 3% but I hope that won't be a big 
factor. How does this look?

Chris


> From: dangf...@hotmail.com
> To: u2-users@listserver.u2ug.org
> Date: Tue, 3 Jul 2012 16:57:34 -0400
> Subject: Re: [U2] RESIZE - dynamic files
>
>
> One rule of thumb is to make sure that you have an average of 10 or less 
> items in each group. Going by that, you'd want a minimum mod of 130k or more. 
> I've also noticed that files approach the "sweet spot" for minimizing 
> overflow without having excessive empty groups when the total size is pretty 
> nearly twice the data size.
>
> The goal can vary according to your situation. I'm personally not all that 
> afraid of making the modulus a little too large, as overflow is a pretty bad 
> performance hit (overflow means at least two disk reads to retrieve your 
> data, "badly" means at least 2 extra disk reads, and I've seen files where 
> that was thousands (this file isn't that bad, but 20% of your data is forcing 
> at least one extra disk read). Empty groups contribute to overhead on a 
> sequential search, so you'd want to consider how often you do a sequential 
> search on a file - usually, that's a pretty inefficient way to retrieve data, 
> but, again, your mileage may vary.
>
> To me, 20% is too much overflow, and 114 empty groups is trivial; much less 
> than 0.2%. I'd be tempted to go to 23 as a minimum Mod, just to see what 
> it looks like there. That'll give you an average of 6 records per group, not 
> unreasonably shallow, and it's likely to be a while before you have to resize 
> again.
>
> > From: cjausti...@hotmail.com
> > To: u2-users@listserver.u2ug.org
> > Date: Tue, 3 Jul 2012 15:23:23 -0500
> > Subject: Re: [U2] RESIZE - dynamic files
> >
> >
> > I guess what I need to know is what's an acceptable % of overflow for a 
> > dynamic file? For example, when I change the SPLIT LOAD to 90% (while using 
> > the calculated min modulus)
> > I'm still left with ~ 20% of overflow (see below). Is 20% overflow 
> > considered acceptable on average or should I keep tinkering with it to 
> > reach a lower overflow %?
> >
> > Correct me if I'm wrong but it seems the goal here is to REDUCE the 
> > overflow % while not creating too many modulus (groups).
> >
> > Chris
> >
> >
> > File name ..   GENACCTRN_POSTED
> > Pathname ...   GENACCTRN_POSTED
> > File type ..   DYNAMIC
> > File style and revision    32BIT Revision 12
> > Hashing Algorithm ..   GENERAL
> > No. of groups (modulus)    105715 current ( minimum 103889, 114 empty,
> > 21092 overflowed, 1452 badly )
> > Number of records ..   1290469
> > Large record size ..   3267 bytes
> > Number of large records    180
> > Group size .   4096 bytes
> > Load factors ...   90% (split), 50% (merge) and 70% (actual)
> > Total size .   522260480 bytes
> > Total size of record data ..   287400239 bytes
> > Total size of record IDs ...   21508521 bytes
> > Unused space ...   213343528 bytes
> > Total space for records    522252288 bytes
> >
> > > From: r...@lynden.com
> > > To: u2-users@listserver.u2ug.org
> > > Date: Tue, 3 Jul 2012 13:10:43 -0700
> > > Subject: Re: [U2] RESIZE - dynamic files
> > >
> > > The split load is not affecting anything here, since it is more than the 
> > > actual load.  What your overflow suggests is that you lower the 
> > >

Re: [U2] RESIZE - dynamic files

2012-07-03 Thread Rick Nuckolls
The actual load is 70% on your file. The split.load of 90 was set after the 
file was loaded. If you leave it at that value, and add another 100,000 
records, your modulus will not grow, but the number of overflowed groups will. 

Perhaps you need to look at is as "80% not overflowed".  Despite the output, I 
doubt that any of those overflows are that bad. 




-Rick

On Jul 3, 2012, at 1:23 PM, "Chris Austin"  wrote:

> 
> I guess what I need to know is what's an acceptable % of overflow for a 
> dynamic file? For example, when I change the SPLIT LOAD to 90% (while using 
> the calculated min modulus)
> I'm still left with ~ 20% of overflow (see below). Is 20% overflow considered 
> acceptable on average or should I keep tinkering with it to reach a lower 
> overflow %?
> 
> Correct me if I'm wrong but it seems the goal here is to REDUCE the overflow 
> % while not creating too many modulus (groups).
> 
> Chris
> 
> 
> File name ..   GENACCTRN_POSTED
> Pathname ...   GENACCTRN_POSTED
> File type ..   DYNAMIC
> File style and revision    32BIT Revision 12
> Hashing Algorithm ..   GENERAL
> No. of groups (modulus)    105715 current ( minimum 103889, 114 empty,
>21092 overflowed, 1452 badly )
> Number of records ..   1290469
> Large record size ..   3267 bytes
> Number of large records    180
> Group size .   4096 bytes
> Load factors ...   90% (split), 50% (merge) and 70% (actual)
> Total size .   522260480 bytes
> Total size of record data ..   287400239 bytes
> Total size of record IDs ...   21508521 bytes
> Unused space ...   213343528 bytes
> Total space for records    522252288 bytes
> 
>> From: r...@lynden.com
>> To: u2-users@listserver.u2ug.org
>> Date: Tue, 3 Jul 2012 13:10:43 -0700
>> Subject: Re: [U2] RESIZE - dynamic files
>> 
>> The split load is not affecting anything here, since it is more than the 
>> actual load.  What your overflow suggests is that you lower the split.load 
>> value to 70$% or below.  You could go ahead and set the merge.load to an 
>> arbitrarily low number ("1"), and it will probably never do a merge, which 
>> would be the same as specifying a minimum.modulus equal to "as large as it 
>> ever gets".  The exception to this is during file creation & clear.file,  
>> when the minimum.modulus value determines the initial disk allocation.  
>> Short of going to an arbitrarily large minimum.modulus, and a very low 
>> split.load, you are going to have some overflow (unless you have sequential 
>> keys & like sized records).
>> 
>> -Rick
>> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org 
>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
>> Sent: Tuesday, July 03, 2012 12:54 PM
>> To: u2-users@listserver.u2ug.org
>> Subject: Re: [U2] RESIZE - dynamic files
>> 
>> 
>> Using the formula below, and changing the split to 90% I get the following:
>> 
>> File name ..   GENACCTRN_POSTED
>> Pathname ...   GENACCTRN_POSTED
>> File type ..   DYNAMIC
>> File style and revision    32BIT Revision 12
>> Hashing Algorithm ..   GENERAL
>> No. of groups (modulus)    103889 current ( minimum 103889, 114 empty,
>>22249 overflowed, 1764 badly )
>> Number of records ..   1290469
>> Large record size ..   3267 bytes
>> Number of large records    180
>> Group size .   4096 bytes
>> Load factors ...   90% (split), 50% (merge) and 72% (actual)
>> Total size .   519921664 bytes
>> Total size of record data ..   287400591 bytes
>> Total size of record IDs ...   21508497 bytes
>> Unused space ...   211004384 bytes
>> Total space for records    519913472 bytes
>> 
>> How does this look in terms of performance?
>> 
>> My Actual load went down 8% as well as some overflow but it looks like my 
>> load % is still high at 72% I'm wondering if I should raise the 
>> MINIMUM.MODULUS even more
>> since I still have a decent amount of overflow and not many large records.
>> 
>> Chris
>> 
>> 
>>> From: r...@lynden.com
>>> To: u2-users@listserver.u2ug.org
>>> Date: Tue, 3 Jul 2012 10:21:16 -0700
>>> Subject: Re: [U2] RESIZE - dynamic files
>>> 
>>> (record + id / 4096 or 2048)
>>> 
>>> You need to factor in overhead & the split factor:   (records + ids) * 1.1 
>>> * 1.25  / 4096(for 80%)
>>> 
>>> If you use a 20% merge factor and a 80% split factor, the file will start 
>>> merging unless you delete 60 percent of your records.  If you use 90% split 
>>> factor, you will have more overflowed groups.  These numbers refer to the 
>>> total amount of data in the file, not to any individual group.
>>> 
>>> For records of the size that you have, I do not see any advantage to using 
>>> a larger, 4

Re: [U2] RESIZE - dynamic files

2012-07-03 Thread Rick Nuckolls
The split load is not affecting anything here, since it is more than the actual 
load.  What your overflow suggests is that you lower the split.load value to 
70$% or below.  You could go ahead and set the merge.load to an arbitrarily low 
number ("1"), and it will probably never do a merge, which would be the same as 
specifying a minimum.modulus equal to "as large as it ever gets".  The 
exception to this is during file creation & clear.file,  when the 
minimum.modulus value determines the initial disk allocation.  Short of going 
to an arbitrarily large minimum.modulus, and a very low split.load, you are 
going to have some overflow (unless you have sequential keys & like sized 
records).

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Tuesday, July 03, 2012 12:54 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


Using the formula below, and changing the split to 90% I get the following:

File name ..   GENACCTRN_POSTED
Pathname ...   GENACCTRN_POSTED
File type ..   DYNAMIC
File style and revision    32BIT Revision 12
Hashing Algorithm ..   GENERAL
No. of groups (modulus)    103889 current ( minimum 103889, 114 empty,
22249 overflowed, 1764 badly )
Number of records ..   1290469
Large record size ..   3267 bytes
Number of large records    180
Group size .   4096 bytes
Load factors ...   90% (split), 50% (merge) and 72% (actual)
Total size .   519921664 bytes
Total size of record data ..   287400591 bytes
Total size of record IDs ...   21508497 bytes
Unused space ...   211004384 bytes
Total space for records    519913472 bytes

How does this look in terms of performance? 

My Actual load went down 8% as well as some overflow but it looks like my load 
% is still high at 72% I'm wondering if I should raise the MINIMUM.MODULUS even 
more 
since I still have a decent amount of overflow and not many large records. 

Chris


> From: r...@lynden.com
> To: u2-users@listserver.u2ug.org
> Date: Tue, 3 Jul 2012 10:21:16 -0700
> Subject: Re: [U2] RESIZE - dynamic files
> 
> (record + id / 4096 or 2048)
> 
> You need to factor in overhead & the split factor:   (records + ids) * 1.1 * 
> 1.25  / 4096(for 80%) 
> 
> If you use a 20% merge factor and a 80% split factor, the file will start 
> merging unless you delete 60 percent of your records.  If you use 90% split 
> factor, you will have more overflowed groups.  These numbers refer to the 
> total amount of data in the file, not to any individual group.
> 
> For records of the size that you have, I do not see any advantage to using a 
> larger, 4096, group size. You will end up with twice the number of records 
> per group vs 2048 (~ 13 vs ~ 7 ), and a little slower keyed access.
> 
> -Rick
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
> Sent: Tuesday, July 03, 2012 9:48 AM
> To: u2-users@listserver.u2ug.org
> Subject: Re: [U2] RESIZE - dynamic files
> 
> 
> File name ..   GENACCTRN_POSTED
> Pathname ...   GENACCTRN_POSTED
> File type ..   DYNAMIC
> File style and revision    32BIT Revision 12
> Hashing Algorithm ..   GENERAL
> No. of groups (modulus)    92776 current ( minimum 31, 89 empty,
> 28229 overflowed, 2485 badly )
> Number of records ..   1290469
> Large record size ..   3267 bytes
> Number of large records    180
> Group size .   4096 bytes
> Load factors ...   80% (split), 50% (merge) and 80% (actual)
> Total size .   500600832 bytes
> Total size of record data ..   287035391 bytes
> Total size of record IDs ...   21508449 bytes
> Unused space ...   192048800 bytes
> Total space for records    500592640 bytes
> 
> Using the record above, how would I calculate the following?
> 
> 1) MINIMUM.MODULUS (Is there a formula to use or should I add 20% to the 
> current number)?
> 2) SPLIT - would 90% seem about right?
> 3) MERGE - would 20% seem about right? 
> 4) Large Record Size - does 3276 seem right? 
> 5) Group Size - should I be using 4096?
> 
> I'm just a bit confused as to how to set these, I saw the formula to 
> calculate the MINIMUM.MODULUS which is (record + id / 4096 or 2048) but I 
> always get a lower number
> than my current modulus.. 
> 
> I also saw where it said to simply take your current modulus # and add 10-20% 
> and set the MINIMUM.MODULUS based on that..
> 
> Based on the table above I'm just trying to get an idea of what these should 
> be set at.
> 
> Thanks,
> 
> Chris
> 
> 
> > From: cjausti...@hotmail.com
> > To: u

Re: [U2] RESIZE - dynamic files

2012-07-03 Thread Rick Nuckolls
(record + id / 4096 or 2048)

You need to factor in overhead & the split factor:   (records + ids) * 1.1 * 
1.25  / 4096(for 80%) 

If you use a 20% merge factor and a 80% split factor, the file will start 
merging unless you delete 60 percent of your records.  If you use 90% split 
factor, you will have more overflowed groups.  These numbers refer to the total 
amount of data in the file, not to any individual group.

For records of the size that you have, I do not see any advantage to using a 
larger, 4096, group size. You will end up with twice the number of records per 
group vs 2048 (~ 13 vs ~ 7 ), and a little slower keyed access.

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Tuesday, July 03, 2012 9:48 AM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


File name ..   GENACCTRN_POSTED
Pathname ...   GENACCTRN_POSTED
File type ..   DYNAMIC
File style and revision    32BIT Revision 12
Hashing Algorithm ..   GENERAL
No. of groups (modulus)    92776 current ( minimum 31, 89 empty,
28229 overflowed, 2485 badly )
Number of records ..   1290469
Large record size ..   3267 bytes
Number of large records    180
Group size .   4096 bytes
Load factors ...   80% (split), 50% (merge) and 80% (actual)
Total size .   500600832 bytes
Total size of record data ..   287035391 bytes
Total size of record IDs ...   21508449 bytes
Unused space ...   192048800 bytes
Total space for records    500592640 bytes

Using the record above, how would I calculate the following?

1) MINIMUM.MODULUS (Is there a formula to use or should I add 20% to the 
current number)?
2) SPLIT - would 90% seem about right?
3) MERGE - would 20% seem about right? 
4) Large Record Size - does 3276 seem right? 
5) Group Size - should I be using 4096?

I'm just a bit confused as to how to set these, I saw the formula to calculate 
the MINIMUM.MODULUS which is (record + id / 4096 or 2048) but I always get a 
lower number
than my current modulus.. 

I also saw where it said to simply take your current modulus # and add 10-20% 
and set the MINIMUM.MODULUS based on that..

Based on the table above I'm just trying to get an idea of what these should be 
set at.

Thanks,

Chris


> From: cjausti...@hotmail.com
> To: u2-users@listserver.u2ug.org
> Date: Tue, 3 Jul 2012 10:28:17 -0500
> Subject: Re: [U2] RESIZE - dynamic files
> 
> 
> Doug,
> 
> When I do the math I come up with a different # (see below):
> 
> File name ..   TEST_FILE
> Pathname ...   TEST_FILE
> File type ..   DYNAMIC
> File style and revision    32BIT Revision 12
> Hashing Algorithm ..   GENERAL
> No. of groups (modulus)    82850 current ( minimum 24, 104 empty,
> 26225 overflowed, 1441 badly )
> Number of records ..   1157122
> Large record size ..   2036 bytes
> Number of large records    576
> Group size .   4096 bytes
> Load factors ...   80% (split), 50% (merge) and 80% (actual)
> Total size .   449605632 bytes
> Total size of record data ..   258687736 bytes
> Total size of record IDs ...   19283300 bytes
> Unused space ...   171626404 bytes
> Total space for records    449597440 bytes
> 
> -- 
> 258,687,736 bytes - Total size of record data
> 19,283,300 bytes - Total size of record IDs
> ===
> 277,971,036 bytes (record + id's)
> 
> 277,971,036 / 4,084 = 68,063 bytes (minimum modulus)
> -- 
> 
> 68,063 is less than the current modulus of 82,850. Something with this 
> formula doesn't seem right because if I use that formula I always calculate a 
> minimum modulus of less than the current modulus.
> 
> Thanks,
> 
> Chris
> 
> 
> 
> > Date: Mon, 2 Jul 2012 16:08:16 -0600
> > From: dave...@gmail.com
> > To: u2-users@listserver.u2ug.org
> > Subject: Re: [U2] RESIZE - dynamic files
> > 
> > Hi Chris:
> > 
> > You cannot get away with not resizing dynamic files in my experience.  The
> > files do not split and merge like we are led to believe.  The separator is
> > not used on dynamic files.  Your Universe file is badly sized.  The math
> > below will get you reasonably file size.
> > 
> > Let's do the math:
> > 
> > 258687736 (Record Size)
> > 192283300 (Key Size)
> > 
> > 450,971,036 (Data and Key Size)
> > 
> > 4096 (Group Size)
> > - 12   (32 Bit Overhead)
> > 
> > 4084 Usable Space
> > 
> > 450971036/4084 = Minimum Modulo 110424 (Prime is 110431)
> > 
> > 
> > [ad]
> > I hate doing this math all of the time.  I have a reasonably priced resize
> > program called XLr8Resizer for $99.00 to do this for me.
> > [/ad]
> > 
> > Regards,
> > Doug
> > www.u

Re: [U2] RESIZE - dynamic files

2012-07-02 Thread Rick Nuckolls
Chris,

I second the thought that, because of the splitting and merging of groups, it 
can be a waste of effort to overwork the "sizing" of a dynamic file.

One problem with your TEST_FILE below is that the Large Record Size is spec'ed 
at less than 50% of the group size.  Each record that is larger than the "large 
record size" is given at least one full sized buffer in the overflow file, so a 
record of 2037 bytes, in your example, would occupy 4096 bytes of space.  The 
ID and pointer is left in the primary data group.  It appears that your records 
average 250 bytes, so this probably is not a large factor, but that would also 
suggest that you stick to a GROUP.SIZE of 1 (2048 bytes) rather than 2.  Btw, 
each of your 576 large records probably counts towards the "overflowed badly" 
column, though, from an access point of view, the group might be in optimal 
shape.

The effective modulo of a dynamic file is based on the space used by the 
not(large records), but the " Total size of record data" includes the full 
buffer size of the overflow records, I believe, and so should not be used to 
compute the total size of your data. For record sizes like you have, I would 
compute the total of the ids+records, add about 10% for overhead, divide by the 
group size (2048, if you use the default), multiply by 1.25 (allow for the 80% 
splitting factor), and then set the minimum modulus to the next larger prime 
number.

In the example below, you can see 50 large records in a single group of a 
dynamic file, but only the id's are in the primary buffer.  If you do the math, 
you will find that each 1001 record is using up a  4096 byte overflow buffer. 


File name ..   BIGD
Pathname ...   BIGD
File type ..   DYNAMIC
Hashing Algorithm ..   GENERAL
No. of groups (modulus)    1 current ( minimum 1, 0 empty,
1 overflowed, 1 badly )
Number of records ..   50
Large record size ..   1000 bytes
Number of large records    50
Group size .   4096 bytes
Load factors ...   80% (split), 50% (merge) and 30% (actual)
Total size .   217088 bytes
Total size of record data ..   205466 bytes
Total size of record IDs ...   534 bytes
Unused space ...   2896 bytes
Total space for records    208896 bytes

LIST BIGD TOTAL EVAL "LEN(@ID)" TOTAL EVAL "LEN(@RECORD)" DET.SUP 18:03:29  07-
02-12  PAGE 1
LEN(@ID)..LEN(@RECORD)

==
134   50050

50 records listed.

Note that if I stuck to the defaults and used sequential ids, I would have 
saved more than 1/2 of the disk space, but still have used 150% of the total 
id+record size.

File name ..   BIGD
Pathname ...   BIGD
File type ..   DYNAMIC
Hashing Algorithm ..   GENERAL
No. of groups (modulus)    31 current ( minimum 1, 3 empty,
4 overflowed, 0 badly )
Number of records ..   50
Large record size ..   1628 bytes
Number of large records    0
Group size .   2048 bytes
Load factors ...   80% (split), 50% (merge) and 80% (actual)
Total size .   79872 bytes
Total size of record data ..   50709 bytes
Total size of record IDs ...   91 bytes
Unused space ...   24976 bytes
Total space for records    75776 bytes

Rick Nuckolls
Lynden Inc


-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Monday, July 02, 2012 2:07 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] RESIZE - dynamic files


The dynamic file I'm working with is below. What do 'overflowed' and 'badly' 
refer to under MODULUS? Is the goal of the RESIZE to eliminate that
overflow? Any ideas what I should change to achieve this?


File name ..   TEST_FILE
Pathname ...   TEST_FILE
File type ..   DYNAMIC
File style and revision    32BIT Revision 12
Hashing Algorithm ..   GENERAL
No. of groups (modulus)    82850 current ( minimum 24, 104 empty,
26225 overflowed, 1441 badly )
Number of records ..   1157122
Large record size ..   2036 bytes
Number of large records    576
Group size .   4096 bytes
Load factors ...   80% (split), 50% (merge) and 80% (actual)
Total size .   449605632 bytes
Total size of record data ..   258687736 bytes
Total size of record IDs ...   19283300 bytes
Unused space ...   171626404 bytes
Total space for records    449597440 bytes

Thanks,

Chris


> From: cjausti...@hotmail.com
> To: u2-users@listserver.u2ug.org
> Date: Mon, 2 Jul 2012 14:

Re: [U2] Do indexes record mv pos ?

2012-06-06 Thread Rick Nuckolls
Added "unique" to the first paragraph for clarification.
-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
Sent: Wednesday, June 06, 2012 11:58 AM
To: 'U2 Users List'
Subject: Re: [U2] Do indexes record mv pos ?

I am not sure what bug you are referring to. If the same value is repeated 
within a single MV field, the key should only be indexed a single time, but the 
same primary key would be referenced once in the index for each *unique* value 
in the MV list.

I would need to know a bit more about what you are trying to do to offer much 
other advice!

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Wednesday, June 06, 2012 11:52 AM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] Do indexes record mv pos ?


That bug is what caused me to come here Rick.
The program is finding the key twice, and repeating logic that doesn't apply 
using a LOCATE and getting the wrong position.



-Original Message-
From: Rick Nuckolls 
To: 'u2-users@listserver.u2ug.org' 
Sent: Wed, Jun 6, 2012 11:49 am
Subject: Re: [U2] Do indexes record mv pos ?


The short answer is "no".  The index does not contain the position within the 
ecord.  You could, theoretically, create an index based on an itype that 
ontained that information, but it would be a whole lot simpler, and probably 
ore efficient to just LOCATE the value that you are looking for within the 
asic program that is accessing the index.
Rick Nuckolls
ynden Inc
-Original Message-
rom: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] 
n Behalf Of Wjhonson
ent: Wednesday, June 06, 2012 11:37 AM
o: u2-users@listserver.u2ug.org
ubject: [U2] Do indexes record mv pos ?

sing the CREATE-INDEX command you can create secondary indexes on files, and 
hen in BASIC using the SELECTINDEX command you can retrieve results into a list 
ariable so you can walk it with READNEXT
Can you use a construct like
EADNEXT KEY,MV FROM MYLIST ELSE
That is, does the index itself retain the multi-value position into the 
nderlying primary record?
r are all index entries key only without any knowledge of the multivalue 
osition ?
___
2-Users mailing list
2-us...@listserver.u2ug.org
ttp://listserver.u2ug.org/mailman/listinfo/u2-users
__
2-Users mailing list
2-us...@listserver.u2ug.org
ttp://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Do indexes record mv pos ?

2012-06-06 Thread Rick Nuckolls
I am not sure what bug you are referring to. If the same value is repeated 
within a single MV field, the key should only be indexed a single time, but the 
same primary key would be referenced once in the index for each value in the MV 
list.

I would need to know a bit more about what you are trying to do to offer much 
other advice!

-Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Wednesday, June 06, 2012 11:52 AM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] Do indexes record mv pos ?


That bug is what caused me to come here Rick.
The program is finding the key twice, and repeating logic that doesn't apply 
using a LOCATE and getting the wrong position.



-Original Message-
From: Rick Nuckolls 
To: 'u2-users@listserver.u2ug.org' 
Sent: Wed, Jun 6, 2012 11:49 am
Subject: Re: [U2] Do indexes record mv pos ?


The short answer is "no".  The index does not contain the position within the 
ecord.  You could, theoretically, create an index based on an itype that 
ontained that information, but it would be a whole lot simpler, and probably 
ore efficient to just LOCATE the value that you are looking for within the 
asic program that is accessing the index.
Rick Nuckolls
ynden Inc
-Original Message-
rom: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] 
n Behalf Of Wjhonson
ent: Wednesday, June 06, 2012 11:37 AM
o: u2-users@listserver.u2ug.org
ubject: [U2] Do indexes record mv pos ?

sing the CREATE-INDEX command you can create secondary indexes on files, and 
hen in BASIC using the SELECTINDEX command you can retrieve results into a list 
ariable so you can walk it with READNEXT
Can you use a construct like
EADNEXT KEY,MV FROM MYLIST ELSE
That is, does the index itself retain the multi-value position into the 
nderlying primary record?
r are all index entries key only without any knowledge of the multivalue 
osition ?
___
2-Users mailing list
2-us...@listserver.u2ug.org
ttp://listserver.u2ug.org/mailman/listinfo/u2-users
__
2-Users mailing list
2-us...@listserver.u2ug.org
ttp://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Do indexes record mv pos ?

2012-06-06 Thread Rick Nuckolls
The short answer is "no".  The index does not contain the position within the 
record.  You could, theoretically, create an index based on an itype that 
contained that information, but it would be a whole lot simpler, and probably 
more efficient to just LOCATE the value that you are looking for within the 
basic program that is accessing the index.

Rick Nuckolls
Lynden Inc

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Wednesday, June 06, 2012 11:37 AM
To: u2-users@listserver.u2ug.org
Subject: [U2] Do indexes record mv pos ?


Using the CREATE-INDEX command you can create secondary indexes on files, and 
then in BASIC using the SELECTINDEX command you can retrieve results into a 
list variable so you can walk it with READNEXT

Can you use a construct like
READNEXT KEY,MV FROM MYLIST ELSE

That is, does the index itself retain the multi-value position into the 
underlying primary record?
Or are all index entries key only without any knowledge of the multivalue 
position ?

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] SAVING UNIQUE ( multivalued)

2012-05-18 Thread Rick Nuckolls
Nice,

Rick

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Brian Leach
Sent: Friday, May 18, 2012 6:48 AM
To: 'U2 Users List'
Subject: Re: [U2] SAVING UNIQUE ( multivalued)

Another option, using UniVerse SQL to create the list:

SELECT DISTINCT column_name TO SLIST 0 FROM UNNEST filename ON column_name
[WHERE clause]

For example:

LIST rigtable005 GROUP_COL 01:46:32pm  18 May 2012  PAGE1
rigtable005 Group_col.

10  GROUP 2
GROUP 3
GROUP 1
GROUP 2
GROUP 3
GROUP 1
GROUP 2
GROUP 3
GROUP 1
GROUP 2
11  GROUP 3
GROUP 1
(etc)

01 SELECT DISTINCT GROUP_COL TO SLIST 0 FROM UNNEST rigtable005 ON
GROUP_COL;

3 record(s) selected to SELECT list #0.
>>LIST VOC

0 records listed.
"GROUP 1" not found.
"GROUP 2" not found.
"GROUP 3" not found.

Brian




___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] SAVING UNIQUE ( multivalued)

2012-05-17 Thread Rick Nuckolls
Deduping BASIC program, short version:

0001:   SELECT '' TO 1  
0002:   EXECUTE 'MERGE.LIST 0 UNION 1'  
0003:END

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
Sent: Thursday, May 17, 2012 2:36 PM
To: 'U2 Users List'
Subject: Re: [U2] SAVING UNIQUE ( multivalued)

Okay,  I timed the difference with 1,400,000 or so record ids on a relatively 
old SUN box.

Union against an identical list 64930 milliseconds of CPU
Union with a blank list 31890 ms.

The result is the same.

The timings were started after both lists were instantiated, and are for the 
MERGE.LIST operation only.


-Rick 

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
Sent: Thursday, May 17, 2012 2:22 PM
To: 'U2 Users List'
Subject: Re: [U2] SAVING UNIQUE ( multivalued)

I do not know the guts of the MERGE.LIST command, but it may well sort and 
dedupe each list prior to performing the merge /union operation.  But, for the 
sake of argument, suppose that, for a union, MERGE.LIST creates a single 
internal hashmap and makes an entry for each unique item in list1 and list2.  
Using a blank list for the either list in "MERGE.LIST list1 UNION list2" will 
produce the same result as using a duplicate list, but with just slightly more 
than half the work.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Thursday, May 17, 2012 2:15 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] SAVING UNIQUE ( multivalued)


Rick,

I'm not following you.. There isn't a 'second list'.. it's one list that is 
being manipulated (George's example only uses 1 list) which he calls 1 and 
UNIQUE (interchangeably) . 

Perhaps you can show us what you're referring to so we can see an example.. I 
thought George's solution was excellent.

Chris


> From: r...@lynden.com
> To: u2-users@listserver.u2ug.org
> Date: Thu, 17 May 2012 14:07:24 -0700
> Subject: Re: [U2] SAVING UNIQUE  ( multivalued)
> 
> UNION would definely be an alternative, but doing it against a needlessly 
> long second list offends my Scotch genes. It is possible to create an active, 
> zero length, selectlist programmatically, so perhaps I should write a little 
> command to do that and and a MERGE.LIST UNION against it. 
> 
> 
> 
> -Rick
> 
> On May 17, 2012, at 1:47 PM, "George Gallen"  wrote:
> 
> > What about ...
> > 
> > : P 
> > 
> > 0001: PA
> > 
> > 0002: QSELECT <> * SAVING <>  
> > 
> > 0003: SAVE.LIST UNIQUE 
> > 0004: GET.LIST UNIQUE TO 1
> > 0005: MERGE.LIST 1 UNION 1
> > 0006: SAVE.LIST UNIQUE
> > 0007: GET.LIST UNIQUE
> > 
> > (The MERGE.LIST will sort and dedupe)
> > 
> > 
> > 0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'" 
> > 
> > 0005: GET.LIST UNIQUE
> > 
> > -Original Message-
> > From: u2-users-boun...@listserver.u2ug.org 
> > [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
> > Sent: Thursday, May 17, 2012 4:38 PM
> > To: 'U2 Users List'
> > Subject: Re: [U2] SAVING UNIQUE ( multivalued)
> > 
> > This does present a challenge,
> > 
> > The following (non-portable solution works)
> > :ED VOC MUNIQUE 
> > 
> > 5 lines long.   
> > 
> > 
> > : P 
> > 
> > 0001: PA
> > 
> > 0002: QSELECT <> * SAVING <>  
> > 
> > 0003: SAVE.LIST UNIQUE  
> > 
> > 0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'" 
> > 
> > 0005: GET.LIST UNIQUE
> > 
> > Or, I suppose that one could also
> > 
> > EDIT.LIST GARBAGE

Re: [U2] SAVING UNIQUE ( multivalued)

2012-05-17 Thread Rick Nuckolls
Okay,  I timed the difference with 1,400,000 or so record ids on a relatively 
old SUN box.

Union against an identical list 64930 milliseconds of CPU
Union with a blank list 31890 ms.

The result is the same.

The timings were started after both lists were instantiated, and are for the 
MERGE.LIST operation only.


-Rick 

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
Sent: Thursday, May 17, 2012 2:22 PM
To: 'U2 Users List'
Subject: Re: [U2] SAVING UNIQUE ( multivalued)

I do not know the guts of the MERGE.LIST command, but it may well sort and 
dedupe each list prior to performing the merge /union operation.  But, for the 
sake of argument, suppose that, for a union, MERGE.LIST creates a single 
internal hashmap and makes an entry for each unique item in list1 and list2.  
Using a blank list for the either list in "MERGE.LIST list1 UNION list2" will 
produce the same result as using a duplicate list, but with just slightly more 
than half the work.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Thursday, May 17, 2012 2:15 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] SAVING UNIQUE ( multivalued)


Rick,

I'm not following you.. There isn't a 'second list'.. it's one list that is 
being manipulated (George's example only uses 1 list) which he calls 1 and 
UNIQUE (interchangeably) . 

Perhaps you can show us what you're referring to so we can see an example.. I 
thought George's solution was excellent.

Chris


> From: r...@lynden.com
> To: u2-users@listserver.u2ug.org
> Date: Thu, 17 May 2012 14:07:24 -0700
> Subject: Re: [U2] SAVING UNIQUE  ( multivalued)
> 
> UNION would definely be an alternative, but doing it against a needlessly 
> long second list offends my Scotch genes. It is possible to create an active, 
> zero length, selectlist programmatically, so perhaps I should write a little 
> command to do that and and a MERGE.LIST UNION against it. 
> 
> 
> 
> -Rick
> 
> On May 17, 2012, at 1:47 PM, "George Gallen"  wrote:
> 
> > What about ...
> > 
> > : P 
> > 
> > 0001: PA
> > 
> > 0002: QSELECT <> * SAVING <>  
> > 
> > 0003: SAVE.LIST UNIQUE 
> > 0004: GET.LIST UNIQUE TO 1
> > 0005: MERGE.LIST 1 UNION 1
> > 0006: SAVE.LIST UNIQUE
> > 0007: GET.LIST UNIQUE
> > 
> > (The MERGE.LIST will sort and dedupe)
> > 
> > 
> > 0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'" 
> > 
> > 0005: GET.LIST UNIQUE
> > 
> > -Original Message-
> > From: u2-users-boun...@listserver.u2ug.org 
> > [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
> > Sent: Thursday, May 17, 2012 4:38 PM
> > To: 'U2 Users List'
> > Subject: Re: [U2] SAVING UNIQUE ( multivalued)
> > 
> > This does present a challenge,
> > 
> > The following (non-portable solution works)
> > :ED VOC MUNIQUE 
> > 
> > 5 lines long.   
> > 
> > 
> > : P 
> > 
> > 0001: PA
> > 
> > 0002: QSELECT <> * SAVING <>  
> > 
> > 0003: SAVE.LIST UNIQUE  
> > 
> > 0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'" 
> > 
> > 0005: GET.LIST UNIQUE
> > 
> > Or, I suppose that one could also
> > 
> > EDIT.LIST GARBAGE   
> >
> > New record. 
> > 
> > 
> > : I 
> > 
> > 0001= KAJDF;LJASDLF;KJADSL;FKJASDL;FJKASLD;JFALS;DJFLASKDF  
> > 
> > 0002=   
> > 
> > Bottom at line 1. 

Re: [U2] SAVING UNIQUE ( multivalued)

2012-05-17 Thread Rick Nuckolls
I do not know the guts of the MERGE.LIST command, but it may well sort and 
dedupe each list prior to performing the merge /union operation.  But, for the 
sake of argument, suppose that, for a union, MERGE.LIST creates a single 
internal hashmap and makes an entry for each unique item in list1 and list2.  
Using a blank list for the either list in "MERGE.LIST list1 UNION list2" will 
produce the same result as using a duplicate list, but with just slightly more 
than half the work.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Thursday, May 17, 2012 2:15 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] SAVING UNIQUE ( multivalued)


Rick,

I'm not following you.. There isn't a 'second list'.. it's one list that is 
being manipulated (George's example only uses 1 list) which he calls 1 and 
UNIQUE (interchangeably) . 

Perhaps you can show us what you're referring to so we can see an example.. I 
thought George's solution was excellent.

Chris


> From: r...@lynden.com
> To: u2-users@listserver.u2ug.org
> Date: Thu, 17 May 2012 14:07:24 -0700
> Subject: Re: [U2] SAVING UNIQUE  ( multivalued)
> 
> UNION would definely be an alternative, but doing it against a needlessly 
> long second list offends my Scotch genes. It is possible to create an active, 
> zero length, selectlist programmatically, so perhaps I should write a little 
> command to do that and and a MERGE.LIST UNION against it. 
> 
> 
> 
> -Rick
> 
> On May 17, 2012, at 1:47 PM, "George Gallen"  wrote:
> 
> > What about ...
> > 
> > : P 
> > 
> > 0001: PA
> > 
> > 0002: QSELECT <> * SAVING <>  
> > 
> > 0003: SAVE.LIST UNIQUE 
> > 0004: GET.LIST UNIQUE TO 1
> > 0005: MERGE.LIST 1 UNION 1
> > 0006: SAVE.LIST UNIQUE
> > 0007: GET.LIST UNIQUE
> > 
> > (The MERGE.LIST will sort and dedupe)
> > 
> > 
> > 0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'" 
> > 
> > 0005: GET.LIST UNIQUE
> > 
> > -Original Message-
> > From: u2-users-boun...@listserver.u2ug.org 
> > [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
> > Sent: Thursday, May 17, 2012 4:38 PM
> > To: 'U2 Users List'
> > Subject: Re: [U2] SAVING UNIQUE ( multivalued)
> > 
> > This does present a challenge,
> > 
> > The following (non-portable solution works)
> > :ED VOC MUNIQUE 
> > 
> > 5 lines long.   
> > 
> > 
> > : P 
> > 
> > 0001: PA
> > 
> > 0002: QSELECT <> * SAVING <>  
> > 
> > 0003: SAVE.LIST UNIQUE  
> > 
> > 0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'" 
> > 
> > 0005: GET.LIST UNIQUE
> > 
> > Or, I suppose that one could also
> > 
> > EDIT.LIST GARBAGE   
> >
> > New record. 
> > 
> > 
> > : I 
> > 
> > 0001= KAJDF;LJASDLF;KJADSL;FKJASDL;FJKASLD;JFALS;DJFLASKDF  
> > 
> > 0002=   
> > 
> > Bottom at line 1.   
> > 
> > :   
> > 
> > Top.
> > 
> > : FI
> > 
> > "GARBAGE" filed in file "&SAVEDLISTS&". 
> > 
> > :GET.LIST GARBAGE TO 1  
> > 
> > 
> > 1 record(s) selected to SELECT

Re: [U2] SAVING UNIQUE ( multivalued)

2012-05-17 Thread Rick Nuckolls
UNION would definely be an alternative, but doing it against a needlessly long 
second list offends my Scotch genes. It is possible to create an active, zero 
length, selectlist programmatically, so perhaps I should write a little command 
to do that and and a MERGE.LIST UNION against it. 



-Rick

On May 17, 2012, at 1:47 PM, "George Gallen"  wrote:

> What about ...
> 
> : P   
>   
> 0001: PA  
>   
> 0002: QSELECT <> * SAVING <>
>   
> 0003: SAVE.LIST UNIQUE 
> 0004: GET.LIST UNIQUE TO 1
> 0005: MERGE.LIST 1 UNION 1
> 0006: SAVE.LIST UNIQUE
> 0007: GET.LIST UNIQUE
> 
> (The MERGE.LIST will sort and dedupe)
> 
> 
> 0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'"   
>   
> 0005: GET.LIST UNIQUE
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rick Nuckolls
> Sent: Thursday, May 17, 2012 4:38 PM
> To: 'U2 Users List'
> Subject: Re: [U2] SAVING UNIQUE ( multivalued)
> 
> This does present a challenge,
> 
> The following (non-portable solution works)
> :ED VOC MUNIQUE   
>   
> 5 lines long. 
>   
> 
> : P   
>   
> 0001: PA  
>   
> 0002: QSELECT <> * SAVING <>
>   
> 0003: SAVE.LIST UNIQUE
>   
> 0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'"   
>   
> 0005: GET.LIST UNIQUE
> 
> Or, I suppose that one could also
> 
> EDIT.LIST GARBAGE 
>  
> New record.   
>   
> 
> : I   
>   
> 0001= KAJDF;LJASDLF;KJADSL;FKJASDL;FJKASLD;JFALS;DJFLASKDF
>   
> 0002= 
>   
> Bottom at line 1. 
>   
> : 
>   
> Top.  
>   
> : FI  
>   
> "GARBAGE" filed in file "&SAVEDLISTS&".   
>   
> :GET.LIST GARBAGE TO 1
>   
> 
> 1 record(s) selected to SELECT list #1.   
>   
> :QSELECT IU * SAVING 19   
>   
> 
> 32987 record(s) selected to SELECT list #0.   
>   
> ::MERGE.LIST 0 DIFF 1 
>   
> 
> 90 record(s) selected to SELECT list #0.  
>   
> ::  
> 
> 
> Be nice if there was MV support of 'SAVING UNIQUE', or a cleaner syntactic 
> way to use MERGE.LIST to dedupe.
> 
> -Rick
> 
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
> Sent: Thursday, May 17, 2012 1:20 PM
> To: u2-users@listserver.u2ug.org
> Subject: Re: [U2] SAVING UNIQUE ( multivalued)
> 
> 
> I usually get my exploded list and then DEDUPE using the following:
> 
> LOCATE  VALUE.TO.FIND IN UNIQUE.LIST BY "AL" SETTING POS ELSE
> UNIQUE.LIST = INSERT(UNIQUE.LIST,1,POS,0,VALUE.TO.FIND)
> END
> 
> This puts everything in a nice ARRAY called UNIQUE.LIST, I then can use a FOR 
> loop to loop through as needed.
> 
> Chris
> 
> 
>> To: u2-users@listserver.u2ug.org
>> From: wjhon...@aol.com
>> Date: Thu, 17 May 2012 16:13:31 -0400
>> Subject: Re: [U2] SAVING UNIQUE  ( multivalued)
>> 
>> 
>> You have two issues.
>> One is to create a list from an exploded multi-value
>> The other issue, is to dedupe that list.
>> 
>> Without using something like REFORMAT I don't

Re: [U2] SAVING UNIQUE ( multivalued)

2012-05-17 Thread Rick Nuckolls
This does present a challenge,

The following (non-portable solution works)
:ED VOC MUNIQUE 
5 lines long.   

: P 
0001: PA
0002: QSELECT <> * SAVING <>  
0003: SAVE.LIST UNIQUE  
0004: sh -c "/usr/bin/sort -uo '&SAVEDLISTS&/UNIQUE' '&SAVEDLISTS&/UNIQUE'" 
0005: GET.LIST UNIQUE

Or, I suppose that one could also

EDIT.LIST GARBAGE  
New record. 

: I 
0001= KAJDF;LJASDLF;KJADSL;FKJASDL;FJKASLD;JFALS;DJFLASKDF  
0002=   
Bottom at line 1.   
:   
Top.
: FI
"GARBAGE" filed in file "&SAVEDLISTS&". 
:GET.LIST GARBAGE TO 1  

1 record(s) selected to SELECT list #1. 
:QSELECT IU * SAVING 19 

32987 record(s) selected to SELECT list #0. 
::MERGE.LIST 0 DIFF 1   

90 record(s) selected to SELECT list #0.
::  


Be nice if there was MV support of 'SAVING UNIQUE', or a cleaner syntactic way 
to use MERGE.LIST to dedupe.

-Rick



-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Thursday, May 17, 2012 1:20 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] SAVING UNIQUE ( multivalued)


I usually get my exploded list and then DEDUPE using the following:

LOCATE  VALUE.TO.FIND IN UNIQUE.LIST BY "AL" SETTING POS ELSE
 UNIQUE.LIST = INSERT(UNIQUE.LIST,1,POS,0,VALUE.TO.FIND)
END

This puts everything in a nice ARRAY called UNIQUE.LIST, I then can use a FOR 
loop to loop through as needed.

Chris


> To: u2-users@listserver.u2ug.org
> From: wjhon...@aol.com
> Date: Thu, 17 May 2012 16:13:31 -0400
> Subject: Re: [U2] SAVING UNIQUE  ( multivalued)
> 
> 
> You have two issues.
> One is to create a list from an exploded multi-value
> The other issue, is to dedupe that list.
> 
> Without using something like REFORMAT I don't think you can get the two 
> issues resolved at once.
> Qselect does not allow Unique
> So
> QSELECT MYFILE SAVING 2
> will explode the multi-values, but it won't dedupe them.
> 
> 
> 
> -Original Message-
> From: Rick Nuckolls 
> To: 'U2 Users List' 
> Sent: Thu, May 17, 2012 1:06 pm
> Subject: [U2] SAVING UNIQUE ( multivalued)
> 
> 
> Does anyone know a trick to achieve the equivalent of
> SELECT filename SAVING UNIQUE fieldname
> When "fieldname" is the name of a multivalued field, and I want a list  of 
> all 
> he unique values for that field?
> The syntax above does not explode the values, but just looks at the whole 
> field.
> I suppose that I can do a LIST with a BY.EXP & a BREAK.ON, but perhaps I am 
> issing something...
> Thanks,
> Rick Nuckolls
> ynden Inc.
> 
> __
> 2-Users mailing list
> 2-us...@listserver.u2ug.org
> ttp://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
  
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] SAVING UNIQUE ( multivalued)

2012-05-17 Thread Rick Nuckolls
QSELECT ...SAVING... evidently does not allow UNIQUE...   (Universe)

Still, it looked hopeful.

-Rick 

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
Sent: Thursday, May 17, 2012 12:56 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] SAVING UNIQUE ( multivalued)


I found an old post that seemed to address this:


To do a SAVING UNIQUE with a mulit-valued field, you have to use
QSELECT and the field has to be an attribute number, not a dictionary name

Ex.

GET.LIST WORKING.IMOD.6 TO 1
QSELECT ADDRESS WITH ADDRESS.CHANGE.DATE GE ':X.CHG.DATE:' SAVING UNIQUE 4
SAVE.LIST GET.IMOD.ADDRESS
...

George

> From: r...@lynden.com
> To: u2-users@listserver.u2ug.org
> Date: Thu, 17 May 2012 12:39:09 -0700
> Subject: [U2] SAVING UNIQUE  ( multivalued)
> 
> Does anyone know a trick to achieve the equivalent of
> 
> SELECT filename SAVING UNIQUE fieldname
> 
> When "fieldname" is the name of a multivalued field, and I want a list  of 
> all the unique values for that field?
> 
> The syntax above does not explode the values, but just looks at the whole 
> field.
> 
> I suppose that I can do a LIST with a BY.EXP & a BREAK.ON, but perhaps I am 
> missing something...
> 
> Thanks,
> 
> Rick Nuckolls
> Lynden Inc.
> 
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
  
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


[U2] SAVING UNIQUE ( multivalued)

2012-05-17 Thread Rick Nuckolls
Does anyone know a trick to achieve the equivalent of

SELECT filename SAVING UNIQUE fieldname

When "fieldname" is the name of a multivalued field, and I want a list  of all 
the unique values for that field?

The syntax above does not explode the values, but just looks at the whole field.

I suppose that I can do a LIST with a BY.EXP & a BREAK.ON, but perhaps I am 
missing something...

Thanks,

Rick Nuckolls
Lynden Inc.


___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] User timeout question

2012-05-01 Thread Rick Nuckolls
I gather that in Unidata, the command is "TIMEOUT".  Note that the parameter is 
seconds.  "TIMEOUT 0" might reset it, but it does not say anything in this 
document.  (From Unidata Commands reference)

-Rick

TIMEOUT nn
Description
The ECL TIMEOUT command automatically logs a user out of a UniData session if 
input is not received in nn seconds. The setting remains in effect for the 
current UniData session only.
TIMEOUT applies to the following:
ECL (colon) prompt.
Proc IP and IBP commands.
Paragraph inline prompting (except with the I option).
UniBasic INPUT commands and the IN function.
TIMEOUT does not apply to the prompt that displays after an interrupt in ECL.
UniData executes the LOGOUT paragraph before exiting the session.Warning: 
Depending on your application coding, setting TIMEOUT could cause logical 
database inconsistencies. For example, without transaction processing in 
effect, an application might update part of a record, prompt for user input, 
and then time out at the prompt without updating the rest of the record.
Example
In the following example, the TIMEOUT command logs the user off after 59 
seconds if UniData receives no input:
:TIMEOUT 59
Process will timeout after waiting 59 seconds for input.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Lunt, Bruce
Sent: Tuesday, May 01, 2012 12:48 PM
To: 'U2 Users List'
Subject: Re: [U2] User timeout question

I tried HELP AUTOLOGOUT but it was not there. Is this a recent command? We
are running version 7.1 of Unidata.

-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Tuesday, May 01, 2012 12:18 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] User timeout question


HELP AUTOLOGOUT



-Original Message-
From: Lunt, Bruce 
To: u2-users 
Sent: Tue, May 1, 2012 11:59 am
Subject: [U2] User timeout question


Hi All,

e are having a problem with a particular user who is opening up a aintenance
screen and then leaving the record in the locked state when he oes home. Is
there a way to log him off the system (and unsetting locks) fter a certain
amount of time has elapsed?

hanks in advance,
ruce

tw we are running HPUX 11 on HP9000 with SB+ screens.
__
2-Users mailing list
2-us...@listserver.u2ug.org
ttp://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] User timeout question

2012-05-01 Thread Rick Nuckolls
No guarantees as to how it works with SB, but UV has an  AUTOLOGOUT {idle 
minutes} command that might be of use.

-Rick Nuckolls

-Original Message-
From: u2-users-boun...@listserver.u2ug.org 
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Lunt, Bruce
Sent: Tuesday, May 01, 2012 11:58 AM
To: u2-users@listserver.u2ug.org
Subject: [U2] User timeout question

Hi All,
 
We are having a problem with a particular user who is opening up a
maintenance screen and then leaving the record in the locked state when he
goes home. Is there a way to log him off the system (and unsetting locks)
after a certain amount of time has elapsed?
 
Thanks in advance,
Bruce
 
btw we are running HPUX 11 on HP9000 with SB+ screens.
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] YYMMDD easy way?

2012-04-25 Thread Rick Nuckolls
Even the best code for converting an internal date to an external one is a tad 
complicated. I would take all reasonable steps to avoid doing it an extra two 
times per date. 

-Rick

On Apr 25, 2012, at 7:43 AM, "Charlie Noah"  wrote:

> Hi Chuck,
> 
> I've never seen this to fail on any implementation or flavor:
> 
> OCONV(TODAY,'DY2')'R%2': OCONV(TODAY,'DM')'R%2': OCONV(TODAY,'DD')'R%2'
> 
> If anyone has, please let me know and I'll rethink. The code assumes 
> (yeah, I know) that TODAY is in ICONV form. I've always used D2Y (I 
> don't remember why) but it's interesting to note that DY2 works as well.
> 
> Charlie
> 
> On 04-25-2012 9:30 AM, Charles Stevenson wrote:
>> me:  Win 2003
>> Perry? 10.2? 10.3?  Redhat?
>> 
>> I'd sure like to know what makes the difference.
>> I'd hate to get bit - again! - in a migration or upgrade.
>> The worst fall-out I ever had in an upgrade was when they changed an 
>> obscure FMT code without telling anyone.
>> 
>> On 4/25/2012 9:07 AM, Rick Nuckolls wrote:
>>> If not flavor, then hardware/os?
>>> 
>>> (Sparc/Solaris)
>>> 
>>> -Rick
>>> 
>>> On Apr 25, 2012, at 5:26 AM, Charles Stevenson wrote:
>>> 
>>>> On my UV10.2.10 it behaves properly only with [2'',2''], as Richard&
>>>> Perry describe.
>>>> 
>>>>OCONV( "16187", "DYMD['','']" )   = "2012425"
>>>>OCONV( "16187", "DYMD[2'',2'']" ) = "120425"
>>>> 
>>>> Like Rick, I find flavor does not matter.
>>>> On 4/24/2012 7:38 PM, Rick Nuckolls wrote:
>>>>> That was my thought, but the flavor does not seem to affect it on 
>>>>> my version.
>>>>> 
>>>>> -Rick
>>>>> 
>>>>> On Apr 24, 2012, at 5:36 PM, Richard Lewis wrote:
>>>>> 
>>>>>> Or maybe it's my Pick flavor.
>>>>>> 
>>>>>> Richard Lewis
>>>>>> 
>>>>>> On Tue, Apr 24, 2012 at 6:27 PM, Rick Nuckolls   
>>>>>> wrote:
>>>>>> 
>>>>>>> Hmmm,
>>>>>>> 
>>>>>>> That must be a change at UV 11.  10.2.x still produces 2 digit 
>>>>>>> months and
>>>>>>> days without the extra 2’s.
>>>>>>> 
>>>>>>> -Rick
>>>>>>> 
>>>>>>> 
>>>>>>> On Apr 24, 2012, at 5:21 PM, Richard Lewis wrote:
>>>>>>> 
>>>>>>>> On UV 11.1.3 this leaves single-digit months as a single digit.
>>>>>>>> 
>>>>>>>> OCONV(TODAY, 'DYMD[2"",2"",2]') does the job correctly.  The 
>>>>>>>> brackets
>>>>>>> allow
>>>>>>>> format modifiers to the parameters that follow the D conversion 
>>>>>>>> code, in
>>>>>>>> this case, 'YMD'.  The 2's specifiy how many characters to 
>>>>>>>> display, and
>>>>>>> the
>>>>>>>> empty quotes specify the 'text' with which to separate the 
>>>>>>>> elements.
>>>>>>>> There's about 80 lines that describe it when you do HELP CONV D 
>>>>>>>> at TCL.
>>>>>>>> 
>>>>>>>> Richard Lewis
>>>>>>>> 
>>>>>>>> 
>>>>>>>> On Tue, Apr 24, 2012 at 6:08 PM, Rick 
>>>>>>>> Nuckolls   wrote:
>>>>>>>> 
>>>>>>>>> Or, a bit more simply:
>>>>>>>>> 
>>>>>>>>> OCONV(TODAY, "D2YMD[‘’ , ’’]”)
>>>>>>>>> On Apr 24, 2012, at 4:58 PM, Perry Taylor wrote:
>>>>>>>>> 
>>>>>>>>>> OCONV(TODAY, 'DYMD[4"",2"",2]')
>>>>>>>>>> 
>>>>>>>>>> 
>>>>>>>>>> - Original Message -
>>>>>>>>>> From: Lunt, Bruce [mailto:bl...@shaklee.com]
>>>>>>>>>> Sent: Tuesday, April 24, 2012 07:55 PM
>>>>>>>>>> To: 'U2 Users List'
>>>>>>>>>> Subject: Re: [U2] YYMMDD easy way?
>>>>>>>>>> 
>>>>>>>>>> On Unidata try: OCONV(TODAY,'DYMD')
>>>>>>>>>> 
>>>>>>>>>> -Original Message-
>>>>>>>>>> From: u2-users-boun...@listserver.u2ug.org
>>>>>>>>>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of 
>>>>>>>>>> Wjhonson
>>>>>>>>>> Sent: Tuesday, April 24, 2012 4:52 PM
>>>>>>>>>> To: u2-users@listserver.u2ug.org
>>>>>>>>>> Subject: [U2] YYMMDD easy way?
>>>>>>>>>> 
>>>>>>>>>> 
>>>>>>>>>> 
>>>>>>>>>> YYMMDD = OCONV(TODAY,'DY2'):OCONV(TODAY,'DM'):OCONV(TODAY,'DD')
>>>>>>>>>> 
>>>>>>>>>> easier way to do this? 
>>>>>>>>>> ___
>>>>>>>>>> 
>>>> 
>>>> ___
>>>> U2-Users mailing list
>>>> U2-Users@listserver.u2ug.org
>>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>>> ___
>>> U2-Users mailing list
>>> U2-Users@listserver.u2ug.org
>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>>> 
>> 
>> 
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] YYMMDD easy way?

2012-04-25 Thread Rick Nuckolls
If not flavor, then hardware/os?

(Sparc/Solaris)

-Rick

On Apr 25, 2012, at 5:26 AM, Charles Stevenson wrote:

> 
> On my UV10.2.10 it behaves properly only with [2'',2''], as Richard & 
> Perry describe.
> 
>OCONV( "16187", "DYMD['','']" )   = "2012425"
>OCONV( "16187", "DYMD[2'',2'']" ) = "120425"
> 
> Like Rick, I find flavor does not matter.
> On 4/24/2012 7:38 PM, Rick Nuckolls wrote:
>> That was my thought, but the flavor does not seem to affect it on my version.
>> 
>> -Rick
>> 
>> On Apr 24, 2012, at 5:36 PM, Richard Lewis wrote:
>> 
>>> Or maybe it's my Pick flavor.
>>> 
>>> Richard Lewis
>>> 
>>> On Tue, Apr 24, 2012 at 6:27 PM, Rick Nuckolls  wrote:
>>> 
>>>> Hmmm,
>>>> 
>>>> That must be a change at UV 11.  10.2.x still produces 2 digit months and
>>>> days without the extra 2’s.
>>>> 
>>>> -Rick
>>>> 
>>>> 
>>>> On Apr 24, 2012, at 5:21 PM, Richard Lewis wrote:
>>>> 
>>>>> On UV 11.1.3 this leaves single-digit months as a single digit.
>>>>> 
>>>>> OCONV(TODAY, 'DYMD[2"",2"",2]') does the job correctly.  The brackets
>>>> allow
>>>>> format modifiers to the parameters that follow the D conversion code, in
>>>>> this case, 'YMD'.  The 2's specifiy how many characters to display, and
>>>> the
>>>>> empty quotes specify the 'text' with which to separate the elements.
>>>>> There's about 80 lines that describe it when you do HELP CONV D at TCL.
>>>>> 
>>>>> Richard Lewis
>>>>> 
>>>>> 
>>>>> On Tue, Apr 24, 2012 at 6:08 PM, Rick Nuckolls  wrote:
>>>>> 
>>>>>> Or, a bit more simply:
>>>>>> 
>>>>>> OCONV(TODAY, "D2YMD[‘’ , ’’]”)
>>>>>> On Apr 24, 2012, at 4:58 PM, Perry Taylor wrote:
>>>>>> 
>>>>>>> OCONV(TODAY, 'DYMD[4"",2"",2]')
>>>>>>> 
>>>>>>> 
>>>>>>> - Original Message -
>>>>>>> From: Lunt, Bruce [mailto:bl...@shaklee.com]
>>>>>>> Sent: Tuesday, April 24, 2012 07:55 PM
>>>>>>> To: 'U2 Users List'
>>>>>>> Subject: Re: [U2] YYMMDD easy way?
>>>>>>> 
>>>>>>> On Unidata try: OCONV(TODAY,'DYMD')
>>>>>>> 
>>>>>>> -Original Message-
>>>>>>> From: u2-users-boun...@listserver.u2ug.org
>>>>>>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
>>>>>>> Sent: Tuesday, April 24, 2012 4:52 PM
>>>>>>> To: u2-users@listserver.u2ug.org
>>>>>>> Subject: [U2] YYMMDD easy way?
>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>>> YYMMDD = OCONV(TODAY,'DY2'):OCONV(TODAY,'DM'):OCONV(TODAY,'DD')
>>>>>>> 
>>>>>>> easier way to do this? ___
>>>>>>> 
> 
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] YYMMDD easy way?

2012-04-24 Thread Rick Nuckolls
That was my thought, but the flavor does not seem to affect it on my version.

-Rick

On Apr 24, 2012, at 5:36 PM, Richard Lewis wrote:

> Or maybe it's my Pick flavor.
> 
> Richard Lewis
> 
> On Tue, Apr 24, 2012 at 6:27 PM, Rick Nuckolls  wrote:
> 
>> Hmmm,
>> 
>> That must be a change at UV 11.  10.2.x still produces 2 digit months and
>> days without the extra 2’s.
>> 
>> -Rick
>> 
>> 
>> On Apr 24, 2012, at 5:21 PM, Richard Lewis wrote:
>> 
>>> On UV 11.1.3 this leaves single-digit months as a single digit.
>>> 
>>> OCONV(TODAY, 'DYMD[2"",2"",2]') does the job correctly.  The brackets
>> allow
>>> format modifiers to the parameters that follow the D conversion code, in
>>> this case, 'YMD'.  The 2's specifiy how many characters to display, and
>> the
>>> empty quotes specify the 'text' with which to separate the elements.
>>> There's about 80 lines that describe it when you do HELP CONV D at TCL.
>>> 
>>> Richard Lewis
>>> 
>>> 
>>> On Tue, Apr 24, 2012 at 6:08 PM, Rick Nuckolls  wrote:
>>> 
>>>> Or, a bit more simply:
>>>> 
>>>> OCONV(TODAY, "D2YMD[‘’ , ’’]”)
>>>> On Apr 24, 2012, at 4:58 PM, Perry Taylor wrote:
>>>> 
>>>>> OCONV(TODAY, 'DYMD[4"",2"",2]')
>>>>> 
>>>>> 
>>>>> - Original Message -
>>>>> From: Lunt, Bruce [mailto:bl...@shaklee.com]
>>>>> Sent: Tuesday, April 24, 2012 07:55 PM
>>>>> To: 'U2 Users List' 
>>>>> Subject: Re: [U2] YYMMDD easy way?
>>>>> 
>>>>> On Unidata try: OCONV(TODAY,'DYMD')
>>>>> 
>>>>> -Original Message-
>>>>> From: u2-users-boun...@listserver.u2ug.org
>>>>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
>>>>> Sent: Tuesday, April 24, 2012 4:52 PM
>>>>> To: u2-users@listserver.u2ug.org
>>>>> Subject: [U2] YYMMDD easy way?
>>>>> 
>>>>> 
>>>>> 
>>>>> YYMMDD = OCONV(TODAY,'DY2'):OCONV(TODAY,'DM'):OCONV(TODAY,'DD')
>>>>> 
>>>>> easier way to do this? ___
>>>>> U2-Users mailing list
>>>>> U2-Users@listserver.u2ug.org
>>>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>>>>> ___
>>>>> U2-Users mailing list
>>>>> U2-Users@listserver.u2ug.org
>>>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>>>>> 
>>>>> CONFIDENTIALITY NOTICE: This e-mail message, including any
>>>>> attachments, is for the sole use of the intended recipient(s)
>>>>> and may contain confidential and privileged information.  Any
>>>>> unauthorized review, use, disclosure or distribution is
>>>>> prohibited. ZirMed, Inc. has strict policies regarding the
>>>>> content of e-mail communications, specifically Protected Health
>>>>> Information, any communications containing such material will
>>>>> be returned to the originating party with such advisement
>>>>> noted. If you are not the intended recipient, please contact
>>>>> the sender by reply e-mail and destroy all copies of the
>>>>> original message.
>>>>> ___
>>>>> U2-Users mailing list
>>>>> U2-Users@listserver.u2ug.org
>>>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>>>> 
>>>> ___
>>>> U2-Users mailing list
>>>> U2-Users@listserver.u2ug.org
>>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>>>> 
>>> ___
>>> U2-Users mailing list
>>> U2-Users@listserver.u2ug.org
>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] YYMMDD easy way?

2012-04-24 Thread Rick Nuckolls
Hmmm,

That must be a change at UV 11.  10.2.x still produces 2 digit months and days 
without the extra 2’s.

-Rick


On Apr 24, 2012, at 5:21 PM, Richard Lewis wrote:

> On UV 11.1.3 this leaves single-digit months as a single digit.
> 
> OCONV(TODAY, 'DYMD[2"",2"",2]') does the job correctly.  The brackets allow
> format modifiers to the parameters that follow the D conversion code, in
> this case, 'YMD'.  The 2's specifiy how many characters to display, and the
> empty quotes specify the 'text' with which to separate the elements.
> There's about 80 lines that describe it when you do HELP CONV D at TCL.
> 
> Richard Lewis
> 
> 
> On Tue, Apr 24, 2012 at 6:08 PM, Rick Nuckolls  wrote:
> 
>> Or, a bit more simply:
>> 
>> OCONV(TODAY, "D2YMD[‘’ , ’’]”)
>> On Apr 24, 2012, at 4:58 PM, Perry Taylor wrote:
>> 
>>> OCONV(TODAY, 'DYMD[4"",2"",2]')
>>> 
>>> 
>>> - Original Message -
>>> From: Lunt, Bruce [mailto:bl...@shaklee.com]
>>> Sent: Tuesday, April 24, 2012 07:55 PM
>>> To: 'U2 Users List' 
>>> Subject: Re: [U2] YYMMDD easy way?
>>> 
>>> On Unidata try: OCONV(TODAY,'DYMD')
>>> 
>>> -Original Message-
>>> From: u2-users-boun...@listserver.u2ug.org
>>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
>>> Sent: Tuesday, April 24, 2012 4:52 PM
>>> To: u2-users@listserver.u2ug.org
>>> Subject: [U2] YYMMDD easy way?
>>> 
>>> 
>>> 
>>> YYMMDD = OCONV(TODAY,'DY2'):OCONV(TODAY,'DM'):OCONV(TODAY,'DD')
>>> 
>>> easier way to do this? ___
>>> U2-Users mailing list
>>> U2-Users@listserver.u2ug.org
>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>>> ___
>>> U2-Users mailing list
>>> U2-Users@listserver.u2ug.org
>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>>> 
>>> CONFIDENTIALITY NOTICE: This e-mail message, including any
>>> attachments, is for the sole use of the intended recipient(s)
>>> and may contain confidential and privileged information.  Any
>>> unauthorized review, use, disclosure or distribution is
>>> prohibited. ZirMed, Inc. has strict policies regarding the
>>> content of e-mail communications, specifically Protected Health
>>> Information, any communications containing such material will
>>> be returned to the originating party with such advisement
>>> noted. If you are not the intended recipient, please contact
>>> the sender by reply e-mail and destroy all copies of the
>>> original message.
>>> ___
>>> U2-Users mailing list
>>> U2-Users@listserver.u2ug.org
>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] YYMMDD easy way?

2012-04-24 Thread Rick Nuckolls
Or, a bit more simply:

OCONV(TODAY, "D2YMD[‘’ , ’’]”)
On Apr 24, 2012, at 4:58 PM, Perry Taylor wrote:

> OCONV(TODAY, 'DYMD[4"",2"",2]')
> 
> 
> - Original Message -
> From: Lunt, Bruce [mailto:bl...@shaklee.com]
> Sent: Tuesday, April 24, 2012 07:55 PM
> To: 'U2 Users List' 
> Subject: Re: [U2] YYMMDD easy way?
> 
> On Unidata try: OCONV(TODAY,'DYMD')
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
> Sent: Tuesday, April 24, 2012 4:52 PM
> To: u2-users@listserver.u2ug.org
> Subject: [U2] YYMMDD easy way?
> 
> 
> 
> YYMMDD = OCONV(TODAY,'DY2'):OCONV(TODAY,'DM'):OCONV(TODAY,'DD')
> 
> easier way to do this? ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> CONFIDENTIALITY NOTICE: This e-mail message, including any 
> attachments, is for the sole use of the intended recipient(s) 
> and may contain confidential and privileged information.  Any
> unauthorized review, use, disclosure or distribution is 
> prohibited. ZirMed, Inc. has strict policies regarding the 
> content of e-mail communications, specifically Protected Health 
> Information, any communications containing such material will 
> be returned to the originating party with such advisement 
> noted. If you are not the intended recipient, please contact 
> the sender by reply e-mail and destroy all copies of the 
> original message.
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] End of Month date routine

2011-12-05 Thread Rick Nuckolls
Just for laughs, the following works with only a single date conversion, though 
I will admit that it gets a little too obscure to be considered maintainable.  
Admittedly, there are probably easier ways to tell how many days there are in a 
month, but they may not be as much fun!

Rick Nuckolls
Lynden Inc


 extdate = oconv( d, 'D4-YMD’)

 year = field(extdate, '-',1)
 month = field( extdate, '-', 2)
 dom = field(extdate,'-',3)

 if month = 2 then
daysinmonth = 28 + ( not(mod(year,4)) & ( mod(year,100) ! 
not(mod(year,400)) ))
 end else
daysinmonth = 30 + mod( if month < 8 then abs(month-2) else 
month-7, 2)
 end

 lastdayofmonth = d - dom + daysinmonth


On Dec 5, 2011, at 2:26 PM, Wjhonson wrote:

> 
> I changed Marco's code slightly using Oconv to make it more clear what DD is 
> doing and make it more generic
> I'm also adding 40 instead of 32 to make it clear that we don't care how much 
> we are adding as long as it's between 32 and 57
> To make it clear what this is doing, we are taking the internal date, and 
> subtracting from that the "day number" on which we are running.
> This will *always* give you the last day of the previous month.  Always.
> Then we add enough to jump us into the next month anywhere, doesn't matter at 
> all.
> And then do the same trick again, which will *always* give you the last day 
> of the month in which you are running
> This is a fantastic bit of magic.
> 
> 
>   TODAY = DATE() ; LAST.MO.END = TODAY - OCONV(TODAY,'DD')
>   A.DAY.NEXT.MO = LAST.MO.END + 40
>   END.OF.MO.DATE = A.DAY.NEXT.MO - OCONV(A.DAY.NEXT.MO,'DD')
> 
> 
> 
> 
> -Original Message-
> From: Wjhonson 
> To: u2-users 
> Sent: Mon, Dec 5, 2011 2:15 pm
> Subject: Re: [U2] End of Month date routine
> 
> 
> 
> arco, this is absolutely brilliant.
> nd I reserve the use of the word "brilliant", for code that truly transcends 
> ormal space-time
> 'm not certain that the use of "DD" is vendor independent, but it could be 
> made 
> o, by merely using OCONV(TODAY, 'DD') instead
> 
> -Original Message-
> rom: Marco Antonio Rojas Castro 
> o: u2-users 
> ent: Mon, Dec 5, 2011 12:49 pm
> ubject: Re: [U2] End of Month date routine
> 
> ODAY = DATE()
> M = TODAY - TODAY"DD" + 32
> M = EOM - EOM"DD"
> 
> To: u2-users@listserver.u2ug.org
> From: wjhon...@aol.com
> Date: Mon, 5 Dec 2011 15:16:02 -0500
> Subject: Re: [U2] End of Month date routine
> 
> 
> Doesn't work on my system Anthony.
> The This month o gives the month and year ok
> but the attempt to iconv that sets it to zero, it doesn't pad the "01" into 
> it 
> something
> so i just get 31 at that point.
> 
> I think you were expecting that it would take "12 2011" and make it into "12 
> 2011" or whatever
> but it's not working
> 
> 
> 
> 
> -Original Message-
> From: George Gallen 
> To: U2 Users List 
> Sent: Mon, Dec 5, 2011 12:10 pm
> Subject: Re: [U2] End of Month date routine
> 
> 
> Haven't checked it, but what happens on 01/31 by adding 31, it should take 
> you 
> arch, backing up
> Will give you 02/xx (28 or 29)?
> George
> -Original Message-
> rom: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] 
>> n Behalf Of Wols Lists
> ent: Monday, December 05, 2011 3:05 PM
> o: u2-users@listserver.u2ug.org
> ubject: Re: [U2] End of Month date routine
> On 05/12/11 19:03, Wjhonson wrote:
> 
> Does someone have a routine that, no matter what day you run it, returns the 
> nd of Month Date ?
> (Assume the end of month date, is the calendar end of month date not some 
> crewy business date)
> Hmmm... no-one seems to have done my approach ...
> TODAY = @DATE
> HIS.MONTH.O = OCONV (TODAY, "DMY") ;* strip day off
> EXT.MONTH.I = ICONV( THIS.MONTH.O, "D") + 31 ;* random day next month
> EXT.MONTH.O = OCONV( NEXT.MONTH.I, "DMY") ;* strip day off
> AST.DAY.I = ICONV( NEXT.MONTH.O, "D") - 1 ;* subract one day
> If you don't have a day in your i/oconv it defaults to 1, so the logic 
> orks. Unfortunately you can't combine the first three lines because 
> here's no number you can pick that will guarantee to land you in next 
> onth whatever today's date :-(
> Cheers,
> ol
> __
> 2-Users mailing list
> 2-us...@listserver.u2ug.org
> ttp://listserver.u2ug.org/mailman/listinfo/u2-us

Re: [U2] End of Month date routine

2011-12-05 Thread Rick Nuckolls
I think that with a slight modification, adding 31 works reasonably well.

Just use the “DYM” conversion consistently through the program:

To be concise, in Universe, for any internal date, “D”, the internal form of 
the last day of the month is:

lastdayofmonth = iconv(oconv(iconv(oconv( D, 'DMY'), 'DMY') +31 ,'DMY'),'DMY') 
-1

“DYM” would work as well.

Rick Nuckolls
Lynden Inc

> 
> Doesn't work on my system Anthony.
> The This month o gives the month and year ok
> but the attempt to iconv that sets it to zero, it doesn't pad the "01" into 
> it or something
> so i just get 31 at that point.
> 
> I think you were expecting that it would take "12 2011" and make it into "12 
> 01 2011" or whatever
> but it's not working
> 
> 
> 
> 
> -Original Message-
> From: George Gallen 
> To: U2 Users List 
> Sent: Mon, Dec 5, 2011 12:10 pm
> Subject: Re: [U2] End of Month date routine
> 
> 
> Haven't checked it, but what happens on 01/31 by adding 31, it should take 
> you 
> arch, backing up
> Will give you 02/xx (28 or 29)?
> George
> -Original Message-
> rom: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] 
> n Behalf Of Wols Lists
> ent: Monday, December 05, 2011 3:05 PM
> o: u2-users@listserver.u2ug.org
> ubject: Re: [U2] End of Month date routine
> On 05/12/11 19:03, Wjhonson wrote:
> 
> Does someone have a routine that, no matter what day you run it, returns the 
> nd of Month Date ?
> (Assume the end of month date, is the calendar end of month date not some 
> crewy business date)
> Hmmm... no-one seems to have done my approach ...
> TODAY = @DATE
> HIS.MONTH.O = OCONV (TODAY, "DMY") ;* strip day off
> EXT.MONTH.I = ICONV( THIS.MONTH.O, "D") + 31 ;* random day next month
> EXT.MONTH.O = OCONV( NEXT.MONTH.I, "DMY") ;* strip day off
> AST.DAY.I = ICONV( NEXT.MONTH.O, "D") - 1 ;* subract one day
> If you don't have a day in your i/oconv it defaults to 1, so the logic 
> orks. Unfortunately you can't combine the first three lines because 
> here's no number you can pick that will guarantee to land you in next 
> onth whatever today's date :-(
> Cheers,
> ol
> __
> 2-Users mailing list
> 2-us...@listserver.u2ug.org
> ttp://listserver.u2ug.org/mailman/listinfo/u2-users
> __
> 2-Users mailing list
> 2-us...@listserver.u2ug.org
> ttp://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Problem reading XML node value in Universe BASIC

2011-10-04 Thread Rick Nuckolls
I do not have the manual with me at the moment, but you need to go down one 
more level. The text is in the text node under "name"

-Rick

On Oct 4, 2011, at 3:09 PM, "Jason Lin"  wrote:

> Hi.
> 
> I tried to use the XDOM API (XML for BASIC API Programmatic
> Interfaces) in Universe Basic for parsing XML file and extracting
> element values but for some reason I got error when calling the  
> XDOMGetNodeValue function.
> 
> 
> Here is an example.
> Suppose I have a simple XML file called "TEST.xml" stored in a type 19
> file (directory) called TEST.FILE:
> 
> LIST.ITEM TEST.FILE TEST.xml 01:25:41pm  04 Oct 2011  PAGE1
> 
>TEST.xml
> 001 
> 002 
> 003 John Smith
> 004 12345
> 005 
> 
> 
> I also created following program which uses XDOM API and a XPath
> string to locate the "name" element node in TEST.xml and extract its
> value.
> 
>> ED TEST.BP TEST.XDOM
> 50 lines long.
> 
> : P999
> 0001: $OPTIONS DEFAULT
> 0002: $INCLUDE UNIVERSE.INCLUDE XML.H
> 0003: !
> 0004:   STATUS = XDOMOpen("TEST.FILE/TEST.xml", XML.FROM.FILE,
> XDOMHandle)
> 0005:   BEGIN CASE
> 0006:  CASE STATUS = XML.SUCCESS
> 0007: CRT "XDOMOpen Success"
> 0008:  CASE STATUS = XML.ERROR
> 0009: CRT "XDOMOpen Error"
> 0010: GOSUB DISPLAY.XML.ERROR ; STOP
> 0011:  CASE STATUS = XML.INVALID.HANDLE
> 0012: CRT "XDOMOpen Invalid Handle"
> 0013: GOSUB DISPLAY.XML.ERROR ; STOP
> 0014:   END CASE
> 0015: !
> 0016:   XPath = '/test/name'
> 0017:   nsMap = ''
> 0018:   STATUS = XDOMLocate(XDOMHandle, XPath, nsMap, nodeHandle)
> 0019:   BEGIN CASE
> 0020:  CASE STATUS = XML.SUCCESS
> 0021: CRT "XDOMLocate Success"
> 0022:  CASE STATUS = XML.ERROR
> 0023: CRT "XDOMLocate Error"
> 0024: GOSUB DISPLAY.XML.ERROR ; STOP
> 0025:  CASE STATUS = XML.INVALID.HANDLE
> 0026: CRT "XDOMLocate Invalid Handle"
> 0027: GOSUB DISPLAY.XML.ERROR ; STOP
> 0028:   END CASE
> 0029: !
> 0030:   STATUS = XDOMGetNodeValue(nodeHandle, nodeValue)
> 0031:   BEGIN CASE
> 0032:  CASE STATUS = XML.SUCCESS
> 0033: CRT "XDOMGetNodeValue Success"
> 0034:  CASE STATUS = XML.ERROR
> 0035: CRT "XDOMGetNodeValue Error"
> 0036: GOSUB DISPLAY.XML.ERROR ; STOP
> 0037:  CASE STATUS = XML.INVALID.HANDLE
> 0038: CRT "XDOMGetNodeValue Invalid Handle"
> 0039: GOSUB DISPLAY.XML.ERROR ; STOP
> 0040:   END CASE
> 0041: !
> 0042:   CRT 'nodeValue = ':nodeValue
> 0043: !
> 0044:   STOP
> 0045: !
> 0046: DISPLAY.XML.ERROR:
> 0047:   STATUS = XMLGetError(errorCode, errorMessage)
> 0048:   CRT "errorCode = ":errorCode
> 0049:   CRT "errorMessage = ":errorMessage
> 0050:   RETURN
> Bottom at line 50.
> : Q
> 
> 
> When I run the program the XDOMGetNodeValue function always
> return an erro code 28.
> 
>> RUN TEST.BP TEST.XDOM
> XDOMOpen Success
> XDOMLocate Success
> XDOMGetNodeValue Error
> errorCode = 28
> errorMessage = No requested data was available.
> 
> 
> I have tested this program on both UniVerse 10.2.7 running on HP-UX
> 11.23 and also UniVerse 10.1.18 on a Windows XP workstation but I got
> the same error code 28 on both platforms.
> 
> It would be greatly appreciated if anyone can point out if I made any
> mistake using the XDOM API or if there is a better way to parse XML
> file using XPath in Universe Basic.
> 
> Thank you.
> Jason
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] easy way to get count of a DIM()?

2011-08-18 Thread Rick Nuckolls
You can redimension an array as long as it is not a common variable.  This 
tends to be a “slow” process, or at least one that you do not want to do each 
time that you add something to the array.

You can use  inmat( X ) to get a vector on the size of the array, as you might 
want to do within a subroutine.

Rick Nuckolls
Lynden Inc


On Aug 18, 2011, at 10:43 AM, Chris Austin wrote:

> 
> Yes,
> 
> That is correct DIM X(25) to initialize X, how do we then get the size of X?
> 
> Thanks,
> 
> Chris
> 
> 
>> From: gglorfi...@vertisinc.com
>> To: u2-users@listserver.u2ug.org
>> Date: Thu, 18 Aug 2011 13:41:17 -0400
>> Subject: Re: [U2] easy way to get count of a DIM()?
>> 
>> First off, I've never seen that syntax before.  Do you mean:
>> 
>> DIM X(25)
>> 
>> or do you mean you are setting X to the 25th value in a dimensioned 
>> variable?  And I don't understand what you mean when you say "some records 
>> get taken out".  How are they taken out?
>> 
>> I'm a little confused by your question.
>> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org 
>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
>> Sent: Thursday, August 18, 2011 1:30 PM
>> To: u2-users@listserver.u2ug.org
>> Subject: [U2] easy way to get count of a DIM()?
>> 
>> 
>> I'm trying to get the count of a dimensioned array DIM() in UniVerse 10.x
>> 
>> Let's say we have a variable that's set to an array:
>> 
>> X = DIM(25)
>> 
>> if I wanted to find out the count of X later on in the program (let's say 
>> some records get taken out and we need the count), how would
>> you do this?
>> 
>> Thanks,
>> 
>> Chris
>> 
>>
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Document Management

2011-07-22 Thread Rick Nuckolls
I would not store blobs directly in a U2 file.  All it would take is one use of 
ED and an inadvertent “file” to corrupt it.  Using a plain WRITE statement to 
put a blob into a type 1 or 19 file may well corrupt it.

An alternative  using U2 is to use the sequential file statements of WRITEBLK 
and READBLK (along with SEEK) to pack multiple blobs into sequential files, and 
then index the searchable attributes and blob location information in a U2 
hashed file.

This will be a far more efficient use of disk space, with faster searches and 
backups, than placing each blob into a separate OS file (either type 1 or 19 
records).

It is always best to put markers in the sequential file so that the index of it 
can be rebuilt if the hash file becomes corrupted.

You could also use zip and unzip with various options to accomplish the same 
thing, just indexing the path to the archive.  This would save additional space 
by compressing the data, but might not have the performance of READBLK with a 
specific address.

Using any method, you need to be cognizant of the size of the resulting 
archives, and the number of archives within a single directory.  If the total 
number of bytes generated per day is reasonable, using a date as part of the 
archive name works nicely.

Rick Nuckolls
Lynden Inc
Seattle

On Jul 22, 2011, at 8:10 AM, Bill Brutzman wrote:

> Does it make any sense to use a U2 database to save scanned pdf's?  That is...
> 
> Does it make any sense to save small blobs in a U2 data base?
> 
> Would a Type 1 file be best?
> 
> Are there any advantages to using MS-SQL, MySQL, or some other database 
> technology?
> 
> --Bill
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] [UV] Marking New Index as Built

2011-05-06 Thread Rick Nuckolls
I tried this at U2 university on 11.1 in December with problems similar to 
those in my earlier message. 

-Rick

On May 6, 2011, at 6:09 AM, "Kurt Neumann"  wrote:

> Hi Perry
> 
> One of the new features in UniVerse 11.1 is the concurrent build of indices.  
> I would suggest being very careful in using it as, to my knowledge, it could 
> have an impact on your performance. From the new features Pdf: BUILD.INDEX 
> filename {attribute [attribute...] | ALL } [CONCURRENT]
> 
> Regards
> Kurt Neumann; U2 Distributor in Africa
> 
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Perry Taylor
> Sent: 06 May 2011 02:55 PM
> To: U2 Users List
> Subject: Re: [U2] [UV] Marking New Index as Built
> 
> In the end I took down the application that updates the indexed field and did 
> a BUILD.INDEX at 1am.  It took approximately one hour to build but 
> unfortunately another process that accesses that file shutdown in error as 
> the BUILD.INDEX had the FX lock on the file.  No harm done but again without 
> a truly online build this will continue to be a messy operation for 7X24 
> shops.  Sure wish Rocket would take this seriously and give us a better tool.
> 
> Perry
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles Stevenson
> Sent: Thursday, May 05, 2011 9:21 PM
> To: U2 Users List
> Subject: Re: [U2] [UV] Marking New Index as Built
> 
> So, Perry,  what did you finally decide to do?
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> CONFIDENTIALITY NOTICE: This e-mail message, including any attachments, is 
> for the sole use of the intended recipient(s) and may contain confidential 
> and privileged information.  Any unauthorized review, use, disclosure or 
> distribution is prohibited. ZirMed, Inc. has strict policies regarding the 
> content of e-mail communications, specifically Protected Health Information, 
> any communications containing such material will be returned to the 
> originating party with such advisement noted. If you are not the intended 
> recipient, please contact the sender by reply e-mail and destroy all copies 
> of the original message.
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> 
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] [UV] Marking New Index as Built

2011-04-28 Thread Rick Nuckolls
I did some investigation of this in the past, and it is a nightmare.

I seem to recall that for a given process to correctly update an index, the 
index had to have been created and enabled at the time that the file was opened 
by that user.  Otherwise, a user that had the file open prior to the 
build.index would not update the newly enabled index.

The implication is that you want to have everyone off of the system while doing 
a BUILD.INDEX.

Alternately, create the index, build it, then rebuild it after the next 
restart.  Building it will cause it to be "enabled", which ensures that all of 
the processes treat it that way at the restart. 

An enabled, partially built index will cause all sorts of anomalous behavior 
unless you specify "NO.INDEX" in all the right places.

I did submit this as a problem, complete with a demo program,  to Rocket a 
while ago.  But I have no reason to believe that it has been fixed.

If you are really willing to work with a partially built index...
Another possible trick, if your index is "NO.NULLS" , and is built on a i-type 
that calls a subroutine, would be to make the return value of the subroutine 
blank during the first build.  This will cause the BUILD.INDEX process to 
functionally skip the list creation for all records and enable the index 
immediately after the select.  Once that is done, recatalog the program with 
the real code, but do not change the calling i-type.  Thereafter, the index 
should be updated, at least for those processes that opened the file after the 
first, null, BUILD.INDEX.  Depending on your OS / hardware configuration, it 
can sometimes be worthwhile to COUNT the file prior to the first BUILD.INDEX; 
causing the caching of most of the file in memory.  (You can test this by 
COUNTing the file twice, and seeing if the second one goes appreciably faster 
than the first.)

Indeed, once you get all of the processes updating the index, you could 
probably write a little program to figure out all of the ids that are indexed, 
MERGE.LIST INTERSECT this against the id's that should be indexed on the file, 
and then

readu the record,
blank out the reference field(s) (saving the correct record)
writeu the record to create an "old version" of the record on file
write the original record, thus updating the index to the current version.


Rick Nuckolls
Lynden Inc.


On Apr 28, 2011, at 10:38 AM, Perry Taylor wrote:

> Hey Chuck.
> 
> The CONCURRENT option is actually there although it's not documented
> (and I suspect not officially supported).  All it really does it not
> lock the file which doesn't happen until the select is completed anyway.
> One would have to make sure no updates were being made to the file until
> the select finishes or the index build may not be complete and accurate
> or may include entries for deleted records.  At this point not taking a
> file lock on the data file seems less useful as the index file is going
> to be cleared prior to population and the population doesn't really take
> all that long in comparison to the select in most cases.  In any event
> seems very messy to me.
> 
> Traditional relational databases have the option to build/rebuild
> indexes while the table is in use.  In the end it seems to me that
> Rocket needs to come up with a completely new strategy for
> building/rebuilding an index.
> 
> Perry
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charles
> Stevenson
> Sent: Thursday, April 28, 2011 10:53 AM
> To: U2 Users List
> Subject: Re: [U2] [UV] Marking New Index as Built
> 
> That should work.
> And then you can write your own update program to back-populate the 
> index w/o having to do a build at all.
> 
> But if your & my connivings are true, then why doesn't RocketSQ give 
> that to us as a concurrent build option?   A few years ago they (as IBM)
> 
> declared that 7x24 uptime was a big goal for U2.
> 
> Warm regards,
> Chuck
> 
> On 4/27/2011 2:24 PM, Perry Taylor wrote:
>> I have a need in UniVerse to add a new index on a large file which has
>> existing indexes.  I don't have a time window in the coming days in
>> which to build the index but need to use the index for new records
> which
>> will be added to the file after the index has been created.   Is there
> a
>> way to force UniVerse to think that the index has been built so that
> it
>> can be used for newer records allowing me to defer the build to a
> later
>> date?
>> 
>> Thanks.
>> Perry Taylor
>> Zirmed, Inc.
>> 
>> 
>> 
>> 
>> CONFIDENTIALITY NOTICE: This e-mail message, including any
>> attachments, is for the sole use of th

Re: [U2] Uodotnet and Connection Pooling Timeouts

2011-03-28 Thread Rick Nuckolls
Jackson,

Off hand, it sounds like all of the sessions are in use and you are timing out 
while waiting for one to be checked back in.  As far as the first exception 
goes, "System.Exception: Non-negative number required", double check to make 
sure that your pool definition defines:

OpenSessionTimeOut=3;* or to some positive number.

What is probably happening is that you run into a situation where all of your 
sessions in the pool are in use, or "opened" and only then is this parameter 
being checked.  The parameter defines how long a process should keep trying to 
grab a pooled session before it throws an exception.

You should have all of your connection pool access within try ... finally 
structures

UniSession session = null;
try {
session = unijava.openSession();
} catch (Exception e) {
...
} finally {
if (session != null) {
unijava.closeSession(session)
}
}


I am also unclear about how many Connection Pooling entitlements you have.  If 
you only have one, but are defining a pool as 10, then you will bump into this 
as soon as you try and open a second concurrent session.  If you have 10 
entitlements, these can be used by different pools/ UniJava instances, but the 
total number of open sessions can be no more than 10, even if each pool is 
defined as 10.

Without CP, you would just be eating away at your regular seats.

-

I see, in your last message, that you have figured out the license part of the 
problem.

Rick Nuckolls
Seattle


On Mar 28, 2011, at 7:20 AM, Jackson Pope wrote:

> Hiya all,
> 
> We're trying to get connection pooling working with uodotnet and currently 
> failing miserably. When we turn connection pooling off everything works as 
> expected, but when we turn it on we often get timeouts or errors with one of 
> the following trace outputs:
> 
> 2011-03-28T15:09:28 System.Exception: Non-negative number required.
> Parameter name: millisecondsTimeout Source: UniObjects Class Method: Boolean 
> ObjWait(Boolean, Int32, System.Object)   at 
> System.Threading.Monitor.ObjWait(Boolean exitContext, Int32 
> millisecondsTimeout, Object obj)
>   at System.Threading.Monitor.Wait(Object obj, Int32 millisecondsTimeout, 
> Boolean exitContext)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniObjects.OpenSession(String hostname, Int32 
> port_number, String userid, String password, String account, String service, 
> Int32 min_poolsize, Int32 max_poolsize)
>   at TP.UNIVERSE.UniversePage.OpenSession()
>   at TP.UNIVERSE.UniversePage.Page_Init(Object sender, EventArgs e)
>   at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, 
> Object t, EventArgs e)
>   at System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, 
> EventArgs e)
>   at System.Web.UI.Control.OnInit(EventArgs e)
>   at System.Web.UI.Page.OnInit(EventArgs e)
>   at System.Web.UI.Control.InitRecursive(Control namingContainer)
>   at System.Web.UI.Page.ProcessRequestMain(Boolean 
> includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
> 
> 2011-03-28T15:09:32 System.Exception: [IBM U2][UODOTNET - 
> UNICLIENT][ErrorCode=81015] The connection has timed out Source: UniObjects 
> Class Method: IBMU2.UODOTNET.UniSession FindSession(Int32)   at 
> IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniPool.FindSession(Int32 pTimeout)
>   at IBMU2.UODOTNET.UniObjects.OpenSession(String hostname, Int32 
> port_number, String userid, String password, String account, String service, 
> Int32 min_poolsize, Int32 max_poolsize)
>   at TP.UNIVERSE.UniversePage.OpenSession()
>   at TP.UNIVERSE.UniversePage.Page_Init(Object sender, EventArgs e)
>   at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, 
> Object t, EventArgs e)
>   at System.Web.Util.CalliEventHandlerDelegateProxy.Callback(O

Re: [U2] how to round to 2 decimals?

2010-10-14 Thread Rick Nuckolls
Universe does not have a DROUND() function that I can find.  However, at some 
point a FIX() function was included in the language.

:ED BP FIX 
5 lines long.

: P
0001: ABC = 123.45678
0002: PRINT FIX(ABC,2)
0003: PRINT FIX(ABC, 2, 0)
0004: PRINT FIX(ABC, 2, 1)
0005: END
Bottom at line 5.
: Q
:RUN BP FIX
123.46
123.46
123.45

Rick Nuckolls
Lynden Inc

On Oct 14, 2010, at 9:37 AM, Larry Hiscock wrote:

> No idea if it's been implemented in UV ... it appears not, from your error
> message.  It works in UD 
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
> Sent: Thursday, October 14, 2010 9:35 AM
> To: u2-users@listserver.u2ug.org
> Subject: Re: [U2] how to round to 2 decimals?
> 
> 
> Are you sure DROUND() is a UniVerse function?
> 
> When I do the following code:
> 
> X = 2596 * 8.333
> *
> PRINT DROUND(X,2)
> 
> I get the following error:
> 
> "Array 'DROUND' never dimensioned."
> 
> 
>> From: lar...@wcs-corp.com
>> To: u2-users@listserver.u2ug.org
>> Date: Thu, 14 Oct 2010 09:25:23 -0700
>> Subject: Re: [U2] how to round to 2 decimals?
>> 
>> What's so difficult about ANS = DROUND(N1 * N2, 2) ?
>> 
>> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org
>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of John Woollam
>> Sent: Thursday, October 14, 2010 8:59 AM
>> To: U2 Users List
>> Subject: Re: [U2] how to round to 2 decimals?
>> 
>> Hi
>> 
>> Never heard of the DROUND() function in Universe.
>> 
>> Anyway, why would I want to use a function syntax when I can do
>> 
>> ANS = N1 * N2 'R2' and it is the answer that gets rounded?
>> Easy to write.
>> Easy to read...
>> 
>> John Woollam  |  Group Function Support 1  (Finance Systems)  |  Travis
>> Perkins PLC  |  01604 682751
>> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org
>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Larry Hiscock
>> Sent: 14 October 2010 16:49
>> To: 'U2 Users List'
>> Subject: Re: [U2] how to round to 2 decimals?
>> 
>> Does UniVerse not support the DROUND() function?  
>> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org
>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of John Woollam
>> Sent: Thursday, October 14, 2010 1:02 AM
>> To: U2 Users List
>> Subject: Re: [U2] how to round to 2 decimals?
>> 
>> Hi
>> 
>> I've always used 'R2'
>> 
>> e.g. ANS = N1 * N2 'R2'
>> 
>> No scaling, just rounding
>> 
>> Regards
>> 
>> John Woollam  |  Group Function Support 1  (Finance Systems)  |  Travis
>> Perkins PLC  |  01604 682751
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org
>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Chris Austin
>> Sent: 13 October 2010 22:22
>> To: u2-users@listserver.u2ug.org
>> Subject: [U2] how to round to 2 decimals?
>> 
>> 
>> I'm trying to figure out how to round to 2 decimal places with a
>> floating point in UniVerse
>> 
>> For example 2596 x 8.333 = 21,632.468
>> 
>> How would you round that in UniVerse to 21,632.47?
>> 
>> Thanks!
>>
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
>> 
>> 
>> 
>> 
>> 
>> > style="FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'">This e-mail and
>> any 
>> attachments are confidential and intended solely for the use of the
>> addressee 
>> only. If you have received this message in error, you must not copy,
>> distribute 
>> or disclose the contents; please notify the sender immediately and
>> delete
>> the 
>> message. 
>> > style="FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'">This message is 
>> attributed to the sender and may not necessarily reflect the view of
>> Travis 
>> Perkins plc or its subsidiaries (Travis Perkins). Agreements binding
>> Travis 
>> Perkins may not be concluded by means of e-mail communication.
>> 
>> > style="FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'">E-mail
>> transmissions
>> 

Re: [U2] Stumped with TRANS...

2010-10-11 Thread Rick Nuckolls
I do not think that there is a way to test the result of a TRANS to discover if 
the read succeeded or was not found.  So, that would leave the slightly flawed 
options of a) calling a subroutine or b) using the itype below (though it does 
have a problem with a record id of "", or a value in F1 of 'not found').  What 
did you want to happen if the record is not on file?

I doubt that you would, in practice, find much penalty for doing the TRANS 
twice on the same record.

Example for a dictionary:

TRANS(transfile, @ID,@ID,'X'); IF @ = '' THEN 'not found' ELSE TRANS( 
transfile, @ID, F1,'X')

For Basic:

VALUE = TRANS("TRANSFILE", id, 1, "X")
IF VALUE = "" THEN
IF  TRANS("TRANSFILE", id, 0, "X") = "" THEN
VALUE = "not found"
END
END

But ultimately, either one is flawed if the key is blank.
Is there some reason why you do not want to open the file to named common?

COMMON /MYSUB/ MYTIME, MYFILE
IF (MYTIME # @TIME ) THEN
*  new program execution
OPEN '','TRANSFILE' TO MYFILE ELSE 
MYTIME = @TIME
END

(Just as I am about to send this, I see a similar suggestion from Mark 
Eastwood.)

Rick Nuckolls
Lynden Inc


On Oct 11, 2010, at 11:41 AM, George Gallen wrote:

> yes, there are times, when the entire record is empty. The ID exists meaning 
> it's valid, but there has been no data associated with it yet.
> 
> It was acceptable that 
> 
> 1. the record could be empty (but the @ID exist)
>   essentially, this is the same as <1> being ""
> 2. the record could contain <1> and not be the same as @ID
> 3. the record could contain <1> and be the same as @ID 
> 4. the record not exist (then a whole other set of checks come into play)
> 
> It's just coincedence the <1> and @ID would be the same value, however
>   they are not the same field, so it's not that I'm duplicating the @ID
>   into <1>.
> 
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-
>> boun...@listserver.u2ug.org] On Behalf Of Kebbon Irwin
>> Sent: Monday, October 11, 2010 1:58 PM
>> To: u2-users@listserver.u2ug.org
>> Subject: Re: [U2] Stumped with TRANS...
>> 
>> 
>> I don't mean to belabor this point, but unless your *entire* record is
>> empty, doing the the trans with a full record requrest -
>> TRANS('FNAME',@ID ,-1,'X') - you should only have a null returned if
>> the record does not exist.  I use Unidata; is Universe any different?
>> You can do something like a DCOUNT to ensure that if <1> is emplty,
>> there are other attributes in the record
>> 
>> Last post, I promise.
>> 
>> Cheers,
>> 
>> Kebbon
>> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UniVerse Global Cataloging

2010-10-08 Thread Rick Nuckolls
Bill,

Normally, during an upgrade of Universe, the catalog space is preserved, with 
updates for the Universe provided subroutines.
You did not specify which platform, but it would be critical that you do any 
copy using the underlying OS command rather than a UV COPY, which could corrupt 
the records.

Of course, if you copy everything from the old catdir to the new one, you will 
overwrite the new versions of BASIC programs that were cataloged during 
installation.

Universe updates the header of each cataloged routine each time it is called.  
If a user does not have rights to update the catalog space, calls will fail.  
(How stupid is this!)

The catalog space is normally a "type 1" file.  It would probably function as 
type 19, but certainly not as a hashed file.  As a type 1 file, the catdir 
directory must contain a hidden file ".Type1", that is only visible from the OS 
level.

Rick Nuckolls
Lynden Inc

On Oct 8, 2010, at 10:32 AM, Bill Brutzman wrote:

> I am in the process of upgrading UV here.
> 
> Following a noble suggestion from Rocket tech support, when I tried to copy 
> my cataloged files from my UV 10.1 to 10.3.6, my apps would not launch.  I 
> think the folder is /usr/ibm/catdir.  We are using HP-Ux 11 v2.
> 
> Because we have tons of subs, globally re*Cataloging hundreds of files and 
> then having to validate apps are two big hurdles we face whenever we upgrade 
> UV.
> 
> While I wrote a little batch script to auto-catalog is helpful, we have a 
> ways to go before we are fully OSGI compliant.
> 
> Insights on global cataloging works would be appreciated.  Perhaps catalog 
> migration works on another operating system.
> 
> --Bill
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] [UV] Shared Record Locks

2010-09-01 Thread Rick Nuckolls
READL can be useful when there is a need to maintain a consistent view of 
master-detail or a set of records related in a tree structure.  Putting a READL 
lock on the master or root record will guarantee a consistent tree during the 
reading of the detail or nodes, assuming that a READU is taken on the root 
prior to updating any detail record within the tree.

Rick Nuckolls
Lynden Inc

On Sep 1, 2010, at 5:20 AM, Tom Whitmore wrote:

> Thanks Mecki!
> That is what I was trying to relay.
> 
> The only conceivable reason that I can think of for READL is if you have a 
> process where you want to be able to have more than one person pull up a 
> record, so they could "discuss it", and not have the data change between the 
> two reads.  In real life, I think there are a lot of ways to handle this 
> situation without using READL.
> 
> Tom
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org 
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Mecki Foerthmann
> Sent: Wednesday, September 01, 2010 3:28 AM
> To: U2 Users List
> Subject: Re: [U2] [UV] Shared Record Locks
> 
> Hi Stuart,
> 
> you are talking about READU not READL.
> Of course it is dangerous to allow a user to read a record without
> locking it if that user can then write that record back.
> But READL will not allow any user to WRITE, not even the holder of the
> lock unless all locks have been released.
> OTOH it is contrary to your statement quite useful not to lock
> "everything" during a process when no update will occur.
> Why lock the customer master record for instance if it is only read to
> display the name and address on a screen?
> And even your example with the exchange rate doesn't really make sense.
> If you want to make sure the exchange rate doesn't change then you read
> it once and assign the value to a variable.
> Especially on large systems locking the exchange rate record of a
> popular currency every time somebody reads it can cause serious problems.
> And no, I don't think this would be a good application for READL, since
> you only can update the exchange rate once all locks have been released.
> Imagine you have 1000 or more users and the poor person trying to update
> exchange rates has to wait until everybody who uses a process that uses
> this rate to release their locks.
> 
> Mecki
> 
> 
> 
> 
> On 01/09/2010 07:25, Boydell, Stuart wrote:
>> Hi Tom,
>> READL is useful. Normatively, DBMS theory says you should lock *everything* 
>> during a process to guarantee that other processes aren't making changes to 
>> the db underneath your process. In practice, I've seen a lot of code which 
>> doesn't do this. Most of these systems must simply get away with it through 
>> sheer dumb luck.
>> 
>> Looking at the standard read mechanism; Consider two sessions (pid 101 & 
>> 102) running on a U2 database both READ a customer record, X at the same 
>> time (without locking). Both processes update a comments field; both 
>> processes write X back to file.
>> (101 reads X, 102 reads X, 101 changes X, 102 changes X, 101 writes X, 102 
>> writes X.)
>> 
>> In the scenario above the comments added by 101 are lost because 102 
>> overwrites the changes made by 101. 
>> 
>> This is an obvious problem with concurrent use of a DB. To fix this you use 
>> pessimistic locking and an update lock, READU. This will ensure that if 101 
>> and 102 both try to READU the record, the second process will fail 
>> (hopefully gracefully).
>> 
>> All good. Now what if the user also needs to read (and not update) a shared 
>> parameter item? For example, a spot currency conversion rate.
>> 
>> Consider if your process (101) reads, without locking, a rate, while another 
>> (102) updates it; you do some processing with the old rate, writes some 
>> files, calls a subroutine that re-reads the rate that has just been written 
>> by 102 and then does some calculations and writes to some more files - the 
>> db could now be inconsistent with figures calculated against both the old 
>> and new rate.
>> (101 reads rate, 102 reads rate, 102 changes rate, 102 writes rate, 101 
>> calculates partly based on old rate and new rate).
>> 
>> If you (101) were to use READU it would stop other processes from updating 
>> the rate while you were doing your calculation but also any other processes 
>> which needed to just read the rate record (because they would also be using 
>> READU). That could get annoying for users! This is where READL is useful, as 
>> it allows a shared lock to be set - ensuring that the recor

Re: [U2] as.java.unirpc.UniRPCException

2010-05-06 Thread Rick Nuckolls
Oops,

I keep mixing up the platforms :-)

Find the tomcat directory with the following in it

apache-tomcat-5.5.20/
LICENSE RUNNING.txt confshared  work
NOTICE  bin logstemp
RELEASE-NOTES   common  server  webapps

There is a chance that you will need to repackage the zip file as a jar with a 
MANIFEST ifle to get tomcat to see it

jar xf asjava.zip
jar cf asjava.jar asjava

Place the jar's in the shared\lib of the tomcat directory

-Rick



On May 6, 2010, at 10:32 AM, Rick Nuckolls wrote:

> On tomcat, that should be:
>
> $CATALINA_HOME / shared/ lib
>
> where $CATALINA_HOME is probably C:\tomcat
>
> -Rick
>
>
>
> On May 6, 2010, at 10:17 AM, Shawn Hayes wrote:
>
>> I placed asjava.jar and unijdbc.jar in
>>
>> C:\Program Files\pentaho\server\enterprise-console\lib
>>
>> and then I tried
>>
>> C:\Program Files\pentaho\server\enterprise-console\jdbc
>>
>> No luck (so far:)
>> 'We act as though comfort and luxury were the chief requirements of life, 
>> when all that we need to make us happy is something to be enthusiastic 
>> about.'
>>
>>
>>
>> - Original Message 
>> From: Bob Little 
>> To: U2 Users List 
>> Sent: Thu, May 6, 2010 11:51:52 AM
>> Subject: Re: [U2] as.java.unirpc.UniRPCException
>>
>> I believe you'd put the jar files either in $CATALINA_HOME/lib or in
>> your web app's WEB-INF/lib/ directory.
>>
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org
>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Robert Houben
>> Sent: Thursday, May 06, 2010 12:42 PM
>> To: U2 Users List
>> Subject: Re: [U2] as.java.unirpc.UniRPCException
>>
>> I don't remember the details off the top of my head, but there is a
>> place to "tell" Tomcat of jars you want it to include.
>>
>> -Original Message-
>> From: u2-users-boun...@listserver.u2ug.org
>> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Shawn Hayes
>> Sent: Thursday, May 06, 2010 9:40 AM
>> To: U2 Users List
>> Subject: Re: [U2] as.java.unirpc.UniRPCException
>>
>> Kettle is an ETL Application and is now a part of the Pentaho BI Suite
>> (Very cool application:)
>>
>> I deployed this "out-of-the-box" in a standalone mode.
>>
>> It uses Tomcat as the application server.
>>
>> I have already confirmed that Unirpcd service is started.
>>
>> I have the correct IP Address for the Host Name.
>>
>> I have used port # 31438 (I took the default when generating the error
>> to show you all).
>>
>> I will look into seeing if asjava.jar needs to be in a specific
>> directory
>> within the app or app server.  Or if I can just place it in the
>> CLASSPATH.
>>
>> I SO appriciate you helping out
>>
>> Here is the error again with the port # and host name
>>
>> Error connecting to database [Test] :
>> org.pentaho.di.core.exception.KettleDatabaseException:
>> Error occured while trying to connect to the database
>> Error connecting to database: (using class
>> com.ibm.u2.jdbc.UniJDBCDriver)
>> asjava/unirpc/UniRPCException
>>
>> org.pentaho.di.core.exception.KettleDatabaseException:
>> Error occured while trying to connect to the database
>> Error connecting to database: (using class
>> com.ibm.u2.jdbc.UniJDBCDriver)
>> asjava/unirpc/UniRPCException
>>
>> at
>> org.pentaho.di.core.database.Database.normalConnect(Database.java:312)
>> at org.pentaho.di.core.database.Database.connect(Database.java:261)
>> at org.pentaho.di.core.database.Database.connect(Database.java:223)
>> at org.pentaho.di.core.database.Database.connect(Database.java:213)
>> at
>> org.pentaho.di.core.database.DatabaseFactory.getConnectionTestReport(Dat
>> abaseFactory.java:55)
>> at
>> org.pentaho.di.core.database.DatabaseMeta.testConnection(DatabaseMeta.ja
>> va:2409)
>> at
>> org.pentaho.ui.database.event.DataHandler.testDatabaseConnection(DataHan
>> dler.java:487)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
>> a:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
>> Impl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:585)
>> at
>> org.pentaho.ui.xul.impl.AbstractXulDomContainer.invoke(AbstractXulDomCon
>> tainer.

Re: [U2] as.java.unirpc.UniRPCException

2010-05-06 Thread Rick Nuckolls
gt; eDialog.java:161)
> at
> org.pentaho.di.ui.spoon.delegates.SpoonDBDelegate.editConnection(SpoonDB
> Delegate.java:79)
> at org.pentaho.di.ui.spoon.Spoon.doubleClickedInTree(Spoon.java:2317)
> at org.pentaho.di.ui.spoon.Spoon.access$1600(Spoon.java:242)
> at
> org.pentaho.di.ui.spoon.Spoon$25.widgetDefaultSelected(Spoon.java:4061)
> at org.eclipse.swt.widgets.TypedListener.handleEvent(Unknown Source)
> at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)
> at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
> at org.eclipse.swt.widgets.Display.runDeferredEvents(Unknown Source)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Unknown Source)
> at org.pentaho.di.ui.spoon.Spoon.readAndDispatch(Spoon.java:945)
> at org.pentaho.di.ui.spoon.Spoon.start(Spoon.java:5574)
> at org.pentaho.di.ui.spoon.Spoon.main(Spoon.java:412)
> Caused by: org.pentaho.di.core.exception.KettleDatabaseException:
> Error connecting to database: (using class
> com.ibm.u2.jdbc.UniJDBCDriver)
> asjava/unirpc/UniRPCException
> at
> org.pentaho.di.core.database.Database.connectUsingClass(Database.java:43
> 9)
> at
> org.pentaho.di.core.database.Database.normalConnect(Database.java:296)
> ... 36 more
> Caused by: java.lang.NoClassDefFoundError: asjava/unirpc/UniRPCException
> at
> com.ibm.u2.jdbc.UniJDBCConnectionImpl.(UniJDBCConnectionImpl.java:
> 137)
> at com.ibm.u2.jdbc.UniJDBCDriver.connect(UniJDBCDriver.java:111)
> at java.sql.DriverManager.getConnection(DriverManager.java:525)
> at java.sql.DriverManager.getConnection(DriverManager.java:171)
> at
> org.pentaho.di.core.database.Database.connectUsingClass(Database.java:41
> 6)
> ... 37 more
> Hostname  : 192.168.1.21
> Port  : 31438
> Database name  : SHAWN
>
>
>
> 'We act as though comfort and luxury were the chief requirements of
> life, when all that we need to make us happy is something to be
> enthusiastic about.'
>
>
>
> - Original Message 
> From: Rick Nuckolls 
> To: U2 Users List 
> Sent: Thu, May 6, 2010 10:59:55 AM
> Subject: Re: [U2] as.java.unirpc.UniRPCException
>
> Looks like your classpath is fine.  It found all the classes that it
> needs.  The problem appears to be that you are failing to connect to the
> database.
>
> There could be a number of reasons for that, including:
>
> The unirpcd service is not started on the machine hosting your data base
> &
> The connection string being used to contact it is wrong.
>
> I have not done this with uv (ud?) running on windows, so I do not know
> how to ensure that the unirpc is running on that; but on Unix, you can
> look for it with "ps -ef |grep unirpcd".
>
> the unijdbc stuff uses the asjava classes to access u2 via the unirpcd
> daemon.
>
> But -- if the port that you are connecting on is really "-1" or the
> hostname is "xx" (as opposed to something edited on your part), then
> you also have not successfully specified the uri of the database to the
> jdbc driver.  On Unix, the default port is 31438.
>
> -Rick
>
>
> The jdbc stuff needs a configuration file for
> On May 6, 2010, at 8:36 AM, Shawn Hayes wrote:
>
>> How do you know you're missing that class?  In the first paragraph of
> the error, it says
>> "Error connecting to database: (using class
> com.ibm.u2.jdbc.UniJDBCDriver)
>> asjava/unirpc/UniRPCException"
>>
>> Are you seeing an error in a log file somewhere?  Here is the whole
> error
>> "Error connecting to database [Test] :
> org.pentaho.di.core.exception.KettleDatabaseException:
>> Error occured while trying to connect to the database
>> Error connecting to database: (using class
> com.ibm.u2.jdbc.UniJDBCDriver)
>> asjava/unirpc/UniRPCException
>>
>> org.pentaho.di.core.exception.KettleDatabaseException:
>> Error occured while trying to connect to the database
>> Error connecting to database: (using class
> com.ibm.u2.jdbc.UniJDBCDriver)
>> asjava/unirpc/UniRPCException
>>
>> at
> org.pentaho.di.core.database.Database.normalConnect(Database.java:312)
>> at org.pentaho.di.core.database.Database.connect(Database.java:261)
>> at org.pentaho.di.core.database.Database.connect(Database.java:223)
>> at org.pentaho.di.core.database.Database.connect(Database.java:213)
>> at
> org.pentaho.di.core.database.DatabaseFactory.getConnectionTestReport(Dat
> abaseFactory.java:55)
>> at
> org.pentaho.di.core.database.DatabaseMeta.testConnection(DatabaseMeta.ja
> va:2409)
>> at
> org.pentaho.ui.database.event.DataHandler.testDatabaseConnection(DataHan
> dler.java:487)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ

Re: [U2] as.java.unirpc.UniRPCException

2010-05-06 Thread Rick Nuckolls
e.Database.connectUsingClass(Database.java:439)
> at org.pentaho.di.core.database.Database.normalConnect(Database.java:296)
> ... 36 more
> Caused by: java.lang.NoClassDefFoundError: asjava/unirpc/UniRPCException
> at 
> com.ibm.u2.jdbc.UniJDBCConnectionImpl.(UniJDBCConnectionImpl.java:137)
> at com.ibm.u2.jdbc.UniJDBCDriver.connect(UniJDBCDriver.java:111)
> at java.sql.DriverManager.getConnection(DriverManager.java:525)
> at java.sql.DriverManager.getConnection(DriverManager.java:171)
> at org.pentaho.di.core.database.Database.connectUsingClass(Database.java:416)
> ... 37 more
> Hostname   : xx
> Port   : -1
> Database name  : SHAWN"
> 'We act as though comfort and luxury were the chief requirements of life, 
> when all that we need to make us happy is something to be enthusiastic about.'
> 
> 
> 
> - Original Message 
> From: Ben Souther 
> To: U2 Users List 
> Sent: Thu, May 6, 2010 10:15:08 AM
> Subject: Re: [U2] as.java.unirpc.UniRPCException
> 
> Maybe we should back up.
> 
> How do you know you're missing that class?
> Are you seeing an error in a log file somewhere?
> 
> 
> 
> 
> On Thu, 2010-05-06 at 08:11 -0700, Shawn Hayes wrote:
>> I was just about to ask that (I am new to Java).  So, I looked in the 
>> asjava.jar file and found
>> "UniRPCException.class" and "UniRPC.class".  He told me that I needed the 
>> driver...
>> 
>> "as.java.unirpc.UniRPCException"
>> 
>> Should this be "asjava.UniRPCException.class" instead or does the 
>> UniRPC.class inherit UniRPCException (I hope I asked that right:).
>> 
>> Thanks!!
>> 'We act as though comfort and luxury were the chief requirements of life, 
>> when all that we need to make us happy is something to be enthusiastic 
>> about.'
>> 
>> 
>> 
>> - Original Message 
>> From: Rick Nuckolls 
>> To: U2 Users List 
>> Sent: Thu, May 6, 2010 10:01:27 AM
>> Subject: Re: [U2] as.java.unirpc.UniRPCException
>> 
>> That class name should really not have a period between "as" and "java".
>> 
>> -Rick
>> 
>> 
>> On May 6, 2010, at 7:44 AM, Shawn Hayes wrote:
>> 
>>> I am trying to connect to a Universe Database to an application called 
>>> "Kettle".  First of all, has anyone done this?  Second, I have had problems 
>>> connecting.  I have been searching their boards looking for solutions and 
>>> reaching out to the community.  I got a response that said...
>>> 
>>> "Looks like you're simply missing a driver library. One that would contain 
>>> the as.java.unirpc.UniRPCException class"
>>> 
>>> I have set the 2 files (unijdbc.jar and asjava.jar) that are needed for 
>>> JDBC connection to a Universe Database. I have placed them in my Classpath 
>>> as
>>> 
>>> C:\IBM\UniDK\jdbc\lib\unijdbc.jar;C:\IBM\UniDK\uojsdk\lib\asjava.zip;%CLASSPATH%
>>> 
>>> I looked through these and can't find "as.java.unirpc.UniRPCException"  Can 
>>> someone help with this?  Thank - Shawn
>>> 'We act as though comfort and luxury were the chief requirements of life, 
>>> when all that we need to make us happy is something to be enthusiastic 
>>> about.'
>>> ___
>>> U2-Users mailing list
>>> U2-Users@listserver.u2ug.org
>>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
>> 
> --
> Ben Souther
> Manager, Web and Web Service Development
> bsout...@fwdco.com | 508.927.8147
> FWDavison & Company, Inc.
> 10 Cordage Park Circle, Suite 200
> Plymouth, MA 02360-7318
> 
> CONFIDENTIALITY NOTICE:  This e-mail message, and any accompanying
> documents, is for the sole use of the intended recipient(s) and may
> contain confidential and privileged information. Any unauthorized
> review, use, disclosure, distribution or copying is prohibited. If you
> are not the intended recipient, please contact our office by e-mail or
> by telephone at (508) 747-7261 and immediately destroy all copies of the
> original message.
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] as.java.unirpc.UniRPCException

2010-05-06 Thread Rick Nuckolls
That class name should really not have a period between "as" and "java".

-Rick


On May 6, 2010, at 7:44 AM, Shawn Hayes wrote:

> I am trying to connect to a Universe Database to an application called 
> "Kettle".  First of all, has anyone done this?  Second, I have had problems 
> connecting.  I have been searching their boards looking for solutions and 
> reaching out to the community.  I got a response that said...
> 
> "Looks like you're simply missing a driver library. One that would contain 
> the as.java.unirpc.UniRPCException class"
> 
> I have set the 2 files (unijdbc.jar and asjava.jar) that are needed for JDBC 
> connection to a Universe Database. I have placed them in my Classpath as 
> 
> C:\IBM\UniDK\jdbc\lib\unijdbc.jar;C:\IBM\UniDK\uojsdk\lib\asjava.zip;%CLASSPATH%
>  
> 
> I looked through these and can't find "as.java.unirpc.UniRPCException"  Can 
> someone help with this?  Thank - Shawn
>  'We act as though comfort and luxury were the chief requirements of life, 
> when all that we need to make us happy is something to be enthusiastic 
> about.' 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Terminal Emulator and Telnet Client for a MacBook Pro

2010-03-17 Thread Rick Nuckolls
Apple does ship a vt100 telnet client with their os.  It is in the  
utilities folder and is called "Terminal".

-Rick

On Mar 17, 2010, at 2:57 PM, "Symeon Breen"  wrote:

> I recommend you buy a pc and use that instead
>
>
>
> Sorry - i just don't like apple .
>
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Dave Taylor
> Sent: 17 March 2010 21:33
> To: u2-users@listserver.u2ug.org
> Subject: [U2] Terminal Emulator and Telnet Client for a MacBook Pro
>
> Does anyone have a recommendation for a terminal emulator and telnet  
> client
> for a MacBook Pro or any MAC OS X operating system that will connect  
> to
> Universe/Unidata?
>
> Thanks,
>
> Dave Taylor
> Sysmark Information Systems, Inc.
> 49 Aspen Way
> Rolling Hills Estates, CA 90274
> (O) 800-SYSMARK (800-797-6275)
> (F) 310-377-3550
> (C) 310-561-5200
> www.sysmarkinfo.com
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] [UV] table of mv-handling functions

2010-02-01 Thread Rick Nuckolls
I should have said "sysdesc.pdf".


On Feb 1, 2010, at 9:50 AM, Charles Stevenson wrote:

> There is (used to be?) a very nice table of all the multivalue-handling 
> functions, lining them up with their single-value equIvalents.  It 
> looks/looked something like:
> 
> MV-handler function  Single-valued equivalent
> ---  
> CATS( X, Y ) ( X : Y )
> GTS( X,Y )   ( X GT Y )
> IFS( X, Y, X )   ( IF X THEN Y ELSE Z )
> OCONVS( X, Y )   OCONV( X, Y )
> 
> ...and so on...
> 
> I think it had a nice description of the overarching common syntax & 
> functionality, including how REUSE() works.
> 
> I can't find said chart.  I need it for some newbies.  This may be going 
> all the way back to PI, not universe.  I don't see it in UV10.3 docs. 
> Can anyone tell me where it is?
> The brain addles,
> cds
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] [UV] table of mv-handling functions

2010-02-01 Thread Rick Nuckolls
sysdef.pdf §5-37,38  (10.2)



On Feb 1, 2010, at 9:50 AM, Charles Stevenson wrote:

> There is (used to be?) a very nice table of all the multivalue-handling 
> functions, lining them up with their single-value equIvalents.  It 
> looks/looked something like:
> 
> MV-handler function  Single-valued equivalent
> ---  
> CATS( X, Y ) ( X : Y )
> GTS( X,Y )   ( X GT Y )
> IFS( X, Y, X )   ( IF X THEN Y ELSE Z )
> OCONVS( X, Y )   OCONV( X, Y )
> 
> ...and so on...
> 
> I think it had a nice description of the overarching common syntax & 
> functionality, including how REUSE() works.
> 
> I can't find said chart.  I need it for some newbies.  This may be going 
> all the way back to PI, not universe.  I don't see it in UV10.3 docs. 
> Can anyone tell me where it is?
> The brain addles,
> cds
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] ITYPE BASIC use?

2010-01-10 Thread Rick Nuckolls
You are, of course, correct.  If your itype does not reference the id field of 
the record, then I do not necessary to assign @id.

My bias towards always assigning it comes from experience writing utilities, 
where no such assumptions may be made, rather then writing code dependent on 
the individual's knowledge of each DICT item.

One other note:  you may some day encounter an itype that alters @id or @record 
during execution, so it is best to set them before each call, not counting on 
them to be static between multiple DICT item evaluations.

-Rick

On Jan 10, 2010, at 8:31 AM, Anthony W. Youngman wrote:

> In message , Rick 
> Nuckolls  writes
>> I doubt that I will be the only one to reply, but
>> 
>> The variables "@id" and "@record" must be set prior to the call, as in:
>> 
> Note that both of these are *optional* *if* they aren't used.
> 
> But it's extremely unlikely you won't use at least one of them. I don't 
> think I've ever bothered with @id, just so happens that's the way the 
> i-types I've used have panned out.
> 
> Cheers,
> Wol
> -- 
> Anthony W. Youngman 
> 'Yings, yow graley yin! Suz ae rikt dheu,' said the blue man, taking the
> thimble. 'What *is* he?' said Magrat. 'They're gnomes,' said Nanny. The man
> lowered the thimble. 'Pictsies!' Carpe Jugulum, Terry Pratchett 1998
> Visit the MaVerick web-site - <http://www.maverick-dbms.org> Open Source Pick
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] ITYPE BASIC use?

2010-01-08 Thread Rick Nuckolls

Oops,

left one "KEY" in the code.

-Rick

> I doubt that I will be the only one to reply, but
> 
> The variables "@id" and "@record" must be set prior to the call, as in:
> 
>> 14   loop
>   readnext @id else
>   exit
>   end
>> 16  
>   read @record from CONF,@id then
> 
>> 18 print KEY:' has CustNO': ITYPE(DICT.ITYPE)
>> 19 print "stop? "
>> 20 input ANS,1
>> 21 if upcase(ANS) = 'Y' then stop
>> 22  end
>> 23   repeat
> 
> 
> On Jan 8, 2010, at 11:12 AM, Karl Pearson wrote:
> 
>> 
>> I have a client who would like to use the uniVerse ITYPE function but
>> the HELP (HELP BASIC ITYPE) documentation is wrong.
>> 
>> For example, here's a sample piece of code, which duplicates the HELP
>> code sample:
>> 
>> 6   DONE = 0
>> 7
>> 8   open "DICT","CONF" to D.CONF else stopm "No DICT CONF file"
>> 9   read DICT.ITYPE from D.CONF,"F01" else DICT.ITYPE = 'Not Found'
>> 10
>> 11   open "CONF" to CONF else stopm "No DICT CONF file"
>> 12   select CONF
>> 13
>> 14   loop
>> 15  readnext KEY else DONE = 1
>> 16   until DONE do
>> 17  read REC from CONF,KEY then
>> 18 print KEY:' has CustNO': ITYPE(DICT.ITYPE)
>> 19 print "stop? "
>> 20 input ANS,1
>> 21 if upcase(ANS) = 'Y' then stop
>> 22  end
>> 23   repeat
>> 24end
>> 
>> Executing this code results in this error:
>> 
>> "Line 18, ITYPE called with bad data item"
>> 
>> Any thoughts?
>> 
>> TIA,
>> 
>> ---
>> Karl Pearson
>> ka...@ourldsfamily.com
>> Owner/Administrator of the sites at
>> http://ourldsfamily.com
>> ---
>> "To mess up your Linux PC, you have to really work at it;
>> to mess up a microsoft PC you just have to work on it."
>> ---
>> Democracy is two wolves and a lamb voting on what to have
>> for lunch. Liberty is a well-armed lamb contesting the vote.
>> --Benjamin Franklin
>> ---
>> Prayer for Obama, et al: http://scriptures.lds.org/en/ps/109/8#8 (~)
>> ---
>> 
>> ___
>> U2-Users mailing list
>> U2-Users@listserver.u2ug.org
>> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] ITYPE BASIC use?

2010-01-08 Thread Rick Nuckolls
I doubt that I will be the only one to reply, but

The variables "@id" and "@record" must be set prior to the call, as in:

> 14   loop
   readnext @id else
exit
end
> 16  
read @record from CONF,KEY then

> 18 print KEY:' has CustNO': ITYPE(DICT.ITYPE)
> 19 print "stop? "
> 20 input ANS,1
> 21 if upcase(ANS) = 'Y' then stop
> 22  end
> 23   repeat


On Jan 8, 2010, at 11:12 AM, Karl Pearson wrote:

> 
> I have a client who would like to use the uniVerse ITYPE function but
> the HELP (HELP BASIC ITYPE) documentation is wrong.
> 
> For example, here's a sample piece of code, which duplicates the HELP
> code sample:
> 
> 6   DONE = 0
> 7
> 8   open "DICT","CONF" to D.CONF else stopm "No DICT CONF file"
> 9   read DICT.ITYPE from D.CONF,"F01" else DICT.ITYPE = 'Not Found'
> 10
> 11   open "CONF" to CONF else stopm "No DICT CONF file"
> 12   select CONF
> 13
> 14   loop
> 15  readnext KEY else DONE = 1
> 16   until DONE do
> 17  read REC from CONF,KEY then
> 18 print KEY:' has CustNO': ITYPE(DICT.ITYPE)
> 19 print "stop? "
> 20 input ANS,1
> 21 if upcase(ANS) = 'Y' then stop
> 22  end
> 23   repeat
> 24end
> 
> Executing this code results in this error:
> 
> "Line 18, ITYPE called with bad data item"
> 
> Any thoughts?
> 
> TIA,
> 
> ---
> Karl Pearson
> ka...@ourldsfamily.com
> Owner/Administrator of the sites at
> http://ourldsfamily.com
> ---
> "To mess up your Linux PC, you have to really work at it;
> to mess up a microsoft PC you just have to work on it."
> ---
> Democracy is two wolves and a lamb voting on what to have
> for lunch. Liberty is a well-armed lamb contesting the vote.
> --Benjamin Franklin
> ---
> Prayer for Obama, et al: http://scriptures.lds.org/en/ps/109/8#8 (~)
> ---
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] [Fwd: Re: Auto logout time {Unclassified}]

2009-12-07 Thread Rick Nuckolls
The "UV.LOGIN"  (paragraph) entry in the main 'uv' installation account's VOC 
file is executed by all logins.
You will probably need to create it.


On Dec 7, 2009, at 4:17 PM, HENDERSON MIKE, MR wrote:

> Bill,
> 
> "UOLOGIN" would be a *lovely* enhancement to UV!
> But unless it's in 10.3, or is an undocumented feature in 10.2, it would
> indeed be an enhancement. :-(
> 
> Wally, Rocket anyone, care to comment?
> 
> 
> Regards
> 
> 
> Mike
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Bill Haskett
> Sent: Tuesday, 8 December 2009 12:21 p.m.
> To: U2 Mail List
> Subject: [U2] [Fwd: Re: Auto logout time {Unclassified}]
> 
>  Mike:
> 
> In UD, UniObjects doesn't hit the LOGIN paragraph (verb) but it does hit
> 
> the "UOLOGIN" globally cataloged item.  One can control a lot from this 
> program.  I'm guessing UV has the same thing.
> 
> Bill
> 
> The information contained in this Internet Email message is intended
> for the addressee only and may contain privileged information, but not
> necessarily the official views or opinions of the New Zealand Defence Force.
> If you are not the intended recipient you must not use, disclose, copy or 
> distribute this message or the information in it.
> 
> If you have received this message in error, please Email or telephone
> the sender immediately.
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Mapping files.

2009-11-30 Thread Rick Nuckolls
(Speaking from a Universe perspective, but I think the issues are the same.)

If you are updating a file on one server, and reading it on another, you will 
probably encounter structural inconsistencies within groups if you do not use 
U2 NFA.  This is due to the fact that groups could be in the process of being 
modified at the same time that they are being read by the second server.

If you are using dynamically hashed files, then information about the modulo 
and load is stored in the file header, which is cached in memory and updated to 
disk when the file is closed. The changes in the modulus that occur during 
update will not be reflected in the header cached on the "read only" machine.  
There is also a possibility that the "read only" machine could overwrite the 
header of the file with out of date information.  If this occurs, then the file 
will be physically corrupt, with some records being unreachable.

-Rick Nuckolls
Lynden, Inc
Seattle, WA

On Nov 30, 2009, at 10:55 AM, Paul Parkinson wrote:

> Thanks for the advice. 
> 
> I am only accessing the data on server A for reading. The only updates that
> take place are on server A.
> 
> Kind Regards
> Paul Parkinson
> Director, Ideal Business Services Ltd
> mob: +1 758 721 4487 (Caribbean)
> skype: 0161 408 2098
> eml: pparkin...@idealnet.co.uk 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wally Terhune
> Sent: 30 November 2009 14:32
> To: U2 Users List
> Subject: Re: [U2] Mapping files.
> 
> I wanted to underscore what one other poster mentioned...
> 
> If you are actively running UniData on two different servers, the only safe
> way to access a UniData file on the 'other' server is via NFA. The reason
> for this is that all file access controls (group locks and record locks) are
> maintained in local shared memory (Windows memory mapped files). You can
> likely make Windows shares work, but you risk corrupting your data files
> with concurrent access from two different servers. A udt process on Server A
> does not have any knowledge of a udt process on Server B accessing the same
> file on Server A (or vice versa).
> 
> Take care...
> 
> Wally Terhune
> U2 Support Architect
> Rocket Software
> 4700 S. Syracuse Street, Suite 400 **Denver, CO 80237 **USA
> Tel: +1.720.475.8055
> Email: wterh...@rs.com
> Web: www.rocketsoftware.com/u2
> 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Paul Parkinson
> Sent: Monday, November 30, 2009 10:13 AM
> To: 'U2 Users List'
> Subject: Re: [U2] Mapping files.
> 
> Thanks for your help people. I enquired about the licence for NFA and at 2
> grand per server I think I'll work around it somehow.  I hate being ripped
> off
> 
> Kind Regards
> Paul Parkinson
> Director, Ideal Business Services Ltd
> mob: +1 758 721 4487 (Caribbean)
> skype: 0161 408 2098
> eml: pparkin...@idealnet.co.uk 
> 
> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Colin Alfke
> Sent: 30 November 2009 12:30
> To: 'U2 Users List'
> Subject: Re: [U2] Mapping files.
> 
> This works for me:
> 
> 001: F   
> 002: \\SERVERNAME\UNIDATA\Datadir\FileName
> 003: \\SERVERNAME\UNIDATA\DictDir\D_FileName
> 
> Both are ud 7.1.6 one on XP and one on win 2003 (remote) and the D:\unidata
> dir is shared as unidata. Of course, if it's a DIR file you need to update
> <1>.
> 
> Hth
> Colin Alfke
> Calgary, Canada
> 
> -Original Message-
> From: Paul Parkinson
> 
> I have 2 servers both running Unidata 7.1 on Windows 2003.  In an
> application on server "A" I want to access data held in an application on
> server "B"
> 
> I have tried the voc entry in the application on serverA
> 
> 001: F
> 002: \\serverB\unidata\filename  
> 003: \\serverB\unidata\D_filename  
> 
> I have also tried replacing "serverB" in the above with the IP address
> But I get the error "open file error no such file."
> Anyone know what I should be doing?
> 
> Paul Parkinson
> 
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
> 
> 
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] "WR" Group Lock

2009-07-27 Thread Rick Nuckolls
A group address of zero indicates that a process failed during an operation on 
the header.  Is there a chance that you are accessing this file with 
UniObjects?  There was a bug in early releases of UV 10 that could cause this 
when a UO process closed down.

Rick Nuckolls
Lynden Inc

From: u2-users-boun...@listserver.u2ug.org 
[u2-users-boun...@listserver.u2ug.org] On Behalf Of Brian Leach 
[br...@brianleach.co.uk]
Sent: Monday, July 27, 2009 1:29 AM
To: 'U2 Users List'
Subject: Re: [U2] "WR" Group Lock

David

Martin is right. Sorry. He usually is.

A WR lock is a transient lock, it is held only during the time a process is
attempting to write to / restructure a group. For whatever reason, a process
(possibly the previous write) has crashed or the write has entered a loop
(screwed pointers) or hit a semaphore/memory issue when trying to extend.
Whichever, there is a good chance that file is now stuffed. Fortunately
these things are very, very rare. Unfortunately, you've been hit. As for the
cause: often it is something outside of UniVerse, hardware/bus error or some
external process affecting the file.

Since you're unlikely to reproduce the same circumstances, the only real
options are to monitor, watch and check your backups. And hope it doesn't
happen again..

Bad luck.

BTW if it's a small file with a single item, why is it dynamic? That's
pointless overhead.

Brian

> -Original Message-
> From: u2-users-boun...@listserver.u2ug.org
> [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of
> Norman, David (Health)
> Sent: 27 July 2009 06:18
> To: 'u2-users@listserver.u2ug.org'
> Subject: [U2] "WR" Group Lock
>
> In what situations can a WR lock be held on a group and not
> released ? (UV10.0.16 HP-UX 11i) We've had this situation in
> one of our test (fortunately) accounts and can't explain it.
> All users got stuck waiting for the group lock to be released
> - we couldn't even LIST or COUNT the file.
>
> Active Group Locks:Record
> Group Group Group
> Device Inode  Netnode Userno  Lmode G-Address.  Locks
> ...RD ...SH ...EX
> 1073807361 900210 31   7 IN  1  5
> 0 0 0
> 1073807361 104830 73  19 IN800  2
> 0 0 0
> 1073807361 529850 73  24 WR  0  0
> 0 0 0
>
> I would also have thought that there would have been a number
> in the Group EX column.
> We had to log out the user with a kill -9 and unlock their
> locks as a kill -15 had no effect.
> The file in question is dynamic, with a modulus of 1 and only
> had 1 record in it (mildly overflowed).
> I have read Martin Phillips' explanation of group locks, and
> favour his technical suggestion that in this situation "your
> system is stuffed".
> The notes for the Internals course don't help either.
>
> Any comments would be appreciated !
> 
> David Norman
> Senior Software Engineer - SA Ambulance Service
>
> ICT Services
> SA Health
> Government of South Australia
>
> Box 3, GPO
> Adelaide, South Australia 5001
> *+61 8 8274 0384
> * fax +61 8 8271 4844
> *
> norman.da...@saambulance.com.au<mailto:norman.da...@saambulanc
> e.com.au>
>
>
> This e-mail may contain confidential information, which also
> may be legally privileged. Only the intended recipient(s) may
> access, use, distribute or copy this e-mail. If this e-mail
> is received in error, please inform the sender by return
> e-mail and delete the original. If there are doubts about the
> validity of this message, please contact the sender by
> telephone. It is the recipient's responsibility to check the
> e-mail and any attached files for viruses.
>
>
>
> ___
> U2-Users mailing list
> U2-Users@listserver.u2ug.org
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


RE: [U2] UV 10.1.22; Dynamic File question

2009-04-23 Thread Rick Nuckolls
There isn't that much that is secret about the algorithm:

Mod:next_group

1:1, 2:1, 3:1 4:2, 5:1 6:2 7:3 8:4, 9:1 ...16:8, 17:1 ... 32:16, 33:1

Theoretically, it could be a variation on that, but that is the basic idea of 
linear hashing -- Whenever the modulus reaches a new power of two, the next 
group to split will be the first group, then #2, 3, 4 etc.

Rick Nuckolls
Lynden Inc.



-Original Message-
From: owner-u2-us...@listserver.u2ug.org 
[mailto:owner-u2-us...@listserver.u2ug.org] On Behalf Of Scott Ballinger
Sent: Thursday, April 23, 2009 12:14 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] UV 10.1.22; Dynamic File question

My understanding is the when a dynamic file's *total* size exceeds the
SPLIT.LOAD threshold, a group (almost certainly not the group you are
writing to or just wrote to) will be split. The group(s) chosen to be split
are controlled by some secret algorithm, but I don't believe that the
largest groups are the ones first chosen to be split. This can be verified
by doing a GROUP.STAT on a dynamic file (with poorly hashing keys) and
noting that there are many empty groups as well as many overflowing groups.
Dynamic files perform well on the total file (*average* group size) level,
but still suffer from the same problems as static hashed files regarding
poorly hashing keys when you get down to individual groups within the file.
If this is not how the splitting process in dynamic files actually works, I
would appreciate being enlightened.

/Scott Ballinger
Pareto Corporation
Edmonds WA USA
206 713 6006

On Thu, Apr 23, 2009 at 11:47 AM, Martin Phillips <
martinphill...@ladybridge.com> wrote:

> Hi Allen,
>
>  If I know in advance that I'm adding a large number of records
>> to a file, is there any way to force the file to "grow" in advance?
>>
>
> You could do this with the MINIMUM.MODULUS parameter but the whole point of
> dynamic files is that they do their own tuning. Although a dynamic file is
> unlikely to be as good as a perfectly tuned static file, it will be a lot
> better than a typical static file that has been left alone for a long while.
>
> Another important point is that a split affects only one (or arguably two)
> groups unlike resizing a static file from modulo N to modulo N+1 which would
> affect every group.
>
> My real point here is that it is usually best to let a dynamic file look
> after itself.
>
>
> Martin Phillips
> Ladybridge Systems Ltd
> 17b Coldstream Lane, Hardingstone, Northampton, NN4 6DB
> +44-(0)1604-709200 ---
>
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] UniObjects for Java on Ubuntu anyone?

2009-02-16 Thread Rick Nuckolls
There is rather a significant "oversight" in UOJ: it fails to specify  
the encoding when it translates bytes to Java characters, and vice  
versa.


Beware too, of the 32 file limit in UOJ.   There are a number of  
solutions to this problem, but you should probably start by creating  
your own interfaces to access UOJ. Our "Session" object caches files,  
and has methods for read, write, etc. eg. String s =  
session.read(filename, key).


The opening of the file is implicit in the method.

-Rick

On Feb 16, 2009, at 9:14 AM, "Jeff Powell"  wrote:


That did it.

Thanks.

On Fri, 2009-02-13 at 16:42 -0800, Richard Nuckolls wrote:


I have not used Ubuntu, but try optioning Java with "-
Dfile.encoding=iso8859-1"
If you are using tomcat, this would go in the CATALINA_OPTS  
environment

variable. (setenv.sh)

-Rick




On Feb 13, 2009, at 2:34 PM, Jeff Powell wrote:


The LANG variable issue takes a new twist with Ubuntu Server 8.10.
Neither LANG=C (IBM recommended) or LANG=en_US.iso885915 (must use  
for

RedHat) will work. The value marks are wrongly used as field marks.
And
in case you're  wondering no, LANG=en_US.UTF-8 also does not work.

Has anyone made UniObjects for java work on Ubuntu?

Thanks.

Jeff
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] UV/NET questions/confirmation

2008-08-20 Thread Rick Nuckolls
Curt,

Only the file server (remote) needs to be licensed for UV/NET. The
client just needs uv.  If you have two machines that want to access each
other, then both need UN/NET licenses.

If your local box is accessing a remote UV box via UV/NET, you need
enough UV/NET licenses to support the number of users on the local
machine who might be logged in and accessing the remote box.  Only one
connection will be made for each user.  I am not sure how IBM is
licensing this now; they may just give you unlimited remote connections
when you buy UVNET for a machine.  They do that for the Enterprise
licenses.

If a local user opens a connection to a remote machine, he will hold
that connection open for a configurable amount of time (1 hr of idle
time), or until he logs out.  If your applications open files to common,
you may need to reconfigure the timeout to a large number to avoid users
attempting to access a file that has been closed with the connection.

UVNET has been a very reliable product for us; but we also use it over
some very fast wire.  If you intend to run over a slow network, you
should consider what the transmission time will do to your processes.
For instance, if an application were to open 25 remote files, you will
have injected considerable delay into it if it is accessing a those
files over a slow UVNET link.  All of the operations using UVNET are
essentially blocking, so an application is going to pause momentarily
between remote reads and writes.  This is only an issue if you have a
slow connection.

-Rick Nuckolls
Lynden Inc.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Curt Stewart
Sent: Wednesday, August 20, 2008 8:30 AM
To: [EMAIL PROTECTED]
Subject: [U2] UV/NET questions/confirmation

First off let me apologize for my last post. I realized it was unsigned
the moment I released the button after clicking on Send.

I've just reviewed the Uv/Net documentation and would just like to get
confirmation on my understanding of what I read.

For UV/NET to work, both systems need to be running Universe and UV/NET.
Do both have to have the same user licenses? What is the minimum license
count needed for the remote server, given the local server is licensed
for 34 users?

The documentation states that the Unix version must be installed and
authorized, but the Windows version is installed and licensed. Does this
mean that the Windows version does not need to be authorized and can be
used right out of the box?

Thanks for all the help and insight.
Curt Stewart
Tri-sys Consulting
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] [BB] Internal functions in Basic

2006-12-22 Thread Rick Nuckolls
Using LOCAL to label a LOCAL subroutine seems a bit unnecessary in U2, since
the names of subroutines are ignored by the run environment, which only
looks at the name used for cataloging the routine.

Regardless, if I interpret this correctly, I think that requiring variables
in LOCAL subroutines be declared as PRIVATE in order to be locally scoped is
a mistake.  Local scoping within a subroutine ought to be the default.

Likewise, any labels outside of a LOCAL subroutine ought to be out of scope
of the subroutine itself.  So the syntax of "gosub name(a, b)" for calling a
local subroutine is confusing, since "name" may be another local subroutine
within the file, but "gosub" ought to be confined to labels within a given
program, function, or subroutine. (imho).  I prefer "call" for calling local
subroutines.

But if variables are local (to a local subroutine) by default, then there
needs to be some manner of declaring variables, inserts, and commons as
global to the file.  My (admittedly Fortran or C like ) proposal for this
was to declare them before the first PROGRAM, SUBROUTINE, or FUNCTION
statement within a file, and I certainly see the possibility for some
ambiguity in doing this; it just seemed like an easy way to avoid the
PRIVATE and PUBLIC modifiers in a time tested manner.  

The problem that develops is when there is code preceding a subroutine
declaration:  Should that be considered the (no argument) subroutine by the
run machine, or should it be considered as part of a global declaration?  A
possible solution would be to define a "global" block as in the following
example, where the actual cataloged subroutine would be MYSUB, but the
GLOBAL code would be executed before the the code under MYSUB was invoked. 
The first declared subroutine would be the entry point, unless there was
"undeclared" code before the subroutine (for compatibility).

I would just as soon not have to go back and add PUBLIC to all the insert
files we have.

GLOBAL
   $INCLUDE BLAH
   DEFFUN MYSUBSUB( ARG ) CALLING MYSUBSUB
   COMMON /BLAT/ BLAT1
   VAR1 = 10
END

SUBROUTINE MYSUB( ARG1, ARG2 )
  ARG1 = BLAT1 + MYSUBSUB(ARG2)
END

SUBROUTINE MYSUBSUB( ARG1, ARG2)
  ARG1 = ARG2 + VAR1
END

The bottom line, of course, is that IBM is going to come up with their own
solution, if at all, and they have only the slightest inclination  to match
QM's syntax or listen to any individual customer.

btw, Although I have not read much of the QM documentation,but I have been
wanting some sort of CLASS definition in Basic for about 20 years (And I am
not exaggerating).




Martin Phillips wrote:
> 
>> I'd really appreciate a way to write an internal function which
>> can have parameters and can contain it's own local variables
>> (although global variables would be OK).
> 
> This is an excellent idea. We did it for the QM multivalue database
> product 
> a year or so back and it is very useful. Hopefully, if IBM decide to take
> up 
> this suggestion, they will use our implementation as the de facto 
> specification of the user interface rather than "reinvent the wheel".
> 
> We have
>LOCAL SUBROUTINE name(arg1, arg2, ...)
>   PRIVATE var, var2(10,5)
>   ... do something...
>END
> entered using
>GOSUB name(X,Y)
> 
> and
> 
>LOCAL FUNCTION name(arg1, arg2, ...)
>   PRIVATE var, var2(10,5)
>   ... do something...
>   RETURN value
>END
> declared with
>DEFFUN name(a,b) LOCAL
> and used in exactly the same way as external functions.
> 
> The private variables are truly stacked to allow recursive calls each with 
> their own variables. We even allow variable length argument lists.
> 
> You never know, if IBM take up this one, they may then look at our object 
> oriented programming extensions which are incredibly useful (see the next 
> issue of Spectrum Magazine for the first of two articles on this topic).
> 
> 
> Martin Phillips
> Ladybridge Systems Ltd
> 17b Coldstream Lane, Hardingstone, Northampton, NN4 6DB
> +44-(0)1604-709200 
> ---
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/-BB--Internal-functions-in-Basic-tf2837863.html#a8027883
Sent from the U2 - Users mailing list archive at Nabble.com.
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] [BB] Internal functions in Basic

2006-12-20 Thread Rick Nuckolls
One way to accomplish this would be to allow multiple subroutine blocks
within a single source file.  The code (in one file) of:

SUBROUTINE ONE( ARG1, ARG2)
  MYVAR = 1
  CALL TWO(ARG2, ARG1)  ;*  reverse them
END
SUBROUTINE TWO(ARG1, ARG2)
 PRINT MYVAR ; * UNDEFINED!! out of scope
 PRINT ARG1, ARG2
END

 would print the two arguments in reverse order since the "CALL TWO(ARG2,
ARG1)" reverses them from TWO'S point of view.
In the above case, the "catalogged" subroutine would have two arguments and
would start executing the first subroutine, returning at the first "END"
statement.

If code or a PROGRAM statement preceded the first SUBROUTINE or FUNCTION,
then the variables in that block would scope to the rest of the file unless
declared in a subroutine argument.

PROGRAM X  ;* optional line
   COMMON /MYCOM/ AA,BB,CC
   FOO = 9
   CALL ONE( 1 , 2 )
   CALL TWO(1)
END
SUBROUTINE ONE( ARG1, FOO)
   PRINT ARG1, FOO ;* prints "1   2" in this example
   PRINT AA,BB,CC ;*  defined from above common
   DELTA = AA-BB ;*  invisible to other blocks
END
SUBROUTINE TWO( ARG1)
   PRINT ARG1, FOO ;* prints "1   9" in this example
END

Note that if "SUBROUTINE X" was substituted for "PROGRAM X", no variables or
common from "X" would be within the scope of ONE or TWO.

And yes, each internal subroutine or function should get a new set of stack
variables each time it is invoked, even if it is a recursive invocation, so
the following example would print out the factorial of 20 (I hope!).

PROGRAM FACT20
   DEFFUN FACT(N) CALLING "FACT"
PRINT FACT( 20)
END
FUNCTION FACT(  N)
 IF (N > 1 ) THEN
RETURN N * FACT(N-1)
 END ELSE
RETURN N
 END
END



Womack, Adrian wrote:
> 
> I'd really appreciate a way to write an internal function which can have
> parameters and can contain it's own local variables (although global
> variables would be OK). Often it's just not worth the effort to write a
> full blown external function that's only called a few times by one
> program.
> 
> Perhaps these could be defined after the final "END" statement in the
> program.
> 
> Something like:
> 
> .
> .
> ANS = MYFUNCT(12, 34)
> CRT MYFUNCT(56, 78)
>   END
> 
> DEFFUN MYFUNCT(I, J) {
>FUNCT.VAR = I * J
>RETURN (FUNCT.VAR)
> }
> 
> 
> 
> 
> 
> 
> DISCLAIMER:
> Disclaimer.  This e-mail is private and confidential. If you are not the
> intended recipient, please advise us by return e-mail immediately, and
> delete
> the e-mail and any attachments without using or disclosing the contents in
> any
> way. The views expressed in this e-mail are those of the author, and do
> not
> represent those of this company unless this is clearly indicated. You
> should
> scan this e-mail and any attachments for viruses. This company accepts no
> liability for any direct or indirect damage or loss resulting from the use
> of
> any attachments to this e-mail.
> ---
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/-BB--Internal-functions-in-Basic-tf2837863.html#a7934450
Sent from the U2 - Users mailing list archive at Nabble.com.
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/