一个用C++编写的protobuf生成SQL语句的SQL插件
- 资源大小:1.01 MB
- 上传时间:2021-06-29
- 下载次数:0次
- 浏览次数:1次
- 资源积分:1积分
-
标 签:
资 源 简 介
This is a sql plugin for protobuf to generate sql statement from .proto file with some user defined options. And I define the options in the file named "MyOptions.proto" which including message option and field options. Now it can only generate create table sql statement.
usage: protoc.exe --proto_path="." --plugin=protoc-gen-sql="sql_plugin.exe" --sql_out="." Table.Role.proto (Table.Role.proto is your proto file that defines the database table)
文 件 列 表
google
protobuf
MyOptions.pb.cc
MyOptions.pb.h
MyOptions.proto
protobuf_sql.bat
protoc.exe
sql_generator.cpp
sql_generator.h
sql_plugin.cpp
sql_plugin.exe
Table.Role.proto
Table.Role.sql