That's just it, George, there is no saved list. It's just an active list 0.
On Mon, Sep 24, 2012 at 12:05 PM, George R Smith < geo...@grsmith.arcoxmail.com> wrote: > Have you given any consideration on reading the list from the pointer file > ? > George > > -----Original Message----- From: Kevin King Sent: Monday, September 24, > 2012 1:01 PM To: U2 Users List Subject: Re: [U2] Unidata 7.1.16 Multiple > Active Select Lists > Bob, this is exactly what I'm attempting, to save the current 0 list and > restore it. David, checking the list before the FORM.LIST appears to have > solved the problem. Thank you. > > Has this kind of thing always been this onerous? I recall doing it much > more easily - on Unidata - but it's been years. > > On Mon, Sep 24, 2012 at 11:57 AM, Woodward, Bob > <bob_woodw...@k2sports.com>**wrote: > > Seems like the simple solution would be in your subroutine, before you >> need to generate your select, test the SYSTEM variable to see if an >> active select is already in use. If it is, do a READLIST into a >> variable. Then at the end of your subroutine, if anything is in your >> variable, do a UNIBASIC SELECT to reestablish the active select list. >> You might just always check for an active list at the beginning of your >> subroutine as a normal setup function then as a exit routine, restore >> the active list. >> >> Just a thought. >> >> -----Original Message----- >> From: >> u2-users-bounces@listserver.**u2ug.org<u2-users-boun...@listserver.u2ug.org> >> [mailto:u2-users-bounces@**listserver.u2ug.org<u2-users-boun...@listserver.u2ug.org>] >> On Behalf Of Kevin King >> Sent: Monday, September 24, 2012 10:43 AM >> To: U2 Users List >> Subject: Re: [U2] Unidata 7.1.16 Multiple Active Select Lists >> >> Well, that success was short lived. While the READLIST and FORMLIST >> allow my SUBR(..) field to not consume the active select list zero, >> these two commands produce different results: >> >> LIST ORDER.LINE WITH fieldName fieldName >> >> ...this will show the lines that have this field set, and will show the >> field properly. However, this command returns no items: >> >> SELECT ORDER.LINE WITH fieldName >> >> Basically my program is doing this: >> >> READLIST ACTIVE.LIST FROM 0 ELSE NULL >> * >> CMD = "select ... TO 2" >> EXECUTE CMD CAPTURING OUTPUT >> * >> EOF = @FALSE >> LOOP >> READNEXT ID FROM 2 ELSE EOF = @TRUE >> UNTIL EOF DO >> .. >> REPEAT >> * >> CLEARSELECT 2 >> * >> FORMLIST ACTIVE.LIST TO 0 >> >> All other input/ideas appreciated. >> >> On Mon, Sep 24, 2012 at 11:26 AM, Kevin King <ke...@precisonline.com> >> wrote: >> >> > And we have a winner! Thank you everyone! The READLIST and FORMLIST >> > will work; seems kinda kludgy, but hey, it's working. >> > >> > >> > On Mon, Sep 24, 2012 at 11:21 AM, David A. Green >> > <dgr...@dagconsulting.com >> > > wrote: >> > >> >> If you already have an active list then you'll have to save it, then >> >> restore it. See READLIST and FORMLIST. >> >> >> >> David A. Green >> >> (480) 813-1725 >> >> DAG Consulting >> >> >> >> -----Original Message----- >> >> From: >> >> u2-users-bounces@listserver.**u2ug.org<u2-users-boun...@listserver.u2ug.org> >> >> [mailto:u2-users-bounces@**listserver.u2ug.org<u2-users-boun...@listserver.u2ug.org>] >> On Behalf Of Kevin King >> >> Sent: Monday, September 24, 2012 10:11 AM >> >> To: U2 Users List >> >> Subject: Re: [U2] Unidata 7.1.16 Multiple Active Select Lists >> >> >> >> It's all fine if the program controls both lists, but in this case >> >> the >> >> SUBR(..) type field could be accessed in just about any context, from >> >> >> TCL, from a download, from MITS, from another BASIC routine, with or >> >> without a select list... >> >> >> >> The RTNLIST doesn't solve the problem of my "select" command >> >> consuming the active list 0. It seems that the PASSLIST extension to >> >> >> EXECUTE is designed specifically for this purpose, but it produces >> >> nothing but compilation >> >> errors: >> >> >> >> CMD = "select ..." >> >> EXECUTE CMD CAPTURING OUTPUT RTNLIST 2 PASSLIST 2 >> >> >> >> ...produces a compilation error about the "misuse" of RTNLIST, >> >> despite the documentation saying this should be possible. >> >> >> >> The point is that I want to leave select list 0 entirely alone, which >> >> >> is why I'm using $BASICTYPE "U". BASICTYPE "P" - standard on these >> >> SB+ systems - does not allow one to READNEXT from anything but list >> >> 0, and I want to leave list zero untouched. >> >> >> >> Gotta be a way, right? >> >> >> >> -K >> >> >> >> On Mon, Sep 24, 2012 at 10:56 AM, Martin Braid <mbr...@epicor.com> >> wrote: >> >> >> >> > Hi Kevin, Any reason why you are using type "U" ? This >> certainly >> >> > works using "P" ... >> >> > >> >> > S='SELECT SOMEFILE WITH SOMETHING = "OOJIT"' >> >> > EXECUTE S RTNLIST MYLIST CAPTURING ANYOUTPUT >> >> > EOF=0 >> >> > LOOP UNTIL EOF DO >> >> > READNEXT MYID FROM MYLIST THEN >> >> > GSOUB MYMESS >> >> > END ELSE EOF=1 >> >> > REPEAT >> >> > >> >> > Martin >> >> > >> >> > >> >> > -----Original Message----- >> >> > From: >> >> > u2-users-bounces@listserver.**u2ug.org<u2-users-boun...@listserver.u2ug.org> >> >> > [mailto:u2-users-bounces@**listserver.u2ug.org<u2-users-boun...@listserver.u2ug.org>] >> On Behalf Of Baker >> >> > Hughes >> >> > Sent: 24 September 2012 17:49 >> >> > To: 'U2 Users List' >> >> > Subject: Re: [U2] Unidata 7.1.16 Multiple Active Select Lists >> >> > >> >> > Can you use SELECT yourfile WITH whatever TO 8 {specific list >> >> > number} in the master process, and let your SUBR virtual field >> >> > default to list >> >> > 0 {zero}? >> >> > >> >> > The other option could be to do a READLIST within the SUBR function >> >> >> > and reset the list when RETURNing, but this could be onerous in >> >> > terms of processing speed. >> >> > >> >> > HTH >> >> > -Baker >> >> > >> >> > >> >> > >> >> > -----Original Message----- >> >> > From: >> >> > u2-users-bounces@listserver.**u2ug.org<u2-users-boun...@listserver.u2ug.org> >> >> > [mailto:u2-users-bounces@**listserver.u2ug.org<u2-users-boun...@listserver.u2ug.org>] >> On Behalf Of Kevin >> >> > King >> >> > Sent: Monday, September 24, 2012 11:43 AM >> >> > To: U2 Users List >> >> > Subject: [U2] Unidata 7.1.16 Multiple Active Select Lists >> >> > >> >> > How does one manage multiple active select lists in Unidata? I >> >> > could have sworn I've done this before, but for some reason it's >> >> > not working at all as I recall. >> >> > >> >> > I have this SUBR(..) type field in file A that selects records from >> >> >> > file B to calculate an aggregate. This works fine when listing >> >> > file A and showing the field. However, if there's an active select >> >> >> > list when file A is listed with this field, the select statement in >> >> >> > my SUBR(..) is consuming the active select list 0 and returning >> incorrect results. >> >> > >> >> > My subroutine is $BASICTYPE "U" and is selecting records using the >> >> > lower case select and selecting to active list #3. It then >> >> > processes from list >> >> > #3 and returns its result. I've tried using the RTNLIST and >> >> > PASSLIST options on the EXECUTE statements and I get a "Misuse of >> >> > Reserved Word 'PASSLIST'" or "Misuse of Reserved Word 'RTNLIST'". >> >> > I've tried UDTEXECUTE with no compilation errors but also no >> >> > improvement on the problem. I've even tried MDPERFORM but I get >> >> > the misuse errors with the RTNLIST and PASSLIST options. Oddly >> >> > enough, removing $BASICTYPE "U" I don't get an error on MDPERFORM >> >> > but I can't READNEXT from a numbered select without the $BASICTYPE >> "U". >> >> > >> >> > How should I structure this SUBR(..) so that it does not consume >> >> > list >> >> > 0 when selecting to list 3? >> >> > ______________________________**_________________ >> >> > U2-Users mailing list >> >> > U2-Users@listserver.u2ug.org >> >> > http://listserver.u2ug.org/**mailman/listinfo/u2-users<http://listserver.u2ug.org/mailman/listinfo/u2-users> >> >> > >> >> > ______________________________**__ >> >> > >> >> > This communication, its contents and any file attachments >> >> > transmitted with it are intended solely for the addressee(s) and >> >> > may contain confidential proprietary information. >> >> > Access by any other party without the express written permission of >> >> >> > the sender is STRICTLY PROHIBITED. >> >> > If you have received this communication in error you may not copy, >> >> > distribute or use the contents, attachments or information in any >> way. >> >> > Please destroy it and contact the sender. >> >> > ______________________________**_________________ >> >> > U2-Users mailing list >> >> > U2-Users@listserver.u2ug.org >> >> > http://listserver.u2ug.org/**mailman/listinfo/u2-users<http://listserver.u2ug.org/mailman/listinfo/u2-users> >> >> > >> >> > >> >> > Click >> >> > https://www.mailcontrol.com/**sr/wQw0zmjPoHdJTZGyOCrrhg==<https://www.mailcontrol.com/sr/wQw0zmjPoHdJTZGyOCrrhg==> >> >> > 04y!**LlOoL8USVGrPZehFfPKcPPmbfFPdrr**1lqOECv!Swg== to report this >> >> > email as spam. >> >> > ------------------------------**-------------------------- >> >> > >> >> > Epicor Software (UK) is a limited company registered in England & >> Wales. >> >> > Registration Number: 2338274. Registered Office: 6th Floor, One >> >> London >> >> > Wall, London EC2Y 5EB >> >> > This e-mail is for the use of the intended recipient(s) only. If >> >> > you have received this e-mail in error, please notify the sender >> >> > immediately and then delete it. If you are not the intended >> >> > recipient, you must not use, disclose or distribute this e-mail >> >> > without the >> >> author's >> >> prior permission. >> >> > We have taken precautions to minimize the risk of transmitting >> >> > software viruses, but we advise you to carry out your own virus >> >> > checks on any attachment to this message. We cannot accept >> >> > liability for any loss or damage caused by software viruses. Any >> >> > views and/or opinions expressed in this e-mail are of the author >> >> > only and do not represent the views of Epicor Software (UK) Limited >> >> >> > or any other company within >> >> its >> >> group. >> >> > >> >> > >> >> > This message has been scanned for malware by Websense. >> >> > www.websense.com ______________________________**_________________ >> >> > U2-Users mailing list >> >> > U2-Users@listserver.u2ug.org >> >> > http://listserver.u2ug.org/**mailman/listinfo/u2-users<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<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<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<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<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<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<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