Mybatis-sharp {} problem solving

An insert statement written in the

JavaWeb project looks something like this

customerInfo object has all the values, and none is empty.

here is the add method

public boolean customerInfoAdd(SendCard customerInfo){
        try {
            sqlSession.insert("insertSendCard", customerInfo);
        } catch (Exception e) {
            log.error(":insertSendCard");
            e.printStackTrace();
            return false;
        }
        return true;
    }
<insert id="insertSendCard"  parameterType="com.****.****.****.****">
     <![CDATA[ 
             insert into  T_SENDCARD(
               sendcardid,
               termid,
               idno,
              name,
              telphone,
              address,
              cardno,
              issuedate,
              operator,
              sex,
              nationality,
              birthday,
              cardtype,
              organs
              )
             values
             (
               -sharp{sendcardid},
               -sharp{termno},
              -sharp{idcard_no},
              -sharp{cus_name},
              -sharp{phone},
              -sharp{home_address},
              -sharp{bankcardno},
              -sharp{status_datetime},
              -sharp{bankuserid},
              -sharp{sex},
              -sharp{nation},
              -sharp{birthday},
              -sharp{cardtype},
              -sharp{fzjg}
             )
        ]]>    
     </insert>

failed to insert data.

[0410 11:07:27 424 INFO ] [http-bio-8080-exec-7] factory.xml.XmlBeanDefinitionReader - Loading XML bean definitions from class path resource [org/springframework/jdbc/support/sql-error-codes.xml]
[0410 11:07:27 451 INFO ] [http-bio-8080-exec-7] jdbc.support.SQLErrorCodesFactory - SQLErrorCodes loaded: [DB2, Derby, H2, HSQL, Informix, MS-SQL, MySQL, Oracle, PostgreSQL, Sybase]
[0410 11:07:27 456 ERROR] [http-bio-8080-exec-7] TradeLogDaoImpl - :insertSendCard
Mar.03,2021

how does your mapper interface write


try to write parameterType more specifically. Just put the SendCard, error message on


set mybatis to debug, in the configuration and then execute the sql statement. This makes it convenient for you to solve the problem


give the Mapper interface and entity class to help you solve the problem. Now there is too little information to locate.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3a823-2c211.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3a823-2c211.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?