Been using SupaBase for a couple of months now on a side project and it’s very nice. I’ve used Firebase extensively and it’s so nice to have a similar offering using SQL for the DB layer. Good to see them sticking to the open source ethos.
Firebase has some strengths, but I profoundly dislike its NoSQL databases. I started learning web dev ~6 years ago with non-relational dbs but now I'm in the camp that 98% of new projects should start with a relational db. Eager to try Supabase on my next project.
The main problem with Firebase is the lack of search capabilities which is ironic considering Google is the parent company. The fact that they haven't shipped this is probably down to backing themselves into a corner with the DB architecture they've chosen.
Oh god. I'm dealing with this now. Whole project on firebase. Implementing my final feature before launch (full text search). Any last words of wisdom before I drop off the face of the earth for a month trying to get this working?
So I wrote a little function that iterates over the searchable text (in this case it was full names and user names) and adds each fragment/token to a collection and then did a match on that collection in the query. Anything the user might type to find the thing has to go in that child object so you have to tokenise to give yourself every version of what they will be searching as they type.
So my name would go in as
S
Si
Sim
Simo
Simon
Simonb
Simonbar
Simonbark
Simonbarke
Simonbarker
B
Ba
Bar
Bark
Barke
Barker
Etc
Etc
Failing that just dump everything in to an elastic search instance and call out to that for search. It’s not too hard to keep and ES in sync but it’s also more expensive sadly
Comments
Been using SupaBase for a couple of months now on a side project and it’s very nice. I’ve used Firebase extensively and it’s so nice to have a similar offering using SQL for the DB layer. Good to see them sticking to the open source ethos.
Firebase has some strengths, but I profoundly dislike its NoSQL databases. I started learning web dev ~6 years ago with non-relational dbs but now I'm in the camp that 98% of new projects should start with a relational db. Eager to try Supabase on my next project.
NoSQL was overhyped. SQL is awesome.
The main problem with Firebase is the lack of search capabilities which is ironic considering Google is the parent company. The fact that they haven't shipped this is probably down to backing themselves into a corner with the DB architecture they've chosen.
And still point customers to a competitors... https://firebase.google.com/docs/firestore/solutions/search
Ahhhhh! I had to make partial search indexes for anything I wanted to be searchable as the user typed, so infuriating and unbelievable
Oh god. I'm dealing with this now. Whole project on firebase. Implementing my final feature before launch (full text search). Any last words of wisdom before I drop off the face of the earth for a month trying to get this working?
So I wrote a little function that iterates over the searchable text (in this case it was full names and user names) and adds each fragment/token to a collection and then did a match on that collection in the query. Anything the user might type to find the thing has to go in that child object so you have to tokenise to give yourself every version of what they will be searching as they type.
So my name would go in as S Si Sim Simo Simon Simonb Simonbar Simonbark Simonbarke Simonbarker B Ba Bar Bark Barke Barker Etc Etc
Failing that just dump everything in to an elastic search instance and call out to that for search. It’s not too hard to keep and ES in sync but it’s also more expensive sadly
Great thank you!