MyBatis you want to insert a null value, you need to specify Jdbctype
MyBatis insert NULL returns an empty value exception, but PL/SQL does not prompt for errors, mainly because MyBatis cannot be converted
<insert id= "Insertinstrument" parametertype= "com.labway.oa.po.Instruments" >insert Intoinstruments (group_name,name,description,on_line,operator,x_sbxh,serial_no,x_lc,x_sbjd,vendor,<!-- X_sbsx, -->location,changed_on,changed_by,removed,low_threshold,high_threshold,stability_delta, Stability_number,port_number,discard_time,size_limit,time_out,polling_time,needs_calibration,needs_pm,holds_ Samples,include_subdirs,debug,store_in_db_file,db_file_prompt,x_jlsx,x_funcheck_status,x_timecheck_status,x_ Name,x_description,x_funcheck_date,x_timecheck_date,pm_date,x_pm_status,x_status,x_group_name) values (#{ Group_name,jdbctype=varchar},#{name,jdbctype=varchar},#{description,jdbctype=varchar},#{on_line,jdbctype= Varchar},#{operator,jdbctype=varchar},#{x_sbxh,jdbctype=varchar},#{serial_no,jdbctype=varchar},#{x_lc,jdbctype =varchar},#{x_sbjd,jdbctype=varchar},#{vendor,jdbctype=varchar},<!-- #{x_sbsx}, -->#{location, Jdbctype=varchar},#{changed_on,javAtype=string,jdbctype=date,typehandler=com.labway.portal.handler.lwdatetypehandler},#{changed_by,jdbctype= VARCHAR}, ' F ', ' 0 ', ' 0 ', ' 0 ', ' 0 ', ' 0 ', ' 0 ', ' 0 ', ' 0 ', ' 0 ', ' f ', ' F ', ' F ', ' F ', ' F ', ' F ', ' f ', ' T ', ' f ', ' F ', #{name,jdbctype= Varchar},#{description,jdbctype=varchar},#{x_funcheck_date,javatype=string,jdbctype=date,typehandler= Com.labway.portal.handler.lwdatetypehandler},#{x_timecheck_date,javatype=string,jdbctype=date,typehandler= Com.labway.portal.handler.lwdatetypehandler},#{pm_date,javatype=string,jdbctype=date,typehandler= Com.labway.portal.handler.lwdatetypehandler},#{x_pm_status,jdbctype=varchar},#{x_status,jdbctype=varchar},#{x_ Group_name,jdbctype=varchar}) </insert>
This article is from the "Big Talk Program" blog, please be sure to keep this source http://houqida.blog.51cto.com/8877896/1584685
MyBatis you need to specify Jdbctype when inserting null