Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Simple filter based on cell <> # in Power Query

In Excel, I have a column we'll call "Serial Numbers"

 

Serial Numbers

4859848598 <-- 10 characters

8458504058 <-- 10 characters

598495898489 <-- 12 characters

289302940409 <-- 12 characters

 

I would like a filter that will show me only serial numbers with serial number with text length of 10 characters.

  • Hi Anonymous ,

     

    You can create a custom column and use it as filter like this:-

    Character_filter =
    IF ( LEN ( Serial_Number[Serial Numbers] ) = 10, TRUE (), FALSE () )

     

    Thanks,

    Samarth

1 Reply

  • Samarth_18's avatar
    Samarth_18
    Icon for Community Champion rankCommunity Champion

    Hi Anonymous ,

     

    You can create a custom column and use it as filter like this:-

    Character_filter =
    IF ( LEN ( Serial_Number[Serial Numbers] ) = 10, TRUE (), FALSE () )

     

    Thanks,

    Samarth