![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
When trying to create a complex type, the parser produces an error. e.g. CREAYE TYPE product AS (name varchar, price numeric); produces ERROR: parser: parse error at or near "as" |
#3
| |||
| |||
|
|
In my haste to write the email I didn't notice the spelling mistake. However in postgres I did spell CREATE coreectly. I am using the Windows 2000 os and the windows native version of PostgresQL 8.0.1. I tried this command in psql and pgaccess. Both return the same error - parser error at or near "as". Also I realised later the type I was trying to create was a composite, not complex as I wrote. |
#4
| |||
| |||
|
|
From: Michael Fuhr <mike (AT) fuhr (DOT) org Reply-To: pgsql-bugs (AT) postgresql (DOT) org To: John Smith <johnsmit89 (AT) hotmail (DOT) com CC: pgsql-bugs (AT) postgresql (DOT) org Subject: Re: [BUGS] BUG #1547: CREATE TYPE AS error Date: Tue, 22 Mar 2005 20:07:13 -0700 On Tue, Mar 22, 2005 at 11:05:46PM +0000, John Smith wrote: In my haste to write the email I didn't notice the spelling mistake. However in postgres I did spell CREATE coreectly. I am using the Windows 2000 os and the windows native version of PostgresQL 8.0.1. I tried this command in psql and pgaccess. Both return the same error - parser error at or near "as". Also I realised later the type I was trying to create was a composite, not complex as I wrote. Please copy and paste the exact command you're running and the exact error message. It's important to copy the actual command and error rather than type what you *think* they are because minor differences can sometimes matter. The following works for me in PostgreSQL 8.0.1: CREATE TYPE product AS (name varchar, price numeric); -- Michael Fuhr http://www.fuhr.org/~mfuhr/ |
#5
| |||
| |||
|
|
I re-installed postgresql as a service and CREATE TYPE AS works. So I then re-installed postgresql as a program (as I had originally done) and CREATE TYPE AS doesn't work. Perhaps you could check this on your system. |
#6
| |||
| |||
|
|
From: Michael Fuhr <mike (AT) fuhr (DOT) org Reply-To: pgsql-bugs (AT) postgresql (DOT) org To: John Smith <johnsmit89 (AT) hotmail (DOT) com CC: pgsql-bugs (AT) postgresql (DOT) org Subject: Re: [BUGS] BUG #1547: CREATE TYPE AS error Date: Sat, 2 Apr 2005 19:23:45 -0700 On Mon, Mar 28, 2005 at 12:51:42AM +0000, John Smith wrote: I re-installed postgresql as a service and CREATE TYPE AS works. So I then re-installed postgresql as a program (as I had originally done) and CREATE TYPE AS doesn't work. Perhaps you could check this on your system. Can't help there -- none of my systems distinguish between installing PostgreSQL as a "service" versus as a "program." We still haven't seen the *exact* command you're running and the *exact* error message (the command in your original message had a typo that results in a different error than the one you posted). Could you please post a complete set of steps that a person using the same platform could follow to reproduce the problem? Whenever possible, please copy and paste commands and output instead of typing them manually, to avoid introducing mistakes that aren't really present. -- Michael Fuhr http://www.fuhr.org/~mfuhr/ |
#7
| ||||
| ||||
|
|
I have already told you the exact command I am using - twice. |
|
I identified the problem in my previous email, and how to reproduce it. If you don't have a system with Windows 2000 then find someone who does. They will then confirm what I say. |
|
I resent the implication in your emails that I am some stupid user who does't know what he is doing. Insulting your users is not the best way to increase your user base. |
|
I have identified the problem, and how to reproduce it. I therefore will not engage in any further communication on this matter. |
#8
| |||
| |||
|
| Can anybody else with a Windows system reproduce the problem? The messages in the links above are said to contain enough information to do so. |
#9
| |||
| |||
|
|
Can anybody else with a Windows system reproduce the problem? The messages in the links above are said to contain enough information to do so. windows XP pro SP2 PostgreSQL 8.0.1 this is working for me (but not tested on win 2000 system): CREATE TYPE product AS (name varchar, price numeric); |
#10
| |||
| |||
|
|
In the following message, the OP says that CREATE TYPE works if he installs PostgreSQL as a service but it doesn't work if he installs PostgreSQL as a program (can anybody think of why this would make a difference?). |
![]() |
| Thread Tools | |
| Display Modes | |
| |