you don't need songid = models.Integerfield()
On Tue, Jul 23, 2013 at 6:04 AM, Brian Millham wrote:
> I have the following models:
>
> class Requestlist(models.Model):
>>id = models.IntegerField(primary_key=True)
>>songid = models.Integerfield()
>>song = ForeignKey('Song', db_column
you are very welcome
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users
Avraham Serour writes:
> you don't need songid = models.Integerfield()
... and the ForeignKey should not specify a db_column.
>
> On Tue, Jul 23, 2013 at 6:04 AM, Brian Millham wrote:
>
> I have the following models:
>
> class Requestlist(models.Model):
> id = models.Int
Exactly @Babatundle =)
2013/7/23 Babatunde Akinyanmi
> Override your get method but it's easier to override the get_context_data
> method like
> # From my head
> def get_context_data(**kwargs):
> context = super(IndexView, self).get_context_data(**kwargs)
> #filter1 is already present a
Hi all,
I'm doing a web site where the users can upload some images. These images
are uploaded through django-storages [0] to Amazon S3. But it's taking too
long to uploaded these files.
There is a way where I can upload these images async?
Thank you in advance!
Nicolas.
[0] http://django-stora
I have many database setted in my setting.py in my formModel, when I try
to validate the form, show me error:
http://stackoverflow.com/questions/17797419/modelforms-and-multiple-datasbase-error-in-form-is-valid
The problem is.. is_valid is going to "default" database... how can I force
to got
I've done that with this code:
if form.is_valid():
> f = form.save(commit = False)
> f.save(using='yourdatabase')
Works fine for me.
On Tuesday, July 23, 2013 1:21:29 PM UTC-4, Fellipe Henrique wrote:
>
> I have many database setted in my setting.py in my formModel, when I try
> to vali
The problem is: when usng modelForm, it try to validate the unique key in
the database, and this validation use a default database.. if I remove
primary_key=True in my model, work fine, but I need to set the pk in my
model, because when I try to get using: obj.get(xx) show me error...
I try ever
This bug has been solved here: https://code.djangoproject.com/ticket/20782
On Friday, July 19, 2013 10:05:46 PM UTC+5:30, Debanshu Kundu wrote:
>
> Also interestingly, if I do:
>
> Book.objects.values('rating').aggregate(Max('rating'))
>
> It returns an empty dict without performing any DB query!
This bug has been solved here: https://code.djangoproject.com/ticket/20782
On Friday, July 19, 2013 11:49:52 AM UTC+5:30, Debanshu Kundu wrote:
>
> If I have a model *Book* defined as:
>
> class Book(models.Model):
>name = models.CharField(max_length=300)
>pages = models.IntegerField()
>
Fellipe,
See:
https://docs.djangoproject.com/en/dev/topics/db/multi-db/
There are a number of ways for force use of a specific database.
You can force it per query, per table, or by any other criteria you
like. You may need to set up a simple "database router".
--Fred
-
virtualenv seems to work well and I can get django tamed.
On Saturday, July 20, 2013 5:55:21 PM UTC-4, Jay Lozier wrote:
>
> Using openSUSE 12.3
> python 2.7.3
> django 1.5.1 installed manually and verified
>
> When I enter "django-admin.py startproject mysite" at the command prompt I
> get the f
virtualenv works, this for the link.
On Sunday, July 21, 2013 10:09:59 PM UTC-4, Jay Lozier wrote:
>
> I get the following error when run python manage.py runserver:
>
> OS openSUSE 12.3
> django 1.7
>
>
> boopers@linux-nss6:~/myfirstsite> python manage.py runserver
> Traceback (most recent call l
*1.*
I wrote this to make python shell only list Words that have no translation.
>>> Word.objects.filter(translation='')
[, , ]
*2.*
How can I use the above filter result and chain it,
so that I can make a new list that displays the field *"articulate"*,
from the other table "Pronunciation"?
Apache solr or ElasticSearch: yes
Haystack: maybe
Regex: no
2013/7/21 Kamal Kaur
> We can search from database using phonetic codes or queries. I want an
> advanced search module in my project. That can suggest similar
> spellings from database, if user enters something wrong, like if
> somethi
On Wed, Jul 24, 2013 at 5:15 AM, Amirouche Boubekki
wrote:
> Apache solr or ElasticSearch: yes
> Haystack: maybe
> Regex: no
Thanks.
Studying ElasticSearch currently.
--
Kamaljeet Kaur
kamalkaur188.wordpress.com
facebook.com/kaur.188
--
You received this message because you are subscribed
On Mon, Jul 22, 2013 at 10:53 AM, Harjot Mann wrote:
> In django when we add a new field in existing class, we need to drop
> the table and then run the syncdb again. Is there any alternative for
> it so that we can add the field without dropping the table??
>
You can also run sqldiff django comm
Suppose I have following table in my database :
activity1 | activity2 | activity3 | activity4 | activity5
6| 7 | 5| 9 | 8
The first row are the field names and the second row are the data
entries. How can I get 3 maximum values out of each row of this t
I'm probably doing something stupid here but I can't see it. I'm trying to
implement password change and reset using auth, and I'm getting a "No
Reverse Match" error for the password_reset_done view. Normally that would
mean that I forgot to creaste a url that calls this view, but I have, and
The problem is, as you already stated the argument for the ReverseMatch. I
had this problem once, and the error was that i used the url tag in the
template wrong - it changed between two django versions. My urls are
defined as yours, in the templates i use: {% url "password_reset_done"
paramete
20 matches
Mail list logo