Services
24×7×365 Technical Support
Migration to PostgreSQL
High Availability Deployment
Database Audit
Remote DBA for PostgreSQL
Products
Postgres Pro Enterprise
Postgres Pro Standard
Cloud Solutions
Postgres Extensions
Resources
Blog
Documentation
Webinars
Videos
Presentations
Community
Events
Training Courses
Books
Demo Database
Mailing List Archives
About
Leadership team
Partners
Customers
In the News
Press Releases
Press Info
Services
24×7×365 Technical Support
Migration to PostgreSQL
High Availability Deployment
Database Audit
Remote DBA for PostgreSQL
Products
Postgres Pro Enterprise
Postgres Pro Standard
Cloud Solutions
Postgres Extensions
Resources
Blog
Documentation
Webinars
Videos
Presentations
Community
Events
Training Courses
Books
Demo Database
Mailing List Archives
About
Leadership team
Partners
Customers
In the News
Press Releases
Press Info
Facebook
Downloads
Home
>
mailing lists
[GENERAL] How to access a second database - Mailing list pgsql-general
From
Sherman Willden
Subject
[GENERAL] How to access a second database
Date
October 31, 2017
13:15:14
Msg-id
CAGv-wXGfhp=S31kb2KwuLzoSbCKmw3pYutefyWs03i_uNYBbbQ@mail.gmail.com
Whole thread
Raw
Responses
Re: [GENERAL] How to access a second database
Re: [GENERAL] How to access a second database
List
pgsql-general
Tree view
I am trying to access a table from another database. I have the permissions to create under my own login. I have performed the following so far:
sherman@sql-dev: createdb sandbox01
sherman@sql-dev:~$ createdb sandbox02.
After logging into sandbox02 I performed the following: sandbox02=# CREATE TABLE last_names(last_name TEXT);
sandbox02=# INSERT INTO last_names VALUES(willden);
Now I think I want to use a foreign key in sandbox01. Is the following how it works after logging into sandbox01?
sandbox01=# CREATE TABLE first_and_last(first_name TEXT, last_name FOREIGN KEY last_name REFERENCES sandbox02(last_names(last_name))
and then sandbox01=# INSERT INTO first_and_last(sherman, willden);
Thank you;
Sherman
pgsql-general
by date:
Previous
From:
Ivan Voras
Date:
31 October 2017, 12:50:51
Subject:
Re: [GENERAL] Roles inherited from a role which is the owner of adatabase can drop it?
Next
From:
Stanislav Ganin
Date:
31 October 2017, 13:40:47
Subject:
Re: [GENERAL] How to access a second database
Есть вопросы? Напишите нам!
Соглашаюсь с условиями обработки персональных данных
I confirm that I have read and accepted PostgresPro’s
Privacy Policy
.
I agree to get Postgres Pro discount offers and other marketing communications.
✖
×
×
Everywhere
Documentation
Mailing list
List:
all lists
pgsql-general
pgsql-hackers
buildfarm-members
pgadmin-hackers
pgadmin-support
pgsql-admin
pgsql-advocacy
pgsql-announce
pgsql-benchmarks
pgsql-bugs
pgsql-chat
pgsql-cluster-hackers
pgsql-committers
pgsql-cygwin
pgsql-docs
pgsql-hackers-pitr
pgsql-hackers-win32
pgsql-interfaces
pgsql-jdbc
pgsql-jobs
pgsql-novice
pgsql-odbc
pgsql-patches
pgsql-performance
pgsql-php
pgsql-pkg-debian
pgsql-pkg-yum
pgsql-ports
pgsql-rrreviewers
pgsql-ru-general
pgsql-sql
pgsql-students
pgsql-testers
pgsql-translators
pgsql-www
psycopg
Period
anytime
within last day
within last week
within last month
within last 6 months
within last year
Sort by
date
reverse date
rank
Services
24×7×365 Technical Support
Migration to PostgreSQL
High Availability Deployment
Database Audit
Remote DBA for PostgreSQL
Products
Postgres Pro Enterprise
Postgres Pro Standard
Cloud Solutions
Postgres Extensions
Resources
Blog
Documentation
Webinars
Videos
Presentations
Community
Events
Training Courses
Books
Demo Database
Mailing List Archives
About
Leadership team
Partners
Customers
In the News
Press Releases
Press Info
By continuing to browse this website, you agree to the use of cookies. Go to
Privacy Policy
.
I accept cookies