Re: [Tutor] Classes and Databases

2008-11-13 Thread ALAN GAULD
> Thanks Allan... we have used CVS for the base system.. but for users provided > functions, > we think for having them persistent in the database.. I'm puzzled. CVS provides much better facilities for handling code, especially with multiple versions (visibility of diffs, who changed what and w

Re: [Tutor] Dictionary of dictionaries issue

2008-11-13 Thread Pablo Englebienne
Thank you all, this is exactly what I was trying to do and the syntax is beautiful... :-) -- Pablo Englebienne "Progress is made by lazy men looking for easier ways to do things." - Robert A. Heinlein Kent Johnson wrote: On Thu, Nov 13, 2008 at 10:01 AM, A.T.Hofkamp <[EMAIL PROTECTED]> wro

Re: [Tutor] Classes and Databases

2008-11-13 Thread Jojo Mwebaze
Thanks Allan... we have used CVS for the base system.. but for users provided functions, we think for having them persistent in the database.. Cheers Johnson On Thu, Nov 13, 2008 at 7:18 PM, Alan Gauld <[EMAIL PROTECTED]>wrote: > > "Jojo Mwebaze" <[EMAIL PROTECTED]> wrote > > Because we have

Re: [Tutor] Converting EBCDIC characters to ASCII

2008-11-13 Thread bob gailer
Steve Bricker wrote: I see the scenario does not give enough to really allow someone to formulate an answer. An excellent reminder to write no code until the user's requirements are fully understood! OTOH a little rapid prototyping can be a fast path to discovery of requirements. Allow

Re: [Tutor] Classes and Databases

2008-11-13 Thread Alan Gauld
"Jojo Mwebaze" <[EMAIL PROTECTED]> wrote Because we have very many such cases, we can not incorporate such adhoc changes in the system.. we are thinking of storing such classes in the database and have classes run from the database. if anyone else feels they need to use someone's algorithm

Re: [Tutor] experience/opinions with deploying python GUI app toLinux, Win32, and Mac OS X

2008-11-13 Thread Alan Gauld
"greg whittier" <[EMAIL PROTECTED]> wrote - jython/SWT -- I have no experience with this, but everybody has a JVM, Of the client GUI options this is probably the easiest, but Does "probably the easiest" mean "probably the easiest to develop?" Sorry, I meant easiest to deploy. Hardest (or on

Re: [Tutor] Converting EBCDIC characters to ASCII

2008-11-13 Thread Steve Bricker
BODY { font-family:Arial, Helvetica, sans-serif;font-size:12px; }I stand corrected. There was enough information. Thank you. BAT file has nothing to do with Python. I used it because I knew how. Once I figure it out in Python, I'll use that instead. Steve Bricker On Thu 13/11/08 11:58 , b

Re: [Tutor] Converting EBCDIC characters to ASCII

2008-11-13 Thread Steve Bricker
I see the scenario does not give enough to really allow someone to formulate an answer. Allow me to clarify a bit. The three PD fields are each 10 positions in length. Using the example below, a field with X'014C' would need to be expanded to a 19-character field of '000

Re: [Tutor] Converting EBCDIC characters to ASCII

2008-11-13 Thread bob gailer
Steve Bricker wrote: I am trying to build an application for work that FTPs a file from an IBM mainframe to my Windows desktop then process it. The EBCDIC-to-ASCII conversion works nicely (using a BAT file I created) except for three packed-decimal data fields (for example, X'

Re: [Tutor] Converting EBCDIC characters to ASCII

2008-11-13 Thread Kent Johnson
On Thu, Nov 13, 2008 at 11:14 AM, Steve Bricker <[EMAIL PROTECTED]> wrote: > I am trying to build an application for work that FTPs a file from an IBM > mainframe to my Windows desktop then process it. The EBCDIC-to-ASCII > conversion works nicely (using a BAT file I created) except for three > pa

Re: [Tutor] import data (txt/csv) into list/array and manipulation

2008-11-13 Thread Kent Johnson
On Thu, Nov 13, 2008 at 9:50 AM, trias <[EMAIL PROTECTED]> wrote: > PS I could maybe upload a couple of small example flies or a schematic to > see what I mean A small example would be very helpful. Also please subscribe to the list. Kent ___ Tutor mail

[Tutor] Converting EBCDIC characters to ASCII

2008-11-13 Thread Steve Bricker
BODY { font-family:Arial, Helvetica, sans-serif;font-size:12px; }I am trying to build an application for work that FTPs a file from an IBM mainframe to my Windows desktop then process it. The EBCDIC-to-ASCII conversion works nicely (using a BAT file I created) except for three packed-decimal dat

[Tutor] cx_Oracle import problem in CGI

2008-11-13 Thread Jiang, Yonghua
Dear Tutor, Although several posts discussed how to solve the problem about cx_Oralce import, I struggled with that for quite long time without success. Following is the code I wrote: # #!/opt/bin/python import cgi import sys import os os.environ['ORAC

[Tutor] Classes and Databases

2008-11-13 Thread Jojo Mwebaze
Hello There, I would like store python classes in a database and then execute these classes from the database? Scientists do always want apply their own algorithms at the same time we want to keep this information. (knowing which class is responsible for which data) Because we have very many such

Re: [Tutor] Dictionary of dictionaries issue

2008-11-13 Thread Tim Golden
Kent Johnson wrote: On Thu, Nov 13, 2008 at 10:01 AM, A.T.Hofkamp <[EMAIL PROTECTED]> wrote: d3 = dict(( (rv, dict.fromkeys(c)) for rv in r )) You don't need the double parentheses, this works just as well: d3 = dict( (rv, dict.fromkeys(c)) for rv in r ) A generator expression just has to be

Re: [Tutor] import data (txt/csv) into list/array and manipulation

2008-11-13 Thread trias
Hi again, I got a bit better in python the last few days, but looking at some codes it almost looks impossible to catch up. but definitely want to fight it, looks well worth the effort, plus it probably works exponentially :) I read a little bit about the interval/segment trees, and it looks t

Re: [Tutor] Dictionary of dictionaries issue

2008-11-13 Thread Kent Johnson
On Thu, Nov 13, 2008 at 10:01 AM, A.T.Hofkamp <[EMAIL PROTECTED]> wrote: d3 = dict(( (rv, dict.fromkeys(c)) for rv in r )) You don't need the double parentheses, this works just as well: d3 = dict( (rv, dict.fromkeys(c)) for rv in r ) A generator expression just has to be in parentheses, it'

Re: [Tutor] Dictionary of dictionaries issue

2008-11-13 Thread Kent Johnson
On Thu, Nov 13, 2008 at 8:11 AM, Pablo Englebienne <[EMAIL PROTECTED]> wrote: > Hi, I'm trying to work with a dictionary of dictionaries and I'm having > trouble accessing a specific element of it: > > $ python > Python 2.6 (trunk:66714:66715M, Oct 1 2008, 18:36:04) > [GCC 4.0.1 (Apple Computer, I

Re: [Tutor] Dictionary of dictionaries issue

2008-11-13 Thread A.T.Hofkamp
Pablo Englebienne wrote: Hi, I'm trying to work with a dictionary of dictionaries and I'm having trouble accessing a specific element of it: $ python Python 2.6 (trunk:66714:66715M, Oct 1 2008, 18:36:04) [GCC 4.0.1 (Apple Computer, Inc. build 5370)] on darwin Type "help", "copyright", "credits

[Tutor] Dictionary of dictionaries issue

2008-11-13 Thread Pablo Englebienne
Hi, I'm trying to work with a dictionary of dictionaries and I'm having trouble accessing a specific element of it: $ python Python 2.6 (trunk:66714:66715M, Oct 1 2008, 18:36:04) [GCC 4.0.1 (Apple Computer, Inc. build 5370)] on darwin Type "help", "copyright", "credits" or "license" for more i

Re: [Tutor] experience/opinions with deploying python GUI app to Linux, Win32, and Mac OS X

2008-11-13 Thread greg whittier
Thanks for all the great replies! You've reaffirmed my #1 and #2 seeds -- wxpython and a web app. I haven't really found any show stoppers for wxpython, but I guess I was unnecessarily suspicious. dabodev.com looks like it targets my problem so that's something I'll definitely look at. I had one

Re: [Tutor] experience/opinions with deploying python GUI app to Linux, Win32, and Mac OS X

2008-11-13 Thread Jeff Johnson
Check out Dabo. It is a framework that wraps wxpython and is developed on the mac and is deployed on mac, windows and linux. It has great features like an app builder to get you up and running quickly. http://dabodev.com/ And for the email list: http://leafe.com/mailman/listinfo/dabo-users -

Re: [Tutor] experience/opinions with deploying python GUI app to Linux, Win32, and Mac OS X

2008-11-13 Thread spir
You may have a look at easygui. Probably not for final release, rather for design stage. It's based on tkinter I guess. I found it very helpful as long as the app does not require sophisticated widgets and there is a proper separation of process and UI. Once everything works, it is fast enough t

Re: [Tutor] experience/opinions with deploying python GUI app to Linux, Win32, and Mac OS X

2008-11-13 Thread Alan Gauld
"greg whittier" <[EMAIL PROTECTED]> wrote Deploying to the Mac seems to be the most difficult from what I've read. That's probably true in that for a truly native experience you need to pay a lot of attention to Apple's guidelines and use some kind of tool to produce the correct bundle of fil