title: Cannot resolve the collation conflict between "Latin1_General_CI_AI" and "SQL_Latin1_General_CP1_CI_AS" in the equal to operation
body: <p>I am trying to create a procedure in SQL Server 2008R2 but it is showing this error</p>
  
  <blockquote>
    <p>Cannot resolve the collation conflict between "Latin1_General_CI_AI"
    and "SQL_Latin1_General_CP1_CI_AS" in the equal to operation.</p>
  </blockquote>
  
  <p>The procedure that I have created is</p>
  
  <pre><code>CREATE Procedure Ps_Quiz_OnlineTest_QuestionsWithOptions_Get --'Ques1'
    @Ques Varchar(8000)
  As        
  Begin
  
    Select 
      A.QuestionId, 
      A.QsnDesc, 
      A.CorrectOption, 
      B.OptionValue, 
      A.Marks,
      (
        Select QsnName 
        From Quiz_tblQsnsLimitMaster
        Where QsnId = @Ques) QuesPaper,
      (
        Select Durationoftest 
        From Quiz_tblQsnsLimitMaster
        Where QsnId = @Ques) QuesPaper
      From 
        Quiz_tblQsnCreationMaster A, 
        Quiz_tblQsnCreationDetail B        
      Where 
        A.QuestionId = B.QuestionId
        And A.QuestionId In (
          Select QuestionIds 
          From FN_Question_Answers_Quiz(@Ques))
        And B.QuestionId In (
          Select QuestionIds 
          From FN_Question_Answers_Quiz(@Ques))  
      Order By 
        A.QuestionId, 
        B.OptionOrder 
  
  End    
  </code></pre>
  
  <p>I tried to collate tables with different collations but it did not worked.
  How can I solve this.</p>