Re: migrating from sqlite to mysql breaks the site

2019-03-14 Thread Pedram Badakhchani
details as expected. However, switching to mysql breaks the redirecting to post details. I get No Post matches the given query. I am not sure why this happens. I thought the Django ORM means that the code should work regardless of the database used. So I am confused why this happens. best Pedram

Re: migrating from sqlite to mysql breaks the site

2019-03-13 Thread Pedram Badakhchani
bump On Wednesday, 6 March 2019 10:44:56 UTC, Pedram Badakhchani wrote: > > specifically in the get_absolute_url method. >> > > I don't understand why this works fine with sqlite but breaks in mysql. > > thanks for any help. > -- You received this message b

Re: migrating from sqlite to mysql breaks the site

2019-03-06 Thread Pedram Badakhchani
> > specifically in the get_absolute_url method. > I don't understand why this works fine with sqlite but breaks in mysql. thanks for any help. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving

migrating from sqlite to mysql breaks the site

2019-03-06 Thread Pedram Badakhchani
atus = models.CharField(max_length=10, choices=STATUS_CHOICES, default='draft') objects = models.Manager() # The default manager. published = PublishedManager() # Our custom manager. class Meta: ordering = ('-publish',) def __str__(self): return self.title

Django 2 - migrating to Mysql from sqlite issues

2019-03-05 Thread Pedram Badakhchani
ublish - 2019-01-31 10:56:40.00 created - 2019-01-31 10:56:59.674959 updated - 2019-01-31 10:56:59.674976 status - published author_id - 1 I would appreciate any advice on why this is happening when the database is switched to MySQl thank you Pedram -- You received this message because you

Re: Exception happened during processing of request from ...

2019-02-08 Thread Pedram Badakhchani
I am getting similar errors, also running Django 2.15 with python 3.72, would be very interested if you have found a solution On Thursday, 31 January 2019 15:52:38 UTC, Jon bae wrote: > > Hello, > I'm running here *django 2.1.5* with *python 3.7.2* (installed with > homebrew) on a macOS (mojave)

Re: "RuntimeError: Error creating new content types."

2015-05-15 Thread Pedram Negahdar
Same problem nothing is working!! On Wednesday, May 6, 2015 at 6:07:45 AM UTC-4, Max Usachev wrote: > > Try to migrate auth application first, and then others: > manage.py migrate auth > manage.py migrate > > среда, 29 апреля 2015 г., 14:12:33 UTC+3 пользователь Shubham Goyal > написал: >> >> Fac

Re: Parenthesis in regex in URLConf

2011-05-23 Thread Pedram
Thanks but I still have problem. My URLConf is like this: Thank you very much. Problem Solved :) On May 23, 1:39 pm, Tom Evans wrote: > On Mon, May 23, 2011 at 10:25 AM, Pedram wrote: > > Hello, > > I have a regular expression for usernames and I want to use this regex > &

Parenthesis in regex in URLConf

2011-05-23 Thread Pedram
Hello, I have a regular expression for usernames and I want to use this regex in my URLConf and bind that to a view. The problem is, I have parenthesis in my regex which should not consider as *args*. Here's my regex: ^[a-zA-Z0-9]+((\.[a-zA-Z0-9]+)|(_[a-zA-Z-0-9]+))*$ Values in '()' are necessary

Extending Profile with a ForeignKey field

2010-09-25 Thread Pedram
Hi, I want to add a ForeignKey field in UserProfile. Sth like this: from myapp.models import Person class Profile(models.Model): user = models.ForeignKey(User, unique=True, verbose_name=_('user')) name = models.CharField(_('name'), max_length=50, null=True, blank=True) about = m

Re: Unknown command: graph_models

2010-07-14 Thread Pedram
On Jul 14, 8:56 pm, Rolando Espinoza La Fuente wrote: > On Wed, Jul 14, 2010 at 6:55 AM, Pedram wrote: > > Hello, > > Sorry if this thread already exists. I've searched but nothing could > > find. > > I tried this code: > > python manage.py graph_models gr

Unknown command: graph_models

2010-07-14 Thread Pedram
Hello, Sorry if this thread already exists. I've searched but nothing could find. I tried this code: python manage.py graph_models graphdb -o scheme.dot But I got this error: Unknown command: 'graph_models' Type 'manage.py help' for usage. I installed python-graphviz, graphviz-deb, python-django-e