Re: sql query for manytomany table

2009-02-18 Thread Karen Tracey
On Wed, Feb 18, 2009 at 4:14 PM, May wrote: > > Hello Karen, > > What I need then is to rewrite the model statement. I imported the > tables from MySQL, so the table structures were already set. Should I > add a manytomany field in the contact table? I'm concerned about > django creating a new

Re: sql query for manytomany table

2009-02-18 Thread May
Hello Karen, What I need then is to rewrite the model statement. I imported the tables from MySQL, so the table structures were already set. Should I add a manytomany field in the contact table? I'm concerned about django creating a new separate table from the intermed table I already have. Re

Re: sql query for manytomany table

2009-02-18 Thread Karen Tracey
Regarding whether to dpaste or not: Ideally, there is a happy medium were the bulk of a problem is described in email and dpaste (or simliar) is used for full specifics of the code, if necessary, to get help. Usually when the line (or section) of code that is causing the problem is identified, it

Re: sql query for manytomany table

2009-02-18 Thread Karen Tracey
On Wed, Feb 18, 2009 at 3:13 PM, May wrote: > > Hello Karen, > > Yes, I seem confused here. I've been trying everything. The key is > that this query works correctly in the postgres database to retrieve > the institutionname (institution), using the contact id retrieved from > Project: > > sele

Re: sql query for manytomany table

2009-02-18 Thread May
Hello Angel, Previously, when I placed code into the message, I was reprimanded by users for taking up message space and to use dpaste. However, I agree with you, the code is necessary for future reference. Since, you also seem to agree, I will henceforth place the code into the message. Thank

Re: sql query for manytomany table

2009-02-18 Thread May
Hello Karen, Yes, I seem confused here. I've been trying everything. The key is that this query works correctly in the postgres database to retrieve the institutionname (institution), using the contact id retrieved from Project: select DISTINCT Institution.institution from Contactintermed, Ins

Re: sql query for manytomany table

2009-02-18 Thread Karen Tracey
On Wed, Feb 18, 2009 at 2:46 PM, May wrote: > > Hello Karen, > > Here are my views and models: > > http://dpaste.com/122204/ > > http://dpaste.com/14/ > > > The manytomany table is actually a tertiary table. I was just trying > to use django terms, so people would understand what type of tab

Re: sql query for manytomany table

2009-02-18 Thread Angel Cruz
this off topic, but i am saving these postings in my gmail. The problem with putting your code in dpaste is that in 29 days, that link is invalid, and when I look upon this thread in the future, I will have no idea what your source looks like and what the possible solutions are. dpaste looks coo

Re: sql query for manytomany table

2009-02-18 Thread May
The complete view is here: http://dpaste.com/17/ On Feb 18, 11:46 am, May wrote: > Hello Karen, > > Here are my views and models: > > http://dpaste.com/122204/ > > http://dpaste.com/14/ > > The manytomany table is actually a tertiary table.  I was just trying > to use django terms, so p

Re: sql query for manytomany table

2009-02-18 Thread May
Hello Karen, Here are my views and models: http://dpaste.com/122204/ http://dpaste.com/14/ The manytomany table is actually a tertiary table. I was just trying to use django terms, so people would understand what type of table. Thanks for your help! May On Feb 18, 11:33 am, Karen Trac

Re: sql query for manytomany table

2009-02-18 Thread Karen Tracey
On Wed, Feb 18, 2009 at 1:43 PM, May wrote: > > I need to get the institution name through an intermediary table (two > foreign keys) to display in a template. > > The code is here: > > http://dpaste.com/122204/ > > Thank you anyone, > (Your subject line says manytomany but I don't see any evide

sql query for manytomany table

2009-02-18 Thread May
I need to get the institution name through an intermediary table (two foreign keys) to display in a template. The code is here: http://dpaste.com/122204/ Thank you anyone, May --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Goog