Chapter 43. PostgreSQL Դ����

Table of Contents
43.1. ��ʽ
43.2. �����������Ĵ���
43.3. ������Ϣ���ָ��
43.3.1. ��ȥ�δ�
43.3.2. ��ʽ��
43.3.3. ����
43.3.4. ʹ������
43.3.5. �﷨�ͱ��
43.3.6. ��д�ַ���Сд�ַ��Ƚ�
43.3.7. ���ⱻ������
43.3.8. �ִ�ʱ���ȥʱ�ıȽ�
43.3.9. ��������
43.3.10. ������
43.3.11. ��װ������Ϣ
43.3.12. �����ԭ��
43.3.13. ������
43.3.14. �������������
43.3.15. ��ȷ��ƴд
43.3.16. ���ػ�

43.1. ��ʽ

�����ʽʹ��ÿ���Ʊ����tab��4�еĿհף� Ŀǰ�DZ����Ʊ��״̬��Ҳ����˵�Ʊ������չ��Ϊ�հף��� ÿ���߼�������ζ��Ǹ����һ�� tab�����ֹ��򣨻�������λ�ȣ���ѭ BSD ��ͳ��

��Ȼ�ύ�IJ���������Ҫ����ȫ��ѭ��Щ��ʽ������������û�����ô���� ��Ĵ��뽫�ᱻ pgindent ������Ȼ���������������������������ĸ�ʽ��ϰ�߸��ÿ���

����ʹ�� Emacs ���ˣ��������У��������ƵĶ��������ӵ���� ~/.emacs ��ʼ���ļ�����ȥ��

;; check for files with a path containing "postgres" or "pgsql"
(setq auto-mode-alist
	(cons '("\\(postgres\\|pgsql\\).*\\.[ch]\\'" . pgsql-c-mode)
		auto-mode-alist))
(setq auto-mode-alist
	(cons '("\\(postgres\\|pgsql\\).*\\.cc\\'" . pgsql-c-mode)
		auto-mode-alist))

(defun pgsql-c-mode ()
  ;; sets up formatting for PostgreSQL C code
  (interactive)
  (c-mode)
  (setq-default tab-width 4)
  (c-set-style "bsd")             ; set c-basic-offset to 4, plus other stuff
  (c-set-offset 'case-label '+)   ; tweak case indent to match PG custom
  (setq indent-tabs-mode t))      ; make sure we keep tabs when indenting

���� vi����� ~/.vimrc �����൱���ļ�Ӧ�ð�������Ķ�����

set tabstop=4

������ vi �������

:set ts=4

�ı�������� more �� less �����������������

more -x4
less -x4

�����Ϳ�����������ȷ��ʾ tab ����