Re: [U2] Selecting a List
Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? Greg ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] Selecting a List
VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' Will the following work to get rid of all the @VM's (Not just the first) VL.JS.LIST.VAR1 = ':CONVERT(@VM,REUSE( ),VL.JS.LIST.VAR1):' George -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users- boun...@listserver.u2ug.org] On Behalf Of Greg Coelho Sent: Wednesday, June 08, 2011 11:47 AM To: u2-users@listserver.u2ug.org Subject: Re: [U2] Selecting a List Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? 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
Re: [U2] Selecting a List
On 08/06/11 16:47, Greg Coelho wrote: Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? Yes. I think you need the ?REPLACE? function. There is a function that replaces one string with another. It might be EREPLACE instead. Anyways. Read the BASIC manual - it is there. Cheers, Wol ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] Selecting a List
What about SWAP? SWAP str.expr1 WITH str.expr2 IN var The UniBasic SWAP command replaces all occurrences of one substring with a second substring. The search string does not have to be the same length as the replacement string. SWAP supports mulitbyte languages. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Greg Coelho Sent: Wednesday, June 08, 2011 11:47 AM To: u2-users@listserver.u2ug.org Subject: Re: [U2] Selecting a List Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? 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
Re: [U2] Selecting a List
I'm assuming this is in a basic program and you want to use CHANGE instead of CONVERT. In Unidata, anyway. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wols Lists Sent: Wednesday, June 08, 2011 9:00 AM To: U2 Users List Subject: Re: [U2] Selecting a List On 08/06/11 16:47, Greg Coelho wrote: Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? Yes. I think you need the ?REPLACE? function. There is a function that replaces one string with another. It might be EREPLACE instead. Anyways. Read the BASIC manual - it is there. 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] Selecting a List
EREPLACE function? SYNTAX EREPLACE (expression, substring, replacement [,occurrence [,begin]] ) DESCRIPTION Use the EREPLACE function to replace substring in expression with another substring. If you do not specify occurrence, each occurrence of substring is replaced. occurrence specifies the number of occurrences of substring to replace. To replace all occurrences, specify occurrence as a number less than 1. Glorfield, Gordon wrote: What about SWAP? SWAP str.expr1 WITH str.expr2 IN var The UniBasic SWAP command replaces all occurrences of one substring with a second substring. The search string does not have to be the same length as the replacement string. SWAP supports mulitbyte languages. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Greg Coelho Sent: Wednesday, June 08, 2011 11:47 AM To: u2-users@listserver.u2ug.org Subject: Re: [U2] Selecting a List Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? 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 -- 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
Re: [U2] Selecting a List
Guys, As always a number of great options! I was able to throw in SWAP with the least effort and it's working great! Thanks again, Greg From: Bob Woodward bob_woodw...@k2sports.com To: U2 Users List u2-users@listserver.u2ug.org Date: 06/08/2011 12:06 PM Subject:Re: [U2] Selecting a List Sent by:u2-users-boun...@listserver.u2ug.org I'm assuming this is in a basic program and you want to use CHANGE instead of CONVERT. In Unidata, anyway. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wols Lists Sent: Wednesday, June 08, 2011 9:00 AM To: U2 Users List Subject: Re: [U2] Selecting a List On 08/06/11 16:47, Greg Coelho wrote: Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? Yes. I think you need the ?REPLACE? function. There is a function that replaces one string with another. It might be EREPLACE instead. Anyways. Read the BASIC manual - it is there. 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 ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] Selecting a List
CHANGE works in UV too. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Bob Woodward Sent: Wednesday, June 08, 2011 12:07 PM To: U2 Users List Subject: Re: [U2] Selecting a List I'm assuming this is in a basic program and you want to use CHANGE instead of CONVERT. In Unidata, anyway. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wols Lists Sent: Wednesday, June 08, 2011 9:00 AM To: U2 Users List Subject: Re: [U2] Selecting a List On 08/06/11 16:47, Greg Coelho wrote: Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? Yes. I think you need the ?REPLACE? function. There is a function that replaces one string with another. It might be EREPLACE instead. Anyways. Read the BASIC manual - it is there. 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 ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] Selecting a List
What system ? this works fine in UV. 001 x=@VM:@VM:@VM 002 crt x 003 crt convert(@VM,x,x) 004 end RUN DEV.BP X ²²² xxx -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Greg Coelho Sent: Wednesday, June 08, 2011 11:47 AM To: u2-users@listserver.u2ug.org Subject: Re: [U2] Selecting a List Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? 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
Re: [U2] Selecting a List
Jeff, Thanks for the info on EREPLACE! It looks like this would allow me to replace a specified number of the substrings - something I've been wrestling with on another assignment... Thanks again, Greg From: Jeff Schasny jscha...@gmail.com To: U2 Users List u2-users@listserver.u2ug.org Date: 06/08/2011 12:11 PM Subject:Re: [U2] Selecting a List Sent by:u2-users-boun...@listserver.u2ug.org EREPLACE function? SYNTAX EREPLACE (expression, substring, replacement [,occurrence [,begin]] ) DESCRIPTION Use the EREPLACE function to replace substring in expression with another substring. If you do not specify occurrence, each occurrence of substring is replaced. occurrence specifies the number of occurrences of substring to replace. To replace all occurrences, specify occurrence as a number less than 1. Glorfield, Gordon wrote: What about SWAP? SWAP str.expr1 WITH str.expr2 IN var The UniBasic SWAP command replaces all occurrences of one substring with a second substring. The search string does not have to be the same length as the replacement string. SWAP supports mulitbyte languages. -Original Message- From: u2-users-boun...@listserver.u2ug.org [ mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Greg Coelho Sent: Wednesday, June 08, 2011 11:47 AM To: u2-users@listserver.u2ug.org Subject: Re: [U2] Selecting a List Hi All, Again, I need a little help. The following PROCEDURE LINE works just fine. In this case I'm just inserting the variable V.CALENDAR.YEAR to complete my file suite and I am going after 2 alphanumeric records ('P2021422' 'P2083158'). PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = 'P2021422' 'P2083158' The problem arises when I attempt to select from a LIST (below) PROCEDURE LINE SELECT GLA.:V.CALENDAR.YEAR: WITH GLA.REF.NO = : VL.JS.LIST.VAR1 Of course the system does not like the Value Marker so I need to get rid of it... VL.JS.LIST.VAR1 = ':CONVERT (@VM,' ',VL.JS.LIST.VAR1):' The hope here is to replace @VM with ' ' and then place the ' at each end... but CONVERT will only switch one for one - one @VM for a single single quote (') which results in a quote mismatch. Any suggestions? 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 -- 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] [UniData] UniRPCD
Nice. Thanks for the info. I'll find the one you mentioned and try it. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Doug Averch Sent: Tuesday, June 07, 2011 7:19 PM To: U2 Users List Subject: Re: [U2] [UniData] UniRPCD Hi: The lastest version we installed of UOJ about 4 months ago is 4.1.4. It seems to work on every version of Unidata back to 6.0. Those files are quite old, it could be your problem but before jumping to into old code you need to try the latest and greatest. Regards, Doug www.u2logic.com Eclipse based Resizing and Editor for U2 ___ 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] Logical error
Hi, I am having problem in using escape sequence in UniBasic coding.I cant use the following command in UniBasic code. Command: echo -e \033[44m. If i use this command in UniBasic code it shows error for using \.So can you suggest any solution for using this command in UniBasic coding. Thanks, Sathish ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] Logical error
In UniBasic, you could just do: CRT CHAR(27):[44m -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of sathish Sent: Wednesday, 8 June 2011 11:24 PM To: u2-users@listserver.u2ug.org Subject: [U2] Logical error Hi, I am having problem in using escape sequence in UniBasic coding.I cant use the following command in UniBasic code. Command: echo -e \033[44m. If i use this command in UniBasic code it shows error for using \.So can you suggest any solution for using this command in UniBasic coding. Thanks, Sathish ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ ### The information transmitted in this message and attachments (if any) is intended only for the person or entity to which it is addressed. The message may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer. The intended recipient of this e-mail may only use, reproduce, disclose or distribute the information contained in this e-mail and any attached files with the permission of IMB. ### ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] Logical error {Unclassified}
Sathish, Or, if you want to make life a little easier for the next poor guy who gets to maintain the code: ESC = CHAR(27) MeaningfulNameForString = [44m ScreenCommand = ESC:MeaningfulNameForString CRT ScreenCommand Regards Mike -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Dan McGrath Sent: Thursday, 9 June 2011 5:14 p.m. To: U2 Users List Subject: Re: [U2] Logical error In UniBasic, you could just do: CRT CHAR(27):[44m -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of sathish Sent: Wednesday, 8 June 2011 11:24 PM To: u2-users@listserver.u2ug.org Subject: [U2] Logical error Hi, I am having problem in using escape sequence in UniBasic coding.I cant use the following command in UniBasic code. Command: echo -e \033[44m. If i use this command in UniBasic code it shows error for using \.So can you suggest any solution for using this command in UniBasic coding. Thanks, Sathish 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