cx_Oracle - Django ORM - Reference Count Increase

2014-12-27 Thread Anurag Chourasia
All, I have a Long Running Python Process that uses Django ORM against Oracle database. The size of the process keeps on increasing steadily. I was profiling this process using mem_top and i find that the reference count of one particular data type increases continuously with iterations. Datat

Re: Installing Django

2013-12-12 Thread Anurag Chourasia
It goes into Lib\site-packages folder. Regards, Anurag On Thu, Dec 12, 2013 at 6:55 PM, Frederick Miller wrote: > For Windows XP, should Django be installed under the Python27 folder? Or > should Django be on the root of the C: drive? > > Frederick Miller > > -- > You received this message bec

Re: Need Advise on the best way to track how much time a user is logged in.....

2013-08-22 Thread Anurag Chourasia
So they will present the RFID Tag to the reader at the time of login .and logout also? You could do this directly in Python thenCapture the logout read (same way as login) and use the datetime module to generate the current time and save it in the Database. Just trying to understand what i

Re: postgresql

2013-05-20 Thread Anurag Chourasia
Read this for a starter http://www.postgresql.org/docs/9.2/interactive/index.html Regards, Guddu On Mon, May 20, 2013 at 3:35 PM, Kakar Arunachal Service < kakararunachalserv...@gmail.com> wrote: > hi guyz! > I'm new to django and python, and very new to postgresql. Can u suggest > any books or

Re: django-auth-ldap

2013-05-15 Thread Anurag Chourasia
Glad that it worked On Wed, May 15, 2013 at 11:52 AM, Cody Scott wrote: > The problem was that the LDAPSearch had to start with a OU= I had it start > with a DC=. > > > On Wednesday, 15 May 2013 11:27:08 UTC-4, Cody Scott wrote: >> >> I have that code but where does the logging go? >> >> On W

Re: django-auth-ldap

2013-05-15 Thread Anurag Chourasia
Its just basic python logging http://docs.python.org/2/library/logging.html Look at logging to a file http://docs.python.org/2/howto/logging.html#logging-advanced-tutorial Regards, Guddu On Wed, May 15, 2013 at 11:27 AM, Cody Scott wrote: > I have that code but where does the logging go? > >

Re: django-auth-ldap

2013-05-15 Thread Anurag Chourasia
Ok. Now try to get django-ldap-auth working. See if you can enable the logging handler and grab some more information. http://pythonhosted.org/django-auth-ldap/logging.html Regards Guddu On Wed, May 15, 2013 at 10:56 AM, Cody Scott wrote: > Ok The problem was that I had the file named ldap.py.

Re: django-auth-ldap

2013-05-15 Thread Anurag Chourasia
Hi Cody In the link that you sent i see that initialize is a valid attribute. Also did you name your python file as ldap.py? If yes then that's the problem i guess. Please rename it to something else and see what it gives you. Could you run these in a Python interpreter and tell me what does thi

Re: django-auth-ldap

2013-05-15 Thread Anurag Chourasia
What does this give you? import ldap dir(ldap) Regards Guddu On Wed, May 15, 2013 at 10:04 AM, Cody Scott wrote: > I put that code in a separate python file and ran it without django or > django-auth-ldap. > > l = ldap.initialize() > AttributeError: 'module' object has no attribute 'initialize'

Re: django-auth-ldap

2013-05-14 Thread Anurag Chourasia
Setting up of groups is not a requirement. In my case I am searching for group membership just to grant/deny access based on Group membership also. I sent my settings to you just to show you how I was using sAMAccountName for user search. So what exactly is not working in your case? You are not ab

Re: django-auth-ldap

2013-05-14 Thread Anurag Chourasia
Hi Cody, I am also using a Search Bind in a similar situation as yours You could easily use the samaccountName for User Search. Here is what I have in settings.py to give you a clearer picture. AUTH_LDAP_USER_SEARCH = LDAPSearchUnion( > LDAPSearch("OU=Users, > OU=Central,OU=IDD,DC=client

Re: Custom view on the home page based on groups assigned to user.

2013-04-12 Thread Anurag Chourasia
Within the templates, you can show different HTML elements based on the user attributes/group. Traditional IF checks. Regards, Guddu On Fri, Apr 12, 2013 at 4:59 PM, Enator24 wrote: > Hi I need to develop an application where I have three groups first the > creator, second the reviewer, 3rd the

Re: django / django cms + responsive

2013-03-14 Thread Anurag Chourasia
Look at 1. Twitter Bootstrap. http://twitter.github.com/bootstrap/ 2. Foundation Zurb. http://foundation.zurb.com/ Regards, Anurag On Mar 14, 2013 7:03 AM, "Frank Bieniek" wrote: > Hi Guys, > what are your preferred apps to turn django or django cms into a > responsive website? > > What are yo

Re: WebService WSDL

2012-06-28 Thread Anurag Chourasia
Try using gSOAP if that fits your needs. http://www.cs.fsu.edu/~engelen/soap.html Regards, Guddu On Thu, Jun 28, 2012 at 2:47 PM, Rene wrote: > Pessoal, > > Preciso montar um webservice que gere um wsdl, mas não achei algo que > fosse mais direto na web, alguém tem um caminho para indicar. > >

Re: Apache does not display a flash file

2012-05-10 Thread Anurag Chourasia
Could you have a look at the Error Logs as shown on the Tools --> Web Developer --> Web Console in Firefox if u have something in there? On Thu, May 10, 2012 at 7:43 AM, atul khairnar wrote: > When right-clicked at the location where flash should have rendered, > it gives error message, "Movie No

Re: Django making box

2012-03-13 Thread Anurag Chourasia
What Javier meant in his previous message was a client application .which of course could be a browser running on your own computer. For a better understanding of client/server model you could review the Wikipedia page http://en.wikipedia.org/wiki/Client%E2%80%93server_model Regards, Guddu

Re: dropdown select box in django

2012-02-20 Thread Anurag Chourasia
This is weird I simply copy pasted your code in my environment and it shows me a Drop Down. Could you save the models file again and close your browser (or even try clearing cache) and restart your apache/django dev server whatever may be the case and try again? Regards, Anurag On Mon, Feb

Re: mod_Wsgi Problem

2012-01-04 Thread Anurag Chourasia
You will need to allow apache access to the folder where you have your wsgi script. Please add this in your httpd.conf and restart apache and see if it helps. Order deny,allow Allow from all Regards, Anurag On Wed, Jan 4, 2012 at 6:52 PM, Hassan wrote: > i tryed > > WSGIScriptAlias /mysite1

Re: mod_Wsgi Problem

2012-01-04 Thread Anurag Chourasia
Could you try changing your WSGIScriptAlias in httpd.conf From WSGIScriptAlias / "C:/mysite/django.wsgi" To WSGIScriptAlias /MYSITE "C:/mysite/django.wsgi" And then access http:localhost:port/MYSITE and tell is the results. Regards, Anurag On Jan 4, 2012 7:19 AM, "Hassan" wrote: > Dear ALL,

Re: Possible interest in a webcast/presentation about Django site with 40mil+ rows of data??

2011-06-22 Thread Anurag Chourasia
I am in :-) On Wed, Jun 22, 2011 at 11:39 AM, Ivan Aleman wrote: > > > On 22 June 2011 08:15, Cal Leeming [Simplicity Media Ltd] < > cal.leem...@simplicitymedialtd.co.uk> wrote: > >> >> If you're interested, please reply on-list so others can see. >> >> >> > Sweet! Count me in :) > > >> >> > --

Re: How to fix a column typo in django

2011-04-18 Thread Anurag Chourasia
he column name manually using SQL and modify the > models.py afterwards? > > Kann > > On Mon, Apr 18, 2011 at 4:06 PM, Anurag Chourasia > wrote: >> >> Hi Kann, >> >> Does Dropping the Table and Recreating using SyncDB work well in your >> setup? >

Re: How to fix a column typo in django

2011-04-18 Thread Anurag Chourasia
Hi Kann, Does Dropping the Table and Recreating using SyncDB work well in your setup? Regards, Anurag On Mon, Apr 18, 2011 at 7:30 PM, Kann wrote: > Dear all, > > I am new to django and have question about fixing the typo i made in > the models.py. For example, I created tables with typo in the

Re: Not Printing stmt in for loop

2011-03-17 Thread Anurag Chourasia
This is a Python Question (not Django) How are you populating cr? Did you check if there are any rows at all before looping over the rows? Regards, Anurag On Fri, Mar 18, 2011 at 12:07 AM, NavaTux wrote: > Here I ahd a piece of code to execute my custom python function > > just i executed via p

Re: parsing SOAP request

2011-01-27 Thread Anurag Chourasia
Could you try with this elif request.method == 'POST': print request.raw_post_data response = HttpResponse(mimetype='text/xml') response.write(request.raw_post_data) return response Regards, Anurag On Thu, Jan 27, 2011 at 1:07 PM, sami nathan wrote: > Hi >     No

Re: Django Email

2011-01-21 Thread Anurag Chourasia
Googling for django-mailer gets me to this page http://code.google.com/p/django-mailer/ Regards, Anurag On Fri, Jan 21, 2011 at 8:58 PM, hank23 wrote: > OK what exactly is django-mailer? > > On Jan 19, 4:32 pm, Eduardo Cereto Carvalho > wrote: > > djan

Re: Beginner question about Postgresql

2011-01-14 Thread Anurag Chourasia
If you have installed psycopg2 then are you able to load psycopg2 from the Python Command Prompt? Try this below and see if import works from command line... $ 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", "c

Re: Just saying hi

2010-12-19 Thread Anurag Chourasia
Welcome to the community Dave. Season's greetings to you too and everyone. Regards Anurag On Sun, Dec 19, 2010 at 5:46 PM, Dave Sayer wrote: > Seasons Greetings, > > I joined the list yesterday and just wanted to say "Hi" and introduce > myself. > > I'm a frontend dev who was looking for a fra

Re: Django vs Postgres Connection

2010-12-17 Thread Anurag Chourasia
* Let me know if it works. Regards, Anurag On Sat, Dec 18, 2010 at 3:20 AM, armandoperico wrote: > sorry, > how should do to specify the password on the wsgi file ? > this would be the best i have so far. > > thanks > > > On Dec 17, 10:17 pm, Anurag Chourasia > wrote

Re: Django vs Postgres Connection

2010-12-17 Thread Anurag Chourasia
wrote: > yes. > > On Dec 17, 10:04 pm, Anurag Chourasia > wrote: > > On this server, are you able to connect to the PostGre database using > the > > command line? > > > > psql -U myuser -h 127.0.0.1 -p 5432 -d dbname > > > > Regards, > >

Re: Django vs Postgres Connection

2010-12-17 Thread Anurag Chourasia
On this server, are you able to connect to the PostGre database using the command line? psql -U myuser -h 127.0.0.1 -p 5432 -d dbname Regards, Anurag On Sat, Dec 18, 2010 at 2:19 AM, armandoperico wrote: > on settings.py.. > > DATABASES = { >'default': { >'ENGINE': 'django.db.backe

Re: Django vs Postgres Connection

2010-12-17 Thread Anurag Chourasia
You might want to check your wsgi script. Looks like the environment variables that you have in there are wrong and not allowing the import of settings.py Regards, Anurag On Sat, Dec 18, 2010 at 1:32 AM, armandoperico wrote: > Hi, > this is the first time i try to deploy a django project and i'

Re: Initial Create Table Script

2010-12-03 Thread Anurag Chourasia
Yes there is. You need to use *./manage.py sql auth* instead of *./manage.py sql django.contrib.auth* Regards, Anurag On Fri, Dec 3, 2010 at 5:48 PM, Tim Sawyer wrote: > Is there a way to generate a sql script that gets the entire table > structure required for a django project? Includi

Re: Django 1.2.3, Oracle with Character Set WE8MSWIN1252 - 'utf8' codec can't decode bytes

2010-12-02 Thread Anurag Chourasia
at 6:10 AM, Ian Kelly wrote: > 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 h

Re: Django 1.2.3, Oracle with Character Set WE8MSWIN1252 - 'utf8' codec can't decode bytes

2010-12-02 Thread Anurag Chourasia
Hi Ian, I just tried the ctypes solution that you mentioned in your previous email but it does not work for me. Below is my session transcripts. >>> import ctypes *>>> ctypes.CDLL('kernel32').SetEnvironmentVariableA('NLS_LANG', '.UTF8')* *1* >>> TerminologyMap.objects.get(term_id=8) Traceback (m

Re: Django 1.2.3, Oracle with Character Set WE8MSWIN1252 - 'utf8' codec can't decode bytes

2010-12-02 Thread Anurag Chourasia
port connection >>> connection.cursor() # Initialize the connection >>> print os.environ['NLS_LANG'] .UTF8 >>> print connection.connection.encoding WINDOWS-1252 >>> print connection.connection.nencoding WINDOWS-1252 >>> Regards, Anurag On Fri, Dec 3

Re: Django 1.2.3, Oracle with Character Set WE8MSWIN1252 - 'utf8' codec can't decode bytes

2010-12-02 Thread Anurag Chourasia
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 On Thu, Dec 2, 2010 at 1:20 PM, Ian Kelly wrote: > On Wed, Dec 1, 2010 at 7:58 PM, Anurag Chourasia > wrote: >

Re: Django 1.2.3, Oracle with Character Set WE8MSWIN1252 - 'utf8' codec can't decode bytes

2010-12-01 Thread Anurag Chourasia
on '5.0.3' >>> cursor.execute("select to_term from terminology_map where id=316") >>> cursor.fetchone()[0] 'Registro guardado con \xe9xito' Regards, Anurag On Wed, Dec 1, 2010 at 10:51 PM, Ian wrote: > On Nov 30, 8:31 pm, Anurag Chourasia > wrote

Django 1.2.3, Oracle with Character Set WE8MSWIN1252 - 'utf8' codec can't decode bytes

2010-11-30 Thread Anurag Chourasia
Hi All, On Oracle 10.2 with Character-Set set to WE8MSWIN1252, When using Django, I try to select a Oracle row which contains a field with value as 'Páginas', i encounter the following error "'utf8' codec can't decode bytes " Here is the trace from the python command prompt. >>> tmlist = Termin