creating tables on Postgres db with php
| From: | Mitch | Date: | Thu, 08 Jun 2000 11:45:03 +0000 |
| Subject: | creating tables on Postgres db with php | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-20561@lists.php.net to get a copy of this message | ||
Hi i'am newbie and hard to fail.!!
i try to create a table on a postgres database via php like this
1 <?php
2 $database="somy";
3 myquery="create table adressen (adrnr int unique,name varchar(50),
4 adress varchar(30),
5 country varchar(30));";
6 $myconnect = pg_Connect ("", "", "", "",$database);
7 $result = pg_exec ($myconnect, $myquery);
8 ?>
But i only get a message :
Warning: PostgresSQL query failed: ERROR: parser: parse error at
or near " " in mycreatetable.php3 on line 7
what's up with my code ??
thanks a lot for your fast reply
muhammed
yazici@chss.net