risingwavelabs/risingwave · error · SinkError::BigQuery

Don't support Vector

Error message

Don't support Vector

What it means

The BigQuery sink's protobuf schema builder walks the RisingWave schema and refuses to map columns of type Vector into a BigQuery-supported protobuf field. There is no representation for RisingWave vector types in the generated protobuf schema, so build_protobuf_field short-circuits with this config error during sink schema construction.

Source

Thrown at src/connector/src/sink/big_query.rs:1015

        DataType::List(l) => {
            let (mut field, proto) = build_protobuf_field(l.elem(), index, name)?;
            field.label = Some(field_descriptor_proto::Label::Repeated.into());
            return Ok((field, proto));
        }
        DataType::Bytea => field.r#type = Some(field_descriptor_proto::Type::Bytes.into()),
        DataType::Jsonb => field.r#type = Some(field_descriptor_proto::Type::String.into()),
        DataType::Variant => {
            return Err(SinkError::BigQuery(anyhow::anyhow!("Don't support Variant")));
        }
        DataType::Serial => field.r#type = Some(field_descriptor_proto::Type::Int64.into()),
        DataType::Float32 | DataType::Int256 => {
            return Err(SinkError::BigQuery(anyhow::anyhow!(
                "Don't support Float32 and Int256"
            )));
        }
        DataType::Map(_) => return Err(SinkError::BigQuery(anyhow::anyhow!("Don't support Map"))),
        DataType::Vector(_) => {
            return Err(SinkError::BigQuery(anyhow::anyhow!("Don't support Vector")));
        }
    }
    Ok((field, None))
}

#[cfg(test)]
mod test {

    use std::assert_matches;
    use std::collections::HashMap;

    use risingwave_common::catalog::{Field, Schema};
    use risingwave_common::types::{DataType, StructType};

    use crate::connector_common::AwsAuthProps;
    use crate::sink::big_query::{
        BigQueryCommon, BigQueryConfig, BigQuerySink, build_protobuf_descriptor_pool,
        build_protobuf_schema,

View on GitHub (pinned to 6469eb736d)

Solutions

  1. Exclude the vector column by sinking a view that selects only supported columns.
  2. Cast or transform the vector into a supported representation (e.g. array of floats) before sinking.
  3. Use a sink type without protobuf schema building (e.g. different connector) if vector data must be shipped as-is.

Example fix

// before
CREATE SINK bq_sink FROM mv WITH (connector='big_query', ...); -- mv contains vector column
// after
CREATE VIEW mv_no_vec AS SELECT id, payload FROM mv; -- drop the VECTOR column
CREATE SINK bq_sink FROM mv_no_vec WITH (connector='big_query', ...);
Defensive patterns

Strategy: validation

Validate before calling

function assertNoVectorColumns(columns) {
  const bad = columns.filter(c => c.dataType.startsWith('VECTOR'));
  if (bad.length) throw new Error(`Vector columns not sinkable to BigQuery: ${bad.map(c => c.name).join(', ')}`);
}

Type guard

function isVectorColumn(c) { return typeof c.dataType === 'string' && c.dataType.toUpperCase().startsWith('VECTOR'); }

Prevention

When it happens

Trigger: Creating a BigQuery sink whose source/materialized view contains a column of DataType::Vector (e.g. VECTOR or VECTOR(3) columns); the error is raised recursively while build_protobuf_schema builds the field list.

Common situations: Users storing embeddings or similarity-search vectors in RisingWave and attempting to sink the whole table to BigQuery without excluding the vector column.

Related errors


AI-assisted analysis of risingwavelabs/risingwave@6469eb736d (2026-09-11). Data as JSON: /api/errors/e979c17ee272ac55. Report an issue: GitHub.