Re: How do I alter an existing column and add a foreign key which isa Primary key to a table?

Поиск
Список
Период
Сортировка
Искать
От
Ron
Тема
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table?
Дата
Msg-id
931856e7-528d-35e5-3b9d-2e972a7df3a6@gmail.com
Ответ на
Список
Дерево обсуждения
How do I alter an existing column and add a foreign key which is aPrimary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? Ron <ronljohnsonjr@gmail.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? Ron <ronljohnsonjr@gmail.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? "David G. Johnston" <david.g.johnston@gmail.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? Ron <ronljohnsonjr@gmail.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Fw: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which is a Primary key to a table? Holger Jakobs <holger@jakobs.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? Ron <ronljohnsonjr@gmail.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? "David G. Johnston" <david.g.johnston@gmail.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? "David G. Johnston" <david.g.johnston@gmail.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? Ron <ronljohnsonjr@gmail.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? Ron <ronljohnsonjr@gmail.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? Avin Kavish <avinkavish@gmail.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
Re: How do I alter an existing column and add a foreign key which isa Primary key to a table? Scott Ribe <scott_ribe@elevated-dev.com>
Re: How do I alter an existing column and add a foreign key whichis a Primary key to a table? Karen Goh <karenworld@yahoo.com>
On 7/21/19 10:23 AM, Karen Goh wrote:
>
> On Sunday, July 21, 2019, 11:13:58 PM GMT+8, Ron  
> wrote:
>
>
> On 7/21/19 10:10 AM, Karen Goh wrote:
[snip]
> >
> > Here is a compressed format :
> >
> > s_tutor
> > --------
> > zipcode(text)
> > tutor_id (I just checked this is becomes a 'serial id ?' based on the
> > generated sql
> >
> > ALTER TABLE public.s_tutor ALTER COLUMN tutor_id ADD GENERATED BY DEFAULT
> > AS IDENTITY (
> > SEQUENCE NAME public.tutor_strtutorid_seq
> > START WITH 1
> > INCREMENT BY 1
> > NO MINVALUE
> > NO MAXVALUE
> > CACHE 1
> > );
> >
> > tutor_subject
> > ----------------
> > tutor_id
> > subject_Names
>
>
> select s_tutor.zipcode
> from s_tutor, tutor_subject
> where s_tutor.tutor_id = tutor_subject.tutor_id
> and tutor_subject.subject_names ='Angela Merkel'
>
> Hi Ron,
>
> Could you explain why you select s_tutor.zipcode from tutor_subject since 
> there is no zipcode inside tutor_subject?
>

I did not do what you think I did.

> Perhaps my reasoning is wrong and I really want to have your expert view.

It might sound harsh, but is not meant to be: this list is for administering 
PostgreSQL, not teaching basic SQL.

-- 
Angular momentum makes the world go 'round.


В списке pgsql-admin по дате отправления
От: Karen Goh
Дата:
От: Avin Kavish
Дата:
FAQ