Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: SQL-Server
Hello,
I have Table like
 
name| skills | area |
________________________
ajay| .net,wcf | hyd
ram | java,.net| bang


I want to find who have candidates skills like java,dot in stored procedure
can u guide or end any snippets in front my application i am using textbox for for giving input like java,.net
Posted 22-Nov-12 2:54am
kingsa1.5K
v2
Comments
Milind_T at 22-Nov-12 9:11am
   
Why are you reposting the question:
http://www.codeproject.com/Questions/497345/Howplustoplusretriveplustheseplustypeplusofplusdat
?

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You can do it...but it's not easy, particularly if you don't store skills in any particular order. You can use the LIKE condition to pick up one skill:
SELECT name FROM myTable WHERE skills LIKE '%.net%'
would pick up both lines, but for multiple skills it's a PITA.
 
I would change the way you stored skills - have a Skills table, which has a name (".NET", "Java", ...) and an ID, then have a separate table linking the client to a skill (via the client ID). THis way, you can retrieve all those who have multiple skills much, much =more efficiently (And you can't spell "java" as "jova" by mistake when doing data entry and miss some one out for a position)
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 369
1 Sergey Alexandrovich Kryukov 284
2 Maciej Los 260
3 George Jonsson 195
4 King_Fisher 160
0 Sergey Alexandrovich Kryukov 10,899
1 Maciej Los 5,594
2 OriginalGriff 5,544
3 CPallini 3,819
4 BillWoodruff 3,579


Advertise | Privacy | Mobile
Web03 | 2.8.141030.1 | Last Updated 22 Nov 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100