首页新闻资讯管理维护网络安全机房管理部署集成网管工具网管资料专题论坛 杂志
当前位置:首页 >> 管理维护 >> 数据库 >> MySQL >> Linux环境下"Postgresql"的汉字插入问题
Linux环境下"Postgresql"的汉字插入问题
来源:赛迪网 作者:赛迪网 发布时间:2008-03-07

问:Linux环境下如何在Postgresql数据库中完成汉字插入?

解决方法:

首先用postgresql的用户登陆,(su - postgres) ,然后进入数据库,假设数据库名称为“house”,命令为:

 

[postgres@ITC-S postgres]$ psql house
Welcome to psql 8.0.1, the PostgreSQL interactive terminal.
Type:  copyright for distribution terms
h for help with SQL commands
? for help with psql commands
g or terminate with semicolon to execute query
q to quit
house=# 
输入encoding GBK
house=#encoding GBK

现在就可以插入汉字了。

(责任编辑:四方)
阅读次数:
快速检索
推荐文章
 
网友评论
评论加载中…
 
友情链接 | 欢迎投稿 | 杂志发行 | 广告报价 | 人才招聘 | 服务条款 | 免责声明 | 隐私保护 | 关于网管员世界
CopyRight © 2001-2008 [网管员世界 www.365master.com] All Rights Reserved.
《网管员世界》杂志,专为网管服务的刊物!