On Feb 20, 12:50 pm, Brandon Taylor wrote:
> OK, I am pretty sure I found out where to put the tns_names.ora file:
> $ORACLE_HOME/network/admin
>
> But, I'm confused as to how to specify the database name. From the
> Django Oracle docs (http://docs.djangoproject.com/en/dev/ref/
> databases/?from=
On Feb 20, 2:08 pm, Brandon Taylor wrote:
> Hi Ian,
>
> Here's her's the quick model I wrote to try to select *something*:
>
> class TestCategory(models.Model):
> name = models.CharField(max_length=255)
> class Meta:
> db_table = 'ACTIVITY_CODE.CATEGORIES'
Don't include the schem
On Feb 20, 2:25 pm, Brandon Taylor wrote:
> however attempting to retrieve the Category objects from a view
> results in:
> DatabaseError: ORA-00942: table or view does not exist
>
> Thoughts?
You can definitely use views with Django (although inspectdb will
blissfully ignore them). We do that
On Feb 20, 3:01 pm, Brandon Taylor wrote:
> Actually I was referring to my action in views.py to get the Category
> objects:
>
> from activity_codes.models import * (this is the auto-generated
> models.py)
>
> def home(request):
> categories = Categories.objects.all()
> return render_to_r
On Feb 20, 3:14 pm, Brandon Taylor wrote:
> I think I may have found the culprit (?), but I have no idea how to
> fix this. In my project folder, there is a file called sqlnet.log.
> Here's the last entry:
>
> Fatal NI connect error 12505, connecting to:
> (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)
>
On Feb 20, 3:26 pm, Brandon Taylor wrote:
> Yes, I'm just using the built-in server for local development. I've
> restarted it dozens of times, cleared my browser cache, etc.
>
> Is the built-in server not compatible with Oracle? If not, I'll just
> get an Apache/mod_wsgi instance running on my M
On Mar 5, 2:29 pm, "robertmalik...@googlemail.com"
wrote:
> Edit settings.py and;
> DATABASE_NAME = '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(Host=db_hostname)
> (Port=1521))(CONNECT_DATA=(SID=db_sid)))'
>
> Replace the db_sid with your database sid and db_hostname the database
> hostname or IP.
You
On Mar 6, 1:38 pm, Alex Koshelev wrote:
> R.objects.values('type').aggregate(Count('type'))
On Mar 6, 2:12 pm, kbs wrote:
> returned an empty dict
Use annotate, not aggregate:
R.objects.values('type').annotate(Count('type'))
Regards,
Ian
--~--~-~--~~~---~--~~
On Mar 14, 8:04 am, Sergio wrote:
> wow, that's interesting. I was not aware if this.
>
> So, coming to the real question, here is my use case which raised this
> questions:
>
> I've a class in the model with two CharFields. When validating data
> inputs, I need to check that, if the user filled
On Mar 19, 9:21 am, Brandon Taylor wrote:
> Hi Everyone,
>
> I'm using the svn checkout of Django-Tagging and Django-Trunk. Tagging
> is working perfectly for me with any other database except, of course,
> Oracle, which is what I need it to work in.
>
> I can't get the TagField() to show up in t
On Mar 19, 4:55 pm, elm wrote:
> I have bee trying to deal with an erratic error for the last 3 day. I
> hope you can rescue me!!!
>
> After experiencing erratic errors that appeared from time to time on a
> larger project (i.e. ViewDoesNotExist) I have reduced my project to a
> very simple appli
On Mar 20, 8:26 am, Brandon Taylor wrote:
> Hi Ian,
>
> Thanks for the response. The test case is adding the TagField() to any
> model.
>
> Here's an excerpt from my model class:
>
> #models.py
> from django.db import models
> from django.contrib import admin
> from tagging.models import Tag
> fr
On Mar 20, 6:51 am, elm wrote:
> > Are you sharing the web server with web applications written using
> > something else, such as PHP? If PHP is playing with the language
> > settings, you might be hitting an ordering problem. That is, it works
> > if any PHP code gets executed first in a specifi
On Mar 20, 12:08 pm, Brandon Taylor wrote:
> Nope, still not working. If you're not defining tags = TagField() in
> the model, how are you defining it? As a CharField? I'd like to see
> how your model is set up.
>
> Of course, if I create a CharField and call it tags, it will show up.
> Even over
On Mar 20, 11:16 am, Ian Kelly wrote:
> As far as I know, the NLS_LANG environment variable is the only way to
> specify the client encoding in cx_Oracle. If that can't be relied
> upon within your Apache process, then I think you would need to run
> Django either as a CGI or
On Mar 20, 1:52 pm, Brandon Taylor wrote:
> Hmm. Well, I guess the only thing left to ask is what version of
> Django and Tagging you're running?
>
> I'm using Oracle 10g, cx_Oracle-5.0.1, Django and Tagging from svn.
> Other than that, I'm at a loss :)
The same, but cx_Oracle 4.4.1.
On Mar 20
On Mar 20, 3:00 pm, elm wrote:
> Thanxs for the advice Ian!!!
>
> But unfortunately I haven't been succesful.
>
> I have set the NLS_LANG to .UTF8 in the directive at the
> apache conf file:
>
>
> SetHandler python-program
> PythonHandler django.core.handlers.modpython
> SetEnv DJAN
On Mar 23, 1:52 pm, Brandon Taylor wrote:
> Hi Everyone,
>
> Is anyone having issues with Django Tagging (svn) not updating tags on
> an existing model? I'm running cx_Oracle-4.4.1 - thanks to (Ian Kelly)
> and Django Trunk.
Hmm. I tried running the same model you posted be
On Jun 30, 2:55 am, "arli...@gmail.com" wrote:
> I can use the oracle with django admin runserver,
> but when i use apche with mod_wsgi , apache error log :
> ImproperlyConfigured: Error loading cx_Oracle module: DLL load failed:
> What's wrong with it ?
Make sure you're using the same versions
On Jul 3, 6:13 am, Wanpeng wrote:
> Hello,
> I am writing my first app in Django. I already have existing
> tables/sequences/triggers in Oracle. so I used "inspectdb" to generate the
> models for django. Here's one model for example:
>
> class Instructors(models.Model):
>
>
>
> > instructorid
On Jul 15, 7:07 am, Karen Tracey wrote:
> On Wed, Jul 15, 2009 at 4:18 AM, pho...@gmail.com wrote:
>
> > the code of models:
> > mgsyxs = models.DecimalField(decimal_places=-127, null=True,
> > max_digits=126, db_column='MGSYXS', blank=True) # Field name made
> > lowercase.
>
> > i appreciate
On Jul 16, 7:51 am, Petry wrote:
> Hello,
>
> I am working on a project where I have to store a large amount of
> content, (html) in a record from a table, I am using Oracle as the
> database
>
> What is very strange ... is put a text reasonably small, (around 2000
> characters) and it works corr
On Apr 30, 12:30 pm, Jason Geiger wrote:
> Hello. I'm using Oracle and I would like to have a restricted user for
> Django that can only do DML. Is there a way to specify a schema that
> would prefix all "naked" table references so that this user can find
> the tables as it isn't the schema owner
On May 15, 1:23 am, modelmike wrote:
> How do I use 'primary_key=True' with Oracle 10g R2 to create a primary
> key on a custom field instead of on the default ID field?
>
> 'python manage.py sqlall ' shows that Django's SQL
> generation correctly assigns the PRIMARY KEY attribute to the
> 'prima
On May 22, 10:59 am, Christina wrote:
> Hi all,
>
> I'm trying to set up a new Django app that will have several models
> based on existing Oracle tables. I'm running Django 1.0.2, python
> 2.5.1 and cxOracle 5.0.1.
>
> These tables are in a different schema than the one Django connects
> with,
On May 25, 1:07 pm, Andrási László (g) wrote:
> Hi,
>
> We have a problem with an Oracle DB version 10g Release 10.2.0.1.0., Django
> latest svn version and cx_Oracle 5.0.1-2
>
> "select * from nls_database_parameters where parameter='NLS_CHARACTERSET';"
> returns US7ASCII
>
> We tried to change
On Jun 15, 11:11 am, Miles wrote:
> Connections aren't thread safe - you have to ensure every thread gets
> its own connection. You can create a new connection every request or
> use a thread-local to cache connections.
The latter is what Django does, although it's very easy to miss when
perusin
On Sep 30, 11:35 am, Thomas wrote:
> Hello,
>
> OS : windows
> Python : 2.6.2
>
> I have an issue with Textfield in django models.
> The textfield are created as NCLOB in the Oracle 9i DB.
> When I try to save a textfield from the django admin it works fine if
> the limit of 1128 character is kep
On Oct 1, 6:26 pm, alphacc wrote:
> I installed 9i at home and did some more test.
> With the same application running (and updating the same field) I
> discovered that the limit is not the same for my database.
> It is now 1246 Characters.
> I started a new application (a app with a model and a
On Wed, Dec 1, 2010 at 7:58 PM, Anurag Chourasia
wrote:
> This is using cx_Oracle and it works fine
> ===
cx_Oracle.version
> '5.0.3'
cursor.execute("select to_term from terminology_map where id=316")
cursor.fetchone()[0]
> 'Registro guardado con \xe9xit
On Thu, Dec 2, 2010 at 6:43 AM, Anurag Chourasia
wrote:
> Hi Ian,
> Yes.I set the NLS_LANG in my shell to UTF8 before trying this.
> Query using Django model still fails (direct query using cx_Oracle works
> fine)
> Regards,
> Anurag
Okay, so it would appear that the client encoding is not be
On Thu, Dec 2, 2010 at 1:21 PM, Anurag Chourasia
wrote:
> Hi Ian,
> Here is the information requested by you.
> $ python
> Python 2.5.2 (r252:60911, Dec 2 2008, 09:26:14)
> [GCC 3.4.4 (cygming special, gdc 0.12, using dmd 0.125)] on cygwin
> Type "help", "copyright", "credits" or "license" for mo
On Thu, Dec 2, 2010 at 3:23 PM, Ian Kelly wrote:
> Weird. From what I can tell, this seems to have something to do with
> Cygwin, or at least I'm able to replicate it in that environment.
> Setting NLS_LANG in or out of process and changing the registry key
> all have no ef
On Thu, Dec 2, 2010 at 5:34 PM, Anurag Chourasia
wrote:
> Hi Ian,
> I just tried the ctypes solution that you mentioned in your previous email
> but it does not work for me.
In your transcript, it appears that Django has already been loaded
when you call the ctypes code. The environment variable
On Thu, Dec 2, 2010 at 5:52 PM, Anurag Chourasia
wrote:
> Hi Ian,
> Can't tell you how much this helps :-)
> Setting the variable using ctypes before the import of cx_Oracle does the
> trick for me.
> Appreciate the time you spent in helping resolve this.
> Is there any Cygwin specific doc where w
On Wed, Jun 20, 2012 at 12:31 PM, André Pang wrote:
> I honestly don't mind whether Django decides to do this or not, since I can
> always hack our local tree to enforce this at the database level, but I
> thought it's an idea worth discussing. In my case, I found a couple of stray
> records with
On Fri, Aug 31, 2012 at 10:03 PM, Jon Blake wrote:
> Querying column timestamp of view user_objects for tables, sequences and
> triggers appears to confirm my understanding of what base.py does. I'll drop
> and recreate my user account, and try again. I'll advise how this goes. Does
> the Django d
On Tue, Oct 4, 2011 at 2:28 PM, msbuck wrote:
> Below is the settings. I am fairly new to python unit testing so my
> understanding of things could be better. But right now, if I select
> Run As -> Python Unit Test will my project is selected, it runs all of
> my Django tests and clobbers my worki
On Wed, Jan 9, 2013 at 3:55 AM, Jani Tiainen wrote:
> Server is running Oracle Database 10g Release 10.2.0.5.0 - 64bit Production.
> (EE edition)
>
> and charset info:
> NLS_CHARACTERSETWE8ISO8859P1
> NLS_NCHAR_CHARACTERSET AL16UTF16
Sorry, I meant your web server setup.
--
You receive
On Wed, Jan 9, 2013 at 11:40 PM, Jani Tiainen wrote:
> If we just force using force_unicode everything works except in older
> versions of cx_Oracle (our server had 5.0.4 or something) connection strings
> can't be unicode for some reason.
Sure, that's why the check exists in the first place. Pr
On Wed, Mar 6, 2013 at 1:38 AM, Ian wrote:
> In the meanwhile, the commonly used workaround for this is to include the
> schema in the db_table declaration like so:
The other workaround which is mentioned in the ticket I linked but
which I completely neglected to include in my reply, and which I
41 matches
Mail list logo