f



Using xtopdf and pypyodbc to publish MS Access database data to PDF

Wrote a program that lets you publish your MS Access database data to PDF, =
using Python, ReportLab, xtopdf (my toolkit) and pypyodbc.

Sharing it here.

Link:

http://jugad2.blogspot.in/2013/04/using-xtopdf-and-pypyodbc-to-publish-ms.h=
tml

Note: Saw some comments about my blog post on the Python Reddit, which made=
 me realize that I had not explained that similar code can be used to publi=
sh data from any ODBC database (for which you have an ODBC driver, and whic=
h is supported by pypyodbc), to PDF. All you have to do is change the conne=
ction string in the code, and maybe a few other small tweaks for difference=
s between SQL dialects of different RDBMS's.

Enjoy.

- Vasudev Ram
www.dancingbison.com
jugad2.blogspot.com

0
vasudevram (220)
4/14/2013 10:12:20 PM
comp.lang.python 77058 articles. 6 followers. Post Follow

0 Replies
1227 Views

Similar Articles

[PageSpeed] 59

Reply:

Similar Artilces:

Accessing MS ACCESS database using Data Environment
HI, I have developped a program in Visual Basic 6.0 using MS Access database. I have created all my reports through Data Environment where I have entered the location of my database file (for e.g c:\project\app\test.mdb) in the Connection properties. I have installed my application on another PC using Package & Deployment wizard. When viewing the reports on the other PC, I have to enter everytime the new location of the database. How can I solve this problem, please? nadia wrote: > HI, > I have developped a program in Visual Basic 6.0 using MS Access database. >...

how to access data iin a MS Excel file using database components?
Can we read data in columns from an MS Excel file? It is possible to use the usual database components in the Delphi palete to read data in an excel file? but how? ...

Possible to access MS Access 2007 password-protected database from Python?
Googling has shown me various ways of connecting to a non-password- protected Access database, but I was wondering if someone could point to code illustrating how to use an Access db that's password- protected. I haven't been able to find anything on this. Thanks, Ken ...

copying data from MS-SQL to MS-Access using VB.Net
Hi there, I'm trying to use MSAccess as a "container" to move data around from one MS-SQL server DB to another. This is basically already a design decision that has been made for a lot of reasons and can't be changed by me. What I was wondering is what is the bet way to populate the MS-Access DB. The DB will only contain 6 tables which will have a very small amount of data in them. I have tried to use ADO.Net to read the data from MS-SQL into a DataTable and then save it into the MS-Access DB using again using a DataTable populated from the first, but I can't seem to ge...

PDF in a Bottle
pdf_bottle.py is a program I wrote that allows you to create a PDF file from text, over the web, by entering your text into a form and submitting it. Here is the post about it: http://jugad2.blogspot.in/2013/05/pdf-in-bottle-creating-pdf-using-xtopdf.html - Vasudev Ram dancingbison.com jugad2.blogspot.com ...

MS Access Script to import data from external mde database to mdb database
Hi, Does anyone know of a way I can write a script that imports a table from a particular .mde file? I don't seen any obvious way to do it as a macro. Any suggestions if it can be done as a macro or as a written module? My ultimate goal is to have script that clears info out of 1 table in an .mdb file, imports an identically structured table from a .mde file, runs an append query I have in place to copy the data from the imported table to the table in my.mbd file, and then delete the imported table. Any help that could be provided would be greatly appreciated. Best wishes, George Hadl...

How to access data from an MS Excel sheet and import it to a MS Word using LabView?
Hello I would like to know how is it possible to access a specified data( for example row 1 ,column 2 to 5) in an Excel sheet and import it to a word document using LabView. Thanks You can interact with Office application through ActiveX, but you should be warned that it requires opening a lot of properties and going deep into the Office object hierarchy and this does not look nice in LabVIEW. If you open the example finder (Help>>Find Examples) and search for "ActiveX" or "Excel" you should find some examples on the basics of working with Excel. You can ...

Error when using Microsoft Data Access Objects (DAO) to interface with MS Access
MATLAB doesn't seem to like several of the methods available with some MIcrosoft Data Access Objects (DAO). >> DBName = 'C:\CourseTechnology\86092-1d\Access\Brief\Case1\Videos.mdb'; >> SQLServer = DBInitialize; >> TableName = 'Client'; >> Data = DB.OpenRecordset(['SELECT * FROM ' TableName ';']); >> DB.TableDefs(TableName) ??? Index exceeds matrix dimensions. >> td = DB.CreateTableDef td = Interface.Microsoft_DAO_3.6_Object_Library._TableDef >> dbstr = ';DATABASE=C:\CourseTechnology\86092...

PDF in a Bottle
Hi list, Might be of interest: PDF in a Bottle - creating PDF using xtopdf, ReportLab, Bottle and Python http://jugad2.blogspot.in/2013/05/pdf-in-bottle-creating-pdf-using-xtopdf.html - Vasudev Ram Python, Linux and open source training and development www.dancingbison.com ...

Accessing linked tables in MS Access database using JDBC ODBC Bridge
Does anyone know if JDBC can access linked tables in a Microsoft Access? We have a Mictosoft Access database that contains linked tables that are physically on a network drive. On a windows machine, We set up a java servlet that uses JDBC to connect to a microsoft access database using a DSN name set up in the ODBC administrator. We are able to run a query using a table that is physically on the database but not on tables linked into the database. The linked tables are comng from another Microsoft Access database on a mapped network drive. The java servlet and the database containing the linked tables are on the same computer drive. > Does anyone know if JDBC can access linked tables in a Microsoft > Access? HXTT Access( http://www.hxtt.net/access.html ), a pure Java JDBC package, supports Linked Table and View of MS Access. Yonghong Zhao System Analyst www.hxtt.net ...

Accessing linked tables in MS Access database using JDBC ODBC Bridge #2
Does anyone know if JDBC can access linked tables in a Microsoft Access? We have a Mictosoft Access database that contains linked tables that are physically on a network drive. On a windows machine, We set up a java servlet that uses JDBC to connect to a microsoft access database using a DSN name set up in the ODBC administrator. We are able to run a query using a table that is physically on the database but not on tables linked into the database. The linked tables are comng from another Microsoft Access database on a mapped network drive. The java servlet and the database containing the linked tables are on the same computer drive. ...

Access Database Using Python
I'm writing a script to look through DNA sequences in a database and select sequences I require. So far, my code looks like this for authentication: import os import Bio.Clustalw from Bio.Alphabet import IUPAC import pdb import sys import os import urllib import urllib2 import urllib userid = 'kmdawg' password = 'kmdawgyeah' location = 'index.html' params = urllib.urlencode({'user': userid, 'password': password, 'request_uri': location}) f = urllib2.urlopen("http://www.gene-regulation.com/login?%s" % params) print f.read() When ...

How to set Data source in MS Word as MS Access Databases via DDE(*.mdb;*.mde).
How to set Data source in MS Word as MS Access Databases via DDE(*.mdb;*.mde). Everytime i click the command button to merge the data, it gives me item not found and i know that its a problem with my datasource. when i click ok then it opens the word doucment prompting me which datasource you want to use, when i click DDE then it gives me the merged data. Is there anyway i can set it permanantely in my codes below. Private Sub SetQuery(strQueryName As String, strSQL As String) On Error GoTo ErrorHandler 'set the query from which the merge ' document will pull its i...

[ANN] New paper published (Volume 7 of The Python Papers)
Link: http://ojs.pythonpapers.org/index.php/tpp/article/view/243 Abstract In recent years, backup and restore is a common topic in data storage. Howe= ver, there=92s hardly anybody mention about safe data deletion. Common data= destruction methodology requires the wipe operation to fill the disk with = zeros, then with random data, and then with zeros again. Three passes are n= ormally sufficient for ordinary home users. On the down side, such algorith= ms will take many hours to delete a 2TB hard disk. Although current Linux u= tility tools gives most users more than enough secur...

Using xtopdf, a PDF creation toolkit
Hi, Though I posted about this article earlier, reposting it with a more appropriate title, to make it easier for searches. "Using xtopdf, a PDF creation toolkit" URL: http://www.packtpub.com/article/Using_xtopdf This is an article by me, written for Packt Publishing, about how to use my xtopdf toolkit to create PDF from text, DBF, TDV, CSV and XLS data. xtopdf is available at http://www.dancingbison.com/products.html . Enjoy, and feel free to give your feedback on wanted features, bugs, etc. in xtopdf - its appreciated. Vasudev Ram ~~~~~~~~~~~~~~~~~~~~~~ Software consulting an...

Using xtopdf, a PDF creation toolkit
Hi, Though I posted about this article earlier, reposting it with a more appropriate title, to make it easier for searches. "Using xtopdf, a PDF creation toolkit" URL: http://www.packtpub.com/article/Using_xtopdf This is an article by me, written for Packt Publishing, about how to use my xtopdf toolkit to create PDF from text, DBF, TDV, CSV and XLS data. xtopdf is available at http://www.dancingbison.com/products.html . Enjoy, and feel free to give your feedback on wanted features, bugs, etc. in xtopdf - its appreciated. Vasudev Ram ~~~~~~~~~~~~~~~~~~~~~~ Software consulting an...

Access Database Using Python #2
I'm writing a script to look through DNA sequences in a database and select sequences I require. So far, my code looks like this for authentication: import os import Bio.Clustalw from Bio.Alphabet import IUPAC import pdb import sys import os import urllib import urllib2 import urllib userid = 'something' password = 'something2' location = 'index.html' params = urllib.urlencode({'user': userid, 'password': password, 'request_uri': location}) f = urllib2.urlopen("http://www.gene-regulation.com/login?%s" % params) print f.read() Wh...

Create MS/ACCESS database app for non-ms/access users
Is it possible to create an MS/ACCESS database application and package it for users who do not have MS/ACCESS loaded in their PCs? I was told that this is possible, but I don't know what software is needed. Do you know? If so, please answer this post. Thanks. SueB *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! Per Sue Bricker: >Is it possible to create an MS/ACCESS database application and package >it for users who do not have MS/ACCESS loaded in their PCs? > >I was told that this is possible, but...

Use ASP to read MS Access query that calls MS Access function
Hi: I have an MS Access query for a table called MyTable. One of my fields in the query is a custom field that looks like "MyField: = MyFunction(ID)" where ID is a field in MyTable. I have ASP code and I can use it to read the query OK when "MyField" is not part of the query. If I add in MyField and then run my ASP code to try to read all the query fields, I get an error message on my web browser which says something to the effect of "cannot find MyFunction." On the Access side, I have MyFunction set up in a module and use the keyword "Public" in fr...

Clarion using existing MS Access Database
Hi all, I have been reading all the messages about ODBC and Clarion. I have managed to import the Access Database into the Clarion Dictionary. I put the database name in the Owner Name and the Table in the Full Path Name. I then use the application wizard to create a quick application to see if that would work. When I run the application I get an error on the last table in the database. "FILE ACCESS ERROR" - "FILE TEST TABLE COULD NOT BE OPENED. ERROR: DATA SOURCE NAME NOT FOUND AND NO DEFAULT DRIVER SPECIFIED(IM002). PRESS OK TO END THIS APPLICATION." I double ch...

How to use INSERT INTO Statement in MS Access Database
I have a table (Wares) in MS Access database with defined field - type Date/Time (date). I am trying to put a value in this field programmaticaly using Java language (MS Access Driver) with following SQL string (example): INSERT INTO Wares (date) VALUES ('3.6.2003') but I receive an error "Syntax error in INSERT INTO statament..." I've tried to use ( " ) characted instead ( ' ) but error still occurs. Where is the syntax error? I've tried to use also PreparedStatement object (prepStat) with following code: String sql = "INSERT INTO Wares (date) VALUE...

using enumerated data types with ms access
I would like to populate a combo box in ms access 2003 with enumerated values? Is there anyway to do this with vba and still have the corresponding integer values returned to the table? *** Sent via Developersdex http://www.developersdex.com *** joe smith wrote: > I would like to populate a combo box in ms access 2003 with enumerated > values? Is there anyway to do this with vba and still have the > corresponding integer values returned to the table? > > > *** Sent via Developersdex http://www.developersdex.com *** I believe this article explains the technique: http://w...

Using ActiveX to query MS Access Database
Greetings Earthlings, I've been exploring different ways to query MS Access databases using ActiveX controls thru MATLAB. I use actxserver('access.application') to get a component that is populated with many interfaces and methods. My question is, is there documentation addressing how to use these methods and interfaces? I can't find any documentation describing what these methods and interfaces are and how to use them. I.e., what arguments do they accept, what is returned, how do I know which one to use to do which task? In particular, I need to direct matlab to ...

Database access through python using GUI(Tkinter)
hi all, i am accessing sql+ database through python 2.4.3. i am using Tkinter to build my screens. how can i pass parameters on the click event of button from one function to the another? how can i run another file from current file? In article <1151572291.969023.299910@b68g2000cwa.googlegroups.com>, "arvind" <arvind.mulay@gmail.com> wrote: > hi all, > i am accessing sql+ database through python 2.4.3. > i am using Tkinter to build my screens. > how can i pass parameters on the click event of button from one > function to the another? What do you mean by this? If you mean clicking a button runs one function and passes params to another, write a parent function: def doit(): results = func1(...) funct2(results) btn = Tkinter.Button(..., command=doit) > how can i run another file from current file? What kind of file? If you mean a command-line executable, see the subprocess module (new in python 2.4 but backwards compatible with 2.3 and worth using). -- Russell ...

Web resources about - Using xtopdf and pypyodbc to publish MS Access database data to PDF - comp.lang.python

Resources last updated: 3/10/2016 2:30:46 PM