pubu...@pubuntu:~/django-trunk/build/lib/django/bin/mysite$

DATABASE_ENGINE = 'sqlite3'           # 'postgresql_psycopg2',
'postgresql', 'my
sql', 'sqlite3' or 'ado_mssql'.
DATABASE_NAME = '/django-trunk/build/lib/django/bin/mysite/mysite/
mysite.db'
         # Or path to database file if using sqlite3.
DATABASE_USER = ''             # Not used with sqlite3.
DATABASE_PASSWORD = ''         # Not used with sqlite3.
DATABASE_HOST = ''             # Set to empty string for localhost.
Not used wit
h sqlite3.
DATABASE_PORT = ''             # Set to empty string for default. Not
used with
sqlite3.
I created a mysite.db in my directory by vi. Because I looked at an
earlier discussion that said:
For your DATABASE_NAME, try using an absolute path without the tilde
(~)
shortcut, that might solve it:
DATABASE_NAME = '/home/ssk/Projects/mysites/mysite/mysite.db'
So is that mysites/mysite/mysite.db a real file?

I made a mysite directory and mysite.db, but get same error when I do
python manage.py syncdb :
File "/usr/lib/python2.5/site-packages/django/db/backends/sqlite3/
base.py", li
ne 170, in _cursor
    self.connection = Database.connect(**kwargs)
sqlite3.OperationalError: unable to open database file


On May 4, 8:08 am, bconnors <bob.conn...@wdc.usda.gov> wrote:
> I’m getting the error “unable to open database file”
>
> I have sqlite3:
>
> pubu...@pubuntu:~/django-trunk/build/lib/django/bin/mysite$ python
> Python 2.5.2 (r252:60911, Jul 31 2008, 17:28:52)
> [GCC 4.2.3 (Ubuntu 4.2.3-2ubuntu7)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
>
> >>> import sqlite3
>
> I have in ubuntu:
> "/usr/lib/python2.5/site-packages/django/db/backends/sqlite3
>
> I saw an earlier chat with:
> For your DATABASE_NAME, try using an absolute path without the tilde
> (~)
> shortcut, that might solve it:
> DATABASE_NAME = '/home/ssk/Projects/mysites/mysite/mysite.db'
> So is that mysites/mysite/mysite.db a real file?
>
> I have my django working in:
> Django-trunk/build/lib/django/bin/mysite
> When I do pubu...@pubuntu:~/django-trunk/build/lib/django/bin/mysite$
> python manage.py runserver
> I get the message starting with:
> It worked!
> Congratulations on your first Django-powered page.
> When I do python manage.py syncdb I get:
> File "/usr/lib/python2.5/site-packages/django/db/backends/sqlite3/
> base.py", li
> ne 170, in _cursor
>     self.connection = Database.connect(**kwargs)
> sqlite3.OperationalError: unable to open database file
> pubu...@pubuntu:~/django-trunk/build/lib/django/bin/mysite$
>
> sorry for the bother, but what can i do?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to