Quantcast
Channel: CodeProject Latest postings for Regular Expressions
Browsing all 224 articles
Browse latest View live

Is there a way to come up with a regular expression for this?

I am trying to create a question on google forms with the following conditions but having a hard time figuring out how to create a regular expression for this What is your member ID? - Must be an 8...

View Article


Splitting with optionally second line

Hi, I want to split the text above in three results. Every result starts with the word "Leistung" and can optionally have a second line starting with "Zusatz". My regex-expression ist currently this:...

View Article


Find the 4th last object in this campaign

My campaigns all follow the same naming convention, i am trying to use a Regex_Extract formula in DataStudio to create a new custom dimension that only displays the 4th last element in the below...

View Article

Removing + - chars if lines are starting with them only

-Hardsoul -housejazz +Jean Michel Rotin -Anita Perras -St.Niccolo +Mahalia -fr to Hardsoul -housejazz Jean Michel Rotin Anita Perras St.Niccolo Mahalia -fr

View Article

Regex search to find and remove consecutive lines which end with same characters

Hello, I need to write a regular expression search which will locate when a line ends with the same text as the preceding line, but does not have the same first 10 characters. So in this example:...

View Article


How to remove an & in the following expressions

Hello everyone! since more than two decades programming with VC++ I never used Regular Expressions. But now I need... The solution in VS2022 contains some thousands line looking like:...

View Article

Why does this work but this doesn't

This works without the $ but I need it to work from the end of the line not the start of the line. Working: (\b[A-Za-z]{1}[A-Za-z]+\b) Not Working: (\b[A-Za-z]{1}[A-Za-z]+\b)$ What I'm trying to do is...

View Article

Need a bit of help concerning RegEx

I own few virtual pinball files that I need to be clean up. I was planning to use RegEx in Excel to clean them out, I'm ok with VBA programming I know what RegxEx is and what it can do but I'm not...

View Article


Parsing Session Campaign Data in Data Studio

I am trying to create a formula in Data Studio using RegEx that extracts the channel from the below URLs, all channels are passed as the first value before the first _...

View Article


Regular Expression to find parts of a <script/img src=""> or <link...

Regular Expression to find parts of a <script/img src=''> or <link href=''> attribute value Been using my go-to regex101.com editor to work this out, but I always have problems with URLs...

View Article

RegEx- Find files in Linux which match the expression

This is for my VMware vCenter servers where I am trying to clean out extra log files which are no longer required. The type of files for this example are:Quote:...

View Article

Sometimes its a bullet item, sometimes it is not, sometimes it is multiple...

I am trying to write some regex to pull out fields from a set of web pages. The information contained in them can vary for example they can have all or some of the fields (I think I have identified all...

View Article

i need a regular expression to match a single word starting with...

i need to find the strings like below mTimerManager mAutolockManagerbut not like mv this is comment timerManageranand sunku

View Article


Problem combining REGEX expressions

Hello all, I'm a regex newbie and I'm stuck with regex in PCRE/PHP. First expression, I'd like to match letters, numbers or underscore but - no space at start or end - no more than one consecutive...

View Article

Well no that isn't how it works

Rant about regex taken from the Code Project newsletter links. Figured I might as well put a response here.Regular Expressions make me feel like a powerful wizard – and that’s not a good thing –...

View Article


regex expression for us addresses

Do you think this regular expression that I made for US addresses is good enough for 99.9% of addresses out there? ^(?<housenumber>\d{1,5}) (?:(?<predirectional>N|E|S|W|NE|SE|SW|NW)...

View Article

Remove all double quotes not directly preceded or directly followed by a...

Hi, I have 3000 large csv files which give an error when i bulk insert them into a sql server table. This is caused by the fact that some text fields, which are surrounded by double quotes sometimes...

View Article


Regular expression to return all keys in a Bibtex file

A Bibtex file is a structured file (I have shown an example of two records at the end). I would like to extract the 'keys', which is the text between an '@' and a comma but only get the text AFTER the...

View Article

What is the regular expression for this string?

I am looking for the regular expression for the following. Microsoft.Sql/servers/*.*/databases That can match Microsoft.Sql/servers/some-text/databases Microsoft.Sql/servers/some--other-text/databases...

View Article

I need help with a complex regex

Challenge: I have a file with genealogy information which I would like to extract (in Google Sheets) using regex. Data: One cell contains text information. Basically it is four main parts, two of which...

View Article
Browsing all 224 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>