hi developers,

i am developing a s/w that need a search.

i current using "like" for search.

for ex.

select * from Tabl1 where col1 like "% Software Developer %" And Col2 Like "% Software Developer %"

But this is not right way. Am i right.?
Please guide me what will be the right query for search. Can anyone guide me.

Waiting for replies. Please Help asap.

Hi

i have tried something..
Here it is..

Key Word
Software Engineer Sql Server

Query

(JobDesc Like '%Software%'OR JobDesc Like '%Engineer%' OR JobDesc Like '%Sql%' OR JobDesc Like '%Server%' OR JOB_POSTING.KeySkill LIKE '%Software%'OR JOB_POSTING.KeySkill LIKE '%Engineer%' Or JOB_POSTING.KeySkill LIKE'%Sql%'Or JOB_POSTING.KeySkill LIKE'%Server%')

But some what not yet clear.

Please guide

hi

i did this in asp.net to create my query

Dim KeyWord As String
        Dim JobDesc, KeySkill As String
        JobDesc = Strings.Replace(Trim(txtKeyWords.Text), " ", "%' OR JobDesc Like '%")
        KeySkill = Strings.Replace(Trim(txtKeyWords.Text), " ", "%' OR JOB_POSTING.KeySkill LIKE '%")

this will give me some search key word in right format. then i did as ..

SSql &= " where JOB_POSTING.DelFlag='N' and (JobDesc Like '%" & JobDesc & "%' OR "
        SSql &= "  JOB_POSTING.KeySkill LIKE '%" & KeySkill & "%') and "

this is what for actualy query feed :)

Hi sbv,

hi developers,

i am developing a s/w that need a search.

i current using "like" for search.

for ex.

select * from Tabl1 where col1 like "% Software Developer %" And Col2 Like "% Software Developer %"

But this is not right way. Am i right.?
Please guide me what will be the right query for search. Can anyone guide me.

Waiting for replies. Please Help asap.

Your statement is formally correct. Only I would drop the blanks close to the wildcards %.

select * from Tabl1 where col1 like "%Software Developer%" And Col2 Like "%Software Developer%"

Hard to guide you because we don't know your table and your questions exactly.

krs,
tesu

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.