← Winnitude! Search  ·  Reader Mode (749 ms)
Links: Stay in Reader Retro Site Converter Retro Mode: OFF Original Page ↗
GITHUB · 12 LINKS

不支持 postgresql 的 date 字段格式时的类型转换 · Issue #436 · APIJSON/APIJSON

Repository navigation

不支持 postgresql 的 date 字段格式时的类型转换  #436


New issue

New issue

Closed

Closed
不支持 postgresql 的 date 字段格式时的类型转换 #436 Labels
Document 文档

PostgreSQL

Question 使用问题

Description

@transtone's profile transtone opened on Aug 29, 2022

使用如下查询时出错:

{
	"data[]": {	
		"User": {        
			"birthday>=": "2022-08-28",
		},
        "format": true,
        "count": 3,
	},

}
org.postgresql.util.PSQLException: ERROR: operator does not exist: date >= character varying
  建议:No operator matches the given name and argument types. You might need to add explicit type casts.

==================

需要这样转换一下字段格式:

{
	"data[]": {	
		"User": {        
			"birthday>=": "2022-08-28",
                        "@cast": "birthday>=:DATE",
		},
        "format": true,
        "count": 3,
	},

}

Document.md 文档中查不到,可以补上这个功能的文档。

Metadata

Metadata

Assignees

No one assigned

    Labels


    Document 文档

    PostgreSQL

    Question 使用问题

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions