I'm manipulating an MS Access db via ADODB with win32com.client . I
want to rename a field within a table, but I don't know how to. I
assume there is a line of SQL which will do it, but nothing I've tried
(from searching) has worked.
Basic code:
import win32com.client
connection = win32com.client .Dispatch(r'ADO DB.Connection')
DSN = 'PROVIDER=Micro soft.Jet.OLEDB. 4.0;DATA SOURCE=dbfile.m db;'
connection.Open (DSN)
connection.Exec ute("ALTER TABLE tablename CHANGE from to") #this sql
doesn't work
connection.Clos e()
Anyone know how to get this to work?
Iain
want to rename a field within a table, but I don't know how to. I
assume there is a line of SQL which will do it, but nothing I've tried
(from searching) has worked.
Basic code:
import win32com.client
connection = win32com.client .Dispatch(r'ADO DB.Connection')
DSN = 'PROVIDER=Micro soft.Jet.OLEDB. 4.0;DATA SOURCE=dbfile.m db;'
connection.Open (DSN)
connection.Exec ute("ALTER TABLE tablename CHANGE from to") #this sql
doesn't work
connection.Clos e()
Anyone know how to get this to work?
Iain
Comment