Drupal 6: How to sort/filter search results by date - api

How to customize standard search behavior in Drupal 6? I need search results to be sorted by date. In example, people want to show items within 2 past weeks or something like that.
I've tried a lot things on this reference without luck. Have you ever encountered such problem? Any help will b appreciated. Thanks!

You can sort by date using search solutions like Apache Solr. But I understand you want to use standard Drupal search.
In that situation I would recommend using the faceted search module http://drupal.org/project/faceted_search
Faceted Search module does not require the installation of a separate search engine. It also has views integration which will allow you to do thinks like show results from last 2 weeks and so on.
Please see:
http://drupalcode.org/viewvc/drupal/contributions/modules/faceted_search/README.txt?view=co
You can search for "views" in the above document for information.
You can choose to also not show any facets if you don't want your users to see them. In that case you would be installing the module only because of the benefits of views integration.

Related

related keyword recommendation using solr and mongodb

Im new to solr...
I have been looking into related content recommendation engine... for implementing it to my core php and mongodb website.. its music listening website.. so i have added keywords to every music like singer,music,lyrics to mongodb.
My question is related music recommendation using keywords can solr (more like this handler) recommend it?
example keywords : bobby-singer,a-r-rehaman,shreya goshal
its should look for related keywords in order like:
bobby-singer,a-r-rehaman,shreya goshal
bobby-singer,a-r-rehaman
bobby-singer,shreya goshal
a-r-rehaman,shreya goshal
bobby-singer
a-r-rehaman
shreya goshal
my keywords are already in mongodb.. im planning to work with apache solr morelikethis handler.. or please recommend me some good recommendation engine..
Thanks
There are a couple of different things here.
First of all, you can use MLT to get Solr to bring to you related documents but...
I am wondering if you could also benefit from synonyms so that on certain searches you can get results that are similar which may satisfy the user
And also if you have already the list of relationships you can build a small index where you can run an OR of your query and get potential related searches or execute potential related searches and get related results
Hope this helps

Searching in Different Drupal websites

I have 4 drupal websites different in Database and Files.
I need to use drupal search for any website to get any content related in all others.
Also, In article content type need to get related articles through all website.
Is Apache solar is best solution for that? and what's its limitation for this task?
Thanks
You need to read this
http://www.phase2technology.com/blog/exposing-external-content-to-drupals-search/
Do go through the comments as well.
It would be better to treat all 4 sites as different/external in case their DB's are different.

how to store different files that need to searched in ASP.NET MVC 4 website

My requirement is like job sites where a user can upload a document(can be PDF,Text or word document) like Resume/CV. Then all these documents can be searched for a specific or a combination of keyword and they also have to be ranked based on those key words. I need to know which technology can be good from performance point of view when the number of files are huge and also there are good number of request for searching and indexing.
The website is built using SQL Server. So can I store those files in SQL Server? Will be good in terms of performance.
Or can it be done alone using Lucene.NET and i can store those files in single folder?
I think, the best suggestion is to use Lucene ....
you can save your documents as they are with some unique path name/file_name , and use that as identifier when you index the documents ... I am sure you can find a lot of similar examples if you search Lucene ..

Hierarchical Use of SharePoint 2013

I'm trying to determine the best way to utilize SharePoint 2013 to manage a very large project with a number of hierarchical elements. I've thought about using cascading/embedded group permissions (doesn't appear to be possible), audience targeting (I'm concerned about user's ability to understand and correctly enter the appropriate target audience), using some kind of session variable fed from a SharePoint list to determine how to characterize entries but then I need a way to auto filter them in lists (seems awfully complex and not sure this will even work). So I'm wondering if I'm missing a better way to do this. This being the following:
I have various staff levels: people at the bottom who are located at a site, a person at the site that is the manager, a hub that links various sites, areas that oversee hubs and include an area manager. I'd like these various people to be able to see only whats relevant to them so for a simple example: a list with a calendar view. An area lead should be able to see all entries made by his site leads, while a site/hub manager should only be able to see entries made by people under their respective site/hub. This would work perfect if I could assign groups to groups and then filter the list instead of by [me] by [(some permission filter option)]
There has got to be a simple way to do this, anyone have any ideas? I think I'm missing some capability of SharePoint 2013 to do something like this and thus am making it harder than it should be.

User Specific Lucene Search

I don't think this is a very obscure Lucene problem, but somehow I just don't seem to be able to find a good solution to it. I will use an example.
Let's say I am building a news articles website. Registered users can bookmark articles that they are interested in. I want to allow users to search for only articles that he/she bookmarks. For the sake of example, let's also assume that a user can potentially bookmark thousands of articles, and we have hundreds of thousands of users in our database. How do I build a scalable solution for this problem?
Thanks a lot!
This is a very typical Lucene problem as it does not support joins. More specifically, there's no first class support and you have to find your ways around it. I can suggest a few:
You could have a database, which has users, articles and bookmarks tables (the latter would have foreign keys pointing to the first two). You would also have articles indexed in Lucene. When running a search against articles, you could write a Lucene Filter which would exclude all articles not bookmarked by the current user.
You could index all articles and bookmarks in Lucene - probably best if you do this using separate indices. Then you could run a query for bookmarks (to retrieve which articles current user has bookmarked) and then run another separate query for articles. Like in the previous example, you could use the results of the first query to exclude all other articles which are not bookmarked by the current user.
I personally prefer option #1 as this is classical relational structure and databases are designed for exactly this purpose. With the option #2 you would have to modify both user storage and Lucene index when user gets deleted.