milvus-io / milvus

A cloud-native vector database, storage for next generation AI applications
https://milvus.io
Apache License 2.0
30.69k stars 2.93k forks source link

[Bug]: [GoSDK] Insert rows data with varchar field gets error: param column varchar has type string but collection field definition is string #33457

Closed ThreadDao closed 1 month ago

ThreadDao commented 5 months ago

Is there an existing issue for this?

Environment

- Milvus version: master-20240528-b138ae74-amd64
- Deployment mode(standalone or cluster):
- MQ type(rocksmq, pulsar or kafka):    
- SDK version(e.g. pymilvus v2.0.0rc2): go-sdk v2
- OS(Ubuntu or CentOS): 
- CPU/Memory: 
- GPU: 
- Others:

Current Behavior

  1. create collection with fields: int64(pk), varchar, sparseVec
  2. insert row and gets error: param column varchar has type string but collection field definition is string

type BaseRow struct { Bool bool json:"bool,omitempty" milvus:"name:bool" Int8 int8 json:"int8,omitempty" milvus:"name:int8" Int16 int16 json:"int16,omitempty" milvus:"name:int16" Int32 int32 json:"int32,omitempty" milvus:"name:int32" Int64 int64 json:"int64,omitempty" milvus:"name:int64" Float float32 json:"float,omitempty" milvus:"name:float" Double float64 json:"double,omitempty" milvus:"name:double" Varchar string json:"varchar,omitempty" milvus:"name:varchar" JSON JSONStruct json:"json,omitempty" milvus:"name:json" FloatVec []float32 json:"floatVec,omitempty" milvus:"name:floatVec" Fp16Vec []byte json:"fp16Vec,omitempty" milvus:"name:fp16Vec" Bf16Vec []byte json:"bf16Vec,omitempty" milvus:"name:bf16Vec" BinaryVec []byte json:"binaryVec,omitempty" milvus:"name:binaryVec" SparseVec entity.SparseEmbedding json:"sparseVec,omitempty" milvus:"name:sparseVec" Array Dynamic }



### Expected Behavior

_No response_

### Steps To Reproduce

_No response_

### Milvus Log

_No response_

### Anything else?

_No response_
ThreadDao commented 4 months ago

fixed

yanliang567 commented 1 month ago

close as comments above