添加:insert into 表名 (列名1,列名2...) values (值1,值2...)修改:update 表名 set 列名=值 where ... 删除: delete from 表名 where ...
dim netado as new adodb.connection dim netstr as string dim netrecord as recordset
netstr="DSN=数据源" 'ODBC中所声明的数据源 netado.open netstr '添加记录 set netrecord=netado.execute("Insert into 表1 (字段1,字段2,。。)" _ &"values (值1,值2,) Where 条件")
'删除记录 set netrecord=netado.execute("Delete * from 表2 where 条件") '修改记录 Set netrecord=netado.execute("Update 表3 Set 字段1='值1',字段2='值2',....," _ &"Where 条件")
dim netado as new adodb.connection
dim netstr as string
dim netrecord as recordset
netstr="DSN=数据源" 'ODBC中所声明的数据源
netado.open netstr '添加记录
set netrecord=netado.execute("Insert into 表1 (字段1,字段2,。。)" _
&"values (值1,值2,) Where 条件")
'删除记录
set netrecord=netado.execute("Delete * from 表2 where 条件") '修改记录
Set netrecord=netado.execute("Update 表3 Set 字段1='值1',字段2='值2',....," _
&"Where 条件")
metadp.close
'结束