• HOME
  • SEARCH
  • TOPICS
  • DATA

  • PostgreSQL 查看数据库配置信息

    pg_config 与psql一样,pg_config直接在不连接数据库的情况下,命令行中直接查看。 pg_config 输出 ❯ pg_config BIND

    2023-10-20, Views: 1511 , Topics: PostgreSQL

  • macOS Postgres.app 配置命令行工具

    执行命令 执行完成后需重新打开终端。 sudo mkdir -p /etc/paths.d && echo /Applications/Post

    2023-05-22, Views: 1746 , Topics: macOS PostgreSQL

  • Docker 部署 PostgreSQL

    搜索镜像 docker search postgres 拉取镜像 版本号可以去官网查看:https://hub.docker.com/_/postgres do

    2022-02-06, Views: 2197 , Topics: Docker PostgreSQL DevOps

  • PostgreSQL 重置序列序号

    从 1 开始 false表示,数字1还没有被用掉。 select setval('post_id_seq', 1, false); 从 2 开始 true表示,

    2021-05-17, Views: 2690 , Topics: PostgreSQL

  • PostgreSQL 修改字段属性

    重命名 alter table record_page_view rename ua to user_agent; 添加字段 alter table reco

    2021-05-16, Views: 4226 , Topics: PostgreSQL

  • PostgreSQL 时间戳转毫秒值并去除小数位

    时间戳转毫秒值 使用extract函数及epoch from关键词。 select extract(epoch from (current_timestamp)

    2021-05-16, Views: 7774 , Topics: PostgreSQL

  • Linux 编译安装 PostgreSQL 12.2

    下载地址 清华大学镜像,下载并解压。 wget https://mirrors.tuna.tsinghua.edu.cn/postgresql/source/v

    2021-05-15, Views: 2669 , Topics: PostgreSQL Linux

  • PostgreSQL distinct 和 distinct on 区别

    数据 city空值的为null z-blog=# select city, id, ip from ip_pool; city | id |

    2021-01-05, Views: 2525 , Topics: PostgreSQL

  • PostgreSQL update from 根据 A 表更新 B 表

    准备工作 -- 创建表1 create table t1(id integer, name text); -- 创建表2 create table t2(id

    2021-01-04, Views: 5141 , Topics: PostgreSQL

  • PostgreSQL 查询表中的自增序列名称

    SQL 使用pg_get_serial_sequence函数,第一个参数为需要查询的表,第二个参数为自增的列。 select pg_get_serial_seq

    2020-12-31, Views: 7097 , Topics: PostgreSQL

  • PostgreSQL 查看时区

    查看当前时区 show timezone; 或者 show time zone; 查看内置时区 所有时区 select * from pg_timezone_n

    2020-12-30, Views: 12166 , Topics: PostgreSQL

  • PostgreSQL 错误: 编码 "UTF8" 的字符 0x0xc9 0x99 在编码 "GBK" 没有相对应值

    问题描述 在Windows的PowerShell中使用psql查询记录时抛出如下异常。 错误: 编码"UTF8"的字符0x0xc9 0x99在编码"GBK"没

    2020-12-17, Views: 8862 , Topics: PostgreSQL PowerShell chcp

  • PostgreSQL 获取本月第一天时间戳等信息

    date_trunc 日期函数中适用的时间字段 second minute day hour day week month quarter year 当天零

    2020-12-16, Views: 6745 , Topics: PostgreSQL

  • PostgreSQL duplicate key violates unique constraint

    错误原因 当前序列的值小于了目前表中的值。 查看序列 select * from post_id_seq; 输出 last_value | log_cnt |

    2020-12-15, Views: 2718 , Topics: PostgreSQL

  • Go 操作 PostgreSQL

    下载驱动 使用github.com/lib/pq驱动:https://github.com/lib/pq go get -u github.com/lib/pq

    2020-11-10, Views: 4708 , Topics: Go PostgreSQL

  • 使用 MyBatis 注解接收 PostgreSQL 的 returning 结果

    returning PostgreSQL支持在insert/update/delete语句中添加returning返回一些记录的信息。 如:插入记录后返回主键i

    2020-04-25, Views: 6517 , Topics: MyBatis PostgreSQL

  • PostgreSQL 备份与还原

    备份 - pg_dump 参数 -U:指定用户; --encoding:指定编码; -d、--dbname:指定备份数据库; -f、--file:导出到指定文

    2020-04-18, Views: 6332 , Topics: PostgreSQL

  • PostgreSQL增删改使用 returning 获取记录相关属性

    returning 增删改时返回该记录的属性。 示例 returning * 插入时返回记录的所有字段 insert into test(test_filed1

    2020-03-31, Views: 3004 , Topics: PostgreSQL

  • PostgreSQL 统计数组中的元素个数

    需求 统计文章表中的标签数组字段中的不同分类个数。 表字段 使用\d+ post查看。 z-blog=# \d+ post

    2020-03-26, Views: 7983 , Topics: PostgreSQL

  • PostgreSQL 修改数据库拥有者

    查看拥有者 z-blog=# \l 数据库列表 名

    2020-03-25, Views: 4795 , Topics: PostgreSQL

  • First Prev
  • 2
  • 3
  • 4
  • 5
  • 6
  • Next Last

©2025 沪ICP备18012661号-1 阿里云

Messages Sitemap GitHub