Re: Capturing multiple variables in regular expression

2023-03-22 Thread Christopher Stone
> On Mar 22, 2023, at 10:40, Doug Pinkerton wrote: > > I need to convert data formatted for humans into data formatted for a > database. The actual document is subject to privacy regulation. The following > is a mockup to illustrate the task. I need to convert this: Hey Doug, Here's a Perl

Re: Capturing multiple variables in regular expression

2023-03-22 Thread Fletcher Sandbeck
I'd check for "Gremlins" if you haven't already. In any case that step could be cleaned up a little. The version below doesn't rely on the return at the start of the file and doesn't really care about how the name/number part of the line is formatted. Find: (\r|^)(.+?)\r\t(.+?)\r\t\t Replace:

Re: Capturing multiple variables in regular expression

2023-03-22 Thread Doug Pinkerton
Thank you, Fletcher. The first few steps worked perfectly. The data now look like this: ART 200 Alternate Dove, David 11 Fox, Fred 11 Gill, Gertrude 10 But when I run this step: \r(.+?)\r\t(.+?)\r\t\t(.+?)\r it acts on most of the student names, but not all of

Re: Capturing multiple variables in regular expression

2023-03-22 Thread Fletcher Sandbeck
I feel like this would be easier with a script of some sort. Nevertheless the idea I had was to do the following. First, use Shift Right to push all the data in two tab stops. And make sure there's an empty line at the start and end of the file. ART 215-2D Art II, Honors

Capturing multiple variables in regular expression

2023-03-22 Thread Doug Pinkerton
I need to convert data formatted for humans into data formatted for a database. The actual document is subject to privacy regulation. The following is a mockup to illustrate the task. I need to convert this: ART 200-2D Art I First Level Requests Aardvark, Amy 10 Badger, Billy 11 Cat, Carl 12