No-one seems to have done it, but here's my version of the code.
It's strange, I don't have a problem with CONTINUE and I don't even mind
IF SOMETHING ELSE THIS = THAT
which a lot of people really hate, but I just HAD to reverse the IF/CASE
statement order.
SUBROUTINE REXY(RECORD,TEXT)
*
: [U2] CSV to Array
On 15/08/12 23:24, David Wolverton wrote:
> I've done this in the past by doing this:
>
> SWAP DQUOTE WITH @AM
>
> Now, in theory, every EVEN attribute is a 'quoted' string - don't
> touch the commas
> Every ODD attribute is a 'n
12 5:42 PM
To: 'U2 Users List'
Subject: Re: [U2] CSV to Array
You can't have
"3/4" Bolts" in the data stream -- that would not work. So that means the
embedded " has to be 'escaped' - usually by a \..
So you'd have "3/4\" Bolts"
;
DW
-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Mecki Foerthmann
Sent: Thursday, August 16, 2012 2:26 AM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] CSV to Array
The moment you start working in the engineer
It is tempting to use SWAP or CONVERT statements when parsing CSV, but
they never handle all the possible cases correctly. You have to look
at each character and keep track of state.
rex
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://list
Thanks for the support.
As I was working my way through the code I posted I noticed that if you
embedded in the quote is a check to see if the character we're on *and* the
next character are both double quotes.
But if that's true, than the initial check for a double quote to even get
*into* th
Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Charlie Noah
Sent: Thursday, August 16, 2012 5:26 AM
To: U2 Users List
Subject: Re: [U2] CSV to Array
I have double quotes in my product descriptions, and yes, they are a
pain! I
-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Dianne
Ackerman
Sent: Thursday, August 16, 2012 7:52 AM
To: U2 Users List
Subject: Re: [U2] CSV to Array
I actually enjoy reading wjhonson's "puzzle"
users-boun...@listserver.u2ug.org] On Behalf Of Dianne
Ackerman
Sent: Thursday, August 16, 2012 8:52 AM
To: U2 Users List
Subject: Re: [U2] CSV to Array
I actually enjoy reading wjhonson's "puzzle" posts with code examples,
etc. Maybe they can be flagged in the header so those of you who do
I actually enjoy reading wjhonson's "puzzle" posts with code examples,
etc. Maybe they can be flagged in the header so those of you who don't
want to read them can just skip them.
-Dianne
On 8/15/2012 5:49 PM, Tony Gravagno wrote:
Anyone getting paid to play guessing games? Dude, get to the p
On 15/08/12 23:24, David Wolverton wrote:
> I've done this in the past by doing this:
>
> SWAP DQUOTE WITH @AM
>
> Now, in theory, every EVEN attribute is a 'quoted' string - don't touch the
> commas
> Every ODD attribute is a 'non-quoted' string...
>
> Double check me here in case I've lost
TAROW
NEWSTRING := @AM:DATAROW
NEWSTRING<-1> = DATAROW
END
NEXT XXX
-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Wednesday, August 15, 2012 4:11 PM
To: u2-users@listserver.u2ug.org
STRING := @AM:DATAROW
NEWSTRING<-1> = DATAROW
END
NEXT XXX
-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Wednesday, August 15, 2012 4:11 PM
To: u2-users@listserver.u2ug.org
Subject: [U2
SWAP ',' WITH @AM IN DATAROW
NEWSTRING := @AM:DATAROW
NEWSTRING<-1> = DATAROW
END
NEXT XXX
-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson
Sent: Wednesday, August 15, 2012 4:11
> -Original Message-
> From: Phil Walker
> To: U2 Users List
> Sent: Wed, Aug 15, 2012 3:02 pm
> Subject: Re: [U2] CSV to Array
>
>
> At risk of starting a flame war, I agree with Tony. I need to tune my
> email
> rules better.
>
>> -Original Message-
t; To: u2-users@listserver.u2ug.org
> Subject: Re: [U2] CSV to Array
>
>
> There's no point in being abusive Tony. No one appreciates it.
>
>
> -Original Message-
> From: Tony Gravagno <3xk547...@sneakemail.com>
> To: u2-users
> Sent: We
t; To: u2-users@listserver.u2ug.org
> Subject: Re: [U2] CSV to Array
>
>
> There's no point in being abusive Tony. No one appreciates it.
>
>
> -Original Message-
> From: Tony Gravagno <3xk547...@sneakemail.com>
> To: u2-users
> Sent: Wed, Aug 15, 2012
There's no point in being abusive Tony. No one appreciates it.
-Original Message-
From: Tony Gravagno <3xk547...@sneakemail.com>
To: u2-users
Sent: Wed, Aug 15, 2012 2:50 pm
Subject: Re: [U2] CSV to Array
Anyone getting paid to play guessing games? Dude, get to the poi
Anyone getting paid to play guessing games? Dude, get to the point. If
this were presented as "I need help" I think many people would jump to
help. But presenting this as a Mensa challenge is just wasting
people's time.
T
Wjhonson wrote:
> Rex Gozar uploaded this code, and someone (perhaps him) c
Rex Gozar uploaded this code, and someone (perhaps him) corrected it, but
there's a redundancy here. I'm trying to fix it, in my own version, mostly
perhaps I *hate* the CONTINUE, but the logic is a bit convoluted eh? Anyone
spot the redundancy ?
EQU COMMA TO ','
EQU DQ TO '"'
20 matches
Mail list logo