Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gj5Bp-00064k-T9 for pgsql-admin@arkaria.postgresql.org; Mon, 14 Jan 2019 16:34:18 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gj5Aq-0007cZ-IG for pgsql-admin@arkaria.postgresql.org; Mon, 14 Jan 2019 16:33:16 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gj5Aq-0007a7-84 for pgsql-admin@lists.postgresql.org; Mon, 14 Jan 2019 16:33:16 +0000 Received: from sonic301-4.consmr.mail.bf2.yahoo.com ([74.6.129.43]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gj5Ai-0002SI-Ui for pgsql-admin@postgresql.org; Mon, 14 Jan 2019 16:33:15 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1547483586; bh=aJ7G3UIeKDr3DgGaPbW+zNnT62yDDXPW4jhKp8mZPiU=; h=Date:From:Reply-To:To:Cc:In-Reply-To:References:Subject:From:Subject; b=t1tl2LpunAoWzGpKbABFum8e/bz3gBiebSgawzqtY600aQrR2B6Xf2alnlPV8OKtSTgDNp8EzuPR7MoxDk5SDCk+Yl5H8uUwp5zm9iozE222Uisb2w57PNa0TrUGRQe7blzY3qCNwnDPlHtZLZwnR+wxzttwXXc/1p1cIx9t5P72xIPJnc9yYl6xWRDZMzk7eNmQO/aLuAllCzyrl1My5PUHSyHeznu5rNqcx1D3geq9mFXxxZtcw+os0ity/XdVGgtiotxWoFHm4FY4a3I6YSIs8LgRtxLdBXwHatpXD5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K7wfy8F5hhpJ5kAW1kuqFB8nnNVIoCjfelB9L1oA4McAIsR4 RLqBq7sf2chtMn9VUATVuFKOB5jj2EdQAHDu1vUlJK4pyqUoxGVP.Vre61_OicRzFwbMvA2rwriF y Received: from sonic.gate.mail.ne1.yahoo.com by sonic301.consmr.mail.bf2.yahoo.com with HTTP; Mon, 14 Jan 2019 16:33:06 +0000 Date: Mon, 14 Jan 2019 16:33:01 +0000 (UTC) From: Pepe TD Vo Reply-To: Pepe TD Vo To: Shreeyansh Dba Cc: Pgsql-admin Message-ID: <108345181.18369387.1547483581537@mail.yahoo.com> In-Reply-To: References: <858026322.18309717.1547479488317.ref@mail.yahoo.com> <858026322.18309717.1547479488317@mail.yahoo.com> <1244007825.18357044.1547482143445@mail.yahoo.com> Subject: Re: create tablespaces and users MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_18369386_1202993608.1547483581531" X-Mailer: WebService/1.1.12857 YahooMailNeo Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36 Content-Length: 26257 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk ------=_Part_18369386_1202993608.1547483581531 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable yes, we want to migrate oracle to postgres with a new name of database in p= ostgres and keep all the schemas/triggers as same as oracle, not migrate or= acle to postgres using the default postgres database.=C2=A0Do I need to bui= ld a new database name with all the tablespaces? CREATE TABLESPACE cidr_data LOCATION '/ssd1/postgresql/data';REATE TABLESPA= CE cidr_data LOCATION '/ssd1/postgresql/data';CREATE DATABASE "CIDR"=C2=A0 = =C2=A0 WITH=C2=A0=C2=A0 =C2=A0 OWNER =3D "PSmasteruser"=C2=A0 =C2=A0 ENCODI= NG =3D 'UTF8'=C2=A0 =C2=A0 LC_COLLATE =3D 'en_US.UTF-8'=C2=A0 =C2=A0 LC_CTY= PE =3D 'en_US.UTF-8'=C2=A0 =C2=A0 TABLESPACE =3D cidr_data=C2=A0 =C2=A0 CON= NECTION LIMIT =3D -1; you can keep the=C2=A0 schema / trigger same as oracle or transfer data in = different schema by creating new as per your requirement whereas the public= is the default schema in PostgreSQL. Bach-Nga No one in this world is pure and perfect.=C2=A0 If you avoid people for the= ir mistakes you will be alone. So judge less, love and forgive more.To call= him a dog hardly seems to do him justice though in as much as he had four = legs, a tail, and barked, I admit he was, to all outward appearances. But t= o those who knew him well, he was a perfect gentleman (Hermione Gingold) **Live simply **Love generously **Care deeply **Speak kindly.*** Genuinely = rich *** Faithful talent *** Sharing success=20 On Monday, January 14, 2019 11:27 AM, Shreeyansh Dba wrote: =20 Are you talking about migration..?? If yes, you can keep the=C2=A0 schema = / trigger same as oracle or transfer data in different schema by creating n= ew as per your requirement whereas the public is the default schema in Post= greSQL. Thanks & Regards, Shreeyansh DBA Team www.shreeyansh.com On Mon, Jan 14, 2019 at 9:39 PM Pepe TD Vo wrote: thank you.=C2=A0=C2=A0so after create the database, I need to create user a= nd tablespace with each ownershipcreate user ;create tablespace = location '' owner ; what if I transfer the schemas/triggers, etc... from oracle to postgres, ar= e they stayed the same or what?=C2=A0 What is the best way suggestion I nee= d to do? thank you. v/r,=C2=A0Bach-Nga No one in this world is pure and perfect.=C2=A0 If you avoid people for the= ir mistakes you will be alone. So judge less, love and forgive more.To call= him a dog hardly seems to do him justice though in as much as he had four = legs, a tail, and barked, I admit he was, to all outward appearances. But t= o those who knew him well, he was a perfect gentleman (Hermione Gingold) **Live simply **Love generously **Care deeply **Speak kindly.*** Genuinely = rich *** Faithful talent *** Sharing success=20 On Monday, January 14, 2019 10:48 AM, Shreeyansh Dba wrote: =20 In PostgreSQL tablespaces and user all cluster level objects. tablespace i= s just another name for a folder where the Postgres server process owner (t= ypically =E2=80=9Cpostgres=E2=80=9D system user) is the owner and can write= some files.=C2=A0 In PostgreSQL All objects stored in default tablespace i.e. pg_default.=C2= =A0You can create or alter databases in the tablespace and assign ownership= for that tablespace. Commands use for creating user and tablespace:create user ;creat= e tablespace location '' owner ; Thanks & Regards, Shreeyansh DBA Team www.shreeyansh.com On Mon, Jan 14, 2019 at 8:55 PM Pepe TD Vo wrote: Hello experts,