Skip to main content
The 2024 Developer Survey results are live! See the results

All Questions

Tagged with
-4 votes
1 answer
67 views

Java String split by empty lines including empty lines at the end [closed]

I have seen many questions and answers online, but it seems that I cannot find the case that I have. String s = "a\nb\n\nc\n\n\n\n"; String[] split = s.split("\\R"); //is the same ...
Matjaz's user avatar
  • 484
-1 votes
0 answers
35 views

String split on | (pipe delimiter), except if the pipe is inside enclosed string [duplicate]

I am trying to integrate a small REST API in into my C# application, which allows filtering on different columns. I have a string I need to split into an array using the | (pipe) as demiliter. It ...
MichaelO's user avatar
0 votes
1 answer
61 views

JavaScript Split String with regex - match (how to replace match regex into split function)

let s = "AbcDefGH" s.match(/[A-Z]+[a-z]*/g) ["Abc", "Def", "GH"] // This is what expecting with split function s.split(/(?=[A-Z]+[a-z]*)/g) ["Abc", &...
PRATAP's user avatar
  • 197
1 vote
1 answer
64 views

conditional split based on list of column

I have a dataframe having 2 column - "id" (int) and "values" (list of struct). I need to split on name. I have a list of column names as delimiter. I need to check the occurence of ...
steve's user avatar
  • 303
3 votes
3 answers
224 views

How to split character as per specific sequence?

Let's say I have a specific string in R, say "ABCDEFG". I can break it into a sequence of say every two characters using the following regex. strsplit("ABCDEFG", "(?<=(..)...
AnilGoyal's user avatar
  • 26.2k
-2 votes
1 answer
173 views

"The big SQL RegEx": How do I RegEx split an easy SQL query (SELECT ... INTO ... FROM ... WHERE ... GROUP BY ... HAVING ... ORDER BY)?

Background I am working on an overview over all tables and queries in all Access databases in a given folder, and my aim is to split the SQL code behind the queries into columns with RegEx. Thus, I ...
questionto42's user avatar
  • 8,727
1 vote
4 answers
99 views

Regex to split string along &

I have this string PENNER,JANET E TR-50% & PENNER,MICHAEL G TR - 50% & SOURCE LLC & LARRY & FREDDY INC and I want to split it up into groups like this PENNER,JANET E TR PENNER,...
samsun96's user avatar
  • 357
1 vote
3 answers
51 views

Conditionally separating a string in R or alternative Regex expressions

I have a string of 7 dimensions that I want to split into 7 different strings. The string is comma delimited, i.e. there is a comma between each of the dimensions. Ordinarily, to separate the ...
user23356728's user avatar
0 votes
1 answer
39 views

TextBox that searches through file names despite tags order

I have a C# .Net application with images. Images are named like "cat bowl.jpg" "bowl dog.jpg" "possum.jpg" "raccoon bowl night.jpg" I want to create a search ...
Neon's user avatar
  • 3
1 vote
2 answers
146 views

Splitting String in numbers and text in Dart/Flutter

I am trying to divide a string in flutter into text and numbers. The string consists of a number and a measurement in the metric system. My goal is to separate the number from the measure in order to ...
Chris's user avatar
  • 99
3 votes
2 answers
106 views

python split string into letters, numbers and special chars

I have following function want to split string into words. The split result needs to separate letters, numbers and some special chars like / or - import pandas as pd import re def ...
Wennian Li's user avatar
2 votes
6 answers
115 views

Splitting a string by commas, and removing some characters

Here are the values I would like to separate: f <- data.frame(x = c("c(58663.809, 232648.355, 0)", "c(5902.873, 232674.248, 0)")) I would like to remove the "c(", ...
bhopalstiffs's user avatar
-5 votes
2 answers
77 views

UK Postcode Split

The UK post code is like this BB9 7RL I would like to keep the first block then the first letter of the second block like this BB9 7 I am using this at the moment but it only gives me the first block ...
mickfitz's user avatar
0 votes
0 answers
43 views

C# Split text by multicharacter delimiter and keep the delimiter [duplicate]

I've got the below: Line A Snowflake cake flour 12.5kg R142.99 Libresse Toilet Rolls 24s R82.99 3. Snowflake Self Raising Flour 10 x 1kg R264.99 20 x 500g R264.99 Elite Rice 10kg R85.99 5. Allsome ...
Chamkey's user avatar
  • 105
0 votes
0 answers
100 views

what google sheets regex formula will split thai text of variable lengths into different cells but with flexible conditions

I am trying to find a regex expression for the google sheets formula regexreplace to divide the following Thai text so that it is in easier to manage ie in separate cells to translate using google ...
smoking anthill's user avatar

15 30 50 per page
1
2 3 4 5
232