Home Forums SQL Server 2008 T-SQL (SS2K8) Need help on Update statment with where condition RE: Need help on Update statment with where condition

  • LutzM (8/23/2014)


    What are you trying to do?

    Your description is rather vague...

    For instance, what do you mean by

    Where idx=34, Numeric in ApplyJob (3) EXIST in r_ApplyJob --> SET score=10

    ??

    For that idx value there's no '3' in r_ApplyJob. Why change the core?

    Why do you store numeric values as a list in a single column?

    This is my explanation sir..

    1- Idx is a primary key

    2- Whatever numeric in ApplyJob that EXISTS in r_ApplyJob, please set score=10

    3- ApplyJob format is using

    SELECT [CVID]

    , STUFF((SELECT ', ' + Convert(varchar(10),A.[JobNoticeID])

    FROM JobNoticeCV A

    Where A.[CVID]=B.[CVID] FOR XML PATH('')),1,1,'') As [All_JobNoticeID]

    ..........

    How to check figure in ApplyJob is EXISTS in r_ApplyJob?? If one of figure is found, then set SCORE = 10