problems with syncing Python, XML and MySQL

Posted on 2007-10-21
Medium Priority
Last Modified: 2012-06-27
Need of Help!

I have some experience in programming with C#, Java, SQL on Windows.
This is the first time I have to program in Python on Linux (Gutsy Gibbon) OS.
My task is to write middle ware for a small project. The front-end will spit XML to the middle ware, which needs to be traversed and then inserted in to the MySQL database base (on Apache Server). This process is suppose to flow back and forth from the DB to the front-end and Front-end to the DB.
I am very much confused by the concept of Python Modules (.py files) and Python Classes and the fact that everything in Python is an object. Due to this I am not able to think of how I should write this middle ware in Python. I have been able to work with minidom for XML parsing and I have been able to work woth MySQL and Python separately..
But, how this all will work together is something of a blank!
Whether I should write classes in Python or just write Modules(.py) files with functions in it is my biggest question.
I will appreciate if someone can please give me a idea of what approach should I use and  it would be great if someone has some basic sample code which achieves this.
I got some idea from this article but its still not clear:
Please help me out!!  
Question by:deersuper
  • 2
  • 2
LVL 15

Expert Comment

ID: 20124598
You should read "Dive into Python" (www.diveintopython.org) first.

Author Comment

ID: 20124814
Thanks Mish,

I have already read Dive into Python. Any other suggestions?
LVL 17

Expert Comment

ID: 20178078
I suggest, before trying to write program(s) (in any language) that we focus on the analysis and design. I for one could not begin to answer your questions without a good analysis/design.

Do you have you analysis/design skills? Access to analysis/design tools?

Author Comment

ID: 20196434
hey ramrom,

u are right about analysis and design. I have experience with that alot but can't find someone who knows Python in terms of teaching me the flow.

can u suggest a good book or tutorial, where I can see actual developed code in python from start to end?
LVL 17

Accepted Solution

ramrom earned 1500 total points
ID: 20197453
Take a look at http://aspn.activestate.com/ASPN/Cookbook/Python/

If you want more help here please post your design.

Featured Post

Configuration Guide and Best Practices

Read the guide to learn how to orchestrate Data ONTAP, create application-consistent backups and enable fast recovery from NetApp storage snapshots. Version 9.5 also contains performance and scalability enhancements to meet the needs of the largest enterprise environments.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Suggested Courses
Course of the Month17 days, 4 hours left to enroll

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question