Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 18DAFB5DD31 for ; Wed, 19 Oct 2011 23:57:40 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 36541-03-6 for ; Thu, 20 Oct 2011 02:57:32 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0-rc2 Received: from mail-ey0-f174.google.com (mail-ey0-f174.google.com [209.85.215.174]) by mail.postgresql.org (Postfix) with ESMTP id 7426CB5DCD1 for ; Wed, 19 Oct 2011 23:57:25 -0300 (ADT) Received: by eye27 with SMTP id 27so2294268eye.19 for ; Wed, 19 Oct 2011 19:57:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; bh=8YsEp+ehJLuxWzd+0R04I3z5RlTftY75d3vi7i2WI5c=; b=pVIp9ZNPfdR3ySuOVLM+JK5PAh5o9ShakQwgBKC5HFT78xClrdlU8K/Xnbm30C094R wb5lXvm1DhY+zDHFQvN4x/+GnBbd3K320+1pRuyFlnAYf+msc91onDFnbod88ujkn9Gk NHtkK5ugRZTOV57ElBBIbTM6LN71AmPLHAgbQ= MIME-Version: 1.0 Received: by 10.223.85.139 with SMTP id o11mr15308624fal.0.1319079444775; Wed, 19 Oct 2011 19:57:24 -0700 (PDT) Received: by 10.223.78.138 with HTTP; Wed, 19 Oct 2011 19:57:24 -0700 (PDT) In-Reply-To: <257F49CD-D20C-4AFC-BF0E-EC689C19B4CB@me.com> References: <147DA84F-359C-4382-A360-B6B8E2D7E04F@gmail.com> <257F49CD-D20C-4AFC-BF0E-EC689C19B4CB@me.com> Date: Wed, 19 Oct 2011 19:57:24 -0700 Message-ID: Subject: Re: new user on mac From: Scott Swank To: pgsql-sql@postgresql.org Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.889 tagged_above=-5 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, T_TO_NO_BRKTS_FREEMAIL=0.01 X-Spam-Level: X-Archive-Number: 201110/39 X-Sequence-Number: 35923 Thanks all. I'd tried pgadmin3 and perhaps moved on too quickly. On 2nd look it's better than I'd initially considered. Cheers, Scott On Wed, Oct 19, 2011 at 1:13 AM, Basil Bourque wrote: >>> I have a postgres 9.1 database up & running, no problem. Purely in >>> terms of writing sql (ddl, dml & pg/plsql), what tools are >>> recommended? >>> >>> Coming from an Oracle world, I'm thinking of toad, sql developer, etc. >>> >>> 1. psql & text editor of choice (if so, which one?) >>> 2. navicat >>> 3. textmate with pgedit >>> 4. eclipse plugin >>> 5. other? > >>> +1 for pgAdmin3. If you have already used Toad, u would like to check i= t. > > Being new to SQL (but old to other relational databases) and a Mac guy, I= have found pgAdmin to work surprisingly well. Surprising because I have a = knack for breaking/corrupting/crashing nearly every developer tool I start = using as a newbie. But pgAdmin has worked nearly flawlessly for me. It look= s goofy from a Mac aesthetics perspective, but it works. > > I may have once had an inexplicable glitch, but after restart all was wel= l. I've only been bitten by 2 recurring bugs: > > =95 (Cosmetic) Changing font size for use on projectors in a meeting make= s fonts bigger, but the rows of the Output Pane in a SQL window fail to gro= w in height. > > =95 (Serious) Tools > Server Configuration > pg_hba.conf has a nasty anti= -feature. When loading a saved conf file with incorrect syntax (usually I f= orget to put the slash+number on an IP address such as 127.0.0.1/32), pgAdm= in parses the file, identifies the flaw, and chooses to ignore the rule by = not displaying it. Unfortunately, pgAdmin does NOT parse the entries when e= ntering or saving them. So if you screw up a rule: > (a) You won't realize you saved incorrect syntax. To the user, it seems t= he rule you entered simply vanished. > (b) You can't fix it in pgAdmin. You'll have to gain access to the filesy= stem as the Postgres superuser (usually that's the Unix user 'postgres'), a= nd edit the file. This is not easy to do as a Mac GUI user. > This issue has been acknowledged in the mailing lists. > > But otherwise, pgAdmin has served me well for connecting to the Postgres = server, creating databases, creating tables, creating columns, creating a f= ew initial rows of data, editing some field values, and so on. > > When first starting out creating tables, I used the GUI dialogs in pgAdmi= n. Nowadays I take advantage of the feature where pgAdmin generates and sho= ws you the SQL that would re-create the table on which you've clicked. When= creating a new table, I copy the SQL from a similar table, paste into a te= xt editor, and edit appropriately. Then I paste the SQL back into a SQL win= dow in pgAdmin to execute. > > My usual choice in text editors is TextMate, running the surprisingly pro= ductive "Zenburnesque" Fonts & Color scheme in Preferences, where you can f= orce the text to be interpreted as SQL without bothering to save the file b= y choosing "SQL" from the popup at the window's bottom frame. > > Other good text editors include JEdit (Java-based, free-of-cost), TextWra= ngler (free of cost), and BBEdit. > http://www.jedit.org/ > http://www.textwrangler.com/products/textwrangler/ > TextWrangler's commercial big-brother BBEdit is also a popular text-edito= r on Mac OS X. > http://www.textwrangler.com/products/bbedit/ > > Other Java-based IDEs are free-of-cost, run well on Mac OS X, and include= SQL editing tools: IntelliJ, NetBeans, Eclipse. > > There are many other SQL tools that run on Mac OS X, especially the Java-= based tools using JDBC. I've not tried them yet as pgAdmin is sufficient fo= r now. > > =3D=3D Caution =3D=3D > > I'm not too clear on Postgres' defaults when installing Postgres, and whe= n creating a new database. But I believe Postgres defaults to a character s= et appropriate to the platform. I explicitly choose UTF-8 for both, rather = than depend on some mysterious default. The docs are not clear about this, = so I'm not sure about the best course of action. > > Other than this character set issue, one tip I've learned from experts is= to trust the default settings of both Postgres and pgAdmin. > > =3D=3D Another Caution =3D=3D > > Most text editors and IDEs on the Mac, both native and Java, have a tende= ncy to default: > > =95 The character set to MacRoman. > =A0You may want to change the default to UTF-8. > > =95 The newline/end-of-line to CarriageReturn. > =A0You may want to change the default to Linefeed for the Unix convention= . > > Note that some tools do not change the character-set or newline of an exi= sting file, or require that you choose a menu item to make the change happe= n. > > --Basil Bourque > -- > Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgsql-sql >