随笔分类 -  Postgresql

给Postgresql已经存在的表中的列删除或者添加默认值
摘要:改变字段的默认值: 为已有的字段添加默认值 ALTER TABLE table_name ALTER COLUMN column_name SET DEFAULT default_value; 删除默认值 ALTER TABLE table_name ALTER COLUMN column_name 阅读全文
posted @ 2020-11-19 21:47 dancser 阅读(2089) 评论(0) 推荐(1)
删除postgresql数据库下所有的表
摘要:DO $$ DECLARE r RECORD; BEGIN -- if the schema you operate on is not"current", you will want to -- replace current_schema() in query with 'schematodel 阅读全文
posted @ 2020-10-22 10:11 dancser 阅读(3209) 评论(0) 推荐(0)
postgresql invalid byte sequence for encoding "UTF8": 0xe99d2c (转载)
摘要:invalid byte sequence for encoding "UTF8": 0xe99d2c 阅读全文
posted @ 2015-05-22 13:48 dancser 阅读(459) 评论(0) 推荐(0)