If you have a mysql database running locally, please help me test it. python script/extract_mysql_models.py username:passw...@database_name > applications/myapp/models/db_from_mysql.py
Check applications/myapp/models/db_from_mysql.py. Did it work? On Sep 7, 5:47 pm, mdipierro <mdipie...@cs.depaul.edu> wrote: > I turned this into a script in web2py/scripts in trunk. What is the > license? I assume it is GPL or BSD but it should be stated. > > Massimo > > On Aug 26, 5:36 pm, selecta <gr...@delarue-berlin.de> wrote: > > > Create the web2py code needed to access yourmysqllegacydb. > > > To make this work all thelegacytables you want to access need to > > have an "id" field. > > > Thispluginneeds:mysql > > mysqldump > > installed and globally available. > > > Under Windows you will probably need to add themysqlexecutable > > directory to the PATH variable, > > you will also need to modifymysqltomysql.exe and mysqldump to > > mysqldump.exe. > > Just guessing here :) > > > Access your tables with: > > legacy_db(legacy_db.mytable.id>0).select() > > > If the script crashes this is might be due to that fact that the > > data_type_map dictionary is incomplete. > > Please complete it, improve it and continue. > > > downloadhttp://jaguar.biologie.hu-berlin.de/~fkrause/web2py.plugin.legacymysq... > > screenshothttp://jaguar.biologie.hu-berlin.de/~fkrause/screenshot_legacymysql.png