Sheets Tip 358: What do you think happens with this formula?


Brought to you by:


Hi Reader,

Welcome to the Google Sheets Tips newsletter #358, your Monday morning espresso, in spreadsheet form!

Today's tip comes from an accidental discovery I made whilst researching a trick with the LEFT and RIGHT functions.

Let me ask you...

What do you think happens with this formula? (Answer before trying it in your Sheet ;) )

= "A" < "B"

Check out the answer in today's tip and see a real-world application below.


➜ News

I.
​
Google had its day of reckoning in front of the courts last week and the results were in their favor. They must share some of their data with rivals but do not need to sell off Chrome. Good news for investors... the share price jumped 8% that day.

​Read more here >>​


Brought to you by: TabTabTab

Freak in the sheets that will leave you wanting more

TabTabTab fills in missing data and cleans columns, right inside Google Sheets. Just tell it what you want, in plain English, and it'll do the grunt work for you.

🔍 Analyze on command: clean data, write formulas, and spin up quick models while you stay in the flow.

📊 Turn numbers into stories: ask for “sales by week” or “attendance by month” and TabTabTab will generate clean, readable visuals, including native Sheets charts.

⤵️ Enrich rows automatically: pull data from the web, extract tables from PDFs, and drop results into Sheets without the CSV shuffle.

Used by professionals across leading tech companies and universities.


➜ Sheets Tip #358: Alphabet Comparison Trick

So it turns out you can use comparison operators (less than "<" and more than ">") with text strings!

For example, ="A"<="B" outputs TRUE because the A is before B in the alphabet.

(One way to understand this is to convert the letters to their decimal unicode characters and determine which is bigger or smaller. The unicode character for "A" is 65 in decimal terms. "B" is 66, etc.)

More examples:

So this is quite interesting!

Let's see a real-world application.

Practical Use Case

Suppose we work in a library and want to order our books into groups based on the first letter of the author's surname.

We can use this formula to do that!

=IF(LEFT(A2)<="M","A–M","N–Z")

Firstly, the LEFT function is used to get the first letter of the surname.

Quick tip: LEFT(A2) is shorthand for LEFT(A2,1)

This letter is compared to "M" and the surnames are then assigned a group by an IF function.

In our Sheet:

A neat little formula!

What if you want more groups?

Use an IFS function (here combined with LET for readability) to achieve that:

=LET( l , LEFT(A2), IFS( l<="G" , "A-G", l<="M" , "H-M" , l<="S" , "N-S" , l<="Z" , "T-Z" ))

In our Sheet:

Very satisfying! I do love a good formula 😍


If you enjoyed this newsletter, please forward it to a friend who might enjoy it.

Have a great week!

Cheers,
Ben

P.S. Phew and nope​

Google Sheets Tips

Get better at working with Google Sheets! Join 50,000 readers to get an actionable tip in your inbox every Monday.

Read more from Google Sheets Tips
Add a QA check to prompts to make them more accurate

Hi Reader, Welcome to the Future Proof newsletter, your Monday morning espresso, in AI form! (Formerly the Google Sheets Tips newsletter.) One of the stories that jumped out to me in the past week came from an interview with a tearful Cornell mathematics professor, asking "what's the point?" when AI surpasses human ability and steals the meaning (and joy) from mathematical research. (Which is a calling, not just a job to many.) One line stuck with me, and I'm paraphrasing here, but basically,...

Add custom Gemini instructions in sidebar of Google Sheets

Hi Reader, Welcome to the Future Proof newsletter issue 5, your Monday morning espresso, in AI form! (Formerly the Google Sheets Tips newsletter.) Lots of Gemini and Google Workspace news to share today and a tip on custom instructions. Find it all below, but first a little anecdote from my weekend. Kids say the funniest things. My 9-year-old declared over the weekend that he was going to build his own AI company and call his AI tool "Psycho"! I laughed and told him I loved the name. I was...

Output Google Doc as markdown file

Hi Reader, Welcome to Future Proof #4 (formerly the Google Sheets Tips newsletter), your Monday morning espresso, in AI form! My son and I had some fun 3-D printing over the weekend. I printed a rugged case to hold my Field Notes journals (see the finished result at the end of this email). The print run just beginning. It's impressive to watch something grow from nothing, although since the full print took around 3 hours I didn't watch the whole thing ;) And now, perhaps more than ever...