Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - ASP Site Search
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

ASP Site Search

 Post Reply Post Reply
Author
XandarX View Drop Down
Newbie
Newbie


Joined: 17 December 2004
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote XandarX Quote  Post ReplyReply Direct Link To This Post Topic: ASP Site Search
    Posted: 17 December 2004 at 9:33pm
I have Web Wiz Site Search.  I like the feature of being able to search for multiple terms and have it bring back resulting pages with those terms somewhere on the page.  Can this be adapted to search in this way through an access database?
Back to Top
Gullanian View Drop Down
Senior Member
Senior Member
Avatar

Joined: 04 January 2002
Location: England
Status: Offline
Points: 4373
Post Options Post Options   Thanks (0) Thanks(0)   Quote Gullanian Quote  Post ReplyReply Direct Link To This Post Posted: 18 December 2004 at 5:58am
The problem with searching databases is that everyones database is different.  You need to allow for data which shouldn't be publically viewable, and data which doesn't need to be viewed.  It would probably be best to write your own for your database.
Back to Top
XandarX View Drop Down
Newbie
Newbie


Joined: 17 December 2004
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote XandarX Quote  Post ReplyReply Direct Link To This Post Posted: 18 December 2004 at 1:41pm
I have done so, but it lacks functionality that I don't know how to create.
Example:
Searching for an artists name in a song list.
In the database they are listed as FirstName, LastName and Artist.
The first two fields are obvious as to content.  The third (Artist) is entered in the format of First Name, Last name (with the comma).
If someone searches for "Patsy Cline" it comes up with nothing, but "Cline, Patsy" returns appropriate results.  Unfortunately most people search by first name then last name. 
 
I need a search that finds any and all words in a record.  I don't know how to do it.
Anything you can recommend?
Back to Top
Gullanian View Drop Down
Senior Member
Senior Member
Avatar

Joined: 04 January 2002
Location: England
Status: Offline
Points: 4373
Post Options Post Options   Thanks (0) Thanks(0)   Quote Gullanian Quote  Post ReplyReply Direct Link To This Post Posted: 18 December 2004 at 2:07pm
Well, first of all storing artist when you already have the first name and last name isn't a good idea, it's called data repetition and theres no reason to do it.

You would probably want to split the name into it's corresponding parts then use the SQL 'LIKE' to search for records.

So for example someone typing in 'Patsy Cline', spit it into it's parts using the split() function, dump the results in an array and loop through the array searching for records matching those names.
Back to Top
XandarX View Drop Down
Newbie
Newbie


Joined: 17 December 2004
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote XandarX Quote  Post ReplyReply Direct Link To This Post Posted: 18 December 2004 at 4:52pm
The database comes to me with just the artist field.  Stored as "First name, Last Name".
 
I wrote a query to seperate them into two fields. That worked.
 
I then wrote a search engine to search the database, but I only know how to search through one field at a time, and I don't know how to split the SearchWord into seperate components.  Figures, eh?
 
I'll work on those ideas you offered in the meantime.  I should be able to figure something out.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.