-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Return Records #1
Comments
Hi Vincent |
Yep!!! Not entirely sure if it's faster to search through cache, return the gid's, and then query out to sql to return the actual records or just use a gem like ransack, but it would be nice. |
It's an interesting idea when you have LOTS of data. You might simply choose to index the keywords but NOT store the documents (aka DB records) in Redis. You would use NOSAVE http://redisearch.io/Commands/#ftadd for that (I still have to implement support for that in the gem). I think this will slow down the process as it will then need to query your primary DB (MySQL) for the specific GlobalIDs. I will think about how to best support this use case and try to implement it. Otherwise PRs are welcomed. |
Hey thanks!!! But nvm this example is exactly what I've wanted to try and implement https://github.com/mrvncaragay/rails-redis-search. |
I think this example will give you exact matches using regular Redis. But if you install RediSearch module (requires Redis4) that will give you full text search capabilities (if that's what you need). |
Trying to do this in a production env. Completely new to redis I think it's awesome though!!! I just realized, I don't need those records I just need the returned array/hash?.. and to render the views via js. Excuse me for my ignorance, basically I want to search through redis and render in views via js the returned results so that it appears as if I'm searching through an entire db instantly. Now is it better to full text search or do exact matches? I don't know!!!! |
NP, we all start with technologies sometimes. |
Hey Instead of returning an array/hash is there a way to return records?
I opened up rails c and played around with it. If you type
It returns the record is there any way to implement that into the gem?
My users_controller looks like this
my users_helper method looks something like
Users model
Simple form in users index view
The text was updated successfully, but these errors were encountered: