title: How do I create a copy of some columns of a CSV file in Ruby with different data in one column?
body: <p>I have a CSV file called "A.csv". I need to generate a new CSV file called "B.csv" with data from "A.csv".</p>
  
  <p>I will be using a subset of columns from "A.csv" and will have to update one column's values to new values in "B.csv". Ultimately, I will use this data from B.csv to validate against a database.</p>
  
  <ol>
  <li>How do I create a new CSV file?</li>
  <li>How do I copy the required columns' data from A.csv to "B.csv"?</li>
  <li>How do I append values for a particular column?</li>
  </ol>
  
  <p>I am new to Ruby, but I am able to read CSV to get an array or hash.</p>