来源:http://www.clicketyclick.dk/databases/xbase/format/db2_dbf.html#DB2_DBF_NOTE_4_SOURCE

Xbase: dBASE II data files (*.dbf)

  1. _______________________ _______
  2. 0 | Version number *1| ^
  3. |-----------------------| |
  4. 1 | Number of records | Record
  5. 2 | in data file (16 bit) | header
  6. |-----------------------| | _ |=======================| _______
  7. 3 | Date of last update | | / 0| Field name in ASCII | ^
  8. 4 | YYMMDD | | / : (terminated by 00h) : |
  9. 5 | | | | | | |
  10. |-----------------------| | | 10| | |
  11. 6 | Length of each record | | | |-----------------------| For
  12. 7 | ( 16 bits ) *2| | | 11| Field type in ASCII *4| each
  13. |-----------------------|--|--- | |-----------------------| field
  14. 8 | | | ^ | 12| Field length (binary)| |
  15. 9 | Field descriptor | | | ____/ |-----------------------| |
  16. : Array *5 : | | 13| Field adress in memory| |
  17. : (Terminated by 0Dh) : | | 14| | |
  18. : : | | ______ |-----------------------| |
  19. : : | | \ 15| Field decimal count | |
  20. : : | | \_ |=======================| _v_____
  21. | | | |
  22. 519| | | |
  23. |-----------------------| | |
  24. 520| Terminator *3|__v__v_
  25. |=======================| |
  26. 521| Records | |
  27. : : |
  28. : : |
  29. : : |
  30. : : |
  31. n| | |
  32. |__End_of_File__________| ___v____ End of file ( 1Ah ) *11
    1. dBASE II version no: 02h
    1. Sum of lengths of all fields + 1 (deletion flag). Max. length is 1,000 bytes
    1. Terminator: 0Dh if all 32 fields present, otherwise 00h.
    1. Field type Field type: C, N or L
    1. Field descriptor array Max. 32 fields
    1. Field lenght: 0 - ffh. Logical fields = 1, decimal no ( = no of digits)
    2. Field name can be undefined (= 1 x 00h)
  1. Field address in memory can be ignored.
  2. Deleted flag. Blanks (20h) are valid! "*" = deleted.

Note that records remain in the datafile when deleted (i.e. are marked with "*") The deleted record are moved out of the valid range of records by the pack command. But is still present in the data file!!! This means that the file size is unchanged!

  1. Deleted Packed
  2. =========== ===========
  3. |Header | |Header |
  4. |-----------| |-----------|
  5. |Valid 1 | |Valid 1 |
  6. |-----------| |-----------|
  7. |Deleted 1 | |Valid 2 |
  8. |-----------| |-----------|
  9. |Valid 2 | |Valid 3 |
  10. |-----------| |===========|
  11. |Deleted 2 | |EOF |
  12. |-----------| |===========|
  13. |Deleted 3 | |Deleted 1 |
  14. |-----------| |-----------|
  15. |Valid 3 | |Deleted 2 |
  16. |===========| |-----------|
  17. |EOF | |Deleted 3 |
  18. =========== ===========

shapefile中dbf的数据格式(转载)的更多相关文章

  1. PostGIS中dbf file (.dbf) can not be opened.shapefile import failed

    postgis数据库文件shapefile导入 dbf file (.dbf) can not be opened.shapefile import failed. Destination: publ ...

  2. spring中context:property-placeholder/元素 转载

    spring中context:property-placeholder/元素  转载 1.有些参数在某些阶段中是常量 比如 :a.在开发阶段我们连接数据库时的连接url,username,passwo ...

  3. SqlServer中的merge操作(转载)

    SqlServer中的merge操作(转载)   今天在一个存储过程中看见了merge这个关键字,第一个想法是,这个是配置管理中的概念吗,把相邻两次的更改合并到一起.后来在technet上搜索发现别有 ...

  4. postgis数据库文件shapefile导入 dbf file (.dbf) can not be opened.shapefile import failed.

    Destination: public.train_polylineSource File: C:\Documents and Settings\Administrator\桌面\ffffff\tra ...

  5. 解决Asp.net Mvc返回JsonResult中DateTime类型数据格式的问题

    问题背景: 在使用asp.net mvc 结合jquery esayui做一个系统,但是在使用使用this.json方法直接返回一个json对象,在列表中显示时发现datetime类型的数据在转为字符 ...

  6. MyBatis学习总结(三)——优化MyBatis配置文件中的配置(转载)

    本文转载自:http://www.cnblogs.com/jpf-java/p/6013548.html 一.连接数据库的配置单独放在一个properties文件中 之前,我们是直接将数据库的连接配置 ...

  7. 重温WCF之数据契约中使用枚举(转载)(十一)

    转载地址:http://www.zhuli8.com/wcf/EnumMember.html 枚举类型的定义总是支持序列化的.当我们定义一个新的枚举时,不必应用DataContract特性,就可以在数 ...

  8. ASP.NET Web API 中的异常处理(转载)

    转载地址:ASP.NET Web API 中的异常处理

  9. MSSQL中建立分区表(转载备忘)

    转载自CSDN地址:http://bbs.csdn.net/topics/330087045 SQL Server 2005 分区表实践——建立分区表(partition table) 问题:有一个订 ...

随机推荐

  1. CVE-2020-0796复现

    今天整理资料时发现了之前存的一个cve漏洞复现过程,当时打算跟着复现来着,后来也没去复现,今天刚好有时间,所以来复现一下这个漏洞 漏洞讲解 https://www.freebuf.com/vuls/2 ...

  2. go语言循环变量

    阅读go语言圣经第五章第六节介绍到了捕获迭代变量 package main import ( "fmt" ) func main() { var lis []func() for ...

  3. markdown编写文件目录结构

    1.先全局安装tree cnpm i tree-node-cli -g 然后输入: tree --help -L 是确定要几级目录,-I是排除哪个文件夹下的,然后我是要在README里面生成项目结构树 ...

  4. python中IF语句容易犯的错误CASE

    python中没有switch   case类似的语句,但是下面的IF语句却与之类似,却又不同: A = B = C = D = E = 1 if A == 1: B=2 elif B ==2: C= ...

  5. 带你走进memcache,老牌内存缓存技术

    一.核心优化概述 什么是优化:以更小的资源支持更大负载网站的运行,以小博大. 思路:尽量减少用户等待时间,节省系统资源开销,节省带宽使用. 优化什么地方?有三方面:Memcache内存缓存技术.静态化 ...

  6. 阿里云VOD(一)

    一.阿里云视频点播 1.功能介绍 视频点播(ApsaraVideo VoD,简称VoD)是集视频采集.编辑.上传.媒体资源管理.自动化转码处理(窄带高清TM).视频审核分析.分发加速于一体的一站式音视 ...

  7. Sentry(v20.12.1) K8S 云原生架构探索,JavaScript Enriching Events(丰富事件信息)

    系列 Sentry-Go SDK 中文实践指南 一起来刷 Sentry For Go 官方文档之 Enriching Events Snuba:Sentry 新的搜索基础设施(基于 ClickHous ...

  8. SuperUpdate.sh 一键更换Linux软件源脚本

    一.前言 有时候会遇到 Linux 的源更新速度非常的缓慢,特别是在国内使用默认的源,因为国内的网络环境,经常会出现无法更新,更新缓慢的情况.在这种情况下,更换一个更适合或者说更近,更快的软件源,会为 ...

  9. The Node.js Event Loop, Timers, and process.nextTick()

    The Node.js Event Loop, Timers, and process.nextTick() | Node.js https://nodejs.org/uk/docs/guides/e ...

  10. 洛谷P4180

    被教练安排讲题 可恶 这道题我是十月初上课时花了一下午做出来的,当时连倍增都不会,过程比较困难,现在看看还可以 本来想口胡一发,后来想了想可能以后要用,还是写成文章吧 Description 求一棵严 ...