Connect public, paid and private patent data with Google Patents Public Datasets

Method and device for archiving historical data

Download PDF

Info

Publication number
CN103514295A
CN103514295A CN 201310471385 CN201310471385A CN103514295A CN 103514295 A CN103514295 A CN 103514295A CN 201310471385 CN201310471385 CN 201310471385 CN 201310471385 A CN201310471385 A CN 201310471385A CN 103514295 A CN103514295 A CN 103514295A
Authority
CN
Grant status
Application
Patent type
Prior art keywords
historical
data
task
archived
archiving
Prior art date
Application number
CN 201310471385
Other languages
Chinese (zh)
Other versions
CN103514295B (en )
Inventor
冯卫勇
吴卫荣
刘玉龙
张权
刘燕伟
白思杰
耿宏宇
李思昊
王燕
陶安
Original Assignee
中国电子科技集团公司第十五研究所
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING; COUNTING
    • G06FELECTRICAL DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/30Information retrieval; Database structures therefor ; File system structures therefor
    • G06F17/30286Information retrieval; Database structures therefor ; File system structures therefor in structured data stores
    • G06F17/30312Storage and indexing structures; Management thereof
    • G06F17/30342Details of User-Defined Types; Storage management thereof
    • GPHYSICS
    • G06COMPUTING; CALCULATING; COUNTING
    • G06FELECTRICAL DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/30Information retrieval; Database structures therefor ; File system structures therefor
    • G06F17/30286Information retrieval; Database structures therefor ; File system structures therefor in structured data stores
    • G06F17/30386Retrieval requests
    • G06F17/30424Query processing
    • G06F17/30442Query optimisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING; COUNTING
    • G06FELECTRICAL DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/30Information retrieval; Database structures therefor ; File system structures therefor
    • G06F17/30286Information retrieval; Database structures therefor ; File system structures therefor in structured data stores
    • G06F17/30386Retrieval requests
    • G06F17/30424Query processing
    • G06F17/30522Query processing with adaptation to user needs

Abstract

The invention discloses a method for archiving historical data. The method for archiving the historical data comprises the steps of (1) extracting the historical data matched with a task to be edited from a whole historical database containing data which are collected, are stored and are related to tasks; (2) editing the extracted historical data, and forming archived historical data; (3) setting a task identification for the archived historical data, and storing the archived historical data with the task identification on a preset task archived historical database. When the method for archiving the historical data is applied, the access speed of the historical data of the task can be increased.

Description

历史数据归档方法及历史数据归档装置 Historical data archiving methods and historical data archiving device

技术领域 FIELD

[0001] 本发明涉及信息技术领域,尤其涉及一种历史数据归档方法及历史数据归档装置。 [0001] The present invention relates to the field of information technology, particularly to a method and historical data archiving historical data archiving device.

背景技术 Background technique

[0002] 实际应用中,金融、通讯等行业需要建立关系数据库应用系统,通过整体历史数据库来实时记录大量的数据,同时,往往为了满足某一任务需求,需要对预先存储的整体数据中与任务相关的资料进行更新维护。 [0002] practical applications, finance, telecommunications and other industries need to build a relational database application system, a large amount of data recorded in real time through the whole history database, while often in order to meet the needs of a particular task, it is necessary for the overall data previously stored in the task relevant information is updated maintenance. 例如,对于一个大型的功能系统模块,在运行该功能系统模块时,会对该功能系统模块的所有性能指标参数进行实时记录,而所有实时记录的性能指标参数构成整体历史数据;而为了进行一项关于在X条件下性能指标Y对于性能指标Z的影响研究,需要对与该研究相关的数据进行编辑。 For example, for a large system functional module, when running the system function modules will be performed on all the performance parameters of real-time recording function of the system modules, the performance parameters of all the integral of the real time recording history data; In order to carry out a term studies on the impact of the performance index Z under conditions of performance indicators X Y, need to edit the data associated with the study.

[0003] 现有,在待编辑任务开始之后,对当前时刻包含了各待编辑任务相关数据的整体数据中与任务相关的资料进行编辑更新,在任务结束时,将已编辑的整体数据作为整体历史数据归档存储到整体历史数据库中,其中,已编辑的整体数据包括与任务相关的数据以及与任务无关的数据。 [0003] existing, to be edited after the mission began, the current time is included in each of the overall data to be edited tasks related to data and information related to the task of editing the update, at the end of the task, the whole edited data as a whole historical data archive storage to the overall history database, which has been edited overall data includes data related to the task, and the task has nothing to do with the data. 由于在不同的时间段为满足不同的任务需求会产生不同的整体历史数据,因此,可以根据执行该任务的编辑时间段建立索引信息,用以对产生的不同的历史整体数据作出区分。 Due to produce different overall historical data to meet the needs of different tasks in different time periods, so you can edit the index information according to the time period to perform the task, to make a distinction between the different overall historical data generated.

[0004] 这种基于任务资料更新的历史数据归档方法,需要占用较大的存储空间来存储这些不同时间段产生的整体历史数据;而且,产生的整体历史数据中与任务无关的数据存在重复存储的问题,造成了存储空间的浪费。 [0004] This historical data archiving method based on the updated mission information, take up more storage space to store the entire historical data generated by these different time periods; and, overall historical data generated with tasks not related to duplicate data storage the problem, resulting in a waste of storage space. 另一方面,当需要获取某一历史时间段内满足任务需求并与任务相关的任务历史数据时,必须根据与该历史时间段相应的索引信息从整体历史数据库中获取相应的整体历史数据,然后,遍寻整个获取的整体历史数据,从中筛选出该历史时间段内满足任务需求并与任务相关的任务历史数据,存在任务历史数据访问速度慢的问题。 On the other hand, when the need to get a certain historical period of time to meet the mission requirements and job history data associated with the task, it must obtain the appropriate data from the whole history of the entire historical database in accordance with the corresponding period of the history of the index information, then overall historical data anywhere to be found throughout the acquisition, screened out of the question the historical period to meet mission requirements and tasks of historical data related to the task, there is a task of historical data access speed is slow.

[0005] 为解决存储空间浪费的问题,现有提出在对整体数据中与任务相关的数据进行更新维护之后,将与任务相关的且进行更新维护的数据单独归档存储,形成历史更新数据;在不同时间段内,为满足不同的任务需求会产生不同的历史更新数据,因此,可以通过添加时间戳或记录编号等标识信息对不同的历史更新数据作出区分。 [0005] In order to solve the problem of waste storage space, made available after the data in the overall data relevant to the task of updating maintenance, and related tasks will separate archival storage and updating of data maintenance, formation history update data; in different time periods, in order to meet the needs of different tasks will have different historical update data, so you can make a distinction between different historical or update data by adding a time stamp record number and other identifying information. 该改进的技术方案,虽然解决了与任务无关的数据的重复存储问题,但在需要获取某一历史时间段内满足任务需求并与任务相关的任务历史数据时,需根据标识信息获取该历史时间段内更新维护的并与任务相关的历史更新数据;同时需从历史整体数据库中调取同一历史时间段内的整体历史数据,获取与任务相关但未进行更新的历史数据,这样才能准确完整地获取该历史时间段内所有与任务相关的任务历史数据。 When the improved technical solution solves the problem of duplicate storage of data and task-independent, but need to get a certain historical period of time to meet the mission requirements and job history data associated with the task, the need to obtain identification information based on the history of time update and maintain the history and update data in the segment related to the task; at the same time to be retrieved from the database as a whole the whole history of historical data of the same historical period, but did not obtain the relevant update task of historical data, so as to accurately and completely get all tasks associated with the task of historical data for the historical period. 当需要获取不同历史时间段的数据时,则需要在不同的历史更新数据与整体数据之间频繁访问,造成任务历史数据访问速度慢。 When you need to get data from different historical periods, they need frequent access between different historical data and update the overall data, causing job history data access is slow.

发明内容[0006] 本发明的实施例提供一种历史数据归档方法,能够提高任务历史数据访问速度。 SUMMARY [0006] Embodiments of the present invention provides a method of historical data archiving, it is possible to improve the speed of data access task history.

[0007] 根据本发明的另一方面,本发明实施例还提供了一种历史数据归档装置,能够提高任务历史数据访问速度。 [0007] According to another aspect of the present invention, embodiments of the present invention further provides a historical data archiving apparatus can be improved task history data access speed.

[0008] 为达到上述目的,本发明实施例提供的一种历史数据归档方法,该方法包括: [0008] To achieve the above object, a historical data archiving method according to an embodiment of the present invention, the method comprising:

[0009] 从采集并存储的包含了与各待编辑任务相关数据的整体历史数据库中,提取与待编辑任务相匹配的历史数据; [0009] The entire history database contains data related to each editing task to be collected and stored from the extracted history data editing tasks to be matched;

[0010] 对提取的历史数据进行编辑并形成归档历史数据; [0010] historical data extraction form for editing and archiving historical data;

[0011] 为归档历史数据设置任务标识,并将设置有任务标识的归档历史数据存储到预先设置的任务归档历史数据库中。 [0011] set the task to archive historical data to identify and set archiving historical data stored task identifier to the task of archiving preset historical database.

[0012] 较佳地,所述提取的历史数据包括:预操作数据、与所述预操作数据关联的预操作从属数据、条件数据;其中, [0012] Preferably, the extraction history data comprising: a pre-operation data, and operation data associated with the pre-pre-operation dependent data, condition data; wherein,

[0013] 所述预操作数据为当前待编辑任务所需进行更新维护操作的数据; [0013] The pre-operation data required to update data maintenance operations to be currently editing tasks;

[0014] 所述预操作从属数据为与当前待编辑任务相关,且随所述预操作数据的改变而变化的数据; [0014] The pre-operation of the slave data relating to the current task to be edited, and data with the pre-change operation data varies;

[0015] 所述条件数据为与当前待编辑任务相关,但无需进行更新的数据。 The [0015] condition data is associated with the current task to be edited, but the data without updating.

[0016] 较佳地,在所述提取与待编辑任务相匹配的历史数据之前、同时或之后,所述方法进一步包括: [0016] Preferably, prior to the extraction task to be edited to match the historical data, after or simultaneously, said method further comprising:

[0017] 为待编辑任务设置任务标识及任务编辑时间段; [0017] The task ID is provided to edit task period and the task editor;

[0018] 构建包含任务标识栏、预操作数据栏、与预操作数据关联的预操作从属数据栏以及条件数据栏的任务数据关系表; [0018] The construct contains the task identification field, data field pre-operation, the pre-pre-operation data manipulation tasks dependent data and the condition data field of a data table associated column;

[0019] 在所述对提取的历史数据进行编辑形成归档历史数据之前,所述方法进一步包括: Prior to [0019] of the extracted history data editing history data in the archive is formed, said method further comprising:

[0020] 将所述为待编辑任务设置的任务标识写入任务数据关系表中的任务标识栏,并根据待编辑任务、任务标识以及与待编辑任务的相匹配历史数据之间的对应关系,将所述提取的历史数据写入任务数据关系表中的相应栏。 [0020] The data write task tab task relation table as task ID to be edited job setting, and match the correspondence between the historical data to be edited in accordance with the task, the task ID and the task to be edited, the historical data of the extracted data written to the corresponding task bar relational tables.

[0021] 较佳地,所述对提取的历史数据进行编辑并形成归档历史数据,具体为, [0021] Preferably, the historical data extracted for edit, and history data archive is formed, in particular,

[0022] 在待编辑任务的编辑时间段内,对任务历史数据表中与为待编辑任务设置的任务标识对应的预操作数据进行更新维护; [0022] period to be edited in the editing tasks, the task of pre-operation data table history data is to be edited and the task ID corresponding to the set task update maintenance;

[0023] 根据预操作数据的改变更新预操作从属数据。 [0023] The operation of the pre-update data to change the pre-operating slave data.

[0024] 较佳地,所述归档历史数据包括:任务数据关系表中已完成更新维护的预操作数据、根据预操作数据的改变而作出相应更新的预操作从属数据,以及条件数据。 [0024] Preferably, the history data archive comprising: task data relation table pre-operation data have been updated to maintain, update and make the corresponding pre-slave operation data, and operation condition data according to the pre-change data.

[0025] 较佳地,在所述对提取的历史数据进行编辑并形成归档历史数据之后,在所述形成归档历史数据之前,该方法包括: [0025] Preferably, after the edit history data and the extracted history data archiving is formed, prior to forming the archiving historical data, the method comprising:

[0026] 为已编辑的历史数据分别建立预操作数据备份表、预操作从属数据备份表及条件数据备份表;其中, [0026] established as historical data are pre-edited data backup operation table, pre-dependent data backup operation and condition data table backup table; wherein,

[0027] 所述预操作数据备份表用于存储已编辑的历史数据中的预操作数据,并设置有与当前待编辑任务相应的任务标识; [0027] The pre-pre-operation data operation history data table for storing backup data in the editing, and is provided with a respective current editing task to be the task identifier;

[0028] 所述预操作从属数据备份表用于存储已编辑的历史数据中的预操作从属数据,并设置有与当前待编辑任务相应的任务标识;[0029] 所述条件数据备份表用于存储已编辑的历史数据中的条件数据,并设置有与当前待编辑任务相应的任务标识。 [0028] The operation of the pre-pre-history data dependent operation dependent data table for storing backup data in the editing, and is provided with the respective current editing task to be the task identifier; [0029] The condition table for data backup condition data stored historical data edited in, and to be provided with current editing task to identify the appropriate task.

[0030] 进一步地,将所述预操作数据备份表、所述从属数据备份表及所述条件数据备份表存储到预先设置的任务归档历史数据库中。 [0030] Furthermore, the pre-table operation data backup, the backup slave data and the condition data table backup table stored in the job archive preset historical database.

[0031] 较佳地,在所述为归档历史数据设置任务标识,并将设置有任务标识的归档历史数据存储到预先设置的任务归档历史数据库中之后,该方法进一步包括: After [0031] Preferably, in the setting history data archive task identifier, and set an archive of historical data stored task ID of the task to the preset historical database archive, the method further comprising:

[0032] 接收以任务标识表示的任务历史数据查询请求,并根据接收的任务标识从任务归档历史数据库中筛选出与任务标识对应的归档历史数据。 [0032] Historical data query request receiving task to the task identifier indicated, and archiving historical data archiving and screened to identify the corresponding task from the task history database according to the received task ID.

[0033] 根据本发明的另一方面,还提供了一种历史数据归档装置,该装置包括:任务数据管理模块、归档数据更新模块、任务历史数据存储模块;其中, [0033] According to another aspect of the present invention, there is provided a historical data filing apparatus, the apparatus comprising: task data management module, the archive data update module, the task history data storage means; wherein,

[0034] 所述任务数据管理模块,用于从采集并存储的包含了与各待编辑任务相关数据的整体历史数据库中,提取与待编辑任务相匹配的历史数据; [0034] The job data management module for containing the whole historical database associated with each data editing task to be collected and stored from the extracted history data to be edited to match the task;

[0035] 所述归档数据更新模块,用于对由所述任务数据管理模块提取的历史数据进行编辑并形成归档历史数据; [0035] The archived data updating module, for historical task data extracted by the data management module and form editing history data archive;

[0036] 所述任务历史数据存储模块,用于为由所述归档数据更新模块形成的归档历史数据设置任务标识,并将设置有任务标识的归档历史数据存储到预先设置的任务归档历史数据库中。 [0036] The job history data storage means for archiving historical data provided by said task identification archival data update module is formed, and is provided with a history database archive job archive task ID stored historical data to set in advance .

[0037] 较佳地,所述提取的历史数据包括:预操作数据、与预操作数据关联的预操作从属数据、条件数据;其中, [0037] Preferably, the extraction history data comprising: a pre-operation data, operation data slave data associated with the pre-pre-operation condition data; wherein,

[0038] 所述预操作数据为当前待编辑任务所需进行更新维护操作的数据; [0038] The pre-operation data required to update data maintenance operations to be currently editing tasks;

[0039] 所述预操作从属数据为与当前待编辑任务相关,且随所述预操作数据的改变而变化的数据; [0039] The pre-operation of the slave data relating to the current task to be edited, and data with the pre-change operation data varies;

[0040] 所述条件数据为与当前待编辑任务相关,但无需进行更新的数据。 [0040] The condition data is associated with the current task to be edited, but the data without updating.

[0041] 较佳地,所述任务数据管理模块进一步用于为待编辑任务设置任务标识及任务编辑时间段;构建包含任务标识栏、预操作数据栏、预操作从属数据栏以及条件数据栏的任务数据关系表; [0041] Preferably, said task data management module is further used to set the task to be edited editing task ID and the task period; construct contains the task identification field, a pre-operation data field, data field and the pre-operation condition data dependent column task data table;

[0042] 将为待编辑任务设置的任务标识写入任务数据关系表中的任务标识栏,并根据待编辑任务、任务标识以及与待编辑任务相匹配的历史数据之间的对应关系,将所述提取的历史数据写入任务数据关系表中的相应栏。 Task ID [0042] will be written into the task of editing task settings tab in the task table data, and the correspondence between the task to be edited, task identity and history data editing tasks to be matched, The historical data written in the corresponding column of said extracts task data in a relational table.

[0043] 由上述技术方案可见,本发明实施例提供的一种历史数据归档方法以及历史数据归档装置,通过将预先存储的整体数据中与待编辑任务相关的所有历史数据部署给该待编辑任务,并对与该待编辑任务相关的历史数据进行更新维护,形成归档历史数据;为归档历史数据设置任务标识,并作为任务历史数据存储到任务归档历史数据库中,这样,就实现了整体数据与任务历史数据的分离。 [0043] can be seen from the above technical solutions, a historical data archiving historical data archiving methods and apparatus provided in the embodiment of the present invention, all the historical data by deploying the entire data previously stored to be associated with editing tasks to the task to be edited , and historical data associated with the task to be edited is updated to maintain form archive historical data; archive historical data set identifies the task, and the task as historical data stored in the job archive history database, so that you achieve the overall data separate task historical data. 当需要查询或获取某一历史时间段内满足任务需求并与任务相关的任务历史数据时,可以通过任务标识,从任务归档历史数据库中直接筛选出与该任务对应的任务历史数据,而无需访问整体历史数据库,访问速度快。 When you need to query or obtain a certain historical period of time to meet the mission requirements and job history data associated with the task, the task can be identified from the screening task history database archiving historical data directly to a task corresponding to the task, without access overall historical database access speed.

附图说明 BRIEF DESCRIPTION

[0044] 为了更清楚地说明本发明实施例或现有技术中的技术方案,以下将对实施例或现有技术描述中所需要使用的附图作简单地介绍。 [0044] In order to more clearly illustrate the technical solutions in the embodiments or the prior art embodiment of the present invention, the following embodiments or the accompanying drawings required for describing the prior art will be used in the embodiments are introduced briefly. 显而易见地,以下描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员而言,还可以根据这些附图所示实施例得到其它的实施例及其附图。 Apparently, the following description drawings are only some embodiments of the present invention, and those of ordinary skill in the art, may also be obtained in other embodiments and the accompanying drawings according to embodiments shown in these figures.

[0045] 图1为本发明实施例历史数据归档方法流程示意图。 [0045] FIG. 1 is a schematic flowchart archiving method embodiment of the present invention, the historical data.

[0046]图2为本发明实施例历史数据归档装置结构示意图。 [0046] FIG. 2 is a schematic configuration example of history data filing apparatus embodiment of the present invention.

具体实施方式 detailed description

[0047]以下将结合附图对本发明各实施例的技术方案进行清楚、完整的描述,显然,所描述的实施例仅仅是本发明的一部分实施例,而不是全部的实施例。 [0047] The following technical solutions in conjunction with the accompanying drawings of various embodiments of the present invention will be clearly, a complete description of the embodiment, obviously, the described embodiments are merely part of embodiments of the present invention rather than all embodiments. 基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动的前提下所得到的所有其它实施例,都属于本发明所保护的范围。 Based on the embodiments of the present invention, all other embodiments of ordinary skill in the art without creative work are obtained fall within the scope of the claimed invention.

[0048] 现有将与任务相关的数据进行更新维护后的整体数据作为整体历史数据存储到整体历史数据库中,存在浪费存储空间及任务历史数据访问速度慢的问题;即使采用改进的技术方案把与任务相关的数据进行更新维护后的更新数据作为历史更新数据进行单独存储,虽然解决了存储空间浪费问题,但由于需结合历史更新数据与整体数据才能获取完整的任务历史数据,仍然存在任务历史数据访问速度慢的问题。 Overall data [0048] the existing data relevant to the task of updating the maintenance history data storage as a whole to the whole history database, there is a waste of storage space and data access speeds slow task history of problems; even with improved technology solutions to data related to the task of updating the update data maintained as historical update data stored separately, solves the storage space waste problem, but the need to combine history update data and the overall data in order to obtain a complete job history data, there remains the task of history data access speed slow.

[0049] 本发明实施例提供的历史数据归档方法,在任务开始之前,将预先存储的整体数据中与任务相关的所有历史数据部署给该任务。 [0049] The historical data archiving method provided in the embodiment of the present invention, before the task is started, all the historical data previously stored the entire data associated with deployment task to the task. 然后,在该待编辑任务执行期间,可以对历史数据进行更新维护,形成归档历史数据;当任务结束时,为归档历史数据设置任务标识,并将设置了任务标识的归档历史数据作为任务历史数据存储到任务归档历史数据库中,这样,实现了整体数据与任务历史数据的分离。 Then, during the editing tasks to be executed, you can update and maintain historical data, forming archiving historical data; when the end of the task, the task set for the archiving historical data to identify and set the task of archiving historical data identified as a task of historical data stored in the job archive history database, this way, a separation of data and the overall mission of historical data. 在需要获取某一历史时间段内满足任务需求并与任务相关的历史数据时,可以直接通过任务标识,从任务归档历史数据库中筛选出与该任务对应的任务历史数据,访问速度快。 When meet mission requirements needed to obtain a certain historical period and historical data associated with the task, the task can be identified directly from the task history database archive screened task history data corresponding to the task, fast access speed.

[0050] 图1为本发明实施例历史数据归档方法流程示意图。 [0050] FIG. 1 is a schematic flowchart archiving method embodiment of the present invention, the historical data. 在根据任务需求对预先存储的整体数据中与任务相关的数据进行更新维护之前,较佳地,预先在数据库系统中构建任务表以及任务数据关系表;其中, Maintained prior to updating the data in the entire data stored in advance according to the task task-related requirements, preferably, the pre-built data task table and a task relation table in the database system; wherein,

[0051] 构建的任务表中包括任务标识栏、起始时间栏以及终止时间栏,用于存储与各项任务对应的任务标识以及任务的编辑时间段;当然,也可以将起始时间栏及终止时间栏整合成编辑时间段栏; [0051] Construction of the task table comprises the task identification field, a start time column and an end time column editing time period, for storing tasks and task corresponding to the task identifier; of course, also be the start time column and termination time bar period of integration into the edit bar;

[0052] 构建任务与数据的关系表,即任务数据关系表,其中,任务数据关系表中包括任务标识栏、数据栏,用于存储与各项待编辑任务对应的任务标识,以及与当前待编辑任务相关的数据。 [0052] Construction of the task table data, i.e. data table task, wherein the task data comprise the task relationship table identification field, data field, to be used to store the task identifier corresponding to the editing tasks, as well as the current to be data editing tasks related.

[0053] 本发明实施例中,预先存储的整体数据可以由不同的共享数据表及共享数据关系表组成,其中,共享数据关系表中存储的数据随共享数据表中数据的改变而改变。 Embodiment [0053] of the present invention, the entire table may be pre-stored data table and a shared data shared by different data, where the data table stored in the shared data with the changed data in the shared data table changes.

[0054] 例如,整体数据由共享数据表A、共享数据表B以及共享数据关系表C组成;其中,共享数据表A中由数据Ai (i=l、2、3、4……)组成,共享数据表B中由数据Bj (j=l、2、3、4......)组成;共享数据关系表C中由数据Cn (n=l、2、3、4......)组成。 [0054] For example, the overall data from the shared data in Table A, Table B shared data and a shared data table C; wherein the shared data by the data in Table A, Ai (i = l, 2,3,4 ......) composition, table B shared data by the data Bj (j = l, 2,3,4 ......) composition; relationship shared data by the data in table C Cn (n = l, 2,3,4 .... ..)composition.

[0055] 其中,假设当共享数据表A中的数据Al发生改变时,共享数据关系表C中的数据Cl将随数据Al的变化而产生相应的改变;[0056] 当共享数据表B中的数据B2发生改变时,共享数据关系表C中的数据C2将随数据B2的变化而产生相应的改变; [0055] wherein, assumed that when the data is shared data in Table A Al changed, data sharing, data table C is Cl will vary with Al variation data to produce the corresponding change; [0056] When the shared data in Table B changed data B2, C2 of the table data in C B2 will change with data generated by a corresponding change in the shared data relationships;

[0057] 当共享数据表A中添加或删除数据A3,则共享数据关系表C将相应的添加或删除数据C3 ; [0057] add or delete data in Table A, when the shared data A3, the shared data table C to add or delete data corresponding to a C3;

[0058] 当共享数据表A中的数据A2、A4,和/或,共享数据表B中的数据B1、B3发生改变时,共享数据关系表C中的数据不发生改变。 [0058] When the data in Table A shared data A2, data B1 A4, and / or shared data in Table B, B3 changes, the shared data in the table data C does not change.

[0059] 本发明实施例中,需进行数据维护的任务可以以T表示,如第一任务表示为Tl,起始时间为2013年8月I日,终止时间为2013年8月5日;第二任务表示为T2,起始时间为2013年8月8日,终止时间为2013年8月20日。 [0059] The embodiments of the present invention, the need for data maintenance tasks may be represented by T, is expressed as a first task Tl, the starting time is I day in August 2013, the termination time of August 5, 2013; the first two tasks represented as T2, the start time for the August 8, 2013, the end time for the August 20, 2013. 则建立的相应的任务表中可以包括:第一任务的任务标识Tl以及第一任务的起始时间2013.08.01,以及终止时间2013.08.05,或第一任务的编辑时间段2013.08.01-2013.08.05 ;第二任务标识T2以及第二任务的起始时间2013.08.08,以及终止时间2013.08.20,或第二任务的编辑时间段2013.08.08-2013.08.20。 The respective created task table may include: editing task identification period start time Tl of the first task and the first task 2013.08.01, 2013.08.05 and the end time, or the first task 2013.08.01-2013.08 0.05; editing period start time of the second task and the second task identification T2 2013.08.08, 2013.08.20 and the end time, or the second task 2013.08.08-2013.08.20.

[0060] 进一步地,假设在整体数据中与第一任务Tl相关的数据包括共享数据表A中的A1、A2、A3、A4,共享数据表B中的B1、B2、B3 ;因此共享数据关系表C中的数据C1、C2、C3也与第一任务Tl相关,而整体数据中,如共享数据表A中的数据A5、A6等,共享数据表中的数据B4、B5等均为与第一任务Tl无关的数据。 [0060] Further, assuming that the first task Tl shared data includes data relating to Table A A1, A2, A3, A4, shared data in Table B B1, B2, B3 in the overall data; therefore share data relationships data in table C1 C, C2, C3 is also related to the first task Tl, while the overall data, shared data A5 the data in table a, A6, etc., the shared data in the table data B4, B5 and so are the first a task Tl-independent data. 这样,建立的相应的任务数据关系表中可以包括:第一任务的任务标识Tl以及与任务相关的数据Al、A2、A3、A4、B1、B2、B3、Cl、C2、C3,其中,数据Al、A3及B2为第一任务Tl预执行更新维护的数据,数据A2、A4、B1、B3为与第一任务Tl相关但不需进行更新维护的数据。 Thus, the corresponding task table established data may include: a first task Tl task identification and task-related data Al, A2, A3, A4, B1, B2, B3, Cl, C2, C3, wherein the data al, A3 and B2 are a first pre-execution task Tl maintenance update data, data A2, A4, B1, B3 is associated with a first task Tl but without performing the data update maintenance.

[0061] 如图1所示,本发明实施例提供的历史数据归档方法包括: Historical data archiving method provided by [0061] 1, the embodiment of the present invention comprises:

[0062] 步骤101,从采集并存储的包含了各待编辑任务相关数据的整体历史数据库中,提取与待编辑任务相匹配的历史数据; [0062] Step 101, from the collected and stored in the historical database comprising the overall data of each task to be edited, the extraction history data to be edited to match the task;

[0063] 本步骤中,从整体历史数据库中提取的与当前待编辑任务相匹配的历史数据包括:预操作数据、与预操作数据关联的预操作从属数据、条件数据;其中, [0063] In this step, the historical data and the current task to be edited to match the extracted from the whole history database comprising: a pre-operation data, operation data pre-operating with the pre-dependent data, data associated with the condition; wherein,

[0064] 预操作数据为当前待编辑任务所需进行维护或删除等更新维护操作的数据; [0064] pre-operational data to be edited for the current tasks required for maintenance such as update or delete data maintenance operations;

[0065] 预操作从属数据为与当前待编辑任务相关,且随预操作数据的改变而变化的数据; [0065] The pre-operation of the slave data relating to the current task to be edited, and change with pre-operation data varies transactions;

[0066] 条件数据为与当前待编辑任务相关,但无需进行更新的数据。 [0066] condition data associated with the current task to be edited, but without the need for data updates.

[0067] 例如,从存储的整体历史数据库中筛选出与第一任务Tl相关的数据:共享数据表A中的A1、A2、A3、A4,共享数据表B中的B1、B2、B3以及共享数据关系表C中的数据C1、C2、C3。 [0067] For example, screening the whole history database stored in the data related to the first task Tl: Table A shared data A1, A2, A3, A4, shared data in Table B B1, B2, B3 and share table C data C1 of data relationships, C2, C3. 其中,预操作数据是指数据Al、A3及B2 ;预操作从属数据是指数据Cl、C2、C3,而条件数据是指数据A2、A4、B1、B3。 Wherein the pre-operation data is data Al, A3 and B2; pre-operation data is data dependent Cl, C2, C3, and condition data is data A2, A4, B1, B3.

[0068] 较佳地,本发明实施例中,在提取与待编辑任务相匹配的历史数据之前,同时或之后,该方法进一步还可以包括: [0068] Preferably, the embodiments of the present invention, prior to extraction history data editing task to be matched, after or at the same time, the method may further further comprising:

[0069] 为待编辑任务设置任务标识及任务编辑时间段; [0069] The task ID is provided to edit task period and the task editor;

[0070] 构建包含任务标识栏、预操作数据栏、与预操作数据关联的预操作从属数据栏以及条件数据栏的任务数据关系表; [0070] construct contains the task identification field, data field pre-operation, the pre-pre-operation data manipulation tasks dependent data and the condition data field of a data table associated column;

[0071] 在对提取的历史数据进行编辑形成归档历史数据之前,该方法进一步包括:将为待编辑任务设置的任务标识写入任务数据关系表中的任务标识栏,并根据待编辑任务、任务标识以及与待编辑任务的相匹配历史数据之间的对应关系,将提取的历史数据写入任务数据关系表中的相应栏。 [0071] Before forming edit history data archiving historical data extraction, the method further comprising: editing tasks will be set task ID writing task tab task data in relational tables, to be edited and in accordance with the task, the task matches the correspondence between the historical data and the identification of the task to be edited, the extracted history data written in the corresponding column in the task table data.

[0072] 具体地,可以在预先构建的任务表中添加与当前待编辑任务对应的任务标识及任务编辑时间段并将当前编辑任务的起始时间及终止时间以编辑时间段的方式存储到编辑时间段栏中。 [0072] Specifically, in the task table may be added to a pre-constructed and the start time and end time in the current editing task period edit task ID and the storing period of the current editing task corresponding to the task to be edited to the editing time bar.

[0073] 本发明实施例中,任务是指一次活动,该活动涉及预先存储的整体数据中的部分数据,并需对涉及的部分数据中的某些数据进行更新维护。 [0073] Example embodiments of the present invention, refers to a task activity, which relates to the entire data portion of the data stored in advance, and the need for some portion of the data involved in the data is updated maintenance. 其中,每一次活动对应一个任务标识及活动编辑时间段,这样,每一个任务对应一个任务标识、任务编辑时间段,例如第一任务表示为Tl,起始时间为2013年8月I日,终止时间为2013年8月5日,则将第一任务的任务标识Tl以及第一任务的编辑时间段2013.08.01-2013.08.05分别写入任务表中的相应栏。 Among them, a task once for each event logo and edit time activities, so that each task corresponds to a task identity, task editing time period, for example, the first task is expressed as Tl, the start time for the day in August 2013 I terminated time is August 5, 2013, will be the first task of the task ID Tl and edit the time period of the first tasks 2013.08.01-2013.08.05 are written in the corresponding column in the task table. 实际应用中,通过在任务表中记录待编辑任务的任务标识、任务起始时间以及任务结束时间,便于后续应用中,用户可以通过任务标识或编辑时间段来查询并获取与执行的任务相关的任务历史数据。 In practical application, the task identified by the task to be edited is recorded in the task table, start time of the task and the job end time, to facilitate the subsequent application, the user can be queried and obtained by identifying or editing tasks associated with the task execution period of task historical data.

[0074] 本发明实施例中,预先构建的任务数据关系表中的数据栏可以拆分为预操作数据栏、预操作数据关联的预操作数据从属栏以及条件数据栏。 Embodiment [0074] of the present invention, the task data fields data table may be pre-constructed data field split into a pre-operation, operation data associated with the pre-pre-operation condition data dependent column and column. 这样,就完成了与当前任务相关的数据的任务部署。 This completes the tasks related to the current deployment of the mission data.

[0075] 本发明实施例中,将与第一任务Tl相关的数据:A1、A2、A3、A4、B1、B2、B3、C1、C2、CS作为归档数据添加到任务数据关系表中,并与第一任务的任务标识Tl进行关联存储;关于如何将数据与任务通过任务标识进行关联为本领域技术人员所公知的技术,在此不再赘述。 A1, A2, A3, A4, B1, B2, B3, C1, C2, CS added to the task table data as archive data, and: embodiment, the Tl data related to the first embodiment of the task [0075] The present invention task identifier stored in association with the first task Tl; how tasks associated with the data known to those skilled in the art by well-known task ID, are not repeated here.

[0076] 步骤102,对提取的历史数据进行编辑并形成归档历史数据; [0076] Step 102, historical data, and editing the extracted history data archiving is formed;

[0077] 本步骤中,在对提取的历史数据添加到任务数据关系表中之后,可以在待编辑任务的编辑时间段内,对任务数据关系表中与为待编辑任务设置的任务标识对应的预操作数据进行更新维护;同时,根据预操作数据的改变更新预操作从属数据。 [0077] In this step, after the historical data of the extracted data is added to the task table can be edited in the edit time period task, the task of the task with the data table to be identified as corresponding to the set editing tasks pre-updated data maintenance operations; Meanwhile, according to the pre-change data updating operation dependent pre-operation data. 这样,任务数据关系表中与为待编辑任务设置的任务标识对应的已完成更新维护的预操作数据、预操作从属数据,以及条件数据构成归档历史数据。 Thus, the task with the data table to be edited is the task ID corresponding to the set task has been updated to maintain the pre-operation data, data pre-slave operation, and the condition data constituting the archive of historical data.

[0078] 本发明实施例中,如前所述,在第一任务Tl的起始时间2013年8月I日至终止时间2013年8月5日之内,可以对归档数据中的预操作数据Al、A3及B2进行更新维护,相应地,预操作从属数据C1、C2、C3将根据预操作数据A1、A3、B2的变化而作出相应的更新。 [0078] embodiment, the previously described embodiment of the present invention, in a start time of the first task Tl I August 2013 to the end time of August 5, 2013, the operating data archived data pre al, A3 and B2 are updated maintenance, accordingly, the pre-operational slave data C1, C2, C3 will make corresponding updates the operation data according to the pre-change A1, A3, B2 of. 假设,当第一任务Tl终止时,预操作数据Al、B2更新为数据Al '、B2';数据A3被删除,相应地,预操作从属数据Cl、C2、C3更新为数据Cl '、C2 '。 Suppose, when the first task terminates Tl, the pre-operation data Al, B2 updated data Al ', B2'; data A3 is deleted, and accordingly, the pre-operation of the slave data Cl, C2, C3 as a data update Cl ', C2' . 这样,已完成更新维护的数据Al ; , B2 ;,数据Cl ^ , C2 ;,以及条件数据A2、A4、B1、B3构成与任务标识Tl对应的归档历史数据。 Thus, the data has been updated to maintain Al;, B2;, data Cl ^, C2;, and condition data A2, A4, B1, B3 constituting the task identifier corresponding to Tl archive historical data.

[0079] 实际应用中,当该任务内需要更新维护处理的数据量较大时,在处理数据间的逻辑关系时就会耗费一定的时间,因此,为了保证主进程的顺利进行,将打开一个异步进程处理该数据更新事务;数据更新处理完成后将回写一个完成状态,以便通知主进程数据处理完成,并将处理结果反馈至任务数据关系表中;如果中途出现异常,则回写一个异常状态,以便通知主进程进行其他相关处理。 [0079] In practice, when the task requires the update processing of a large amount of data to maintain, during the processing logic relationship between data takes a certain time will, therefore, in order to ensure smooth progress of the main process will open a asynchronous process data updating process the transaction; the data updating process is completed after a complete write-back state, in order to inform the main process of data processing is completed, and the results fed back to the task data in a relational table; if she is abnormal, then a write back abnormal state, in order to inform the main process perform other related processing. 当该任务需要更新维护处理的数据量较小时,则可以采用同步处理机制,直接在任务数据关系表中同步更新处理结果。 When the task needs to be updated when a small amount of data processing maintenance, the synchronization mechanism can be used directly on the task synchronization update process data in a relational table.

[0080] 步骤103,为归档历史数据设置任务标识,并将设置有任务标识的归档历史数据存储到预先设置的任务归档历史数据库中。 [0080] Step 103, the data archive historical task ID is provided, and is provided with stored historical data archive task ID of the task to the preset historical database archive.

[0081] 本步骤中,为由任务数据关系表中已完成更新维护的预操作数据、根据预操作数据的改变而作出相应更新的预操作从属数据,以及条件数据构成的归档历史数据设置任务标识,该任务标识与为当前待编辑任务设置的任务标识相同,并将设置了任务标识的归档历史数据作为任务历史数据存储到预先设置的任务归档历史数据库中。 [0081] In this step, the data table by the task has been completed in the pre-updated data maintenance operations, made archive of historical data set corresponding task identification pre-update data dependent operation, and according to a change condition data pre-operation configuration data the task identifies the current task ID to be set to the same editing tasks, and set the task of archiving historical data identified as the task history data stored in the job archive preset historical database.

[0082] 本发明实施例中,如前所述,当第一任务Tl终止时,预操作数据A1、B2更新为数据Al'、B2';数据A3被删除,相应地,预操作从属数据C1、C2、C3更新为数据Cl '、C2 ',则将任务数据关系表中已完成更新维护的预操作数据Al '、B2',预操作从属数据Cl'、C2丨以及条件数据A2、A4、B1、B3作为归档历史数据存储到任务归档历史数据库中,并以任务标识Tl作为该归档历史数据的索引信息。 Embodiment, the previously described embodiments [0082] of the present invention, when the first task terminates Tl, the pre-operation data A1, B2 updated data Al ', B2'; data A3 is deleted, and accordingly, the pre-operation of the slave data C1 , C2, C3 as a data update Cl ', C2', the task will be completed in the data table updating and maintenance of pre-operation data Al ', B2', the pre-operation data dependent Cl ', C2 Shu and condition data A2, A4, B1, B3 storage as an archive of historical data to the archive task history database, and to identify the task Tl as the index information for the archive historical data. 这样,就可将任务历史数据与整体数据进行分离。 In this way, it is possible to separate the tasks of historical data and the overall data. 当用户需获取某一时间段的任务历史数据时,只需根据任务标识即可获取完整的与任务相关的任务历史数据,包括经过更新维护的预操作数据、预操作从属数据以及条件数据。 When a user needs to get task history data for a period of time, just to get the full task of historical data associated with the task according to the task identity, including maintenance of updated data pre-operation, pre-operation dependent data and condition data.

[0083] 可替换地,本发明实施例中,在对提取的历史数据进行编辑之后,可以为已完成编辑的历史数据分别建立预操作数据备份表、预操作从属数据备份表及条件数据备份表; [0083] Alternatively, embodiments of the present invention, after the edit history data extracted may be established pre-operation data backup table are the historical data is finished editing, the pre-operation dependent data backup sheet and the condition data backup table ;

[0084] 其中,预操作数据备份表用于存储已编辑的历史数据中的预操作数据,并设置有与当前待编辑任务相应的任务标识; [0084] wherein the pre-pre-operation data operation history data table for storing backup data in the editing, and is provided with the current task to be edited corresponding task identifier;

[0085] 预操作从属数据备份表用于存储已编辑的历史数据中的预操作从属数据,并设置有与当前待编辑任务相应的任务标识; [0085] Pre-operation pre-history data dependent operation dependent data table for storing backup data in the editing, and is provided with the respective current editing task to be the task identifier;

[0086] 条件数据备份表用于存储已编辑的历史数据中的条件数据,并设置有与当前待编辑任务相应的任务标识。 [0086] Conditions for data backup condition data table storing historical data is edited, and is provided with the respective current editing task to be the task identifier.

[0087] 进一步地,将预操作数据备份表、从属数据备份表以及条件数据备份表存储到任务归档历史数据库中;其中,设置有相同任务标识的所述预操作数据备份表、所述从属数据备份表及所述条件数据备份表中分别存储的预操作数据、预操作从属数据以及条件数据的综合即为与任务标识对应的归档历史数据。 [0087] Further, the pre-backup operation data table, and the table data backup dependent condition data table stored in the job archive backup history database; wherein the pre-operation data is provided with the same task backup table identifier, said slave data pre-table data backup operation and the condition data stored in the backup table, respectively, pre-operation history data archive that is integrated with the dependent task ID and data corresponding to the condition data. 这样,在查询与任务相关的历史数据并获取准确完整的数据的同时,可以充分了解任务历史数据中的更新的预操作数据和未更新的条件数据,以及与更新的数据相关联的预操作从属数据,便于在获取任务历史数据之后与其他任务历史数据或当前数据的对比分析。 Thus, in the query historical data associated with the task and get accurate and complete data at the same time, we can fully understand the dependent task history data is updated pre-operating data and condition data is not updated, as well as pre and updated data associated with operation data for analysis and other tasks historical data or current comparison data after the data acquisition task history.

[0088] 本发明实施例中,在为归档历史数据设置任务标识,并存储到预先设置的任务归档历史数据库中之后,该方法还可以进一步包括: [0088] The embodiments of the present invention, after setting history data archive task ID, and stored in the job archive preset historical database, the method may further comprise:

[0089] 接收以任务标识表示的任务历史数据查询请求,并根据接收的任务标识从任务归档历史数据库中筛选出与任务标识对应的归档历史数据。 [0089] Historical data query request receiving task to the task identifier indicated, and archiving historical data archiving and screened to identify the corresponding task from the task history database according to the received task ID.

[0090] 实际应用中,针对不同时间段执行的不同任务,都可以采用上述方法对与任务相关的数据进行更新维护,并形成与为待编辑任务设置的任务标识对应的任务历史数据。 [0090] In practice, for different tasks performed in different time periods, the data can be associated with the maintenance tasks are updated by the above method, and forming a task identifier for a task to be historical data corresponding to the set editing tasks. 这样,当接收到用户的任务历史数据请求时,可以首先从任务表中筛选出与任务历史数据查询请求对应的任务标识及编辑时间段;然后,根据任务标识,从任务归档历史数据库中筛选出与任务标识对应的归档历史数据,包括预操作数据、预操作从属数据以及条件数据,从而获取与任务历史数据查询请求对应的详细完整的真实的任务历史数据。 Thus, when receiving the user's task history data requests may be first screened task ID and the editing time period that the task history data query corresponding to the request from the task table; then, according to the task identifier, selected from the task archives history database archive historical data and identify the corresponding tasks, including the pre-operational data, pre-operating condition dependent data and data in order to gain real task of historical data and historical data query request detailed tasks corresponding to the full. [0091] 由上可见,本发明实施例提供的历史数据归档方法,通过将预先存储的整体数据中与待编辑任务相匹配的所有历史数据部署给该待编辑任务,并对与该待编辑任务相匹配的历史数据进行更新维护,形成归档历史数据,对归档历史数据设置任务标识,并作为任务历史数据存储到任务归档历史数据库中,这样,就实现了整体数据与任务历史数据的分离。 [0091] As seen above, the historical data archiving method according to an embodiment of the present invention, all the historical data by deploying the entire data stored in advance in the editing tasks to be matched to the task to be edited, and the task to be edited historical data matches the update maintenance, archiving historical data form, set the task of archiving historical data to identify, and as a task of historical data stored in the job archive history database, so that you achieve the separation of data and the overall mission of historical data. 而在需要查询或获取某一历史时间段内满足任务需求并与任务相关的任务历史数据时,可以通过任务标识,从任务归档历史数据库中直接筛选出与该任务对应的任务历史数据,而无需访问整体历史数据库,访问速度快。 And when needed to meet mission requirements in the inquiry or obtain a certain historical period and historical data tasks associated with the task, the task can be identified from the task history archive database directly selected task history data corresponding to the task, without the whole history database access, access speed.

[0092] 图2为本发明实施例历史数据归档装置结构示意图。 [0092] FIG. 2 is a schematic configuration example of history data filing apparatus embodiment of the present invention. 如图2所示,该装置包括:任务数据管理模块21、归档数据更新模块22、任务历史数据存储模块23 ;其中, As shown, the apparatus 2 comprises: a data management task module 21, update module 22 archive data, job history data storage means 23; wherein,

[0093] 任务数据管理模块21,用于从采集并存储的包含了与各待编辑任务相关数据的整体历史数据库中,提取与待编辑任务相匹配的历史数据; [0093] The task data management module 21, a database containing historical data of the whole of each task to be edited from the collected and stored, historical data to be extracted matches editing tasks;

[0094] 本发明实施例中,从整体历史数据库中筛选出的与当前待编辑任务相匹配的历史数据,包括预操作数据、与预操作数据关联的预操作从属数据、条件数据;其中, [0094] The embodiments of the present invention, selected from the entire history data and the current history database to be edited to match the task, including a pre-operation data, operation data pre-operating with the pre-dependent data, data associated with the condition; wherein,

[0095] 预操作数据为当前待编辑任务所需进行更新维护操作的数据; [0095] The pre-operating data for the current task to be edited to update data required for a maintenance operation;

[0096] 预操作从属数据为与待编辑任务相关,且随预操作数据的改变而变化的数据; [0096] Pre-dependent data operations associated with the task to be edited, and change with the data pre-operation data varies;

[0097] 条件数据为与当前待编辑任务相关,但无需进行更新的数据。 [0097] condition data associated with the current task to be edited, but without the need for data updates.

[0098] 本发明实施例中,任务数据管理模块21进一步用于为待编辑任务设置任务标识及任务编辑时间段;构建包含任务标识栏、预操作数据栏、预操作从属数据栏以及条件数据栏的任务数据关系表; Embodiment [0098] of the present invention, the task data management module 21 is further used to set the task to be edited editing task ID and the task period; construct contains the task identification field, data field pre-operation, the pre-operation condition data dependent field, and data field the task data table;

[0099] 将为待编辑任务设置的任务标识写入任务数据关系表中的任务标识栏,并根据待编辑任务、任务标识以及与待编辑任务相匹配的历史数据之间的对应关系,将所述提取的历史数据写入任务数据关系表中的相应栏。 Task ID [0099] will be written into the task of editing task settings tab in the task table data, and the correspondence between the task to be edited, task identity and history data editing tasks to be matched, The historical data written in the corresponding column of said extracts task data in a relational table. 本发明实施例中,可以构建任务表,并在构建的任务表中添加与当前任务对应的任务标识、起始时间及终止时间,或将起始时间及终止时间以任务编辑时间段的方式添加到任务表中。 Embodiments of the present invention, the task table can be constructed, and added to the task table built in, or added to the task corresponding to the task ID, start time and end time start time and an end time period manner task editor to the task table.

[0100] 本发明实施例中,构建的任务表中包括任务标识栏、任务编辑时间段栏,用于存储与各项待编辑任务对应的任务标识以及任务编辑时间段。 [0100] embodiment of the present invention, the task table is included in the task of constructing identification field, the task editing field period, for storing tasks to be edited with the corresponding task ID and the task editing period. 这样,通过记录所执行的任务,可以便于后续用户通过任务标识或编辑时间段来查询以及获取与执行的待编辑任务相关的任务历史数据。 Thus, by recording the task performed, it may facilitate a subsequent user to query and obtain the historical data associated with the task to be performed by editing tasks or editing task identification period.

[0101] 归档数据更新模块22,用于对由所述任务数据管理模块提取的历史数据进行编辑并形成归档历史数据; [0101] archive data updating module 22, configured to historical task data extracted by the data management module and form editing history data archive;

[0102] 本发明实施例中,在对提取的历史数据添加到任务数据关系表中之后,可以在待编辑任务的编辑时间段内,对任务数据关系表中与为待编辑任务设置的任务标识对应的预操作数据进行更新维护;同时,根据预操作数据的改变更新预操作从属数据。 [0102] In embodiments of the present invention, after the historical data of the extracted data is added to the task table can be edited in the edit time period task, the task of the data table to be edited with the task identifier of the task set corresponding to the pre-operation data is updated maintenance; Meanwhile, according to the pre-change data updating operation dependent pre-operation data. 这样,任务数据关系表中与为待编辑任务设置的任务标识对应的已完成更新维护的预操作数据、预操作从属数据,以及条件数据构成归档历史数据。 Thus, the task with the data table to be edited is the task ID corresponding to the set task has been updated to maintain the pre-operation data, data pre-slave operation, and the condition data constituting the archive of historical data.

[0103] 实际应用中,当该任务内需要更新维护处理的数据量较大时,在处理数据间的逻辑关系时就会耗费一定的时间,因此,为了保证主进程的顺利进行,将打开一个异步进程处理该数据更新事务;数据更新处理完成后将回写一个完成状态,以便通知主进程数据处理完成,并将处理结果反馈至任务数据关系表中;如果中途出现异常,则回写一个异常状态,以便通知主进程进行其他相关处理。 [0103] In practice, when the task requires the update processing of a large amount of data to maintain, during the processing logic relationship between data takes a certain time will, therefore, in order to ensure smooth progress of the main process will open a asynchronous process data updating process the transaction; the data updating process is completed after a complete write-back state, in order to inform the main process of data processing is completed, and the results fed back to the task data in a relational table; if she is abnormal, then a write back abnormal state, in order to inform the main process perform other related processing. 当该任务需要更新维护处理的数据量较小时,则可以采用同步处理机制,直接在任务数据关系表中同步更新处理结果。 When the task needs to be updated when a small amount of data processing maintenance, the synchronization mechanism can be used directly on the task synchronization update process data in a relational table.

[0104] 任务历史数据存储模块23,用于为由所述归档数据更新模块形成的归档历史数据设置任务标识,并将设置有任务标识的归档历史数据存储到预先设置的任务归档历史数据库中。 [0104] task history data storage means 23, for archiving historical data provided by said task identification archival data update module is formed, and is provided with a history data storage archive task ID of the task to the preset historical database archive.

[0105] 本发明实施例中,为由任务数据关系表中已完成更新维护的预操作数据、根据预操作数据的改变而作出相应更新的预操作从属数据,以及条件数据构成的归档历史数据设置任务标识,该任务标识与为当前待编辑任务设置的任务标识相同,并将设置了任务标识的归档历史数据作为任务历史数据存储到预先设置的任务归档历史数据库中。 Embodiment [0105] In the present invention, the data table by the task has been completed in the pre-data updating operation maintained, updated accordingly made dependent pre-operating data, historical data archiving and disposed according to a change condition data pre-operation configuration data task ID, which identifies the tasks for the current task ID to be set to the same editing tasks, and set the task of archiving historical data identified as the task history data stored in the job archive preset historical database.

[0106] 可替换地,本发明实施例中,任务历史数据存储模块23还可以为已完成更新维护的预操作数据、预操作从属数据以及条件数据分别建立预操作数据备份表、从属数据备份表及条件数据备份表,将预操作数据备份表、从属数据备份表以及条件数据数据备份表存储到任务归档历史数据库中;其中,设置有相同任务标识的所述预操作数据备份表、所述从属数据备份表及所述条件数据备份表中分别存储的预操作数据、预操作从属数据以及条件数据的综合即为与任务标识对应的归档历史数据。 [0106] Alternatively, embodiments of the invention, the task history data storage means 23 may also be pre-operation have been updated data maintenance, pre-operation data and the condition data dependent operation data backup table pre-established respectively, slave data backup table and the condition data backup table, the pre-table operation data backup, the backup slave data table and the condition data table stored in the job archive backup history database; wherein the pre-operation data is provided with the same task backup table identifier, the slave pre-table operation data backup and backup said condition data stored in the table, respectively, pre-operation history data archive that is integrated with the dependent task ID and data corresponding to the condition data. 这样,可以根据任务标识获取任务历史数据中的更新的预操作数据和未更新的条件数据,以及与更新的数据相关联的预操作从属数据,便于在获取任务历史数据之后与其他任务历史数据或当前数据的对比分析。 In this way, may be obtained according to the task to identify the task history data updated pre-operation data and the condition data is not updated, and a pre-operation of the slave data with updated data associated facilitate historical data with other tasks after acquiring the task history data or Comparative analysis of the current data.

[0107] 实际应用中,针对不同时间段执行的不同任务,都可以采用上述装置对与任务相关的数据进行更新维护,并形成与任务的任务标识对应的任务历史数据。 [0107] In practice, for different tasks performed in different time periods, the data can be associated with a task update and maintain the above-described apparatus, and forming job history data to a task corresponding to the task ID. 这样,当接收到用户的任务历史数据请求时,可以从构建的任务表中筛选出与任务历史数据请求对应的任务标识;根据任务标识,从任务归档历史数据库中调取与任务标识对应的任务历史数据,包括预操作数据备份表、从属数据备份表以及条件数据备份表中各自存储的数据,从而获取与查询请求对应的详细完整的真实的任务历史数据。 Thus, when receiving the user's task history data request, may be screened from the task table built in the task ID and the task history data corresponding to the request; according to the task identifier, the transfer of the task ID corresponding to the job archive history database tasks historical data, including the pre-table operation data backup, the backup table and the condition data dependent backup data stored in each table, so as to obtain a complete detailed task history of the real data corresponding to the query request.

[0108] 进一步地,本发明实施例中,在为归档历史数据设置任务标识,并存储到预先设置的任务归档历史数据库中之后,该装置还可以包括:数据请求查询模块,用于接收以任务标识表示的任务历史数据查询请求,并根据接收的任务标识从由任务历史数据存储模块23存储任务归档历史数据库中筛选出与任务标识对应的归档历史数据。 [0108] Further, embodiments of the present invention, after setting history data archive task ID, and stored in the job archive preset historical database, the apparatus may further comprise: a data request query module, for receiving a task task history data query request identifier indicated, and screened for the task identifier from the archive received by the task history database history data storage means 23 stores the archive historical task data corresponding to the task ID.

[0109] 由上可见,本发明实施例提供的历史数据归档装置,通过任务数据管理模块21将整体历史数据中与待编辑任务相匹配的所有历史数据部署给该待编辑任务,并通过归档数据更新模块22对与该任务相匹配的历史数据进行更新维护形成归档历史数据,对归档历史数据设置任务标识,并作为任务历史数据存储到任务历史数据存储模块23中,这样,实现了整体历史数据与任务历史数据的分离。 [0109] As seen above, the historical data filing apparatus according to an embodiment of the present invention, the task data management module 21 to deploy all historical data whole history data to be editing tasks matched to the pending editing tasks, and by archiving data update module 22 for historical data associated with the task that matches the whole history data update maintenance form archive historical data, archiving historical data provided task identifier, and a task history data stored in the job history data storage means 23 in this way, a and separating the task of historical data. 当需要查询或获取某一历史时间段内满足任务需求并与任务相关的任务历史数据时,可以通过任务标识,从任务历史数据存储模块23中直接筛选出与该任务对应的任务历史数据。 When you need to query or obtain a certain historical period of time to meet the mission requirements and job history data associated with the task, the task can be identified from the task history data storage means 23 directly selected task history data corresponding to the task.

[0110] 显然,本领域技术人员可以对本发明进行各种改动和变型而不脱离本发明的精神和范围。 [0110] Obviously, those skilled in the art can make various modifications and variations to the invention without departing from the spirit and scope of the invention. 这样,倘若对本发明的这些修改和变型属于本发明权利要求及其等同技术的范围之内,则本发明也包含这些改动和变型在内。 Thus, if part of the claimed invention for such modifications and variations within the scope of the present invention and equivalents thereof, the present invention also include these modifications and variations.

Claims (10)

1.一种历史数据归档方法,该方法包括: 从采集并存储的包含了与各任务相关数据的整体历史数据库中,提取与待编辑任务相匹配的历史数据; 对提取的历史数据进行编辑并形成归档历史数据; 为归档历史数据设置任务标识,并将设置有任务标识的归档历史数据存储到预先设置的任务归档历史数据库中。 An archive of historical data, the method comprising: containing the collected and stored from the whole historical database associated with each task data, history data to be extracted matches editing tasks; historical data and editing the extracted forming archive historical data; archive historical data set task ID, and is provided with stored historical data archive task ID of the task to the preset historical database archive.
2.根据权利要求1所述的方法,其中,所述提取的历史数据包括:预操作数据、与所述预操作数据关联的预操作从属数据、条件数据;其中, 所述预操作数据为当前待编辑任务所需进行更新维护操作的数据; 所述预操作从属数据为与当前待编辑任务相关,且随所述预操作数据的改变而变化的数据; 所述条件数据为与当前待编辑任务相关,但无需进行更新的数据。 The method according to claim 1, wherein the extraction history data comprising: a pre-operation data, data pre-slave operation with the associated pre-operation data, condition data; wherein, the pre-operating data for the current editing tasks are necessary for data updating to be a maintenance operation; pre-operation of the slave data relating to the current task to be edited, and data with the pre-change operation varies transactions; the condition data with the current task to be edited related, but without the need for data updates.
3.根据权利要求2所述的方法,其中,在所述提取与待编辑任务相匹配的历史数据之前,同时或之后,所述方法进一步包括: 为待编辑任务设置任务标识及任务编辑时间段; 构建包含任务标识栏、预操作数据栏、与预操作数据关联的预操作从属数据栏以及条件数据栏的任务数据关系表; 在所述对提取的历史数据进行编辑形成归档历史数据之前,所述方法进一步包括:将所述为待编辑任务设置的任务标识写入任务数据关系表中的任务标识栏,并根据待编辑任务、任务标识以及与待编辑任务的相匹配历史数据之间的对应关系,将所述提取的历史数据写入任务数据关系表中的相应栏。 3. The method according to claim 2, wherein, prior to the extraction task to be edited to match the historical data, after or simultaneously, said method further comprising: editing task to be disposed task ID and the task editor period ; construct comprising a task ID column, task data table column pre-operating data, data associated with the operation of the pre-pre-operation condition data dependent data field, and bar; formed before editing history archive historical data in the extracted data, the said method further comprising: identifying the write task bar task data in the task table identification task settings to be edited, and the match between the corresponding history data to be edited in accordance with the task, and a task identification task to be edited relations, historical data extracted from the data written in the corresponding column task relationship table.
4.根据权利要求3所述的方法,其中,所述对提取的历史数据进行编辑并形成归档历史数据,具体为, 在待编辑任务的编辑时间段内,对任务历史数据表中与为待编辑任务设置的任务标识对应的预操作数据进行更新维护; 根据预操作数据的改变更新预操作从属数据。 4. The method according to claim 3, wherein, for the editing of the extracted data and historical archive of historical data is formed, in particular, in the time period to be edited editing tasks, task and historical data table is to be editing task ID corresponding to the job pre-operation setting data update maintenance; pre-update data dependent operations in accordance with the pre-change operation data.
5.根据权利要求4所述的方法,其中,所述归档历史数据包括:任务数据关系表中已完成更新维护的预操作数据、根据预操作数据的改变而作出相应更新的预操作从属数据,以及条件数据。 The method according to claim 4, wherein said historical data archive comprising: task data relation table has been updated to the pre-operation data maintenance, and operation of the slave data corresponding to the pre-updated data according to a change in the pre-operation, and condition data.
6.根据权利要求4所述的方法,其中,在所述对提取的历史数据进行编辑并形成归档历史数据之后,该方法包括: 为已编辑的历史数据分别建立预操作数据备份表、预操作从属数据备份表及条件数据备份表;其中, 所述预操作数据备份表用于存储已编辑的历史数据中的预操作数据,并设置有与当前待编辑任务相应的任务标识; 所述预操作从属数据备份表用于存储已编辑的历史数据中的预操作从属数据,并设置有与当前待编辑任务相应的任务标识; 所述条件数据备份表用于存储已编辑的历史数据中的条件数据,并设置有与当前待编辑任务相应的任务标识。 6. The method according to claim 4, wherein, after the edit history data and the extracted history data archiving is formed, the method comprising: establishing a pre-table operation data backup of historical data are edited, pre-operation data backup slave condition data table and the backup table; wherein the pre-pre-operation data operation history data table for storing backup data in the editing, and is provided with the respective current editing task to be the task identifier; the pre-operation data backup table for pre-slave operation history data stored in the slave data is edited, and is provided with the respective current editing task to be the task identifier; the condition data the condition data backup table for storing historical data is edited and to be provided with current editing tasks corresponding task ID. 进一步地,将所述预操作数据备份表、所述从属数据备份表及所述条件数据备份表存储到预先设置的任务归档历史数据库中。 Furthermore, the pre-table operation data backup, the backup slave data and the condition data table backup table stored in the job archive preset historical database.
7.根据权利要求5所述的方法,其中,在所述为归档历史数据设置任务标识,并将设置有任务标识的归档历史数据存储到预先设置的任务归档历史数据库中之后,该方法进一步包括: 接收以任务标识表示的任务历史数据查询请求,并根据接收的任务标识从任务归档历史数据库中筛选出与任务标识对应的归档历史数据。 7. The method according to claim 5, wherein, in the setting history data archive task identifier, and set an archive of historical data stored task identifier of the task to the archive after a preset historical database, the method further comprising : receive task history data query request to the task identifier indicated, historical data archiving and archived in the historical database with the selected task ID from the task according to the task corresponding to the received identifier.
8.一种历史数据归档装置,其特征在于,该装置包括:任务数据管理模块、归档数据更新模块、任务历史数据存储模块;其特征在于, 所述任务数据管理模块,用于从采集并存储的包含了与各待编辑任务相关数据的整体历史数据库中,提取与待编辑任务相匹配的历史数据; 所述归档数据更新模块,用于对由所述任务数据管理模块提取的历史数据进行编辑并形成归档历史数据; 所述任务历史数据存储模块,用于为由所述归档数据更新模块形成的归档历史数据设置任务标识,并将设置有任务标识的归档历史数据存储到预先设置的任务归档历史数据库中。 A historical data filing apparatus, wherein, the apparatus comprising: task data management module, the archive data update module, the task history data storage means; wherein the task data management module for collecting and storing from the whole history database contains data related to the respective tasks to be edited, job history data to be extracted matches editing; the archival data updating means for editing the data extracted by the history data management module task and forming a historical data archive; the job history data storage means for archiving historical data provided by said task identification archival data update module is formed, and is provided with a history data storage archive task ID of the task to the preset archive history database.
9.根据权利要求8所述的装置,其特征在于,所述提取的历史数据包括:预操作数据、与所述预操作数据关联的预操作从属数据,以及条件数据;其中, 所述预操作数据为当前待编辑任务所需进行更新维护操作的数据; 所述预操作从属数据为与当前待编辑任务相关,且随所述预操作数据的改变而变化的数据; 所述条件数据为与当前待编辑任务相关,但无需进行更新的数据。 9. The apparatus according to claim 8, wherein the extraction history data comprising: a pre-operation data, data pre-slave operation with the data associated with the pre-operation, and the condition data; wherein, the pre-operation data maintenance operations required to update the data to be currently editing tasks; pre-operation of the slave data relating to the current task to be edited, and change with the pre-operation data varies transactions; the condition data with the current editing tasks to be relevant, but without the need for data updates.
10.根据权利要求9所述的装置,其特征在于,所述任务数据管理模块进一步用于为待编辑任务设置任务标识及任务编辑时间段;构建包含任务标识栏、预操作数据栏、预操作从属数据栏以及条件数据栏的任务数据关系表; 将为待编辑任务设置的任务标识写入任务数据关系表中的任务标识栏,并根据待编辑任务、任务标识以及与待编辑任务相匹配的历史数据之间的对应关系,将所述提取的历史数据写入任务数据关系表中的相应栏。 10. The apparatus according to claim 9, wherein the task data management module is further used to set the task to be edited editing task ID and the task period; construct contains the task identification field, data field pre-operation, the pre-operation task condition data dependent field, and data field of a data table; task ID for the task to be edited settings tab task data writing task relation table, and in accordance with the task to be edited, and a task identity matches the task to be edited correspondence between the historical data, historical data written in the corresponding field of the extracted tasks in the data table.
CN 201310471385 2013-10-10 2013-10-10 Historical data archiving methods and historical data archiving device CN103514295B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201310471385 CN103514295B (en) 2013-10-10 2013-10-10 Historical data archiving methods and historical data archiving device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201310471385 CN103514295B (en) 2013-10-10 2013-10-10 Historical data archiving methods and historical data archiving device

Publications (2)

Publication Number Publication Date
CN103514295A true true CN103514295A (en) 2014-01-15
CN103514295B CN103514295B (en) 2016-09-28

Family

ID=49897019

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201310471385 CN103514295B (en) 2013-10-10 2013-10-10 Historical data archiving methods and historical data archiving device

Country Status (1)

Country Link
CN (1) CN103514295B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104052804A (en) * 2014-06-09 2014-09-17 深圳先进技术研究院 Method, device and cluster for sharing data streams between different task topologies

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070112801A1 (en) * 2005-11-14 2007-05-17 Rockwell Automation Technologies, Inc. Distributed historian architecture
CN101364897A (en) * 2008-09-17 2009-02-11 中兴通讯股份有限公司 System for historical data archiving and implementing method
CN101639839A (en) * 2008-07-30 2010-02-03 中兴通讯股份有限公司 Method for searching multi-archive file based on temporary table
CN103106247A (en) * 2012-12-31 2013-05-15 普天新能源有限责任公司 Data dump method and system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070112801A1 (en) * 2005-11-14 2007-05-17 Rockwell Automation Technologies, Inc. Distributed historian architecture
CN101639839A (en) * 2008-07-30 2010-02-03 中兴通讯股份有限公司 Method for searching multi-archive file based on temporary table
CN101364897A (en) * 2008-09-17 2009-02-11 中兴通讯股份有限公司 System for historical data archiving and implementing method
CN103106247A (en) * 2012-12-31 2013-05-15 普天新能源有限责任公司 Data dump method and system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
张岩: "数据仓库历史数据归档与重构的策略研究", 《中国优秀硕士学位论文全文数据库 信息科技辑》, 31 August 2005 (2005-08-31), pages 138 - 402 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104052804A (en) * 2014-06-09 2014-09-17 深圳先进技术研究院 Method, device and cluster for sharing data streams between different task topologies

Also Published As

Publication number Publication date Type
CN103514295B (en) 2016-09-28 grant

Similar Documents

Publication Publication Date Title
Vora Hadoop-HBase for large-scale data
US7761412B2 (en) Synchronization move support systems and methods
CN101436207A (en) Data restoring and synchronizing method based on log snapshot
CN102594849A (en) Data backup and recovery method and device, virtual machine snapshot deleting and rollback method and device
US20090083336A1 (en) Search based data management
US20130275369A1 (en) Data record collapse and split functionality
US20120151245A1 (en) In-flight block map for a clustered redirect-on-write filesystem
CN101739453A (en) Method and device for carrying out condition query on database table
US20090187882A1 (en) Live bidirectional synchronizing of a visual and a textual representation
US20120290547A1 (en) Transaction processing device, transaction processing method, and transaction processing program
CN102110121A (en) Method and system for processing data
CN102346775A (en) Method for synchronizing multiple heterogeneous source databases based on log
CN102243660A (en) Data access method and device
US20130198139A1 (en) Durability implementation plan in an in-memory database system
US20120150804A1 (en) Multiple contexts in a redirect on write file system
CN102110146A (en) Key-value storage-based distributed file system metadata management method
US20100114848A1 (en) Atomic mulitple modification of data in a distributed storage system
CN103257973A (en) Method and system for updating browser cache
US20090319540A1 (en) Synchronization adapter for synchronizing data to applications that do not directly support synchronization
US20130097117A1 (en) Application of a differential dataset to a data store using sequential change sets
US8712966B1 (en) Backup and recovery of distributed storage areas
CN101246500A (en) Retrieval system and method for implementing data fast indexing
CN101136825A (en) Asynchronous configuration information management method and system for client terminal/server structure
JP2002318717A (en) Database system
CN103020204A (en) Method and system for carrying out multi-dimensional regional inquiry on distribution type sequence table

Legal Events

Date Code Title Description
C06 Publication
C10 Entry into substantive examination
C14 Grant of patent or utility model