Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id BCA202E010E for ; Tue, 4 Mar 2008 17:15:45 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 16067-01 for ; Tue, 4 Mar 2008 17:15:35 -0400 (AST) X-Greylist: delayed 00:20:03.771349 by SQLgrey-1.7.5 Received: from mail3.avature.net (mail3.avature.net [4.78.160.175]) by postgresql.org (Postfix) with SMTP id A7F4F2E0343 for ; Tue, 4 Mar 2008 17:15:25 -0400 (AST) Received: from localhost (unknown [172.16.2.174]) by mail3.avature.net (Postfix) with ESMTP id 7A47C408008; Tue, 4 Mar 2008 15:53:58 -0500 (EST) X-Virus-Scanned: ClamAV at avature.net Received: from mail3.avature.net ([172.16.2.175]) by localhost (amavis.xcade.net [172.16.2.174]) (amavisd-new, port 10024) with ESMTP id OLZT1uLHiQHn; Tue, 4 Mar 2008 15:54:56 -0500 (EST) Received: from hegel.xcade.net (unknown [192.168.133.1]) by mail3.avature.net (Postfix) with SMTP id 3EE6C408007; Tue, 4 Mar 2008 15:53:43 -0500 (EST) Received: from [192.168.133.216] (unknown [192.168.133.216]) by hegel.xcade.net (Postfix) with ESMTP id E87FC320050; Tue, 4 Mar 2008 17:53:09 -0300 (ART) Message-ID: <47CDB71D.3000106@avature.net> Date: Tue, 04 Mar 2008 18:54:53 -0200 From: =?UTF-8?B?VG9tw6FzIERpIERvbcOpbmljbw==?= User-Agent: Mozilla-Thunderbird 2.0.0.9 (X11/20080110) MIME-Version: 1.0 To: Shahaf Abileah , pgsql-general@postgresql.org Subject: Re: Documenting a DB schema References: <082D8A131DF72A4D88C908A1AD3DEB22023B34F2@mail-1.rf.lan> In-Reply-To: <082D8A131DF72A4D88C908A1AD3DEB22023B34F2@mail-1.rf.lan> X-Enigmail-Version: 0.95.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200803/104 X-Sequence-Number: 129426 Check http://www.postgresql.org/docs/8.3/interactive/sql-comment.html Cheers! Shahaf Abileah wrote: > I=E2=80=99m looking for a systematic way to document the schema for the= database > behind our website (www.redfin.com ), so that > the developers using this database have a better idea what all the > tables and columns mean and what data to expect. Any recommendations? >=20 > =20 >=20 > It would be great if the documentation could be kept as close to the > code as possible =E2=80=93 that way we stand a chance of keeping it up = to date.=20 > So, in the same way that Java docs go right there on top of the class o= r > method definitions, it would be great if I could attach my comments to > the table definitions. It looks like MySQL has that kind of capability: >=20 > =20 >=20 > create table table_with_comments(a int comment 'this is > column a...'); >=20 > =20 >=20 > (see http://dev.mysql.com/doc/refman/5.0/en/create-table.html) >=20 > =20 >=20 > However, Postgres doesn=E2=80=99t support the =E2=80=9Ccomment=E2=80=9D= keyword. Is there an > alternative? >=20 > =20 >=20 > Thanks, >=20 > =20 >=20 > --S >=20 > =20 >=20 > *Shahaf Abileah *|* Lead Software Developer * >=20 > shahaf@redfin.com | tel: 206.859.2869 | fax: 877.733.3469 >=20 > Redfin Corporation > 710 2nd Ave > Suite 600 > Seattle, WA 98104 >=20 > =20 >=20