I merely copied what I saw in Jean Jourdain’s post and didn’t recognize the 
brackets as such. Time for bigger text in my email or new glasses . Thank you 
for the explanation!

On Nov 10, 2022, at 2:10 PM, Tom Robinson 
<[email protected]<mailto:[email protected]>> wrote:

Not sure what your intent was with that regular expression?

This inserts tabs between columns, based on their width.  You’ll need a second 
pass to remove trailing spaces:

Find:  ^(.{25})(.{16})(.{29})(.{21})(.+)$

^ Anchors to start of line
( Start a capture buffer ( \1 )
. Any single character
{25} That single character 25 times
) End capture buffer

Replace:  \1\t\2\t\3\t\4\t\5

Cheers


On 2022-11-11, at 09:48, 'Bruce Johnson' via BBEdit Talk 
<[email protected]<mailto:[email protected]>> wrote:

Didn’t work with my example. but this is regexp wizardry beyond my knowledge 
(or my google-fu is weak today)

This is what I had in the find box:

(.(23)) (.(43)) (.(74)) (.(95))

 Sample data

Name                      Alias           Database                    
ProhibitSendQuota    ExternalDirectoryObjectId
----                      -----           --------                    
-----------------    -------------------------
Name1                    Alias1          NAMPR190000-xxxx             49.5 GB 
(53,150,220… objid1
Name2                    Alias2          namPR190000-xxxx             49.5 GB 
(53,150,220… objid2


No matches were found so nothing got replaced.

This was why I loved Columnbo, just drag a marker to the point you wanted the 
column to start and bang it replaced any string of spaces to a tab character.  
Used it to massage large masses of text into tabular data.


--
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email 
"[email protected]<mailto:[email protected]>" rather than posting here. 
Follow @bbedit on Twitter: <https://twitter.com/bbedit>
---
You received this message because you are subscribed to a topic in the Google 
Groups "BBEdit Talk" group.
To unsubscribe from this topic, visit 
https://groups.google.com/d/topic/bbedit/mpUF87o2jXg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to 
[email protected]<mailto:[email protected]>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/B7E3D7AE-68BC-4ACD-980F-765D6BF1F1EB%40gmail.com<https://groups.google.com/d/msgid/bbedit/B7E3D7AE-68BC-4ACD-980F-765D6BF1F1EB%40gmail.com?utm_medium=email&utm_source=footer>.

--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group

Institutions do not have opinions, merely customs

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "[email protected]" rather than 
posting here. Follow @bbedit on Twitter: <https://twitter.com/bbedit>
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/B5EF54E7-CF8C-4B29-8E6E-15648A794668%40pharmacy.arizona.edu.

Reply via email to