Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id D087BB5DC06 for ; Thu, 1 Sep 2011 02:15:18 -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 22555-02 for ; Thu, 1 Sep 2011 05:15:10 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from sam.nabble.com (sam.nabble.com [216.139.236.26]) by mail.postgresql.org (Postfix) with ESMTP id A49F8B5DC01 for ; Thu, 1 Sep 2011 02:15:09 -0300 (ADT) Received: from [192.168.236.26] (helo=sam.nabble.com) by sam.nabble.com with esmtp (Exim 4.72) (envelope-from ) id 1QyzcK-0002nD-2z for pgsql-sql@postgresql.org; Wed, 31 Aug 2011 22:15:08 -0700 Date: Wed, 31 Aug 2011 22:15:08 -0700 (PDT) From: bhavesh1385 To: pgsql-sql@postgresql.org Message-ID: <1314854108076-4757149.post@n5.nabble.com> Subject: Want some basic compare of data type on PostgreSQL and MySQL MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-0.667 tagged_above=-5 required=5 tests=BAYES_00=-1.9, FREEMAIL_ENVFROM_END_DIGIT=0.1, FREEMAIL_FROM=0.001, T_TO_NO_BRKTS_FREEMAIL=0.01, URI_HEX=1.122 X-Spam-Level: X-Archive-Number: 201109/2 X-Sequence-Number: 35802 Hello All, I Want some basic compare of data type on PostgreSQL and MySQL. I am Try to using create the database on PostgreSQL with the same query on MySQL then it will create a problem... I have make changes according to the Datatype of PostgreSQL and below are the syntax for the query. Into MySQL the Syntax Look like :- --------------------------------- CREATE TABLE IF NOT EXISTS `tbl_admin` ( `iadmin_id` int(11) NOT NULL AUTO_INCREMENT, `vemail` varchar(255) NOT NULL, `vname` varchar(255) NOT NULL, `irole_id` int(11) NOT NULL, `vpassword` varchar(255) NOT NULL, `estatus` enum('Active','InActive') NOT NULL, PRIMARY KEY (`iadmin_id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ; So i want to execute the same query into PostgreSQL and i try the same query but error occur.. and i correct the syntax of the query according to PostgreSQL as following ------------------ CREATE TABLE tbl_admin1 ( iadmin_id integer NOT NULL, vemail character varying, vname character varying, irole_id integer, vpassword character varying, PRIMARY KEY (iadmin_id) ) --------------- NOTE :- Still I have some below confusion into following [1] How to make Primary Key as a Auto Increment...? [2] Suppose I want to put 'ENUM' data type then how i can do that ..? [3] Please suggest me basic Data type Comparesion between PostgreSQL and MySQL .. like :- PostgreSQL MySQL --------------------------------------------- characte varying VARCHAR integer INT like that i want all the possible data type comparision. Thanks, Bhavesh Patel -- View this message in context: http://postgresql.1045698.n5.nabble.com/Want-some-basic-compare-of-data-type-on-PostgreSQL-and-MySQL-tp4757149p4757149.html Sent from the PostgreSQL - sql mailing list archive at Nabble.com.