$10.00
Using Regular Expressions To Search BGG
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
Recommend
166 
 Thumb up
3.00
 tip
 Hide
Any half decent programmer is familiar with regular expressions, a simple language for describing patterns, finite state automata, and other geeky things. Thanks to Aldie's infinite wisdom, these powerful and mysterious glyphs can be used to search BGG in a processor-intensive manner, bringing joy to the leet hax0rs amongst us and sluggish response times to the common punter.

And here's how ya use 'em to find games...
Your Tags: Add tags
Popular Tags: searching [+] bgg [+] howto [+] [View All]
  • [+] Dice rolls
1. Board Game: Carcassonne [Average Rating:7.44 Overall Rank:108] [Average Rating:7.44 Unranked]
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
A string (a word or phrase) is a regular expression. To find Carcassonne games and expansions, type this regular expression into the BGG search box:

carcassonne

This is the BGG search you know and love.
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
2. Board Game: Ra [Average Rating:7.48 Overall Rank:95]
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
The ^ and $ symbols indicate beginning and end of a game name. To find Ra without also finding Dragon Dice, use the regular expression:

^ra$

This is equivalent to ticking the little box that used to appear next to the search widget.
5 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
3. Board Game: Go-Moku [Average Rating:5.98 Overall Rank:3989]
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
Part of an expression can be made optional using brackets and the ? symbol. To find Go and Go-moku with the same search, use the regular expression:

^go(-moku)?$

This is some new and fiendish magic.
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
4. Board Game: TATATA! [Average Rating:5.99 Overall Rank:7497]
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
To repeat part of an expression several times, place the desired number inside the {} symbols. To find TATATA, use the expression:

(ta)<3> (these should be curly braces when you type 'em in)

This seems like a novelty, until you consider the case below.
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
5. Board Game: 1776 [Average Rating:6.38 Overall Rank:2034]
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
The sequence [0-9] matches any digit. To find all the games whose names are a four digit sequence, use the expression:

^[0-9]<4>$ (these should be curly braces when you type 'em in)

Oooh, there are some 18xx games here. We'll get to those later.
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
6. Board Game: Kampfpanzer [Average Rating:5.53 Overall Rank:9145]
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
You can represent a choice with a vertical bar. To find Jagdpanzer and Kampfpanzer without finding SS Panzer, use the expression:

^(jagd|kampf)panzer$

I just threw that in for my grognards... aiiight.
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
7. Board Game: Chu Shogi [Average Rating:8.50 Unranked]
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
Once you're comfortable with the above, you can combine expressions, and use the .* sequence as a wildcard. To find chess and its asian variants, use the following expression:

^(chinese |korean )?(chess|.*shogi)$

That's one for Thi to tinker with.
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
8. Board Game: 1830: Railways & Robber Barons [Average Rating:7.78 Overall Rank:112]
フィル
Australia
Ashfield
NSW
flag msg tools
designer
Pushing a lesbian old growth union-approved agenda since '94.
mbmbmbmbmb
And finally, for extra credit, try finding as many 18xx games as you can using one gigantic regexp:

^(18.{2,4})(.*(rail|kit|board).*)?$|2038

That's my best effort thus far.
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
9. Board Game: 007 [Average Rating:5.33 Unranked]
A.N. Onymous
Netherlands
flag msg tools
mbmbmbmbmb
^([0-9])*$

Finds all games of which the name solely consists of digits. The star (*) seems to mean one (zero?) or more occurrences of what's between parentheses.
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
10. Board Game: Dots [Average Rating:4.91 Overall Rank:10348]
...sure...
Netherlands
Rijen
Noord Brabant
flag msg tools
mbmbmbmbmb
I think using dots gets you games with those letters in it, in that sequence. So searching a.b.c. gets you games like
A Backfull of Bullets
How To Host A Teen Mystery: Barbecue With The Vampire
A-B-C OY!
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
11. Board Game: 1800 [Average Rating:6.72 Overall Rank:5217]
I like this list. I didn't know you could search BGG that way.

Here's my search for the 18xx games:

18[0-9][0-9]
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
12. Board Game: Funny Friends [Average Rating:6.49 Overall Rank:1188]
Philippe Beaudoin
Canada
Montréal
Québec
flag msg tools
designer
mbmbmbmbmb
Games that could have been written by Friedemann Friese:

^f([a-z]|[A-Z]|[0-9])*( f([a-z]|[A-Z]|[0-9])*)+$
3 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
13. Board Game: Betrayal at House on the Hill [Average Rating:7.09 Overall Rank:333]
Here's a tip: to go straight to the page of a game with a long name, just type the beginning and the end, with .* in the middle. It works fine so as long there are no more games with the same start and end in the name. For example:

betray.*hill
myst.*bey
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
14. Board Game: Rum & Pirates [Average Rating:6.44 Overall Rank:1445]
 
Werner Bär
Germany
Karlsruhe
Baden
flag msg tools
mbmbmbmbmb
Ru\(h\)m

Regular expressions give a special meaning to some characters; for example, the brackets '(' and ')'. If you want to use them as natural characters, you have to mask them with a '\'
 
 Thumb up
 tip
 Hide
  • [+] Dice rolls
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
Loading... | Locked Hide Show Unlock Lock Comment     View Previous {{limitCount(numprevitems_calculated,commentParams.showcount)}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
{{error.message}}
{{comment.error.message}}
    View More Comments {{limitCount(numnextitems_calculated,commentParams.showcount)}} / {{numnextitems_calculated}} 1 « Pg. {{commentParams.pageid}} » {{data.config.endpage}}
Front Page | Welcome | Contact | Privacy Policy | Terms of Service | Advertise | Support BGG | Feeds RSS
Geekdo, BoardGameGeek, the Geekdo logo, and the BoardGameGeek logo are trademarks of BoardGameGeek, LLC.