Quick tool access

  • JSON to GO: www.printlove.cn/tools/json2…
  • YAML to GO: www.printlove.cn/tools/yaml2…
  • SQL tO Go-Zero Model: printlove.cn/tools/sql2g…
  • Turn the SQL GORM Model: www.printlove.cn/tools/sql2g…
  • SQL > ElasticSearch DSL: printlove.cn/tools/sql2e…
  • SQL to Entgo schema: printlove.cn/tools/sql2e…

JSON turn to GO

Website: www.printlove.cn/tools/json2…

1. There are two modes

  • Transform – Expand: All objects in json are created as new structs
  • Transform-nesting: Objects in JSON are contained in a struct

2. Customize the tag

The default converted tag is JSON, and you can customize it, for example, gorm

3. The renderings

YAML turn to GO

Website: www.printlove.cn/tools/yaml2…

Automatically convert yamL formats to Go Struct structures.

rendering

SQL to ent

Address: printlove. Cn/tools/sql2e…

1. The rendering

Function of 2.

  1. This tool provides for converting SQL statements toent schema
  2. Provides common database type to field function conversions

SQL ElasticSearch DSL

Address: printlove. Cn/tools/sql2e…

1. The rendering

2. Current support

  • sql and expression
  • sql or expression
  • equal(=) support
  • not equal(! =) support
  • gt(>) support
  • gte(>=) support
  • lt(<) support
  • lte(<=) support
  • SQL in (eg. Id in (1,2,3)) expression
  • SQL not in (eg. Id not in (1,2,3)) expression
  • paren bool support (eg. where (a=1 or b=1) and (c=1 or d=1))
  • sql like expression (currently use match phrase, perhaps will change to wildcard in the future)
  • sql order by support
  • sql limit support
  • sql not like expression
  • field missing check
  • support aggregation like count(*), count(field), min(field), max(field), avg(field)
  • support aggregation like stats(field), extended_stats(field), percentiles(field) which are not standard sql function
  • null check expression(is null/is not null)
  • join expression
  • having support

SQL to go – zero

Address: printlove. Cn/tools/sql2g…

1. The rendering

Function of 2.

The code generated by the official goCTL tool is the same as the cached Model or not.

Turn the SQL GORM Model

Website: www.printlove.cn/tools/sql2g…

1. The rendering

Function of 2.

  • Support multiple tables
  • Supports the import of imported packages