Re: Pandas in Django

2014-03-08 Thread Alvin Lindstam
Hello Judy. You could increase the likelihood of a helpful response: -Provide more of the code, such as relevant imports. -Provide the full error report when you get an exception (copy-pasted). -Use the correct channel. It seems that you are using the pandas library and the code you included

Re: database design problem.

2014-03-15 Thread Alvin Lindstam
Actually, the Django term for this is "through". Not via. See https://docs.djangoproject.com/en/1.6/topics/db/models/#extra-fields-on-many-to-many-relationships on how to specify the intermediate table to be used in many-to-many relationships. Den lördagen den 15:e mars 2014 kl. 18:01:02 UTC

Re: Question on a resembling function on truncatewords

2014-04-13 Thread Alvin Lindstam
And also: 1) You have misspelled description in the shorten_words method. In you model field definition, and in your length check it's "description" but in the print/return statements it's spelled "desciption". 2) The python slicing operator is clever enough to handle indexes that are out of b