search

Help with searching for files in C#

I am working on a search and replace console app to help out some people in my department. I am trying to have them input a file path and also the type of file they would like to search for. if they want to find txt files then it will find all txt files in a directory...stick these into an array and then process the files as needed. I...

Cannot crawl complex URL's without setting a site-wide rule to 'crawl as http content'.

I have pages within a site containing a control that uses a query string to provide dynamic data to the user (http://site/pages/example.aspx?id=1). I can get my content source to index these dynamic pages only if I create a rule which sets the root site (http://site/*) to 'include complex urls' and 'crawl sharepoint content as http cont...

mysql: Order By relevance when using prepared statements?

I am creating a site search feature for my e-shop and am using the following code to order my query: ORDER BY((case when name RLIKE $wholeword then 3 else 0 end) + (case when name RLIKE $partialword then 1 else 0)) DESC This selects both complete and partial matches from the database and orders them giving complete matches priority ove...

Problem with PdfTextExtractor in itext!

Hi friends! first excuse me for my bad english! I want to search in pdf document for a word like "Hello" . So I must read each page in pdf by PdfTextExtractor. I did it well. I can read all words in each page separately an save it in string buffer. but when i push this code in For loop ,(for example from page 1 to 7 for search in it) ear...

Ruby on Rails: How are people making search forms on sites with the broken textfield parsing that removes quotation marks?

I'm using Sunspot Solr search, which works fine for the most part for basic search. It's supposed to be able to handle quotation marks around phrases, so that a search for test case will return documents with both test and case, whereas a search for "test case" should return documents with the phrase test case. However, I've been pullin...

Help with Replacing Strings on Solaris

I am on a Solaris 8 box that does not support -i option for sed, so I am using the following from a google search on the topic: # find . -name cancel_submit.cgi | while read file; do > sed 's/ned.dindo.com\/confluence\/display\/CESDT\/CETS+DocTools>DOC Team/wwwin-dev.dindo.com\/Eng\/CntlSvcs\/InfoFrwk\/GblEngWWW\/Public\/index.html>EDCS...

Searching in multiple tables using MS SQL Server 2000

We have a database with a lot of information about Persons. I won't post the entire database structure because it is too big, but it looks something like this: Person ID Name Street City State Country Language LangCode Language Interest ID LastChangedBy LastChangedOn LocalizedInterest InterestID LangCode Description PersonInterest...

Apply access restriction on Content Provider

I found that if I want to use the searchable options using the search key I have to create a content provider. Content provider is used to share data across applications. But I do not want to allow access to my content provider (as well as my data) except/outside my own application. I want to use it only for search suggestion. Because ...

PHP - Searching folders to match a whole string based on the first two characters

This is part of a routine that searches for a word. The folders to search are like this:$entirelist. / a/0 thru a/z all the way to z/0 z/z. The files in those directories are one single column of words. "aardark" would be in $entirelist/a/a a-ardvark would be in $entirelist/a/sc (sc = special char in second position. There will ...

what is the best PHP search engine-friendly method?

What method can you recommended for creating search engine-friendly URLs? When coding in PHP that is. Ideally I would like something like: http://www.example.com/article/523544 So it doesn't display the file it's opening (eg article.php) ...

Search results and Previous/Next Item links

I apologize for vague title so let me explain. Suppose you have a page with search results: http://example.com/search?q=foo. The results are: Foo - http://example.com/foo Bar - http://example.com/bar Baz - http://example.com/baz The links above point to the item details page. On these pages I want to display links which allow to na...

Most Concise Way to Determine List<Foo> Contains Element Where Foo.getBar() = "Baz"?

Given a starting List<Foo>, what is the most concise way to determine if a Foo element having a property bar (accessed by getBar()) has a value of "Baz"? The best answer I can come up with is a linear search: List<Foo> listFoo; for(Foo f:listFoo) { if(f.getBar().equals("Baz")) { // contains value } } I looked into Hash...

Java Web App Universal Search GUI Control

I recently saw a demo of a .NET 3.5 product, which has a "Universal Search" widget ... ie, it allowed you to search their entire product, for either your own strings, or their strings, and the results were context-sensitive links to different parts of the application. For example, let's say this was a Point of Sale system, you could sea...

Debugging Solr search queries on Sunspot

How can I debug Solr search queries when using the Sunspot gem on Rails? I have some queries that are returning bizarrely high scores, and I'm trying to get to the bottom of why this is happening. It doesn't seem like any debugging information is exposed to Sunspot, so I think that I need to debug through Solr directly. Fortunately, So...

Neead a sample for WPF TreeView search with Virtualization and Load On Demand

Hi, I need to implement search feature in WPF treeview(basically I need to remember the last user selection). I have tried various approches suggested but nothing works as virtualization is enabled in my treeview and child nodes are loaded only when parent node is expanded(lazy loading). Anyone knows of a sample having these three thi...

setting up elasticSearch with Postgresql

where do I find a howto to set up elasticSearch using Postgres? My field sizes will be about 350mb, yes, MB, each in size. I have a text output of all of the US Code and all decisions from all the courts, the Statutes at Large, pretty much everything you would find in a library, and I need to be able to do full text searches and return...

What's the best field type and data usage to accelerate searches?

I have a question about equivalent search result, that can occur on different fields. Let's say I record the logical deletion state of records with 3 fields like : Boolean Deleted Date DeleteDate String DeleteUserName The goal of the query is to avoid having deleted records into my selection. So I can search the first field with on...

php my sql search without "like" cause?

hi to all.. i am using php and mysql... i have application in which user enter any text and i want to fiind related data from database without using "LIKE" cause in my mysql query. is there any possible way to search these string in database. or any approach in mysql to do this.... Thanks in advance. ...

How do I detect "_" in a C++ string?

Hello, I want to know the positions of the "_" in a string: string str("BLA_BLABLA_BLA.txt"); Something like: string::iterator it; for ( it=str.begin() ; it < str.end(); it++ ){ if (*it == "_") //this goes wrong: pointer and integer comparison { pos(1) = it; } cout << *it << endl; } Thanks, André ...

which jquery effect does google search uses during pagination?

I searched for a particular term it yielded 'n' number of results. When i do a paginate there was an effect occurring and the contents updated after that.. which jquery effect does google uses during search result pagination? Any suggestion... ...