Unable to create the django_migrations table (ORA-00907: missing right parenthesis)

2019-04-27 Thread tossouwisdom
Django 2.2.2
Cx_oracle 7.2
base Oracle 11g

When I run the django migrate commande, i have error 
django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
django_migrations table (ORA-00907: missing right parenthesis)

  Operations to perform:
  Apply all migrations: admin, auth, contenttypes, sessions
Running migrations:
Traceback (most recent call last):
  File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 82, 
in _execute
return self.cursor.execute(sql)
  File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
line 510, in execute
return self.cursor.execute(query, self._param_generator(params))
cx_Oracle.DatabaseError: ORA-00907: missing right parenthesis

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
line 67, in ensure_schema
editor.create_model(self.Migration)
  File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
line 307, in create_model
self.execute(sql, params or None)
  File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
line 137, in execute
cursor.execute(sql, params)
  File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 99, 
in execute
return super().execute(sql, params)
  File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 67, 
in execute
return self._execute_with_wrappers(sql, params, many=False, 
executor=self._execute)
  File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 76, 
in _execute_with_wrappers
return executor(sql, params, many, context)
  File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 84, 
in _execute
return self.cursor.execute(sql, params)
  File "C:\Python37-32\lib\site-packages\django\db\utils.py", line 89, in 
__exit__
raise dj_exc_value.with_traceback(traceback) from exc_value
  File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 82, 
in _execute
return self.cursor.execute(sql)
  File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
line 510, in execute
return self.cursor.execute(query, self._param_generator(params))
django.db.utils.DatabaseError: ORA-00907: missing right parenthesis

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "manage.py", line 21, in 
main()
  File "manage.py", line 17, in main
execute_from_command_line(sys.argv)
  File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
line 381, in execute_from_command_line
utility.execute()
  File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
line 375, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
  File "C:\Python37-32\lib\site-packages\django\core\management\base.py", line 
323, in run_from_argv
self.execute(*args, **cmd_options)
  File "C:\Python37-32\lib\site-packages\django\core\management\base.py", line 
364, in execute
output = self.handle(*args, **options)
  File "C:\Python37-32\lib\site-packages\django\core\management\base.py", line 
83, in wrapped
res = handle_func(*args, **kwargs)
  File 
"C:\Python37-32\lib\site-packages\django\core\management\commands\migrate.py", 
line 234, in handle
fake_initial=fake_initial,
  File "C:\Python37-32\lib\site-packages\django\db\migrations\executor.py", 
line 91, in migrate
self.recorder.ensure_schema()
  File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
line 69, in ensure_schema
raise MigrationSchemaMissing("Unable to create the django_migrations table 
(%s)" % exc)
django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
django_migrations table (ORA-00907: missing right parenthesis)

-- 
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@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/dac2cda6-2543-4664-aea5-025473ecc3e5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Unable to create the django_migrations table (ORA-00907: missing right parenthesis)

2019-04-27 Thread Joel Mathew
What's the error?
Sincerely yours,

 Joel G Mathew



On Sun, 28 Apr 2019 at 01:26, tossouwisdom  wrote:

> Django 2.2.2
> Cx_oracle 7.2
> base Oracle 11g
>
> When I run the django migrate commande, i have error 
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
>
>   Operations to perform:
>   Apply all migrations: admin, auth, contenttypes, sessions
> Running migrations:
> Traceback (most recent call last):
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 82, in _execute
> return self.cursor.execute(sql)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
> line 510, in execute
> return self.cursor.execute(query, self._param_generator(params))
> cx_Oracle.DatabaseError: ORA-00907: missing right parenthesis
>
> The above exception was the direct cause of the following exception:
>
> Traceback (most recent call last):
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
> line 67, in ensure_schema
> editor.create_model(self.Migration)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
> line 307, in create_model
> self.execute(sql, params or None)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
> line 137, in execute
> cursor.execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 99, in execute
> return super().execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 67, in execute
> return self._execute_with_wrappers(sql, params, many=False, 
> executor=self._execute)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 76, in _execute_with_wrappers
> return executor(sql, params, many, context)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 84, in _execute
> return self.cursor.execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\utils.py", line 89, in 
> __exit__
> raise dj_exc_value.with_traceback(traceback) from exc_value
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 82, in _execute
> return self.cursor.execute(sql)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
> line 510, in execute
> return self.cursor.execute(query, self._param_generator(params))
> django.db.utils.DatabaseError: ORA-00907: missing right parenthesis
>
> During handling of the above exception, another exception occurred:
>
> Traceback (most recent call last):
>   File "manage.py", line 21, in 
> main()
>   File "manage.py", line 17, in main
> execute_from_command_line(sys.argv)
>   File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
> line 381, in execute_from_command_line
> utility.execute()
>   File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
> line 375, in execute
> self.fetch_command(subcommand).run_from_argv(self.argv)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 323, in run_from_argv
> self.execute(*args, **cmd_options)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 364, in execute
> output = self.handle(*args, **options)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 83, in wrapped
> res = handle_func(*args, **kwargs)
>   File 
> "C:\Python37-32\lib\site-packages\django\core\management\commands\migrate.py",
>  line 234, in handle
> fake_initial=fake_initial,
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\executor.py", 
> line 91, in migrate
> self.recorder.ensure_schema()
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
> line 69, in ensure_schema
> raise MigrationSchemaMissing("Unable to create the django_migrations 
> table (%s)" % exc)
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
>
> --
> 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@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/dac2cda6-2543-4664-aea5-025473ecc3e5%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed 

Re: Unable to create the django_migrations table (ORA-00907: missing right parenthesis)

2019-04-27 Thread tossouwisdom


django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
django_migrations table (ORA-00907: missing right parenthesis)


Le samedi 27 avril 2019 19:56:34 UTC, tossouwisdom a écrit :
>
> Django 2.2.2
> Cx_oracle 7.2
> base Oracle 11g
>
> When I run the django migrate commande, i have error 
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
>
>   Operations to perform:
>   Apply all migrations: admin, auth, contenttypes, sessions
> Running migrations:
> Traceback (most recent call last):
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 82, in _execute
> return self.cursor.execute(sql)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
> line 510, in execute
> return self.cursor.execute(query, self._param_generator(params))
> cx_Oracle.DatabaseError: ORA-00907: missing right parenthesis
>
> The above exception was the direct cause of the following exception:
>
> Traceback (most recent call last):
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
> line 67, in ensure_schema
> editor.create_model(self.Migration)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
> line 307, in create_model
> self.execute(sql, params or None)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
> line 137, in execute
> cursor.execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 99, in execute
> return super().execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 67, in execute
> return self._execute_with_wrappers(sql, params, many=False, 
> executor=self._execute)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 76, in _execute_with_wrappers
> return executor(sql, params, many, context)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 84, in _execute
> return self.cursor.execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\utils.py", line 89, in 
> __exit__
> raise dj_exc_value.with_traceback(traceback) from exc_value
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 82, in _execute
> return self.cursor.execute(sql)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
> line 510, in execute
> return self.cursor.execute(query, self._param_generator(params))
> django.db.utils.DatabaseError: ORA-00907: missing right parenthesis
>
> During handling of the above exception, another exception occurred:
>
> Traceback (most recent call last):
>   File "manage.py", line 21, in 
> main()
>   File "manage.py", line 17, in main
> execute_from_command_line(sys.argv)
>   File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
> line 381, in execute_from_command_line
> utility.execute()
>   File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
> line 375, in execute
> self.fetch_command(subcommand).run_from_argv(self.argv)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 323, in run_from_argv
> self.execute(*args, **cmd_options)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 364, in execute
> output = self.handle(*args, **options)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 83, in wrapped
> res = handle_func(*args, **kwargs)
>   File 
> "C:\Python37-32\lib\site-packages\django\core\management\commands\migrate.py",
>  line 234, in handle
> fake_initial=fake_initial,
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\executor.py", 
> line 91, in migrate
> self.recorder.ensure_schema()
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
> line 69, in ensure_schema
> raise MigrationSchemaMissing("Unable to create the django_migrations 
> table (%s)" % exc)
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
>
>

-- 
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@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/852a1dc6-f5ed-4e1d-a84e-d4de0304a55d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Question about form_valid: how to automatically set multiple fields when users input data via CreateView supported form?

2019-04-27 Thread Atsunori Kaneshige
I really appreciate if anybody could give me an advice about form_valid.

Here is what I want to do.
I am making a simple blog.
I am making simple features:
1) only superuser can create articles.
2) logged-in users can make comments to articles.

I followed along tutorials and mostly done.
*But last thing I want to do is that when users make comments to any 
articles, I want author field and article field to be automatically set.*
*Currently, users need to choose author field and article field to make 
comments as well as comment texts.*

The tutorial that I followed along uses form_valid and by using form_valid, 
now I don't need to choose author.
But I have been struggling with how to automatically set article field by 
using form_valid.

I have a simple models.py and views.py below.



class Article(models.Model):
title = models.CharField(max_length=255)
body = models.TextField()
date = models.DateTimeField(auto_now_add=True)
author = models.ForeignKey(
get_user_model(),
on_delete=models.CASCADE,
)

def __str__(self):
return self.title

def get_absolute_url(self):
return reverse('article_detail', args=[str(self.id)])

class Comment(models.Model): # new
article = models.ForeignKey(
Article,
on_delete=models.CASCADE,
related_name = 'comments',
)
comment = models.CharField(max_length=140)
author = models.ForeignKey(
get_user_model(),
on_delete=models.CASCADE,
)

def __str__(self):
return self.comment

def get_absolute_url(self):
return reverse('article_list')


...(not showing all)
#for comment
class ArticleCommentCreateView(LoginRequiredMixin, CreateView):
model = Comment
template_name = 'article_comment_new.html'
fields = ('comment',)
login_url = 'login'

def form_valid(self, form):
form.instance.author = self.request.user
*form.instance.article = self.request.article*
return super().form_valid(form)

I keep getting errors with this code.
I know that *form.instance.article = self.request.article* is something 
wrong, but I am having hard time to figure out how to set article field to 
be automatically set.


Please give any advice about this.
I really appreciate.

Looking forward to hearing from anyone.

Best regards,

Nori




-- 
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@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/fe3a8f1d-2e97-41f8-8af4-fe638cb9e787%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Unable to create the django_migrations table (ORA-00907: missing right parenthesis)

2019-04-27 Thread Rob W
Can you send a copy of your models.py or a copy/paste of the class that shows 
the error?



> On Apr 27, 2019, at 4:41 PM, tossouwisdom  wrote:
> 
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
> 
> Le samedi 27 avril 2019 19:56:34 UTC, tossouwisdom a écrit :
> Django 2.2.2
> Cx_oracle 7.2
> base Oracle 11g
> 
> When I run the django migrate commande, i have error 
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
>   Operations to perform:
>   Apply all migrations: admin, auth, contenttypes, sessions
> Running migrations:
> Traceback (most recent call last):
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 82, in _execute
> return self.cursor.execute(sql)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
> line 510, in execute
> return self.cursor.execute(query, self._param_generator(params))
> cx_Oracle.DatabaseError: ORA-00907: missing right parenthesis
> 
> The above exception was the direct cause of the following exception:
> 
> Traceback (most recent call last):
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
> line 67, in ensure_schema
> editor.create_model(self.Migration)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
> line 307, in create_model
> self.execute(sql, params or None)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
> line 137, in execute
> cursor.execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 99, in execute
> return super().execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 67, in execute
> return self._execute_with_wrappers(sql, params, many=False, 
> executor=self._execute)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 76, in _execute_with_wrappers
> return executor(sql, params, many, context)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 84, in _execute
> return self.cursor.execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\utils.py", line 89, in 
> __exit__
> raise dj_exc_value.with_traceback(traceback) from exc_value
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 82, in _execute
> return self.cursor.execute(sql)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
> line 510, in execute
> return self.cursor.execute(query, self._param_generator(params))
> django.db.utils.DatabaseError: ORA-00907: missing right parenthesis
> 
> During handling of the above exception, another exception occurred:
> 
> Traceback (most recent call last):
>   File "manage.py", line 21, in 
> main()
>   File "manage.py", line 17, in main
> execute_from_command_line(sys.argv)
>   File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
> line 381, in execute_from_command_line
> utility.execute()
>   File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
> line 375, in execute
> self.fetch_command(subcommand).run_from_argv(self.argv)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 323, in run_from_argv
> self.execute(*args, **cmd_options)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 364, in execute
> output = self.handle(*args, **options)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 83, in wrapped
> res = handle_func(*args, **kwargs)
>   File 
> "C:\Python37-32\lib\site-packages\django\core\management\commands\migrate.py",
>  line 234, in handle
> fake_initial=fake_initial,
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\executor.py", 
> line 91, in migrate
> self.recorder.ensure_schema()
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
> line 69, in ensure_schema
> raise MigrationSchemaMissing("Unable to create the django_migrations 
> table (%s)" % exc)
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
> 
> -- 
> 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@googlegroups.com 
> .
> Visit this group at https://groups.google.com/group/django-users 
> .
> To view 

Re: Question about form_valid: how to automatically set multiple fields when users input data via CreateView supported form?

2019-04-27 Thread Atsunori Kaneshige
Sorry, when I make a comment, I get this error.

Any advice would be really appreciated!



AttributeError at /articles/2/comment/

'WSGIRequest' object has no attribute 'article'

Request Method: POST
Request URL: http://127.0.0.1:8000/articles/2/comment/
Django Version: 2.1.5
Exception Type: AttributeError
Exception Value: 

'WSGIRequest' object has no attribute 'article'

Exception Location: 
/Users/Koitaro/Desktop/Web_Development/MMBlog/articles/views.py 
in form_valid, line 75
Python Executable: 
/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/bin/python
Python Version: 3.6.5
Python Path: 

['/Users/Koitaro/Desktop/Web_Development/MMBlog',
 '/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python36.zip',
 '/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6',
 
'/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6/lib-dynload',
 '/Applications/anaconda3/lib/python3.6',
 
'/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6/site-packages']

Server time: Sat, 27 Apr 2019 21:24:45 +


On Saturday, April 27, 2019 at 5:07:19 PM UTC-4, Atsunori Kaneshige wrote:
>
> I really appreciate if anybody could give me an advice about form_valid.
>
> Here is what I want to do.
> I am making a simple blog.
> I am making simple features:
> 1) only superuser can create articles.
> 2) logged-in users can make comments to articles.
>
> I followed along tutorials and mostly done.
> *But last thing I want to do is that when users make comments to any 
> articles, I want author field and article field to be automatically set.*
> *Currently, users need to choose author field and article field to make 
> comments as well as comment texts.*
>
> The tutorial that I followed along uses form_valid and by using 
> form_valid, now I don't need to choose author.
> But I have been struggling with how to automatically set article field by 
> using form_valid.
>
> I have a simple models.py and views.py below.
>
> 
>
> class Article(models.Model):
> title = models.CharField(max_length=255)
> body = models.TextField()
> date = models.DateTimeField(auto_now_add=True)
> author = models.ForeignKey(
> get_user_model(),
> on_delete=models.CASCADE,
> )
>
> def __str__(self):
> return self.title
>
> def get_absolute_url(self):
> return reverse('article_detail', args=[str(self.id)])
>
> class Comment(models.Model): # new
> article = models.ForeignKey(
> Article,
> on_delete=models.CASCADE,
> related_name = 'comments',
> )
> comment = models.CharField(max_length=140)
> author = models.ForeignKey(
> get_user_model(),
> on_delete=models.CASCADE,
> )
>
> def __str__(self):
> return self.comment
>
> def get_absolute_url(self):
> return reverse('article_list')
>
> 
> ...(not showing all)
> #for comment
> class ArticleCommentCreateView(LoginRequiredMixin, CreateView):
> model = Comment
> template_name = 'article_comment_new.html'
> fields = ('comment',)
> login_url = 'login'
>
> def form_valid(self, form):
> form.instance.author = self.request.user
> *form.instance.article = self.request.article*
> return super().form_valid(form)
>
> I keep getting errors with this code.
> I know that *form.instance.article = self.request.article* is something 
> wrong, but I am having hard time to figure out how to set article field to 
> be automatically set.
>
>
> Please give any advice about this.
> I really appreciate.
>
> Looking forward to hearing from anyone.
>
> Best regards,
>
> Nori
>
>
>
>
>

-- 
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@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/352ed4ec-fcf8-4590-ae0b-9c97e29d80ef%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Issues with editing Django files?

2019-04-27 Thread André Toscano
Hi Kevin,
You shouldn't put your files inside the Program Files directory, it's
protected by the system. Instead, you should create a directory (my
suggestion) 'git' in your user's directory.
Inside this directory you should create the directory that will organize
your code.
After that you need to create a virtualenv and installl all Python packages
required in the virtual environment.
Most Python IDE (WingIDE, VS Code, PyCharm, Eclipse, etc) supports virtual
environments.
On Windows you have different options to install Python (Direct, Anaconda,
CygWin, etc) and create the virtual, the best would be to use a Linux or
Unix based system. Consider a virtual machine on VirtualBox with a linux
distribution.
Even if you are able to run as admin, you could create security issues.
Regards
André

Ps.: Here there is a good reference on how to setup the system to develop
with Django: https://tutorial.djangogirls.org/en/django_installation/





Em ter, 23 de abr de 2019 às 09:13, Outomyelement 
escreveu:

> I'm new to Python and am working through the Crash Course for Python book
> using Windows 10 and the latest version of Python and Django.
>
> I am trying to edit the models.py file, but i get a permissions denied:
>
>
> [image: Capture.PNG]
>
> I am learning on a company computer, i'm wondering if my user permissions
> are an issue? Given i'm not an admin for my computer, am I going to have an
> issue trying to save files in these folders without some admin access? I am
> able to run the cmd as admin?
>
> Thank you,
>
> Kevin
>
> --
> 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@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/97307eae-7819-445d-bc9d-4b350a8fbafe%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAPrw5MG7f3umJ2ipeSYnG6r8%3DqkDBbMseWaK8dSy%3DnM9PLPbnQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


GraphQL and Django integration

2019-04-27 Thread Britto .
Hi,

What are the coding challenges to integrate GraphQL with Django?
GraphQL is not like REST it is protocol independent query language.
How to handle mutations at Django?


Regards
Ab

-- 
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@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAF0v3b40%3Db-2U40JaYObpDZNx%3DLuFti7yr4yYBBptJKSA4LTgg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Question about form_valid: how to automatically set multiple fields when users input data via CreateView supported form?

2019-04-27 Thread Britto .
The best way to debug it is add a print function with dir function just
before the error occurring line and see what are available attributes in
request.POST object like this print(dir("", request.POST,
"")) . Also without dir function will show what is available in
POST.
Look at the terminal after running development server and your action to
trigger error, see what are the attributes available for your request.

Probably you have to set form.instance.article = request.POST.get('article')
would work.

Regards
Britto


On Sun, 28 Apr 2019 at 02:56, Atsunori Kaneshige  wrote:

> Sorry, when I make a comment, I get this error.
>
> Any advice would be really appreciated!
>
>
>
> AttributeError at /articles/2/comment/
>
> 'WSGIRequest' object has no attribute 'article'
>
> Request Method: POST
> Request URL: http://127.0.0.1:8000/articles/2/comment/
> Django Version: 2.1.5
> Exception Type: AttributeError
> Exception Value:
>
> 'WSGIRequest' object has no attribute 'article'
>
> Exception Location: 
> /Users/Koitaro/Desktop/Web_Development/MMBlog/articles/views.py
> in form_valid, line 75
> Python Executable:
> /Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/bin/python
> Python Version: 3.6.5
> Python Path:
>
> ['/Users/Koitaro/Desktop/Web_Development/MMBlog',
>  '/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python36.zip',
>  '/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6',
>  
> '/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6/lib-dynload',
>  '/Applications/anaconda3/lib/python3.6',
>  
> '/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6/site-packages']
>
> Server time: Sat, 27 Apr 2019 21:24:45 +
>
>
> On Saturday, April 27, 2019 at 5:07:19 PM UTC-4, Atsunori Kaneshige wrote:
>>
>> I really appreciate if anybody could give me an advice about form_valid.
>>
>> Here is what I want to do.
>> I am making a simple blog.
>> I am making simple features:
>> 1) only superuser can create articles.
>> 2) logged-in users can make comments to articles.
>>
>> I followed along tutorials and mostly done.
>> *But last thing I want to do is that when users make comments to any
>> articles, I want author field and article field to be automatically set.*
>> *Currently, users need to choose author field and article field to make
>> comments as well as comment texts.*
>>
>> The tutorial that I followed along uses form_valid and by using
>> form_valid, now I don't need to choose author.
>> But I have been struggling with how to automatically set article field by
>> using form_valid.
>>
>> I have a simple models.py and views.py below.
>>
>> 
>>
>> class Article(models.Model):
>> title = models.CharField(max_length=255)
>> body = models.TextField()
>> date = models.DateTimeField(auto_now_add=True)
>> author = models.ForeignKey(
>> get_user_model(),
>> on_delete=models.CASCADE,
>> )
>>
>> def __str__(self):
>> return self.title
>>
>> def get_absolute_url(self):
>> return reverse('article_detail', args=[str(self.id)])
>>
>> class Comment(models.Model): # new
>> article = models.ForeignKey(
>> Article,
>> on_delete=models.CASCADE,
>> related_name = 'comments',
>> )
>> comment = models.CharField(max_length=140)
>> author = models.ForeignKey(
>> get_user_model(),
>> on_delete=models.CASCADE,
>> )
>>
>> def __str__(self):
>> return self.comment
>>
>> def get_absolute_url(self):
>> return reverse('article_list')
>>
>> 
>> ...(not showing all)
>> #for comment
>> class ArticleCommentCreateView(LoginRequiredMixin, CreateView):
>> model = Comment
>> template_name = 'article_comment_new.html'
>> fields = ('comment',)
>> login_url = 'login'
>>
>> def form_valid(self, form):
>> form.instance.author = self.request.user
>> *form.instance.article = self.request.article*
>> return super().form_valid(form)
>>
>> I keep getting errors with this code.
>> I know that *form.instance.article = self.request.article* is something
>> wrong, but I am having hard time to figure out how to set article field to
>> be automatically set.
>>
>>
>> Please give any advice about this.
>> I really appreciate.
>>
>> Looking forward to hearing from anyone.
>>
>> Best regards,
>>
>> Nori
>>
>>
>>
>>
>> --
> 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@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/352ed4ec-fcf8-4590-ae0b-9c97e29d80ef%40googlegroups.com
> 
> .
> For more options, visit https://group

Re: Question about form_valid: how to automatically set multiple fields when users input data via CreateView supported form?

2019-04-27 Thread Atsunori Kaneshige
Hi, Britto,

Thank you very much for your reply!
I tried form.instance.article = *self.*request.POST.get('article'), I still 
got an error shown below.

 
RelatedObjectDoesNotExist at /articles/2/comment/

Comment has no article.

Request Method: POST
Request URL: http://127.0.0.1:8000/articles/2/comment/
Django Version: 2.1.5
Exception Type: RelatedObjectDoesNotExist
Exception Value: 

Comment has no article.

Exception Location: 
/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6/site-packages/django/db/models/fields/related_descriptors.py
 
in __get__, line 188
Python Executable: 
/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/bin/python
Python Version: 3.6.5
 

When I tried print(dir(self.request.POST)), I got the below.

 
['__class__', '__contains__', '__copy__', '__deepcopy__', '__delattr__', 
'__delitem__', '__dict__', '__dir__', '__doc__', '__eq__', '__format__', 
'__ge__', '__getattribute__', '__getitem__', '__getstate__', '__gt__', 
'__hash__', '__init__', '__init_subclass__', '__iter__', '__le__', 
'__len__', '__lt__', '__module__', '__ne__', '__new__', '__reduce__', 
'__reduce_ex__', '__repr__', '__setattr__', '__setitem__', '__setstate__', 
'__sizeof__', '__str__', '__subclasshook__', '__weakref__', 
'_assert_mutable', '_encoding', '_getlist', '_mutable', 'appendlist', 
'clear', 'copy', 'dict', 'encoding', 'fromkeys', 'get', 'getlist', 'items', 
'keys', 'lists', 'pop', 'popitem', 'setdefault', 'setlist', 
'setlistdefault', 'update', 'urlencode', 'values']
 

When I tried print(self.request.POST.items), I got the blow, for example.

 
>

 
I typed the message ('I am maru') and needed to specify the article that I 
made the message to. I needed to set fields = ('comment','article',) in 
CommentCreateView, otherwise, I get an error like the below.

 
RelatedObjectDoesNotExist at /articles/2/comment/

Comment has no article.

Request Method: POST
Request URL: http://127.0.0.1:8000/articles/2/comment/
Django Version: 2.1.5
Exception Type: RelatedObjectDoesNotExist
Exception Value: 

Comment has no article.

Exception Location: 
/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6/site-packages/django/db/models/fields/related_descriptors.py
 
in __get__, line 188
Python Executable: 
/Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/bin/python
 

I tried other listed attributes, but seems like I could not find 'article' 
information.
When I set the article field and choose an article, I get like 'article':  
['2'].

Regarding user, by adding form.instance.author = self.request.user, 
'author' was automatically set without choosing it in the form. But, I did 
not see any author information when I tried several 
print(self.request.POST.XXX) 
thing.

When I tried print(self.request.user), the user was printed in terminal.
But, when I tried print(self.request.POST.user), I got an error like below.

 
AttributeError at /articles/2/comment/

'QueryDict' object has no attribute 'user'

Request Method: POST
Request URL: http://127.0.0.1:8000/articles/2/comment/
Django Version: 2.1.5
Exception Type: AttributeError
Exception Value: 

'QueryDict' object has no attribute 'user'


 
When I set the article field, and choose an article in the comment form, I 
tried print(form.instance.article). Then, the article I chose was printed 
in the terminal.
So, seems like form.instance.article is correct.

But how can I set the right part?
form.instance.article = self.response.X???

Where is the user information?
I successfully can access to user by self.request.user, but currently I 
have no idea how to access to article information.

Sorry, any advice I can try would be really appreciated!

Looking forward to hearing advice.

Best regards,

Nori

On Saturday, April 27, 2019 at 10:41:14 PM UTC-4, SimpleHumble wrote:
>
> The best way to debug it is add a print function with dir function just 
> before the error occurring line and see what are available attributes in 
> request.POST object like this print(dir("", request.POST, 
> "")) . Also without dir function will show what is available in 
> POST.
> Look at the terminal after running development server and your action to 
> trigger error, see what are the attributes available for your request.
>
> Probably you have to set form.instance.article = request.POST.get('article') 
> would work.
>
> Regards
> Britto
>
>
> On Sun, 28 Apr 2019 at 02:56, Atsunori Kaneshige  > wrote:
>
>> Sorry, when I make a comment, I get this error.
>>
>> Any advice would be really appreciated!
>>
>>
>>
>> AttributeError at /articles/2/comment/
>>
>> 'WSGIRequest' object has no attribute 'article'
>>
>> Request Method: POST
>> Request URL: http://127.0.0.1:8000/articles/2/comment/
>> Django Version: 2.1.5
>> Exception Type: AttributeError
>> Exception Value: 
>>
>> 'WSGIRequest' object has no attribute 'article'
>>
>> Exception Location: 
>> /Users/Koitaro/Desktop/Web_Development/MMBlog/articles/views.py 
>> in form_valid, l

Re: Question about form_valid: how to automatically set multiple fields when users input data via CreateView supported form?

2019-04-27 Thread Britto .
set form.instance.article = request.POST.get('article')
and add article in fields too like fields = ('comment', 'article')
it should work flawlessly.


Regards
Britto


On Sun, 28 Apr 2019 at 09:30, Atsunori Kaneshige  wrote:

> Hi, Britto,
>
> Thank you very much for your reply!
> I tried form.instance.article = *self.*request.POST.get('article'), I
> still got an error shown below.
>
>
> RelatedObjectDoesNotExist at /articles/2/comment/
>
> Comment has no article.
>
> Request Method: POST
> Request URL: http://127.0.0.1:8000/articles/2/comment/
> Django Version: 2.1.5
> Exception Type: RelatedObjectDoesNotExist
> Exception Value:
>
> Comment has no article.
>
> Exception Location: 
> /Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6/site-packages/django/db/models/fields/related_descriptors.py
> in __get__, line 188
> Python Executable:
> /Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/bin/python
> Python Version: 3.6.5
>
>
> When I tried print(dir(self.request.POST)), I got the below.
>
>
> ['__class__', '__contains__', '__copy__', '__deepcopy__', '__delattr__',
> '__delitem__', '__dict__', '__dir__', '__doc__', '__eq__', '__format__',
> '__ge__', '__getattribute__', '__getitem__', '__getstate__', '__gt__',
> '__hash__', '__init__', '__init_subclass__', '__iter__', '__le__',
> '__len__', '__lt__', '__module__', '__ne__', '__new__', '__reduce__',
> '__reduce_ex__', '__repr__', '__setattr__', '__setitem__', '__setstate__',
> '__sizeof__', '__str__', '__subclasshook__', '__weakref__',
> '_assert_mutable', '_encoding', '_getlist', '_mutable', 'appendlist',
> 'clear', 'copy', 'dict', 'encoding', 'fromkeys', 'get', 'getlist', 'items',
> 'keys', 'lists', 'pop', 'popitem', 'setdefault', 'setlist',
> 'setlistdefault', 'update', 'urlencode', 'values']
>
>
> When I tried print(self.request.POST.items), I got the blow, for example.
>
>
>  ['qRGlWdPTX9qxpFidwKT8bvY3vWXx5caE2wJZSQTtyWodYSICmW4yMwXG3FAn9oQk'],
> 'comment': ['I am maru'], 'article': ['2']}>>
>
>
> I typed the message ('I am maru') and needed to specify the article that I
> made the message to. I needed to set fields = ('comment','article',) in
> CommentCreateView, otherwise, I get an error like the below.
>
>
> RelatedObjectDoesNotExist at /articles/2/comment/
>
> Comment has no article.
>
> Request Method: POST
> Request URL: http://127.0.0.1:8000/articles/2/comment/
> Django Version: 2.1.5
> Exception Type: RelatedObjectDoesNotExist
> Exception Value:
>
> Comment has no article.
>
> Exception Location: 
> /Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/lib/python3.6/site-packages/django/db/models/fields/related_descriptors.py
> in __get__, line 188
> Python Executable:
> /Users/Koitaro/.local/share/virtualenvs/MMBlog-58h299OP/bin/python
>
>
> I tried other listed attributes, but seems like I could not find 'article'
> information.
> When I set the article field and choose an article, I get like 'article':
> ['2'].
>
> Regarding user, by adding form.instance.author = self.request.user,
> 'author' was automatically set without choosing it in the form. But, I did
> not see any author information when I tried several 
> print(self.request.POST.XXX)
> thing.
>
> When I tried print(self.request.user), the user was printed in terminal.
> But, when I tried print(self.request.POST.user), I got an error like below.
>
>
> AttributeError at /articles/2/comment/
>
> 'QueryDict' object has no attribute 'user'
>
> Request Method: POST
> Request URL: http://127.0.0.1:8000/articles/2/comment/
> Django Version: 2.1.5
> Exception Type: AttributeError
> Exception Value:
>
> 'QueryDict' object has no attribute 'user'
>
>
>
> When I set the article field, and choose an article in the comment form, I
> tried print(form.instance.article). Then, the article I chose was printed
> in the terminal.
> So, seems like form.instance.article is correct.
>
> But how can I set the right part?
> form.instance.article = self.response.X???
>
> Where is the user information?
> I successfully can access to user by self.request.user, but currently I
> have no idea how to access to article information.
>
> Sorry, any advice I can try would be really appreciated!
>
> Looking forward to hearing advice.
>
> Best regards,
>
> Nori
>
> On Saturday, April 27, 2019 at 10:41:14 PM UTC-4, SimpleHumble wrote:
>>
>> The best way to debug it is add a print function with dir function just
>> before the error occurring line and see what are available attributes in
>> request.POST object like this print(dir("", request.POST,
>> "")) . Also without dir function will show what is available in
>> POST.
>> Look at the terminal after running development server and your action to
>> trigger error, see what are the attributes available for your request.
>>
>> Probably you have to set form.instance.article = request.POST.get('article')
>> would work.
>>
>> Regards
>> Britto
>>
>>
>> On Sun, 28 Apr 2019 at 02:56, Atsunori Kaneshige 
>> wrote:
>>
>>> Sorry, when

Re: Unable to create the django_migrations table (ORA-00907: missing right parenthesis)

2019-04-27 Thread chirag soni
After executive these two commands:

py manage.py makemigrations
py manage.py migrate

Still you face the problem then go to migrations folder and delete the
associated(or all) migrations then re execute the above commands.

On Sun, 28 Apr 2019, 01:26 tossouwisdom  Django 2.2.2
> Cx_oracle 7.2
> base Oracle 11g
>
> When I run the django migrate commande, i have error 
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
>
>   Operations to perform:
>   Apply all migrations: admin, auth, contenttypes, sessions
> Running migrations:
> Traceback (most recent call last):
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 82, in _execute
> return self.cursor.execute(sql)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
> line 510, in execute
> return self.cursor.execute(query, self._param_generator(params))
> cx_Oracle.DatabaseError: ORA-00907: missing right parenthesis
>
> The above exception was the direct cause of the following exception:
>
> Traceback (most recent call last):
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
> line 67, in ensure_schema
> editor.create_model(self.Migration)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
> line 307, in create_model
> self.execute(sql, params or None)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\base\schema.py", 
> line 137, in execute
> cursor.execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 99, in execute
> return super().execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 67, in execute
> return self._execute_with_wrappers(sql, params, many=False, 
> executor=self._execute)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 76, in _execute_with_wrappers
> return executor(sql, params, many, context)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 84, in _execute
> return self.cursor.execute(sql, params)
>   File "C:\Python37-32\lib\site-packages\django\db\utils.py", line 89, in 
> __exit__
> raise dj_exc_value.with_traceback(traceback) from exc_value
>   File "C:\Python37-32\lib\site-packages\django\db\backends\utils.py", line 
> 82, in _execute
> return self.cursor.execute(sql)
>   File "C:\Python37-32\lib\site-packages\django\db\backends\oracle\base.py", 
> line 510, in execute
> return self.cursor.execute(query, self._param_generator(params))
> django.db.utils.DatabaseError: ORA-00907: missing right parenthesis
>
> During handling of the above exception, another exception occurred:
>
> Traceback (most recent call last):
>   File "manage.py", line 21, in 
> main()
>   File "manage.py", line 17, in main
> execute_from_command_line(sys.argv)
>   File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
> line 381, in execute_from_command_line
> utility.execute()
>   File "C:\Python37-32\lib\site-packages\django\core\management\__init__.py", 
> line 375, in execute
> self.fetch_command(subcommand).run_from_argv(self.argv)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 323, in run_from_argv
> self.execute(*args, **cmd_options)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 364, in execute
> output = self.handle(*args, **options)
>   File "C:\Python37-32\lib\site-packages\django\core\management\base.py", 
> line 83, in wrapped
> res = handle_func(*args, **kwargs)
>   File 
> "C:\Python37-32\lib\site-packages\django\core\management\commands\migrate.py",
>  line 234, in handle
> fake_initial=fake_initial,
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\executor.py", 
> line 91, in migrate
> self.recorder.ensure_schema()
>   File "C:\Python37-32\lib\site-packages\django\db\migrations\recorder.py", 
> line 69, in ensure_schema
> raise MigrationSchemaMissing("Unable to create the django_migrations 
> table (%s)" % exc)
> django.db.migrations.exceptions.MigrationSchemaMissing: Unable to create the 
> django_migrations table (ORA-00907: missing right parenthesis)
>
> --
> 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@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/dac2cda6-2543-4664-aea5-025473ecc3e5%40googlegroups.com
>