Re: [GENERAL] Postgres SQL Syntax

2007-02-09 Thread Joshua D. Drake
Ted Byers wrote: > > - Original Message - From: "Merlin Moncure" <[EMAIL PROTECTED]> >> >> the open standard to convert data from one database to another, >> unfortunately, is SQL. SQL is incomplete, illogical, and obscure, so >> here we are. >> > The same can be said about any programmin

Re: [GENERAL] Postgres SQL Syntax

2007-02-09 Thread Ted Byers
- Original Message - From: "Merlin Moncure" <[EMAIL PROTECTED]> the open standard to convert data from one database to another, unfortunately, is SQL. SQL is incomplete, illogical, and obscure, so here we are. The same can be said about any programming language, can it not? Even la

Re: [GENERAL] Postgres SQL Syntax

2007-02-09 Thread Merlin Moncure
On 2/2/07, Jim C. <[EMAIL PROTECTED]> wrote: > Besides what Tom says, '0' is a string, not an integer. PG takes > it, but it's a bad habit. Maybe it is and maybe it isn't. I wouldn't know. I'm merely the unfortunate soul chosen to convert this from MySQL to Postgres. :-/ I've been working on

Re: [GENERAL] Postgres SQL Syntax

2007-02-08 Thread Jim C.
Richard Huxton wrote: > Jim C. wrote: >>> You probably want one of the mysql converter projects, e.g. >>> http://pgfoundry.org/projects/mysql2pgsql/ >>> Also read the "converting from other databases" section here: >>> http://www.postgresql.org/docs/techdocs >> >> I tried several conversion too

Re: [GENERAL] Postgres SQL Syntax

2007-02-06 Thread Richard Huxton
Jim C. wrote: Richard Huxton wrote: Jim C. wrote: You probably want one of the mysql converter projects, e.g. http://pgfoundry.org/projects/mysql2pgsql/ Also read the "converting from other databases" section here: http://www.postgresql.org/docs/techdocs I tried several conversion tools an

Re: [GENERAL] Postgres SQL Syntax

2007-02-06 Thread Richard Huxton
Jim C. wrote: You probably want one of the mysql converter projects, e.g. http://pgfoundry.org/projects/mysql2pgsql/ Also read the "converting from other databases" section here: http://www.postgresql.org/docs/techdocs I tried several conversion tools and did get some minor success with one

Re: [GENERAL] Postgres SQL Syntax

2007-02-06 Thread Jim C.
> You probably want one of the mysql converter projects, e.g. > http://pgfoundry.org/projects/mysql2pgsql/ > Also read the "converting from other databases" section here: > http://www.postgresql.org/docs/techdocs I tried several conversion tools and did get some minor success with one or two b

Re: [GENERAL] Postgres SQL Syntax

2007-02-06 Thread Richard Huxton
Jim C. wrote: I'm doing this table by table, line by line. Each table, I learn something new about the differences between MySQL and Postgres, I mentally catalog it and I can always look it up in my own code next time for examples. I've a tool that is providing some help but sometimes it choke

Re: [GENERAL] Postgres SQL Syntax

2007-02-06 Thread Brandon Aiken
To: pgsql-general@postgresql.org Subject: Re: [GENERAL] Postgres SQL Syntax > CREATE TABLE "credits" ( > "person" integer NOT NULL default '0', > "chanid" int NOT NULL default '0', > "starttime" timestamp NOT

Re: [GENERAL] Postgres SQL Syntax

2007-02-06 Thread Harald Fuchs
In article <[EMAIL PROTECTED]>, "Jim C." <[EMAIL PROTECTED]> writes: > Maybe it is and maybe it isn't. I wouldn't know. I'm merely the > unfortunate soul chosen to convert this from MySQL to Postgres. :-/ > I've been working on it for a week now. I've got to say that it pains me > to know that

Re: [GENERAL] Postgres SQL Syntax

2007-02-05 Thread Jim C.
> Besides what Tom says, '0' is a string, not an integer. PG takes > it, but it's a bad habit. Maybe it is and maybe it isn't. I wouldn't know. I'm merely the unfortunate soul chosen to convert this from MySQL to Postgres. :-/ I've been working on it for a week now. I've got to say that it pai

Re: [GENERAL] Postgres SQL Syntax

2007-02-05 Thread Jim C.
> CREATE TABLE "credits" ( > "person" integer NOT NULL default '0', > "chanid" int NOT NULL default '0', > "starttime" timestamp NOT NULL default '1970-01-01 00:00:00+00', > "role" > set('actor','director','producer','executive_producer','writer','guest_star','host','adapter','presenter','

Re: [GENERAL] Postgres SQL Syntax

2007-02-01 Thread Ron Johnson
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/01/07 19:02, Jim C. wrote: > I've a postgres statement that reads: > > CREATE TABLE "channel" ( Do you *need* object names to be case-sensitive? If not, it's a bad habit to get in to. Makes more work for you and the developers. > "chan

Re: [GENERAL] Postgres SQL Syntax

2007-02-01 Thread Tom Lane
"Jim C." <[EMAIL PROTECTED]> writes: > I've a postgres statement that reads: > CREATE TABLE "channel" ( > "chanid" int NOT NULL default '0', > "channum" varchar(10) NOT NULL default '', > "freqid" varchar(10) default NULL, > "sourceid" int default NULL, > . > . > . > P

[GENERAL] Postgres SQL Syntax

2007-02-01 Thread Jim C.
I've a postgres statement that reads: CREATE TABLE "channel" ( "chanid" int NOT NULL default '0', "channum" varchar(10) NOT NULL default '', "freqid" varchar(10) default NULL, "sourceid" int default NULL, . . . PRIMARY KEY ("chanid"), KEY "channel_s