错误出现:

含有错误的查询后,选中insert语句无法执行,报错current transaction is aborted, commands ignored until end of transaction block

分析:

事务中含有错误,再执行DML时,事务无法正常进行。

解决方法:

1.尝试connection.setAutoCommit(true);无法执行

2.直接commit ,提交后再执行insert语句,成功插入。

参考了stackoverflow的解法:

https://stackoverflow.com/questions/10399727/psqlexception-current-transaction-is-aborted-commands-ignored-until-end-of-tra

navicat中执行PostgreSQL错误解决:ERROR: current transaction is aborted, commands ignored until end of transaction block的更多相关文章

  1. current transaction is aborted, commands ignored until end of transaction block

    current transaction is aborted, commands ignored until end of transaction block Error updating datab ...

  2. win7 安装过程中遇到的错误解决方法

    win7 安装过程中遇到的错误解决方法 windows安装无法继续.若要安装windows 请单击 确定 重新启动计算机: 当 出现如上提示的时候,按下shift+f10 会打开命令窗口,进入到C:\ ...

  3. MYSQL导入CSV格式文件数据执行提示错误(ERROR 1290): The MySQL server is running with the --secure-file-priv option so it cannot execute this statement.

    MYSQL导入CSV格式文件数据执行提示错误(ERROR 1290): The MySQL server is running with the --secure-file-priv option s ...

  4. mac上Navicat新建数据库3680错误解决办法

    mac上Navicat新建数据库3680错误解决办法 1.在设置里关闭mysql,若不能关闭,在终端输入: sudo /usr/local/mysql/support-files/mysql.serv ...

  5. PHP中Strict Standards错误解决方法二

    在PHP5.3.3 中安装wordpress 3.0.1 ,在安装时出现错误:Strict Standards: PHP Strict Standards: Declaration of Walker ...

  6. PL/SQL“ ORA-14551: 无法在查询中执行 DML 操作”解决

    环境 Oracle 11.2.0 + SQL Plus 问题 根据以下要求编写函数:将scott.emp表中工资低于平均工资的职工工资加上200,并返回修改了工资的总人数.PL/SQL中有更新的操作, ...

  7. maven 中使用jstl 错误解决

    maven 中使用jstl表达式中出现如上错误.原因: 导入jstl 的jar包,却没有在pom文件中添加jstl相关的jar依赖项. <!--jstl表达式--> <depende ...

  8. 【转】linux中执行外部命令提示" error while loading shared libraries"时的解决办法

    今天在Centos下编译kapar 后执行时出错,老说: [root@dc01 ~]# kapar kapar: error while loading shared libraries: libsc ...

  9. navicat 中执行sql脚本 喊中文错误

    执行内容和上篇一样,只是换了工具. 执行成功,但是数据库对应中文没有内容. sql脚本的编码是asci 执行的时候选择gbk 编码

随机推荐

  1. spring boot 接口返回值封装

    Spring Boot 集成教程 Spring Boot 介绍 Spring Boot 开发环境搭建(Eclipse) Spring Boot Hello World (restful接口)例子 sp ...

  2. 18 12 06 sql 的 基本语句 查询 条件查询 逻辑运算符 模糊查询 范围查询 排序 聚合函数 分组 分页 连接查询 自关联 子查询

    -- 数据的准备 -- 创建一个数据库 create database python_test charset=utf8; -- 使用一个数据库 use python_test; -- 显示使用的当前 ...

  3. JS-表单非空验证

    JavaScript 表单验证 JavaScript 可用来在数据被送往服务器前对 HTML 表单中的这些输入数据进行验证. 实例:1.用户名的非空验证代码如下: <head> <m ...

  4. Java时间格式化年-月-日-时间

    Date d = new Date(); System.out.println(d); //Sat Mar 16 20:58:56 CST 2019 System.out.println(d.toLo ...

  5. python 用 pycharm 光速下载各种包

    https://blog.csdn.net/z1178517021/article/details/80200999 就是这么简单

  6. Python说文解字_杂谈05

    1. isinstance和type: is和==符号,is指的是内存地址,是不是一个对象,ID知否相同 集成链 class A: pass class B(A): pass b = B() prin ...

  7. Linux文件目录常用命令

    查看目录内容 ls 切换目录 cd 创建和删除操作 touch rm mkdir 拷贝和移动文件 cp mv 查看文件内容 cat more grep 其他 echo 重定向 > 和 >& ...

  8. 申请FreeDomain,透过DNS转回自己的Godaddy Cpanel

    148.66.136.216这个IP,是我的Cpanel IP. 过了几分钟,这个kkchan.tk就转到Cpanel了. 然后在Cpanel的Addon Domains加上kkchan.tk,那就可 ...

  9. HDU-3038 How Many Answers Are Wrong(带权并查集区间合并)

    http://acm.hdu.edu.cn/showproblem.php?pid=3038 大致题意: 有一个区间[0,n],然后会给出你m个区间和,每次给出a,b,v,表示区间[a,b]的区间和为 ...

  10. BitcoinCore JSONRPC Java使用,创建账号,获取余额,转账等等...

    1.首先要安装好bitcoin core服务 上一篇有怎么安装 下面代码支持多钱包多地址动态调用,但让我没用使用多地址,根据自己的需要然后封装方法就好 2.引入jar  JavaBitcoinRpcC ...