Solved

Search with +

Posted on 1998-09-23
4
234 Views
Last Modified: 2010-03-19
If I want to use "+" in search function (t.ex USA + Job), how can I do??
0
Comment
Question by:ruisun
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 7

Expert Comment

by:spiridonov
ID: 1090230
Could you explain more details
0
 

Author Comment

by:ruisun
ID: 1090231
Thank U for U answer the question!!
It is like this: I think I know how to search in a table "SELECT * from Name Where columname=Keyword"
But now I want that I can search in a table not just by one keyword , but by two. or more
T.ex. I want to search something match two keyword by writing: keyword1 + keyword2  in the search form  Like I do it in "Yahoo", I want to know how can I write script??  
0
 

Expert Comment

by:manish77
ID: 1090232
ARE YOU LOOKING FOR PARTIAL SEARCH ON BOTH KEYWORDS??
0
 
LVL 2

Accepted Solution

by:
formula earned 50 total points
ID: 1090233
Using your one keyword example, here are some other options:

 Your example: SELECT * from Name Where columname=Keyword
1) select * from Name where columnname="Keyword1" or
   columnname="keyword2" (returns records where columnname is
                          keyword1 or keyword2)
2) select * from Name where columnname in ("keyword1","keyword2")
   (Same as 1)
3) select * from Name where columnname like "%keyword1%" or
   columnname like "%keyword2%" (Columnname contains keyword1 or
                                 keyword2, but not both)
4) select * from Name where columnname like "%keyword1%" or
   columnname like "%keyword2%" (Columnname contains keyword1
                                  and keyword2)
5) select * from Name where columnname like "%keyword1%keyword2%"
   (Contains keyword1 and keyword2 in that order)
6) select * from Name where columnname like "%keyword2%keyword1%"
   (Contains keyword2 and keyword1 in that order)

It hope this gives you the choices you need. If not send more
specific info on your problem.


0

Featured Post

Edgartown IT Case Study

Learn about Edgartown's quest to ensure the safety and security of the entire town's employee and citizen data. Read the case study!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction SQL Server Integration Services can read XML files, that’s known by every BI developer.  (If you didn’t, don’t worry, I’m aiming this article at newcomers as well.) But how far can you go?  When does the XML Source component become …
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question