Method and device for storing length-various field of embedded database

An implementation method and database technology are applied in the field of database storage to achieve the effect of improving memory utilization and avoiding memory fragmentation

Inactive Publication Date: 2008-07-23
ZTE CORP
View PDF0 Cites 11 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0006] The technical problem to be solved by the present invention is to provide a method and device for implementing variable-lengt

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and device for storing length-various field of embedded database
  • Method and device for storing length-various field of embedded database
  • Method and device for storing length-various field of embedded database

Examples

Experimental program
Comparison scheme
Effect test

Example Embodiment

[0028] The following examples illustrate the specific implementation of the method of the present invention:

[0029] When creating the data table, allocate a piece of memory from the system as the dedicated memory for variable length fields. This memory is assumed to be 100K in size. This memory can be divided into several BLOCKs. If each BLOCK is 20 bytes, it can be divided into 5000 BLOCK. These 5000 BLOCKs can be shared by all variable length fields, and the index number of each BLOCK is the sequence number of the BLOCK. The variable-length field in the record is represented by the starting BLOCK index number and the data length. The starting BLOCK index number represents the BLOCK at the starting storage location of the data of the variable-length field. The BLOCK itself can be chained to store large-capacity data. The length indicates the data length of the variable length record. A schematic diagram of the storage of a record with a variable length field is shown in Figure ...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a realization method and a device of length-varying field memory of an imbedded database, which comprises: allocating a large memory block as an exclusive memory area of a length-varying field for each datasheet of a database, dividing the memory block into a plurality of BLOCKS with fixed sizes which are connected pre-and post through an index to form a BLOCK chain. When real length of a length-varying field is less than or equals to one BLOCK length, one BLOCK is allocated to store the length-varying field; when real length of a length-varying field is more than one BLOCK length, a plurality of BLOCKS are allocated to form a BLOCK chain to store the length-varying field. The invention can effectively solve the memory fragment problem and improves memory utility rate.

Description

technical field [0001] The invention relates to database storage of an embedded system in the field of computer database storage, in particular to a method and device for realizing variable-length field storage in an embedded database. Background technique [0002] Databases are widely used in various computer data storage systems. With the development of embedded devices, applications on embedded terminals have become more and more complex. The need for storage and management of large amounts of data has led to the emergence of embedded databases. Different from desktop computers, embedded terminal hardware resources are limited, so the memory is often relatively small. In addition, due to the lack of virtual storage management, frequent applications for memory release will cause memory fragmentation, and eventually even if there is memory, it cannot be accessed due to too much fragmentation. Assigned to. The above two points are important factors to consider when designin...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G06F17/30
Inventor 殷飞童晓演薛晨曦
Owner ZTE CORP
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products