<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Forum PostgreSQL - MySQL to PostgreSQL]]></title>
	<link rel="self" href="http://forum.postgresql.org.pl/extern.php?action=feed&amp;tid=1331&amp;type=atom"/>
	<updated>2012-05-07T14:03:48Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.postgresql.org.pl/viewtopic.php?id=1331</id>
		<entry>
			<title type="html"><![CDATA[Odp: MySQL to PostgreSQL]]></title>
			<link rel="alternate" href="https://forum.postgresql.org.pl/viewtopic.php?pid=3594#p3594"/>
			<content type="html"><![CDATA[Sciagnij sobie pgAdmina - szybko nauczysz sie skladni
Ad 1 
CREATE DATABASE x
  WITH ENCODING = 'UTF8'
       TABLESPACE = pg_default
        TEMPLATE=template0
       CONNECTION LIMIT = -1;


ad 2 wersja uproszczona
CREATE TABLE users
(
   id bigserial PRIMARY KEY, 
   login varchar(255) UNIQUE, 
   password varchar (255) NOT NULL
) 
WITH (OIDS = FALSE);]]></content>
			<author>
				<name><![CDATA[c_michal]]></name>
				<uri>https://forum.postgresql.org.pl/profile.php?id=627</uri>
			</author>
			<updated>2012-05-07T14:03:48Z</updated>
			<id>https://forum.postgresql.org.pl/viewtopic.php?pid=3594#p3594</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[MySQL to PostgreSQL]]></title>
			<link rel="alternate" href="https://forum.postgresql.org.pl/viewtopic.php?pid=3593#p3593"/>
			<content type="html"><![CDATA[Hej,

uczę się dopiero postgresa i potrzebuję tych zapytań z mysql w postgresie wykonać, widzę że są różnice i to wcale nie małe, mógłby mi ktoś pomóc przerobić dla postgresa ? 

create database x character set utf8 collate utf8_polish_ci;

GRANT ALL PRIVILEGES ON item_directory.* TO item@localhost IDENTIFIED BY 'item';
GRANT ALL PRIVILEGES ON item_directory.* TO item@"%" IDENTIFIED BY 'item';

flush privileges;



create table users (
	id bigint(20) not null auto_increment,
	login varchar(255) not null,
	password varchar(255) not null,
	
	PRIMARY KEY (id),
	UNIQUE KEY unique_users_login (login)

);


create table locations (
	id bigint(20) not null auto_increment,
	name varchar(255) not null,
	
	PRIMARY KEY (id),
	UNIQUE KEY unique_name (name)
);


Z gory wielkie dzieki]]></content>
			<author>
				<name><![CDATA[daxstec]]></name>
				<uri>https://forum.postgresql.org.pl/profile.php?id=1417</uri>
			</author>
			<updated>2012-05-05T11:21:43Z</updated>
			<id>https://forum.postgresql.org.pl/viewtopic.php?pid=3593#p3593</id>
		</entry>
</feed>
