graphql-engine icon indicating copy to clipboard operation
graphql-engine copied to clipboard

get-graphql-schema export graphqlschema garbled characters

Open Basil1991 opened this issue 2 years ago • 1 comments

Version Information

Server Version: 2.36.1

Environment

Local Docker Env

What is the current behaviour?

get-graphql-schema http://localhost:8089 > schema.graphql

I get a file with UTF-16 LE encoder,bug some words are garbled characters. like this:

...
service_a_t_template_aggregate(
    """distinct select on columns"""
    distinct_on: [service_a_t_template_select_column!]

    """limit the number of rows returned"""
    limit: Int

    """skip the first n rows. Use only with order_by"""
    offset: Int

    """sort the rows by one or more columns"""
    order_by: [service_a_t_template_order_by!]

    """filter the rows returned"""
    where: service_a_t_template_bool_exp
  ): service_a_t_template_aggregate!

  """
  fetch data from the table: "service_a.t_template" using primary key columns
  """
  service_a_t_template_by_pk(
    """鍗曟嵁涓婚敭"""
    id: bigint!
  ): service_a_t_template
}

"""
columns and relationships of "service_a.t_template"
"""
type service_a_t_template {
  """鐢宠鍦板尯"""
  apply_area: String

  """鐢宠鍦板尯缂栫爜"""
  apply_area_code: String

  """鐢宠鏃堕棿"""
  apply_date: timestamp

  """鐢宠閮ㄩ棬"""
  apply_dept: String

  """鐢宠閮ㄩ棬id"""
  apply_dept_id: String

  """鐢宠浜?""
  apply_user: String

  """鐢宠浜篿d"""
  apply_user_id: String

  """鏄惁鍒犻櫎"""
  deleted: smallint!

  """鍗曟嵁涓婚敭"""
  id: bigint!

  """鍗曟嵁鍚嶇О"""
  name: String!

  """娴佺▼id"""
  process_id: String

  """鍗曟嵁鐘舵€?""
  status: smallint

  """鏇存柊浜篿d"""
  update_by: String

  """鏇存柊鏃堕棿"""
  update_time: timestamp
}

"""
aggregated selection of "service_a.t_template"
"""
type service_a_t_template_aggregate {
  aggregate: service_a_t_template_aggregate_fields
  nodes: [service_a_t_template!]!
}

"""
aggregate fields of "service_a.t_template"
"""
type service_a_t_template_aggregate_fields {
  avg: service_a_t_template_avg_fields
  count(columns: [service_a_t_template_select_column!], distinct: Boolean): Int!
  max: service_a_t_template_max_fields
  min: service_a_t_template_min_fields
  stddev: service_a_t_template_stddev_fields
  stddev_pop: service_a_t_template_stddev_pop_fields
  stddev_samp: service_a_t_template_stddev_samp_fields
  sum: service_a_t_template_sum_fields
  var_pop: service_a_t_template_var_pop_fields
  var_samp: service_a_t_template_var_samp_fields
  variance: service_a_t_template_variance_fields
}

"""aggregate avg on columns"""
type service_a_t_template_avg_fields {
  """鏄惁鍒犻櫎"""
  deleted: Float

  """鍗曟嵁涓婚敭"""
  id: Float

  """鍗曟嵁鐘舵€?""
  status: Float
}

"""
Boolean expression to filter rows from the table "service_a.t_template". All fields are combined with a logical 'AND'.
"""
input service_a_t_template_bool_exp {
  _and: [service_a_t_template_bool_exp!]
  _not: service_a_t_template_bool_exp
  _or: [service_a_t_template_bool_exp!]
  apply_area: String_comparison_exp
  apply_area_code: String_comparison_exp
  apply_date: timestamp_comparison_exp
  apply_dept: String_comparison_exp
  apply_dept_id: String_comparison_exp
  apply_user: String_comparison_exp
  apply_user_id: String_comparison_exp
  deleted: smallint_comparison_exp
  id: bigint_comparison_exp
  name: String_comparison_exp
  process_id: String_comparison_exp
  status: smallint_comparison_exp
  update_by: String_comparison_exp
  update_time: timestamp_comparison_exp
}

"""
unique or primary key constraints on table "service_a.t_template"
"""
enum service_a_t_template_constraint {
  """
  unique or primary key constraint on columns "id"
  """
  t_template_pkey
}

"""
input type for incrementing numeric columns in table "service_a.t_template"
"""
input service_a_t_template_inc_input {
  """鏄惁鍒犻櫎"""
  deleted: smallint

  """鍗曟嵁涓婚敭"""
  id: bigint

  """鍗曟嵁鐘舵€?""
  status: smallint
}
...

Basil1991 avatar Jan 08 '24 09:01 Basil1991

how i get clean graphql schema?

Basil1991 avatar Jan 08 '24 09:01 Basil1991