Thankyou Ed!

We did not know you could call a program from a S-type dictionary!  How
long has it been there?

We went through months of work to be able to use I-types to be able to call
subroutines, and to get accurate arithmetic.

Test shows arithmetic has been fixed.  We talked to U2 people about it at a
U2U, and were told UV doe integer arithmetic, and we had to live with it.
 Many (20+) years ago 1.9 + 1.9 gave 2, then it was fixed so we took the
work-arounds out, then it went bad again.  Do you know when it was fixed
again?

We do still need I-types to bring back multi-values from a Translate.
 Perhaps this will be attended to as well some day.

We do not like I-types, as we cannot use dict fields beyond 10 for out data
entry parameters, and inadvertently printing the dict item kills the
session.  Maybe one day we can get rid of them again.

Cheers, Kate

Kate Stanton
Walstan Systems Ltd
4 Kelmarna Ave, Herne Bay, Auckland 1011, New Zealand
Phone: + 64 9 360 5310  Mobile: + 64 21 400 486
Email: k...@walstan.com


On 31 January 2014 10:34, Ed Clark <u...@edclark.net> wrote:

> Curious why you are doing this as a user exit?
> iirc, there are differences between using an A and an Itype. In an itype,
> the subroutine is called just once for each item in the file. With an
> A-type, the subroutine is going to be called once for each value/subvalue
> in the attribute referenced by the amc on line 2 of the dictionary entry
> (which in this case is 0 so there will only be once value, but be careful
> using it on other attributes in the item)
>
> The subroutine needs to be cataloged with a "$" prefix, $RNS.CB.MAS.SUB
> rather than just RNS.CB.MAS.SUB, and I think it needs to be cataloged
> globally.
> >From the universe manual:
>
> Cataloging User Exits
> Once you have written and compiled the UniVerse BASIC subroutine, you must
> catalog the program. User exits are cataloged globally by specifying the
> user exit
> name with a dollar sign in front of it. For example, to catalog the user
> exit U50MB
> in the example shown earlier, use the CATALOG command as follows:
> >CATALOG
>         CATALOG NAME or LOCAL = $50MB
>         FILENAME = APP.PROGS
>         PROGRAM NAME = 50MB
> Or you can use the form:
> >CATALOG APP.PROGS $50MB
> Like any other program, a user exit must be compiled before you can
> catalog it. See
> Chapter 8, " UniVerse BASIC," for more information about cataloging
> UniVerse
> BASIC programs.
>
> Cataloging Programs in PICK Accounts
> PICK and IN2 flavor accounts do not permit global cataloging; therefore
> you must
> either catalog the program in a different flavor account or create an
> INFORMATION
> flavor CATALOG entry in your PICK account. To create an INFORMATION flavor
> CATALOG entry, create a VOC entry which is the same as the entry for
> CATALOG,
> except that field 6 is defined as INFORMATION.FORMAT instead of
> PICK.FORMAT.
>
> On Jan 30, 2014, at 3:07 PM, randyleesmith <randyleesm...@roadrunner.com>
> wrote:
>
> > I'm not use to making these.
> >
> > I based what I was doing on another A type which also called a
> Subroutine.
> >
> > My A Type record;
> >
> > SB.SVC>ED DICT ADFILA RNS.CB.MAS
> >
> > 10 lines long.
> >
> > ----:
> > 0001: A
> > ----:
> > 0002: 0
> > ----:
> > 0003: Reason Not To Be Sent
> > ----:
> > 0004: M
> > ----:
> > 0005:
> > ----:
> > 0006:
> > ----:
> > 0007:
> > ----:
> > 0008: URNS.CB.MAS.SUB
> > ----:
> > 0009: L
> > ----:
> > 0010: 20
> > Bottom at line 10.
> >
> > I cataloged the process RNS.CB.MAS.SUB
> >
> > But get this error;
> >
> > "$RNS.CB.MAS.SUB" is not in the CATALOG space.
> > [ENOENT] No such file or directory
> > Incorrect VOC entry for $RNS.CB.MAS.SUB.
> > Unable to load subroutine.
> >
> > Not seen this before. Any ideas?
> >
> > I know I can just make an I type, and I have done those before.
> > I thought this might be less work in making and porting over to
> production.
> >
> >
> >
> >
> > -----
> > I used to be an Optimist until I knocked over the glass.
> > --
> > View this message in context:
> http://u2-universe-unidata.1073795.n5.nabble.com/A-Descriptors-and-its-Subroutine-Issue-tp42599.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

Reply via email to