title: BIGQUERY csv file load with an additional column with a default value
body: <p>From the example given by Google, I have managed to load CSV files into BigQuery(BQ) table following the guide(link and code below)<br />
  Now I want to add several files into BQ, and want to add a new column <code>filename</code> which contains the filename.</p>
  <p>Is there a way to add column with default data?</p>
  <p><a href="https://cloud.google.com/bigquery/docs/loading-data-cloud-storage-csv" rel="nofollow noreferrer">https://cloud.google.com/bigquery/docs/loading-data-cloud-storage-csv</a></p>
  <pre><code>// Import the Google Cloud client libraries
  const {BigQuery} = require('@google-cloud/bigquery');
  const {Storage} = require('@google-cloud/storage');
  
  // Instantiate clients
  const bigquery = new BigQuery();
  const storage = new Storage();
  
  /**
   * This sample loads the CSV file at
   * https://storage.googleapis.com/cloud-samples-data/bigquery/us-states/us-states.csv
   *
   * TODO(developer): Replace the following lines with the path to your file.
   */
  const bucketName = 'cloud-samples-data';
  const filename = 'bigquery/us-states/us-states.csv';
  
  async function loadCSVFromGCS() {
    // Imports a GCS file into a table with manually defined schema.
  
    /**
     * TODO(developer): Uncomment the following lines before running the sample.
     */
    // const datasetId = 'my_dataset';
    // const tableId = 'my_table';
  
    // Configure the load job. For full list of options, see:
    // https://cloud.google.com/bigquery/docs/reference/rest/v2/Job#JobConfigurationLoad
    const metadata = {
      sourceFormat: 'CSV',
      skipLeadingRows: 1,
      schema: {
        fields: [
          {name: 'name', type: 'STRING'},
          {name: 'post_abbr', type: 'STRING'},
  //      {name: 'filemame', type: 'STRING', value=filename} // I WANT TO ADD COLUMN WITH FILE NAME HERE
        ],
      },
      location: 'US',
    };
  
    // Load data from a Google Cloud Storage file into the table
    const [job] = await bigquery
      .dataset(datasetId)
      .table(tableId)
      .load(storage.bucket(bucketName).file(filename), metadata);
  
    // load() waits for the job to finish
    console.log(`Job ${job.id} completed.`);
  
    // Check the job's status for errors
    const errors = job.status.errors;
    if (errors &amp;&amp; errors.length &gt; 0) {
      throw errors;
    }
  }
  </code></pre>