title: Filtering data using IF
body: <p><div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>students(studentID PK, A, B,sec..) FeesStructure(feeStruct PK, feeA, feeB, ..) FeesCollected(FeesID PK,studentID FK,feeStruct FK, A,B,..)</code></pre>
  </div>
  </div>
  </p>
  
  <p>If students.sec = 'A' return FeesStructure.feeA, FeesCollected.A .., etc
  Have to create a view that will return data based on an if. FeesStructure table has feeA, feeB
  which only apply based on a student's sec. I need to return feeA or feeB based on students.sec </p>