473,382 Members | 1,348 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

to count the occurence of a particular word in search of an indexing database server

how to count the occurence of a particular word in search of an indexing database server
Sep 14 '10 #1
2 1712
hi,
i am trying to query the indexing database server. in the serach i type a word for eg. "now" , so i need the result set to be ordered in a way that the document which has maxOccurrence of "now" is returned first and the rest documents later. that is, they should be ordered from ""maxOccurence" to "minOccurence"
Sep 14 '10 #2
jhardman
3,406 Expert 2GB
I wish you could just do it in the SQL, but failing that, you will need to do it programmatically.
1- search the db so you are getting the set of every record with that string
2- send each to a function that counts ( I would use the instr() function in a loop)
3- sort the list according to that count
That said, ASP won't do a good job of that unless you are getting ~10 hits from the db query.

Jared
Sep 17 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: lee_j | last post by:
Hi, I have a question below. In the Sql server 2000 I store some word documents.Then I get the data from the database through the asp code and display the word document in IE.The ContentType is...
0
by: zheetee | last post by:
i am a XML beginner.... how to search a particular word from xml then lists out all the result by using asp,php...+++...... Any search engine....?or script?or... thank you....
2
by: Larry C | last post by:
Hello, I have an XML doc and I am trying to write a utility thath will allow me to change a particular word with my "title" section of theXML doc. I would like to look for a "word" in the title...
3
by: divina11 | last post by:
How do I go through Multiple tables (tables 1-20) to search for a particular word e.g. "first" and then print the results (i.e. table name & column name which contains the word "first"). Not sure...
1
by: avik1612 | last post by:
Hi all, I am trying to write a perl script to find a particular word in all text files in a particular directory and if that particular word is found in that textfile a mail shouldbe send that...
1
by: NoeliaYavel | last post by:
Hi Everyone! I need to count the number of times a br tag in a given string? For Example: "My dog<br>is big<br>and beautiful" This should return 2 Thanks!
3
by: kushal49 | last post by:
Hi, I need to count a particular word in a string in sql server 2000. Anybody please help me out in this...
4
by: sahil | last post by:
Hello frends i am learning c language, I want to make a program which count occurence of each element in an array .I write following code for it but ity is not giving me desired result.pls help me....
2
by: =?Utf-8?B?SmVycnkgQw==?= | last post by:
I have a server 2008 IIS 7.0 with indexing service installed. I have created the catalog and have a test page using these posts:...
2
by: rajsrmc | last post by:
Hello pals i have connected mysql table in gridview, how to do search by using the particular word from the text box and suggest any ways to get the result in grid view Please send some...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.