瀏覽代碼

查询添加直接传递table

yjp 3 月之前
父節點
當前提交
38a7fc8ac3
共有 5 個文件被更改,包括 148 次插入131 次删除
  1. 4 0
      client/client_query_request.go
  2. 6 0
      dpsv1/client.go
  3. 135 102
      pb/v1/request/query.pb.go
  4. 0 24
      pb/v1/request/query.validator.pb.go
  5. 3 5
      test/v1/v1_test.go

+ 4 - 0
client/client_query_request.go

@@ -2,6 +2,7 @@ package client
 
 type QueryByWhereAndOrderByRequest struct {
 	TablePrefixWithSchema string
+	Table                 string
 	Version               string
 	Select                *Clause
 	Where                 *Clause
@@ -12,6 +13,7 @@ type QueryByWhereAndOrderByRequest struct {
 
 type CommonQueryRequest struct {
 	TablePrefixWithSchema string
+	Table                 string
 	Version               string
 	Select                *Clause
 	Where                 *Clause
@@ -33,12 +35,14 @@ type QueryByKeysRequest struct {
 
 type CountWhereRequest struct {
 	TablePrefixWithSchema string
+	Table                 string
 	Version               string
 	Where                 *Clause
 }
 
 type CommonCountRequest struct {
 	TablePrefixWithSchema string
+	Table                 string
 	Version               string
 	Where                 *Clause
 	Or                    *Clause

+ 6 - 0
dpsv1/client.go

@@ -336,6 +336,7 @@ func (c *Client) QueryByWhereAndOrderBy(req *client.QueryByWhereAndOrderByReques
 	reply, err := c.queryServiceClient.QueryByWhereAndOrderBy(context.Background(), &request.QueryByWhereAndOrderByRequest{
 		DatabaseID:            c.databaseID,
 		TablePrefixWithSchema: req.TablePrefixWithSchema,
+		Table:                 req.Table,
 		Version:               req.Version,
 		Select:                selectJsonBytes,
 		Where:                 whereJsonBytes,
@@ -409,6 +410,7 @@ func (c *Client) CommonQuery(req *client.CommonQueryRequest) (string, []client.T
 	reply, err := c.queryServiceClient.CommonQuery(context.Background(), &request.CommonQueryRequest{
 		DatabaseID:            c.databaseID,
 		TablePrefixWithSchema: req.TablePrefixWithSchema,
+		Table:                 req.Table,
 		Version:               req.Version,
 		Select:                selectJsonBytes,
 		Where:                 whereJsonBytes,
@@ -456,6 +458,7 @@ func (c *Client) QueryOnlyByWhereAndOrderBy(req *client.QueryByWhereAndOrderByRe
 	reply, err := c.queryServiceClient.QueryOnlyByWhereAndOrderBy(context.Background(), &request.QueryByWhereAndOrderByRequest{
 		DatabaseID:            c.databaseID,
 		TablePrefixWithSchema: req.TablePrefixWithSchema,
+		Table:                 req.Table,
 		Version:               req.Version,
 		Select:                selectJsonBytes,
 		Where:                 whereJsonBytes,
@@ -529,6 +532,7 @@ func (c *Client) CommonQueryOnly(req *client.CommonQueryRequest) (string, []clie
 	reply, err := c.queryServiceClient.CommonQueryOnly(context.Background(), &request.CommonQueryRequest{
 		DatabaseID:            c.databaseID,
 		TablePrefixWithSchema: req.TablePrefixWithSchema,
+		Table:                 req.Table,
 		Version:               req.Version,
 		Select:                selectJsonBytes,
 		Where:                 whereJsonBytes,
@@ -598,6 +602,7 @@ func (c *Client) CountWhere(req *client.CountWhereRequest) (string, int64, error
 	reply, err := c.queryServiceClient.CountWhere(context.Background(), &request.CountWhereRequest{
 		DatabaseID:            c.databaseID,
 		TablePrefixWithSchema: req.TablePrefixWithSchema,
+		Table:                 req.Table,
 		Version:               req.Version,
 		Where:                 whereJsonBytes,
 	})
@@ -652,6 +657,7 @@ func (c *Client) CommonCount(req *client.CommonCountRequest) (string, int64, err
 	reply, err := c.queryServiceClient.CommonCount(context.Background(), &request.CommonCountRequest{
 		DatabaseID:            c.databaseID,
 		TablePrefixWithSchema: req.TablePrefixWithSchema,
+		Table:                 req.Table,
 		Version:               req.Version,
 		Where:                 whereJsonBytes,
 		Or:                    orJsonBytes,

+ 135 - 102
pb/v1/request/query.pb.go

@@ -29,11 +29,12 @@ type QueryByWhereAndOrderByRequest struct {
 	DatabaseID            string   `protobuf:"bytes,1,opt,name=DatabaseID,proto3" json:"DatabaseID,omitempty"`
 	TablePrefixWithSchema string   `protobuf:"bytes,2,opt,name=TablePrefixWithSchema,proto3" json:"TablePrefixWithSchema,omitempty"`
 	Version               string   `protobuf:"bytes,3,opt,name=Version,proto3" json:"Version,omitempty"`
-	Select                []byte   `protobuf:"bytes,4,opt,name=Select,proto3" json:"Select,omitempty"`
-	Where                 []byte   `protobuf:"bytes,5,opt,name=Where,proto3" json:"Where,omitempty"`
-	OrderBy               []string `protobuf:"bytes,6,rep,name=OrderBy,proto3" json:"OrderBy,omitempty"`
-	PageNo                int32    `protobuf:"varint,7,opt,name=PageNo,proto3" json:"PageNo,omitempty"`
-	PageSize              int32    `protobuf:"varint,8,opt,name=PageSize,proto3" json:"PageSize,omitempty"`
+	Table                 string   `protobuf:"bytes,4,opt,name=Table,proto3" json:"Table,omitempty"`
+	Select                []byte   `protobuf:"bytes,5,opt,name=Select,proto3" json:"Select,omitempty"`
+	Where                 []byte   `protobuf:"bytes,6,opt,name=Where,proto3" json:"Where,omitempty"`
+	OrderBy               []string `protobuf:"bytes,7,rep,name=OrderBy,proto3" json:"OrderBy,omitempty"`
+	PageNo                int32    `protobuf:"varint,8,opt,name=PageNo,proto3" json:"PageNo,omitempty"`
+	PageSize              int32    `protobuf:"varint,9,opt,name=PageSize,proto3" json:"PageSize,omitempty"`
 }
 
 func (x *QueryByWhereAndOrderByRequest) Reset() {
@@ -89,6 +90,13 @@ func (x *QueryByWhereAndOrderByRequest) GetVersion() string {
 	return ""
 }
 
+func (x *QueryByWhereAndOrderByRequest) GetTable() string {
+	if x != nil {
+		return x.Table
+	}
+	return ""
+}
+
 func (x *QueryByWhereAndOrderByRequest) GetSelect() []byte {
 	if x != nil {
 		return x.Select
@@ -132,15 +140,16 @@ type CommonQueryRequest struct {
 	DatabaseID            string   `protobuf:"bytes,1,opt,name=DatabaseID,proto3" json:"DatabaseID,omitempty"`
 	TablePrefixWithSchema string   `protobuf:"bytes,2,opt,name=TablePrefixWithSchema,proto3" json:"TablePrefixWithSchema,omitempty"`
 	Version               string   `protobuf:"bytes,3,opt,name=Version,proto3" json:"Version,omitempty"`
-	Select                []byte   `protobuf:"bytes,4,opt,name=Select,proto3" json:"Select,omitempty"`
-	Where                 []byte   `protobuf:"bytes,5,opt,name=Where,proto3" json:"Where,omitempty"`
-	OrderBy               []string `protobuf:"bytes,6,rep,name=OrderBy,proto3" json:"OrderBy,omitempty"`
-	Or                    []byte   `protobuf:"bytes,7,opt,name=Or,proto3" json:"Or,omitempty"`
-	GroupBy               []string `protobuf:"bytes,8,rep,name=GroupBy,proto3" json:"GroupBy,omitempty"`
-	Joins                 []byte   `protobuf:"bytes,9,opt,name=Joins,proto3" json:"Joins,omitempty"`
-	Having                []byte   `protobuf:"bytes,10,opt,name=Having,proto3" json:"Having,omitempty"`
-	PageNo                int32    `protobuf:"varint,11,opt,name=PageNo,proto3" json:"PageNo,omitempty"`
-	PageSize              int32    `protobuf:"varint,12,opt,name=PageSize,proto3" json:"PageSize,omitempty"`
+	Table                 string   `protobuf:"bytes,4,opt,name=Table,proto3" json:"Table,omitempty"`
+	Select                []byte   `protobuf:"bytes,5,opt,name=Select,proto3" json:"Select,omitempty"`
+	Where                 []byte   `protobuf:"bytes,6,opt,name=Where,proto3" json:"Where,omitempty"`
+	OrderBy               []string `protobuf:"bytes,7,rep,name=OrderBy,proto3" json:"OrderBy,omitempty"`
+	Or                    []byte   `protobuf:"bytes,8,opt,name=Or,proto3" json:"Or,omitempty"`
+	GroupBy               []string `protobuf:"bytes,9,rep,name=GroupBy,proto3" json:"GroupBy,omitempty"`
+	Joins                 []byte   `protobuf:"bytes,10,opt,name=Joins,proto3" json:"Joins,omitempty"`
+	Having                []byte   `protobuf:"bytes,11,opt,name=Having,proto3" json:"Having,omitempty"`
+	PageNo                int32    `protobuf:"varint,12,opt,name=PageNo,proto3" json:"PageNo,omitempty"`
+	PageSize              int32    `protobuf:"varint,13,opt,name=PageSize,proto3" json:"PageSize,omitempty"`
 }
 
 func (x *CommonQueryRequest) Reset() {
@@ -196,6 +205,13 @@ func (x *CommonQueryRequest) GetVersion() string {
 	return ""
 }
 
+func (x *CommonQueryRequest) GetTable() string {
+	if x != nil {
+		return x.Table
+	}
+	return ""
+}
+
 func (x *CommonQueryRequest) GetSelect() []byte {
 	if x != nil {
 		return x.Select
@@ -354,7 +370,8 @@ type CountWhereRequest struct {
 	DatabaseID            string `protobuf:"bytes,1,opt,name=DatabaseID,proto3" json:"DatabaseID,omitempty"`
 	TablePrefixWithSchema string `protobuf:"bytes,2,opt,name=TablePrefixWithSchema,proto3" json:"TablePrefixWithSchema,omitempty"`
 	Version               string `protobuf:"bytes,3,opt,name=Version,proto3" json:"Version,omitempty"`
-	Where                 []byte `protobuf:"bytes,4,opt,name=Where,proto3" json:"Where,omitempty"`
+	Table                 string `protobuf:"bytes,4,opt,name=Table,proto3" json:"Table,omitempty"`
+	Where                 []byte `protobuf:"bytes,5,opt,name=Where,proto3" json:"Where,omitempty"`
 }
 
 func (x *CountWhereRequest) Reset() {
@@ -410,6 +427,13 @@ func (x *CountWhereRequest) GetVersion() string {
 	return ""
 }
 
+func (x *CountWhereRequest) GetTable() string {
+	if x != nil {
+		return x.Table
+	}
+	return ""
+}
+
 func (x *CountWhereRequest) GetWhere() []byte {
 	if x != nil {
 		return x.Where
@@ -425,11 +449,12 @@ type CommonCountRequest struct {
 	DatabaseID            string   `protobuf:"bytes,1,opt,name=DatabaseID,proto3" json:"DatabaseID,omitempty"`
 	TablePrefixWithSchema string   `protobuf:"bytes,2,opt,name=TablePrefixWithSchema,proto3" json:"TablePrefixWithSchema,omitempty"`
 	Version               string   `protobuf:"bytes,3,opt,name=Version,proto3" json:"Version,omitempty"`
-	Where                 []byte   `protobuf:"bytes,4,opt,name=Where,proto3" json:"Where,omitempty"`
-	Or                    []byte   `protobuf:"bytes,5,opt,name=Or,proto3" json:"Or,omitempty"`
-	GroupBy               []string `protobuf:"bytes,6,rep,name=GroupBy,proto3" json:"GroupBy,omitempty"`
-	Joins                 []byte   `protobuf:"bytes,7,opt,name=Joins,proto3" json:"Joins,omitempty"`
-	Having                []byte   `protobuf:"bytes,8,opt,name=Having,proto3" json:"Having,omitempty"`
+	Table                 string   `protobuf:"bytes,4,opt,name=Table,proto3" json:"Table,omitempty"`
+	Where                 []byte   `protobuf:"bytes,5,opt,name=Where,proto3" json:"Where,omitempty"`
+	Or                    []byte   `protobuf:"bytes,6,opt,name=Or,proto3" json:"Or,omitempty"`
+	GroupBy               []string `protobuf:"bytes,7,rep,name=GroupBy,proto3" json:"GroupBy,omitempty"`
+	Joins                 []byte   `protobuf:"bytes,8,opt,name=Joins,proto3" json:"Joins,omitempty"`
+	Having                []byte   `protobuf:"bytes,9,opt,name=Having,proto3" json:"Having,omitempty"`
 }
 
 func (x *CommonCountRequest) Reset() {
@@ -485,6 +510,13 @@ func (x *CommonCountRequest) GetVersion() string {
 	return ""
 }
 
+func (x *CommonCountRequest) GetTable() string {
+	if x != nil {
+		return x.Table
+	}
+	return ""
+}
+
 func (x *CommonCountRequest) GetWhere() []byte {
 	if x != nil {
 		return x.Where
@@ -528,96 +560,97 @@ var file_v1_request_query_proto_rawDesc = []byte{
 	0x74, 0x1a, 0x36, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6d, 0x77,
 	0x69, 0x74, 0x6b, 0x6f, 0x77, 0x2f, 0x67, 0x6f, 0x2d, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2d, 0x76,
 	0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x2f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61,
-	0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa3, 0x02, 0x0a, 0x1d, 0x51, 0x75,
+	0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa9, 0x02, 0x0a, 0x1d, 0x51, 0x75,
 	0x65, 0x72, 0x79, 0x42, 0x79, 0x57, 0x68, 0x65, 0x72, 0x65, 0x41, 0x6e, 0x64, 0x4f, 0x72, 0x64,
 	0x65, 0x72, 0x42, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x44,
 	0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42,
 	0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73,
-	0x65, 0x49, 0x44, 0x12, 0x3c, 0x0a, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66,
+	0x65, 0x49, 0x44, 0x12, 0x34, 0x0a, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66,
 	0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02, 0x20, 0x01,
-	0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x15, 0x54, 0x61, 0x62, 0x6c,
-	0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d,
-	0x61, 0x12, 0x20, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01,
-	0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x07, 0x56, 0x65, 0x72, 0x73,
-	0x69, 0x6f, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x18, 0x04, 0x20,
-	0x01, 0x28, 0x0c, 0x52, 0x06, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x57,
-	0x68, 0x65, 0x72, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x57, 0x68, 0x65, 0x72,
-	0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x79, 0x18, 0x06, 0x20, 0x03,
-	0x28, 0x09, 0x52, 0x07, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x50,
-	0x61, 0x67, 0x65, 0x4e, 0x6f, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x50, 0x61, 0x67,
-	0x65, 0x4e, 0x6f, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18,
-	0x08, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x22,
-	0xf0, 0x02, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52,
-	0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61,
-	0x73, 0x65, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02,
-	0x58, 0x01, 0x52, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44, 0x12, 0x3c,
-	0x0a, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74,
-	0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2,
-	0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66,
-	0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x20, 0x0a, 0x07,
-	0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2,
-	0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x16,
-	0x0a, 0x06, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06,
-	0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x18,
-	0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07,
-	0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x79, 0x18, 0x06, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x4f,
-	0x72, 0x64, 0x65, 0x72, 0x42, 0x79, 0x12, 0x0e, 0x0a, 0x02, 0x4f, 0x72, 0x18, 0x07, 0x20, 0x01,
-	0x28, 0x0c, 0x52, 0x02, 0x4f, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x42,
-	0x79, 0x18, 0x08, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x42, 0x79,
-	0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x69, 0x6e, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0c, 0x52,
-	0x05, 0x4a, 0x6f, 0x69, 0x6e, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x48, 0x61, 0x76, 0x69, 0x6e, 0x67,
-	0x18, 0x0a, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x48, 0x61, 0x76, 0x69, 0x6e, 0x67, 0x12, 0x16,
-	0x0a, 0x06, 0x50, 0x61, 0x67, 0x65, 0x4e, 0x6f, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06,
-	0x50, 0x61, 0x67, 0x65, 0x4e, 0x6f, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69,
-	0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69,
-	0x7a, 0x65, 0x22, 0x82, 0x02, 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x79, 0x4b, 0x65,
-	0x79, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x44, 0x61, 0x74,
+	0x28, 0x09, 0x52, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57,
+	0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x56, 0x65, 0x72,
+	0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x56, 0x65, 0x72, 0x73,
+	0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01,
+	0x28, 0x09, 0x52, 0x05, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x65, 0x6c,
+	0x65, 0x63, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x53, 0x65, 0x6c, 0x65, 0x63,
+	0x74, 0x12, 0x14, 0x0a, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0c,
+	0x52, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x72, 0x64, 0x65, 0x72,
+	0x42, 0x79, 0x18, 0x07, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42,
+	0x79, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61, 0x67, 0x65, 0x4e, 0x6f, 0x18, 0x08, 0x20, 0x01, 0x28,
+	0x05, 0x52, 0x06, 0x50, 0x61, 0x67, 0x65, 0x4e, 0x6f, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x67,
+	0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x50, 0x61, 0x67,
+	0x65, 0x53, 0x69, 0x7a, 0x65, 0x22, 0xf6, 0x02, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e,
+	0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0a,
+	0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
+	0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61,
+	0x73, 0x65, 0x49, 0x44, 0x12, 0x34, 0x0a, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65,
+	0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78,
+	0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x56, 0x65,
+	0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x56, 0x65, 0x72,
+	0x73, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x65,
+	0x6c, 0x65, 0x63, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x53, 0x65, 0x6c, 0x65,
+	0x63, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28,
+	0x0c, 0x52, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x72, 0x64, 0x65,
+	0x72, 0x42, 0x79, 0x18, 0x07, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x72, 0x64, 0x65, 0x72,
+	0x42, 0x79, 0x12, 0x0e, 0x0a, 0x02, 0x4f, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x02,
+	0x4f, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x42, 0x79, 0x18, 0x09, 0x20,
+	0x03, 0x28, 0x09, 0x52, 0x07, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x42, 0x79, 0x12, 0x14, 0x0a, 0x05,
+	0x4a, 0x6f, 0x69, 0x6e, 0x73, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x4a, 0x6f, 0x69,
+	0x6e, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x48, 0x61, 0x76, 0x69, 0x6e, 0x67, 0x18, 0x0b, 0x20, 0x01,
+	0x28, 0x0c, 0x52, 0x06, 0x48, 0x61, 0x76, 0x69, 0x6e, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61,
+	0x67, 0x65, 0x4e, 0x6f, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x50, 0x61, 0x67, 0x65,
+	0x4e, 0x6f, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0d,
+	0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x22, 0x82,
+	0x02, 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x79, 0x4b, 0x65, 0x79, 0x73, 0x52, 0x65,
+	0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73,
+	0x65, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58,
+	0x01, 0x52, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44, 0x12, 0x3c, 0x0a,
+	0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68,
+	0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf,
+	0x1f, 0x02, 0x58, 0x01, 0x52, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69,
+	0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x20, 0x0a, 0x07, 0x56,
+	0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf,
+	0x1f, 0x02, 0x58, 0x01, 0x52, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x16, 0x0a,
+	0x06, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x53,
+	0x65, 0x6c, 0x65, 0x63, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x4b, 0x65, 0x79, 0x43, 0x6f, 0x6c, 0x75,
+	0x6d, 0x6e, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x70,
+	0x00, 0x52, 0x0a, 0x4b, 0x65, 0x79, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x12, 0x24, 0x0a,
+	0x09, 0x4b, 0x65, 0x79, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x09,
+	0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x70, 0x00, 0x52, 0x09, 0x4b, 0x65, 0x79, 0x56, 0x61, 0x6c,
+	0x75, 0x65, 0x73, 0x22, 0xb7, 0x01, 0x0a, 0x11, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x57, 0x68, 0x65,
+	0x72, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x44, 0x61, 0x74,
 	0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2,
 	0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49,
-	0x44, 0x12, 0x3c, 0x0a, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78,
+	0x44, 0x12, 0x34, 0x0a, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78,
 	0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
-	0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50,
-	0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12,
-	0x20, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
-	0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f,
-	0x6e, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28,
-	0x0c, 0x52, 0x06, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x4b, 0x65, 0x79,
-	0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x42, 0x06, 0xe2,
-	0xdf, 0x1f, 0x02, 0x70, 0x00, 0x52, 0x0a, 0x4b, 0x65, 0x79, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e,
-	0x73, 0x12, 0x24, 0x0a, 0x09, 0x4b, 0x65, 0x79, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x06,
-	0x20, 0x03, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x70, 0x00, 0x52, 0x09, 0x4b, 0x65,
-	0x79, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x22, 0xb1, 0x01, 0x0a, 0x11, 0x43, 0x6f, 0x75, 0x6e,
-	0x74, 0x57, 0x68, 0x65, 0x72, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x26, 0x0a,
-	0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28,
-	0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62,
-	0x61, 0x73, 0x65, 0x49, 0x44, 0x12, 0x3c, 0x0a, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72,
-	0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02,
-	0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x15, 0x54, 0x61,
-	0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68,
-	0x65, 0x6d, 0x61, 0x12, 0x20, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03,
-	0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x07, 0x56, 0x65,
-	0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x18, 0x04,
-	0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x22, 0x8a, 0x02, 0x0a, 0x12,
-	0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65,
-	0x73, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44,
-	0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01, 0x52, 0x0a,
-	0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44, 0x12, 0x3c, 0x0a, 0x15, 0x54, 0x61,
-	0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68,
-	0x65, 0x6d, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58,
-	0x01, 0x52, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69,
-	0x74, 0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x20, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73,
-	0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58,
-	0x01, 0x52, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x57, 0x68,
-	0x65, 0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65,
-	0x12, 0x0e, 0x0a, 0x02, 0x4f, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x02, 0x4f, 0x72,
-	0x12, 0x18, 0x0a, 0x07, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x42, 0x79, 0x18, 0x06, 0x20, 0x03, 0x28,
-	0x09, 0x52, 0x07, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x42, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f,
-	0x69, 0x6e, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x4a, 0x6f, 0x69, 0x6e, 0x73,
-	0x12, 0x16, 0x0a, 0x06, 0x48, 0x61, 0x76, 0x69, 0x6e, 0x67, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c,
-	0x52, 0x06, 0x48, 0x61, 0x76, 0x69, 0x6e, 0x67, 0x42, 0x20, 0x5a, 0x1e, 0x64, 0x70, 0x73, 0x2f,
-	0x61, 0x70, 0x69, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x5f, 0x61, 0x70, 0x69, 0x2f, 0x70, 0x62, 0x2f,
-	0x76, 0x31, 0x2f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
-	0x6f, 0x33,
+	0x52, 0x15, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74,
+	0x68, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69,
+	0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f,
+	0x6e, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09,
+	0x52, 0x05, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65,
+	0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x22, 0x90, 0x02,
+	0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71,
+	0x75, 0x65, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65,
+	0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe2, 0xdf, 0x1f, 0x02, 0x58, 0x01,
+	0x52, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x49, 0x44, 0x12, 0x34, 0x0a, 0x15,
+	0x54, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53,
+	0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x15, 0x54, 0x61, 0x62,
+	0x6c, 0x65, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x57, 0x69, 0x74, 0x68, 0x53, 0x63, 0x68, 0x65,
+	0x6d, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05,
+	0x54, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x61, 0x62,
+	0x6c, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28,
+	0x0c, 0x52, 0x05, 0x57, 0x68, 0x65, 0x72, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x4f, 0x72, 0x18, 0x06,
+	0x20, 0x01, 0x28, 0x0c, 0x52, 0x02, 0x4f, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x47, 0x72, 0x6f, 0x75,
+	0x70, 0x42, 0x79, 0x18, 0x07, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x47, 0x72, 0x6f, 0x75, 0x70,
+	0x42, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x69, 0x6e, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28,
+	0x0c, 0x52, 0x05, 0x4a, 0x6f, 0x69, 0x6e, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x48, 0x61, 0x76, 0x69,
+	0x6e, 0x67, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x48, 0x61, 0x76, 0x69, 0x6e, 0x67,
+	0x42, 0x20, 0x5a, 0x1e, 0x64, 0x70, 0x73, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x72, 0x70, 0x63,
+	0x5f, 0x61, 0x70, 0x69, 0x2f, 0x70, 0x62, 0x2f, 0x76, 0x31, 0x2f, 0x72, 0x65, 0x71, 0x75, 0x65,
+	0x73, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 
 var (

+ 0 - 24
pb/v1/request/query.validator.pb.go

@@ -20,24 +20,12 @@ func (this *QueryByWhereAndOrderByRequest) Validate() error {
 	if this.DatabaseID == "" {
 		return github_com_mwitkow_go_proto_validators.FieldError("DatabaseID", fmt.Errorf(`value '%v' must not be an empty string`, this.DatabaseID))
 	}
-	if this.TablePrefixWithSchema == "" {
-		return github_com_mwitkow_go_proto_validators.FieldError("TablePrefixWithSchema", fmt.Errorf(`value '%v' must not be an empty string`, this.TablePrefixWithSchema))
-	}
-	if this.Version == "" {
-		return github_com_mwitkow_go_proto_validators.FieldError("Version", fmt.Errorf(`value '%v' must not be an empty string`, this.Version))
-	}
 	return nil
 }
 func (this *CommonQueryRequest) Validate() error {
 	if this.DatabaseID == "" {
 		return github_com_mwitkow_go_proto_validators.FieldError("DatabaseID", fmt.Errorf(`value '%v' must not be an empty string`, this.DatabaseID))
 	}
-	if this.TablePrefixWithSchema == "" {
-		return github_com_mwitkow_go_proto_validators.FieldError("TablePrefixWithSchema", fmt.Errorf(`value '%v' must not be an empty string`, this.TablePrefixWithSchema))
-	}
-	if this.Version == "" {
-		return github_com_mwitkow_go_proto_validators.FieldError("Version", fmt.Errorf(`value '%v' must not be an empty string`, this.Version))
-	}
 	return nil
 }
 func (this *QueryByKeysRequest) Validate() error {
@@ -66,23 +54,11 @@ func (this *CountWhereRequest) Validate() error {
 	if this.DatabaseID == "" {
 		return github_com_mwitkow_go_proto_validators.FieldError("DatabaseID", fmt.Errorf(`value '%v' must not be an empty string`, this.DatabaseID))
 	}
-	if this.TablePrefixWithSchema == "" {
-		return github_com_mwitkow_go_proto_validators.FieldError("TablePrefixWithSchema", fmt.Errorf(`value '%v' must not be an empty string`, this.TablePrefixWithSchema))
-	}
-	if this.Version == "" {
-		return github_com_mwitkow_go_proto_validators.FieldError("Version", fmt.Errorf(`value '%v' must not be an empty string`, this.Version))
-	}
 	return nil
 }
 func (this *CommonCountRequest) Validate() error {
 	if this.DatabaseID == "" {
 		return github_com_mwitkow_go_proto_validators.FieldError("DatabaseID", fmt.Errorf(`value '%v' must not be an empty string`, this.DatabaseID))
 	}
-	if this.TablePrefixWithSchema == "" {
-		return github_com_mwitkow_go_proto_validators.FieldError("TablePrefixWithSchema", fmt.Errorf(`value '%v' must not be an empty string`, this.TablePrefixWithSchema))
-	}
-	if this.Version == "" {
-		return github_com_mwitkow_go_proto_validators.FieldError("Version", fmt.Errorf(`value '%v' must not be an empty string`, this.Version))
-	}
 	return nil
 }

+ 3 - 5
test/v1/v1_test.go

@@ -348,9 +348,8 @@ func TestTransactionBatch(t *testing.T) {
 		}, &count).
 		assertEqual(int64(0), count, "数量不一致").
 		countWhere(&client.CountWhereRequest{
-			TablePrefixWithSchema: tablePrefix,
-			Version:               "v1",
-			Where:                 client.NewClause().Equal("id", id2),
+			Table: tablePrefix + "_snaps_v1",
+			Where: client.NewClause().Equal("id", id2),
 		}, &count).
 		assertEqual(int64(0), count, "数量不一致")
 }
@@ -468,8 +467,7 @@ func TestInsertBatch(t *testing.T) {
 		assertEqual(now1.Unix(), resultTableRows[0].ColumnValueTime("time").Unix(), "时间不一致").
 		assertEqual(tableNum1, resultTableRows[0].ColumnValueInt("table_num"), "表数量不一致").
 		commonQuery(&client.CommonQueryRequest{
-			TablePrefixWithSchema: tablePrefix,
-			Version:               "v1",
+			Table: tablePrefix + "_snaps_v1",
 			Where: client.NewClause().
 				Equal("id", id2).
 				Equal("name", name2).