Google Sheets Formula to refine data of a column - google-sheets

Is there any formula to extract a website from a cell value in google sheets
convert value from 1st column to as shown in 2nd column

You can use regex to retrieve string with pattern like website:
=REGEXEXTRACT(G1,"[a-zA-z]+\.[a-zA-z]+\.?[a-zA-z]+")
Reference:
REGEXEXTRACT

try:
=INDEX(TRIM(FLATTEN(QUERY(TRANSPOSE(
IFERROR(IF(ISURL(SPLIT(A1:A, " ")), SPLIT(A1:A, " "), ))),,9^9))))

Related

Google Sheets: How can I Flatten and Split Data while including multiple columns?

I would like to pull data from Google Sheets form responses that include checkboxes. The checkboxes are output into single column cells by commas.
Data/Form Responses sheet:
enter image description here
Current and Expected Results
enter image description here
Current Formula
=ARRAYFORMULA(TRIM(QUERY(SPLIT(FLATTEN(IF(IFERROR(SPLIT('Form Responses'!E2:E, ","))="",,
'Form Responses'!B2:B&"×"&SPLIT('Form Responses'!E2:E, ","))), "×"),
"where Col2 is not null")))
If anyone could please help I would appreciate it!
SUGGESTION
Perhaps you can try this tweaked formula:
=ARRAYFORMULA(TRIM(QUERY(SPLIT(FLATTEN(IF(IFERROR(SPLIT('Form Responses'!E2:E, ","))="",,TEXT('Form Responses'!A2:A,"MM/DD/YYYY HH:MM:SS")&"×"&'Form Responses'!B2:B&"×"&'Form Responses'!C2:C&"×"&'Form Responses'!D2:D&"×"&SPLIT('Form Responses'!E2:E, ","))),"×"),"where Col2 is not null")))
Demo
You may try this LAMBDA() formula. You just need to adjust ranges in lambda input parameter.
=LAMBDA(UnpivotCol,AdjucentCols,QUERY(REDUCE(,REDUCE(,UnpivotCol,LAMBDA(a,x,VSTACK(a,TOCOL(INDEX(JOIN("|",INDEX(AdjucentCols,ROW(x)-(INDEX(ROW(UnpivotCol),1)-1))) & "|" & SPLIT(x,",")))))),LAMBDA(t,g,VSTACK(t,SPLIT(g,"|")))),"offset 2 format Col1 'm/d/yyyy'",0))(E2:E4,A2:D4)

Combine two Functions in Google Sheet as STRING Parameter

I am getting Formula Parse error. Help me with Combining 2 Formula. Here IMPORTRANGE has two String Parameter
=IMPORTRANGE("1Iyxg6vcnAR8zHpJaThfdP7UhdiMwFTbOwrW0l_II83M",QUERY(MAINTAINANCE!A5:K151; "select * where Col7 is not null Order By Col7",0))
Here my second Formula QUERY needs to convert in to string using &" but i dont know how to please help me
I Have Try to Using "& to pass both Functions as STRIG. Because IMPORTRANGE has two Parameter as String For Example..
IMPORTRANGE(URL_ADDRESS,RANGE AS STRING)
this:
=IMPORTRANGE("1Iyxg6vcnAR8zHpJaThfdP7UhdiMwFTbOwrW0l_II83M";
SINGLE(QUERY(MAINTAINANCE!A5:K151; "where Col7 is not null order by Col7"; 0)))
will work but only if output from your QUERY is range or cell. example:
A1
A1:A10
Sheet1!A1:A10

How to use split text to column in Google Sheets

I want to split text in column:
This is link to my spreadsheet:
https://docs.google.com/spreadsheets/d/1uSgHy_RR2Yk30eP0zq-K9W2f4_JgcuiEMDHGA-yQrRg/edit?usp=sharing
Try below formula. See you google-sheet.
=QUERY(ArrayFormula(SPLIT(FLATTEN(SPLIT(A2:A4,", ")&"#"&B2:B4&"#"&C2:C4),"#")),"where Col3 is not null")

Google Sheets: Use ArrayFormula to copy a formula until a set value

I'm trying to create a formula until a set value using ArrayFormula in Google Sheets.
The end result values can be viewed on the spreadsheet:
https://docs.google.com/spreadsheets/d/1yBC4oQuhKOkIkf3lQZGBKcZQ3YjU_5N6MCIJZzdt0O4/edit?usp=sharing
Thank you!
delete everything from red cells and use this in D4:
=ARRAYFORMULA(IFERROR(SUBSTITUTE(SPLIT(REPT("♠♥", B4:B-1)&
REPT(B1/C4:C&"♥", C4:C), "♥"), "♠", )))

Delimiting a column using "OR" in Google Sheets

I am using google sheets and would like to combine the text in cells of a column to a single cell separated by "OR" (with spaces on either side of the OR"
For example
**Column A**
John
Bob
Jim
Donald
would be combined in a single cell as "John OR Bob OR Jim OR Donald"
What formula in Google Sheets would I use to accomplish this?
try:
=JOIN(" OR ", A1:A4)
or:
=TEXTJOIN(" OR ", 1, A:A)
if you hit the limit try:
=ARRAYFORMULA(A1&" "&QUERY(IF(A2:A<>"", "OR "&A2:A, ),,999^99))
See if this works
=textjoin(" OR ", 1, A2:A)
Change range to suit.

Resources