On Wednesday, August 31, 2011 06:33:32 am Thomas Ganss wrote:
> John,
> 
> some months ago I was hacking on my own on that front and
> found Roger's stuff a few days afterwards
> (typical, never do the really smart things first like search the lists...)
> and changed to his code, working to read vfp dbf's
> (after making sure they were vfp6 compliant.)
> 
> IIRC I used some [quasi-standard ?] DBAPI calls to generate the schema.
> Was only basic stuff involved/needed, no DBC in the picture
> 
> The PyODBC cursor AFAIR was not  made out of "dict-records" but
> conformed to DBAPI.
> 
> I got some results, but then came work from a totally different direction
> and I never followed up to make it a rounded package was only needed as
> a demo.
> 
> HTH
> 
> thomas
> 
> John Fabiani schrieb:
> > On Tuesday, August 30, 2011 03:07:13 pm Roger Gammans wrote:
> >> On Tue, 2011-08-30 at 14:08 -0700, John Fabiani wrote:
> >>> Hi,
> >>> I have a little time available and I thought I would look into using
> >>> pyodbc with Dabo.
> >> 
> >> John, If I haven't mentioned it before it might be worth you looking at
> >> http://hg.backslashat.org/repos/dabo-odbc/ which is contains
> >> a set of patchs to an ancient dabo to do this.
> >> 
> >>>  The first issue is the connection string.  The pyodbc does NOT
> >>> 
> >>> follow the "host", "user", etc. that we have been using for the
> >>> connection. For example to connect to an MS SQL database on windows you
> >>> would use something like:
> >>> DRIVER={SQL Server};SERVER=cloak;DATABASE=test;UID=user;PWD=password
> >>> 
> >>> 
> >>> And of course the connection string would be different for other
> >>> platforms and database engines.  At first I thought I would just change
> >>> CxnEditor to deal
> >> 
> >> That's what I did locally and added a driver and dsn attribute. It was
> >> good enough for what I needed so I haven't mantained it. But it would
> >> probably help you in the right direction.
> >> 
> >> The  important patches are :-
> >> http://hg.backslashat.org/repos/dabo-odbc/rev/af94151ed49a
> >> http://hg.backslashat.org/repos/dabo-odbc/graph/aeb4a75ba49f
> >> 
> >> and
> >> http://hg.backslashat.org/repos/dabo-odbc/rev/eb192fd4cd54
> >> 
> >> But you could just the db/dbOdbc.py from the last one and hack from
> >> there.
> > 
> > Roger,
> > 
> > thanks for the code - I'm sure I'll use it in the near future (I've
> > actually haven't started yet).
> > 
> > After reading some of the code I do have a few questions!
> > Why did you find it necessary to create the "Cursor" class?  It appears
> > the pyodbc has pyodbc.Cursor class.  Did you find it did not match the
> > Dabo requirements - I ran into this with the old pymssql and was unable
> > to get it to work - Ed finished the job.
> > 
> > You did not use "INFORMATION_SCHEMA"  to access table, field information.
> >  I was planned on using the INFORMATION_SCHEMA as a universal way of
> > accessing the system info.  Of course I'm under the impression that all
> > the major database engines have it available.
> > 
> > Last the code implies that you were ONLY connecting to MSSQL - is that
> > correct?  Did you try connecting to other database engines?
> > 
> > Johnf
> 
[excessive quoting removed by server]

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message: 
http://leafe.com/archives/byMID/[email protected]

Reply via email to