CSDN首页 空间 新闻 论坛 Blog 下载 读书 网摘 搜索 .NET Java 视频 接项目 求职 在线学习 买书 程序员 通知
山寨机中的战斗机! 程序优化工程师到底对IT界有没有贡献
CSDN社区
搜索 收藏 打印 关闭
CSDN社区 >  Web 开发 >  ASP

怎样读出ACESS数据库里面的表字段的类型、字段长度、字段备注内容?

楼主hchxxzx(NET?摸到一点门槛)2002-02-13 13:24:11 在 Web 开发 / ASP 提问

怎样读出ACESS数据库里面的表字段的类型、字段长度、字段备注内容? 问题点数:100、回复次数:12Top

1 楼hchxxzx(NET?摸到一点门槛)回复于 2002-02-14 18:34:15 得分 0

不会吧,居然没有人会?Top

2 楼ehom(?!)回复于 2002-02-14 22:16:08 得分 20

字段类型rs("***").Type  
  字段长度rs("***").DefinedSize  
  字段备注内容是什么?:)Top

3 楼dust3k(尘)回复于 2002-02-15 08:37:34 得分 80

Field   Object  
  Represents   a   column   of   data   with   a   common   data   type.  
   
   
   
   
   
   
  Remarks  
  Each   Field   object   corresponds   to   a   column   in   the   Recordset.   You   use   the   Value   property   of   Field   objects   to   set   or   return   data   for   the   current   record.   Depending   on   the   functionality   the   provider   exposes,   some   collections,   methods,   or   properties   of   a   Field   object   may   not   be   available.  
   
  With   the   collections,   methods,   and   properties   of   a   Field   object,   you   can   do   the   following:    
   
  Return   the   name   of   a   field   with   the   Name   property.    
  View   or   change   the   data   in   the   field   with   the   Value   property.   Value   is   the   default   property   of   the   Field   object.    
  Return   the   basic   characteristics   of   a   field   with   the   Type,   Precision,   and   NumericScale   properties.    
  Return   the   declared   size   of   a   field   with   the   DefinedSize   property.    
  Return   the   actual   size   of   the   data   in   a   given   field   with   the   ActualSize   property.    
  Determine   what   types   of   functionality   are   supported   for   a   given   field   with   the   Attributes   property   and   Properties   collection.    
  Manipulate   the   values   of   fields   containing   long   binary   or   long   character   data   with   the   AppendChunk   and   GetChunk   methods.    
  If   the   provider   supports   batch   updates,   resolve   discrepancies   in   field   values   during   batch   updating   with   the   OriginalValue   and   UnderlyingValue   properties.    
  All   of   the   metadata   properties   (Name,   Type,   DefinedSize,   Precision,   and   NumericScale)   are   available   before   opening   the   Field   object's   Recordset.   Setting   them   at   that   time   is   useful   for   dynamically   constructing   forms.  
  Top

4 楼dust3k(尘)回复于 2002-02-15 08:40:20 得分 0

字段备注内容是什么?:)   -->   the   content   of   Memo   type   fieldTop

5 楼hchxxzx(NET?摸到一点门槛)回复于 2002-02-15 12:51:07 得分 0

dust3k(尘)   :实在高明。  
  字段备注内容是什么?:)   这个可能是我写错了,我的原意是每个字段后面的说明文字,不知有没有办法得到?  
  为表示敬意,此贴再加分Top

6 楼ksy(一定要争气)回复于 2002-02-15 18:17:22 得分 0

typename()Top

7 楼hchxxzx(NET?摸到一点门槛)回复于 2002-02-15 21:35:04 得分 0

ksy(我是菜鸟我怕谁!我就是来送分的.)    
  不行,根本不接受这个  
    Microsoft   VBScript   运行时错误   错误   '800a01b6'    
   
  对象不支持此属性或方法:   'typename'    
  Top

8 楼julyclyde(Java初学(大学不教只好自己学))回复于 2002-02-16 20:35:08 得分 0

typename不是方法,是VBScript函数Top

9 楼ehom(?!)回复于 2002-02-16 21:03:57 得分 0

对,和用rs("***").Type效果类似,用来返回数据类型!Top

10 楼hchxxzx(NET?摸到一点门槛)回复于 2002-02-17 12:14:49 得分 0

是不是大家的意思不同?我的意思是要取出数据库里面每个字段在设计时的功能说明文字,不是要得到读出的数据的类型。是不是这个问题很难或很难理解?大家看一下,如果能解决,请再来回答一下,不能解决我也准备给分了。Top

11 楼ehom(?!)回复于 2002-02-17 14:15:52 得分 0

我认为用ADO读不出来,自己编写数据库接口?  
  上面的方法其实是用了ADO的FIELD对象属性!而FIELD对象属性中没有字段后面的说明文字这项!而且是否每种数据库都有字段备注这项内容?  
  Top

12 楼hchxxzx(NET?摸到一点门槛)回复于 2002-02-17 16:32:29 得分 0

就我所知,ORCALE就可以读出来,但ACESS我不知道。但我想每种数据库应都有这种东西吧,否则设计时不就很麻烦?Top

相关问题

  • 列出表字段?
  • 表字段的问题
  • mysql表字段问题?
  • 读取交叉表字段
  • SQL 并列表字段
  • 临时表字段问题
  • 数据表字段类型的问题?
  • 关于表字段付值的问题?
  • sql实现修改表字段名
  • 关于表字段的自增

关键词

  • 字段
  • 数据库
  • 内容
  • 属性
  • 文字
  • acess
  • 读出
  • 长度
  • 类型
  • 备注内容

得分解答快速导航

  • 帖主:hchxxzx
  • ehom
  • dust3k

相关链接

  • Web开发类图书

广告也精彩

反馈

请通过下述方式给我们反馈
反馈
提问
网站简介|广告服务|VIP资费标准|银行汇款帐号|网站地图|帮助|联系方式|诚聘英才|English|问题报告
北京创新乐知广告有限公司 版权所有, 京 ICP 证 070598 号
世纪乐知(北京)网络技术有限公司 提供技术支持
Copyright © 2000-2008, CSDN.NET, All Rights Reserved
GongshangLogo