Skip to content

对于基本类型long报错,比如如下SQL #4

Description

@iceqing
@ReturnGeneratedKeys
@SQL("INSERT INTO " + TABLE_NAME + " (" + INSERT_COLUMNS + ") VALUES (" + INSERT_VALUES + ")")
long insert(UserBankcard one);

Activity

  1. iceqing commented on Aug 7, 2018

    @iceqing
    Author

    如果吧long改为Long就行了,能不能解决兼容一下?

  2. changed the title [-]对于基本类型来兴报错,比如如下SQL[/-] [+]对于基本类型long报错,比如如下SQL[/+] on Aug 7, 2018
  3. iceqing commented on Aug 7, 2018

    @iceqing
    Author

    以下是具体的报错信息:
    org.springframework.dao.InvalidDataAccessApiUsageException: error return type, only support int/long/double/float/void type for method with @ReturnGeneratedKeys:public abstract long

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions