CN106909553A - A kind of data validity determines method and device - Google Patents

A kind of data validity determines method and device Download PDF

Info

Publication number
CN106909553A
CN106909553A CN201510974844.0A CN201510974844A CN106909553A CN 106909553 A CN106909553 A CN 106909553A CN 201510974844 A CN201510974844 A CN 201510974844A CN 106909553 A CN106909553 A CN 106909553A
Authority
CN
China
Prior art keywords
predetermined amount
primary sources
time
data
value
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
CN201510974844.0A
Other languages
Chinese (zh)
Other versions
CN106909553B (en
Inventor
朱春茂
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Advanced Nova Technology Singapore Holdings Ltd
Original Assignee
Alibaba Group Holding Ltd
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
Application filed by Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201510974844.0A priority Critical patent/CN106909553B/en
Publication of CN106909553A publication Critical patent/CN106909553A/en
Application granted granted Critical
Publication of CN106909553B publication Critical patent/CN106909553B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/21Design, administration or maintenance of databases
    • G06F16/219Managing data history or versioning

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)
  • Retry When Errors Occur (AREA)

Abstract

Determine method and device this application provides a kind of data validity, including:State change according to primary sources in first, second predetermined amount of time in system determines the numerical value of first, second predetermined amount of time end primary sources respectively;The total value that numerical value and the first predetermined amount of time end system according to first predetermined amount of time end primary sources are stored determines the first difference value, and the total value that the numerical value and the second predetermined amount of time end system according to second predetermined amount of time end primary sources are stored determines the second difference value;First difference value is compared with the difference of second difference value with the change value of secondary sources in the second predetermined amount of time;If equal, determine that data are effective;If unequal, data exception is determined.The application need to only calculate the numerical value of primary sources according to state change, the numerical value without calculating secondary sources, in primary sources and secondary sources and in the case of depositing, can fast and effectively complete Data Detection.

Description

A kind of data validity determines method and device
Technical field
The application is related to technical field of data processing, more particularly to a kind of data validity to determine method and dress Put.
Background technology
In order to ensure that data record is correctly reliable, it usually needs the work for being checked data and being checked.Mesh Before, the determination of data validity be typically by system at the end of the change value of all data and the same day store it is total Numerical value is compared, that is, the change value of the same day all data is first counted, then by the change value of data The total value stored with system at the end of the same day is compared.
However, after system upgrade is regenerated, the form of data, state and pass is associated with other data System often varies widely.After system upgrade, it is understood that there may be the two kinds of simultaneous feelings of data Condition, that is, old data before new data and system upgrade after system upgrade and depositing.Because new data passes through Again design, is in general easier to count change value;And old data due to historical reasons or other because Element, it is very difficult to which statistics cannot count change value at all, and for system, it is total that system is stored Numerical value is only a numeral, can't distinguish new, old data.Therefore, after system upgrade, the structure of data Change is there occurs, causing the data validity determination methods of script cannot fast and effectively verify whether data go out It is now abnormal.
Prior art deficiency is:
The old and new's data and in the case of depositing after system upgrade, prior art cannot fast and effectively determine that data are No exception.
The content of the invention
The embodiment of the present application proposes a kind of data validity and determines method and device, to solve in the prior art The old and new's data and in the case of depositing, it is impossible to fast and effectively determine data whether abnormal technical problem.
The embodiment of the present application determines method there is provided a kind of data validity, comprises the following steps:
State change according to primary sources in the first predetermined amount of time in system determined for first scheduled time The numerical value of the last primary sources of section, according to the state of primary sources in the second predetermined amount of time in system Change determines the numerical value of the second predetermined amount of time end primary sources;Second predetermined amount of time rise Begin the finish time that the moment is first predetermined amount of time;
Numerical value and the first predetermined amount of time end system according to first predetermined amount of time end primary sources The total value of storage determines the first difference value, according to the numerical value of second predetermined amount of time end primary sources The total value stored with the second predetermined amount of time end system determines the second difference value;The sum of the system storage It is worth the numerical value sum of the numerical value and the secondary sources for the primary sources;
By in the difference of first difference value and second difference value and second predetermined amount of time The change value of two class data is compared;If equal, determine that data are effective;If unequal, number is determined According to exception.
The embodiment of the present application provides a kind of data validity determining device, including:
First determining module, for the state change according to primary sources in the first predetermined amount of time in system The numerical value of the first predetermined amount of time end primary sources is determined, according in the second predetermined amount of time in system The state change of primary sources determines the numerical value of the second predetermined amount of time end primary sources;Described The initial time of two predetermined amount of time is the finish time of first predetermined amount of time;
Second determining module, for the numerical value and first according to first predetermined amount of time end primary sources The total value of predetermined amount of time end system storage determines the first difference value, according to second predetermined amount of time end The numerical value of primary sources and the total value of the second predetermined amount of time end system storage determine the second difference value;Institute The total value for stating system storage is the numerical value sum of the numerical value with the secondary sources of the primary sources;
3rd determining module, for by the difference and described of first difference value and second difference value The change value of secondary sources is compared in two predetermined amount of time;If equal, determine that data are effective;Such as It is really unequal, determine data exception.
Have the beneficial effect that:
The data validity that the embodiment of the present application is provided determines method and device, due to only needing to according to system The state change of middle primary sources determines the numerical value of the predetermined amount of time end primary sources, in conjunction with institute State the total value of predetermined amount of time end system storage and can complete data validity and determine to operate, without according to being The state change of secondary sources calculates the numerical value of secondary sources in predetermined amount of time in system, so as to avoid The numerical value of secondary sources is difficult to calculate or imponderable problem at all in the prior art, realizes in the first kind Data and secondary sources and in the case of depositing, fast and effectively determine whether data are abnormal.
Brief description of the drawings
The specific embodiment of the application is described below with reference to accompanying drawings, wherein:
Data validity determines the schematic flow sheet that method is implemented during Fig. 1 shows the embodiment of the present application;
Fig. 2 shows the time shaft schematic diagram of system upgrade in the embodiment of the present application;
Fig. 3 shows that data validity in the prior art determines the schematic diagram of mechanism;
Fig. 4 shows the old and new's data and the schematic diagram deposited after system upgrade;
Fig. 5 shows the structural representation of data validity determining device in the embodiment of the present application.
Specific embodiment
In order that the technical scheme and advantage of the application become more apparent, below in conjunction with accompanying drawing to the application's Exemplary embodiment is described in more detail, it is clear that described embodiment is only the one of the application Section Example, rather than the exhaustion of all embodiments.And in the case where not conflicting, in this explanation Feature in embodiment and embodiment can be combined with each other.
In view of the shortcomings of the prior art, the embodiment of the present application proposes a kind of data validity and determines method and dress Put, the determination of data validity can be completed in a computing system in the case of the numerical value of new data, enter below Row explanation.
Data validity determines the schematic flow sheet that method is implemented during Fig. 1 shows the embodiment of the present application, such as schemes Shown, the data validity determines that method may include steps of:
Step 101, determine first according to the state change of primary sources in the first predetermined amount of time in system The numerical value of the predetermined amount of time end primary sources, according to he first-class numbert in the second predetermined amount of time in system According to state change determine the numerical value of the second predetermined amount of time end primary sources;Described second pre- timing Between section initial time be first predetermined amount of time finish time;
Step 102, the numerical value according to first predetermined amount of time end primary sources and first scheduled time The total value of the last system storage of section determines the first difference value, according to second predetermined amount of time end he first-class numbert According to numerical value and the second predetermined amount of time end system store total value determine the second difference value;The system is deposited The total value of storage is the numerical value sum of the numerical value with the secondary sources of the primary sources;
Step 103, the difference by first difference value with second difference value and the described second pre- timing Between in section the change value of secondary sources be compared;If equal, determine that data are effective;If unequal, Determine data exception.
When the first predetermined amount of time and the second predetermined amount of time can be adjacent two in the embodiment of the present application Between section, two length of time period can be with identical, such as:First predetermined amount of time can be 2012 8 Month 1 day to 2012 on August 31, the second predetermined amount of time can be September in 2012 1 day to 2012 On September 31,;Or, the first predetermined amount of time can be 00:00 to 11:59, the second predetermined amount of time Can be 12:00 to 23:59.In specific implementation, the length of two time periods can also be without together, for example:The One predetermined amount of time can be August in 2012 1 day, and the second predetermined amount of time can be August 2 in 2012 Day to August in 2012 3 days.
In the embodiment of the present application, the numerical value of the first predetermined amount of time end primary sources can be first determined, The numerical value of the second predetermined amount of time end primary sources is determined again;Can also first determine for second scheduled time The numerical value of the end primary sources, then determine the numerical value of the first predetermined amount of time end primary sources; (parallel work-flow) can simultaneously be carried out with the two.Determine two of the second difference value of the first difference value and determination Process is similarly.
In specific implementation, can first according to the state change of primary sources in the first predetermined amount of time in system The numerical value of the first predetermined amount of time end primary sources is determined, then according to first predetermined amount of time The numerical value of last primary sources and the total value of the first predetermined amount of time end system storage determine the first difference value; State change further according to primary sources in the second predetermined amount of time in system determines the second predetermined amount of time The numerical value of the end primary sources, then according to the numerical value of second predetermined amount of time end primary sources The total value stored with the second predetermined amount of time end system determines the second difference value.
State change that can also be first according to primary sources in the second predetermined amount of time in system determines second The numerical value of the predetermined amount of time end primary sources, according to second predetermined amount of time end primary sources Numerical value and the second predetermined amount of time end system storage total value determine the second difference value;Further according in system The state change of primary sources determines the first predetermined amount of time end first kind in first predetermined amount of time The numerical value of data, according to the numerical value and the first predetermined amount of time of first predetermined amount of time end primary sources The total value of last system storage determines the first difference value.
The embodiment of the present application is not restricted for the sequencing of above-mentioned calculating process.
Finally, the embodiment of the present application is by the difference of first difference value and second difference value, and described The change value of secondary sources is compared in second predetermined amount of time, you can complete the inspection of data validity Survey.Wherein, the change value of secondary sources can make a reservation for it for described second in second predetermined amount of time Between section initial time described in secondary sources numerical value and secondary sources described in finish time numerical value it Difference.For example, it is assumed that the second predetermined amount of time is 12:00~24:00,12:Secondary sources described in 00 moment Numerical value is 55,24:The numerical value of secondary sources described in 00 moment is 98, then, this period, section was interior described The change value of secondary sources is 98-55=43.
In specific implementation, although secondary sources (old data) may not meet the data of current system Structure, it is difficult to which the state change according to secondary sources calculates the numerical value of predetermined amount of time end secondary sources, But due to system can identify which be primary sources, which be secondary sources, therefore, statistics the Corresponding change value is to be relatively easy in two class data predetermined amount of time, so that using the two neighboring time period Primary sources numerical value and secondary sources change value complete data validity determination.
In specific implementation, primary sources and secondary sources can carry out area by the property value in tables of data Point, those skilled in the art can also realize that mark is distinguished using other modes, and the application is not limited this System.
The data validity that the embodiment of the present application is provided determines method, according in the first predetermined amount of time first The state change of class data determines the numerical value of the first predetermined amount of time end primary sources, according in system The state change of primary sources determines the second predetermined amount of time end first kind in second predetermined amount of time The numerical value of data, according to the numerical value and the first predetermined amount of time of first predetermined amount of time end primary sources The total value of last system storage determines the first difference value, according to second predetermined amount of time end primary sources Numerical value and the second predetermined amount of time end system storage total value determine the second difference value;Finally, will be described The difference and secondary sources in second predetermined amount of time of the first difference value and second difference value Change value is compared;If equal, determine that data are effective;If unequal, data exception is determined.
In due to the embodiment of the present application, it is only necessary to which the state change according to primary sources in system determines predetermined The numerical value of the time period Mo primary sources, in conjunction with the total value of predetermined amount of time end system storage Data validity can be completed and determine operation, calculate pre- without the state change according to secondary sources in system The numerical value of secondary sources in section of fixing time, so as to the numerical value for avoiding secondary sources in the prior art is difficult to Calculate or imponderable problem at all, realization in primary sources and secondary sources and in the case of depositing, Fast and effectively determine whether data are abnormal.
In view of the promptness requirement that data validity determines, the embodiment of the present application can also be in the following way Implement.
In implementation, first predetermined amount of time can be T-2 days, and second predetermined amount of time can be T-1 days, wherein, T determines the date for data validity.
For example, it is assumed that carrying out data validity determines that date on the same day T of operation is on May 8th, 2013, So, the first predetermined amount of time described in the embodiment of the present application can be on May 6th, 2013, described the Two predetermined amount of time can be on May 7th, 2013.That is, first predetermined amount of time and institute Two days before stating the second predetermined amount of time and can determining the date for data validity.
In specific implementation, data validity determination process can be:
The total value of numerical value and (T-2) day Mo the system storage according to (T-2) the day Mo primary sources, Determine the first difference value;
The total value of numerical value and (T-1) day Mo the system storage according to (T-1) the day Mo primary sources, Determine the second difference value;
Obtain the difference of the first difference value and the first difference value;
By the difference and (T-1) in day the change value of secondary sources be compared.
The technical scheme provided using the embodiment of the present application, it is possible to use before data validity determines the date The total value and the numerical value of primary sources of the system storage of two days, determine that the date is previous with data validity Change value of secondary sources compares in it, realizes determining the purpose of data validity, it is ensured that data validity The promptness of determination.
In implementation, the state change of the primary sources is specifically as follows the trading order form shape of primary sources State changes.
In specific implementation, the state change of the primary sources can be the trading order form shape of primary sources State changes, and the numerical value of predetermined amount of time end primary sources can be primary sources described in predetermined amount of time Remaining sum, the total value of the predetermined amount of time end system storage can be the account balance of predetermined amount of time.
State change in the embodiment of the present application according to primary sources in the first predetermined amount of time in system is true The numerical value of the fixed first predetermined amount of time end primary sources first can make a reservation for according in operation system The change of the trading order form state of primary sources described in the time period (new data) determines the first predetermined amount of time The remaining sum of the primary sources.
The technical scheme that the embodiment of the present application is provided, in can apply to operation system, according to trading order form State change determine the validity of transaction data, it is ensured that the data safety of order transaction.
In implementation, determine in the state change according to primary sources in the first predetermined amount of time in system The numerical value of the first predetermined amount of time end primary sources, according in the second predetermined amount of time in system first Before the state change of class data determines the numerical value of the second predetermined amount of time end primary sources, the side Method may further include:
System records the trading order form state of the primary sources according to trading order form.
In the embodiment of the present application, can when operation system carries out business transaction, according to the order of each transaction, Record the trading order form state of the primary sources.In specific implementation, trading order form state can be with form Form record, for example, a certain Column Properties in tables of data are recorded into trading order form state, can also increase Plus the association attributes such as specific descriptions or explanation, so that the later stage checks.
In the embodiment of the present application in the system directly according to trading order form be can record the he first-class numbert According to trading order form state, without being obtained from other systems, further increase data validity determination effect Rate.
In implementation, the primary sources are the data of generation after the newest upgrading of system, the he second-class number According to the data for being generation before the newest upgrading of system.
It is appreciated that generally, system can with the continuing to develop of business, change and constantly improve, It is perfect, multiple system upgrade may be experienced in this course.The first kind in the embodiment of the present application Data are the data of generation after the newest upgrading of system, and the secondary sources are produced before being the newest upgrading of system Raw data, i.e. how many times upgrading no matter is experienced before the newest upgrading of system, the embodiment of the present application is in the lump Using these data as secondary sources treatment.
Fig. 2 shows the time shaft schematic diagram of system upgrade in the embodiment of the present application, as shown in the figure, it is assumed that On March 1st, 2014 has carried out the upgrading of 1 subsystem, and on March 2nd, 2014 has carried out the upgrading of 2 subsystems, The date that data validity determines is on March 3rd, 2014, then, primary sources are in March, 2014 Produced data after the upgrading of 2nd subsystem on the 2nd, secondary sources are March 2 day in 2014 to be for the 2nd time Data produced by before system upgrading.
In the embodiment of the present application, according to the newest upgrade case of system, all of data in system are divided into One class data and secondary sources, greatly simplifie calculation procedure, reduce answering for data validity determination Miscellaneous degree, such that it is able to ensure fast and effectively to complete Data Detection.
In implementation, trading order form state value, the pass between data form and/or data before and after the system upgrade Connection relation changes.
Generally, trading order form state value may be caused to occur because service logic changes before and after system upgrade Change, for example:Buyer's direct payment, in order to ensure the rights and interests of user, increased to seller before system upgrade Used as internuncial guarantee family, buyer pays guarantee family, by assuring that family pays seller;And for example, with The increase of counterparty occurs in that family of sharing in the benefit, and buyer pays guarantee family, by assure family pay respectively seller and Share in the benefit family.In addition, data form before and after system upgrade, the incidence relation between data and data etc. Etc. changing, for example, there is no redundant data before system upgrade, redundant data etc. is increased after system upgrade. Before and after system upgrade, some attributes of primary sources and secondary sources may have occurred change.
No matter data structure there occurs that what changes before and after system upgrade, and the embodiment of the present application can be calculated only The remaining sum of newest primary sources realizes the detection of data validity, it is not necessary to which is concerned about before and after system upgrade Attribute there occurs the problems such as how data before change and system upgrade calculate remaining sum.
In implementation, the trading order form state of the primary sources can pay guarantee family, load including buyer The insured pays seller and guarantee family pays family of sharing in the benefit;The trading order form state of the secondary sources can be with Guarantee family and guarantee family are paid including buyer pay seller.
In specific implementation, it is assumed that before system upgrade, Xiao Ming (buyer) have purchased a CA in Taobao website Air ticket, Xiao Ming pays Alipay (guarantee family), it is to be determined receive after, Alipay (guarantee family) payment Give China Airline Company (seller), then, the data for producing in this process as secondary sources; After system upgrade, Xiao Ming (buyer) have purchased one and goes where net (family of sharing in the benefit) is provided in Taobao website CA's air ticket, Xiao Ming pays Alipay (guarantee family), it is to be determined receive after, Alipay (guarantee family) Pay where net (family of sharing in the benefit) and China Airline Company (seller), the number for producing in this process According to as primary sources.
It is described pre- regularly according to the numerical value of first predetermined amount of time end primary sources and first in implementation Between section end system storage total value determine the first difference value, according to second predetermined amount of time end first kind The numerical value of data and the total value of the second predetermined amount of time end system storage determine the second difference value, specifically can be with For:
The total value of the first predetermined amount of time end system storage is subtracted into the first predetermined amount of time end first The numerical value of class data obtains the first difference value, and the total value of the second predetermined amount of time end system storage is subtracted into institute The numerical value for stating the second predetermined amount of time end primary sources obtains the second difference value.
What said process can be visualized is expressed as below equation:
The total value of the first predetermined amount of time end system storage-the first predetermined amount of time end primary sources Numerical value=the first difference value;
The total value of the second predetermined amount of time end system storage-the second predetermined amount of time end primary sources Numerical value=the second difference value.
By taking the transaction data detection of operation system as an example, data validity determination process is specifically as follows:
(T-2) difference value of remaining sum+the second=(T-2) day account balance that day new data is calculated;
(T-1) difference value of remaining sum+the first=(T-1) day account balance that day new data is calculated;
The account amount of the old data of second the-the first difference value of difference value=(T-1) day.
Above three formula is arranged as follows:
(T-1) remaining sum+(T-2) day account balance that day new data is calculated-(T-2) day new data is calculated The account amount of the old data of remaining sum=(T-1) day account balance-(T-1) day.
Due to can be identified in operation system which be new data, which be old data, therefore, it can very The corresponding account amount of old data is readily come out, and then realizes the purpose that data validity determines.
In the embodiment of the present application, so that business transition family is for guarantee family as an example, available data validity is briefly described Determine mechanism.
Fig. 3 shows that data validity in the prior art determines the schematic diagram of mechanism, as illustrated, existing skill It is after the order amount of money that do not finish of all data in system is collected, to be compared with account balance in art, comes The validity of detection data.
Assuming that the state value of trading order form has 2, respectively buyer pays guarantee family, guarantee family and pays Seller, the date that data validity determines is T days, then, the formula that data validity determines is:
By T days, all of order amount of money that do not finish collected=the beginning balance of T days account;
Wherein, beginning balance represents the initial amount of money of same day account, and the most end amount of money on the same day is properly termed as the end of term Remaining sum.
For example, collect by all order amount of money that do not finish of October 1, should be with same day October 1 The initial amount of money is equal.
Illustrated with an instantiation below, it is assumed that trading order form is as shown in following table 1.1:
So, carried out assuring the balance check at family, on 03 03rd, 2015 on 03 03rd, 2015 The order not finished has:ID is 2,3 data, that is to say, that the data from order dimension statistics are 5+3=8. The data and account balance are checked, you can whether checking data are correct.
Inventor notices during invention:
After operation system is upgraded, it is assumed that business transition family increased family of sharing in the benefit after system upgrade, new data Trading order form state value becomes for 3, i.e.,:Buyer pays guarantee family, guarantee family and pays seller, load The insured pays family of sharing in the benefit.Within the switching phase of system upgrade, script order status value is 2 (seller's payments To guarantee family, guarantee family pay seller) old data with upgrading after order status value be 3 (seller pay the bill To guarantee family, guarantee family pay seller, guarantee family pay family of sharing in the benefit) new data all there will be.
Now, because order status there occurs change, if continuation determines mechanism using available data validity, Need to count respectively the backlog amount of money, the backlog amount of money of old data of new data, then again will The backlog amount of money of new data is compared with the account balance of new data, orders the unfinished of old data Single amount of money is compared with the account balance of old data.
The example above is intended merely to illustrate the most simplified model of available data detection, in fact, real data Validity determine logic be often it is extremely complex, old data due to historical reasons or other factors cause it is non- Often it is difficult to or cannot be detected at all, and account balance is only a numeral, can't distinguish new number According to, old data, existing data validity determines that mechanism is no longer appropriate for the old and new's data after system upgrade and deposits Situation.
Fig. 4 shows the old and new's data and the schematic diagram deposited after system upgrade, for verifying logic as soon as possible just True property, proposes requirement higher, it is therefore desirable to find out one kind as early as possible for the testing mechanism of data validity New detection logic.
The data validity that the embodiment of the present application is provided determines method, continues to be exemplified as example explanation such as with above-mentioned Under:
Assuming that after system upgrade, counterparty increased 1 family of sharing in the benefit, the state value of trading order form becomes 3 It is individual, i.e.,:Buyer pays guarantee family, and guarantee family pays seller, and guarantee family pays family of sharing in the benefit.It is being Unite in the switching phase of upgrading, the old and new's data all there will be.
Example 1, transaction record is as shown in following table 1.2:
Above-mentioned table 1.2 is 2015.03.04~2015.03.05 order status record cases of two days, wherein user The data that A is produced are old data.
Assuming that the account balance at guarantee family is as shown in following table 1.3:
Assuming that 2015.03.06 days verification guarantee family account, the technical scheme provided using the embodiment of the present application Carry out data validity and determine that operation can be as follows:
(T-2) difference value of remaining sum+the second=(T-2) day account balance that day new data is calculated, i.e.,:
2015.03.04 the difference value of remaining sum+the second=2015.03.04 days account balance that new data is calculated;
Difference value=15 of 5+ second;
Obtain, the second difference value=10;
(T-1) difference value of remaining sum+the first=(T-1) day account balance that day new data is calculated, i.e.,:
2015.03.05 the difference value of remaining sum+the first=2015.03.05 days account balance that new data is calculated;
Difference value=10 of 10+ first;
Obtain, the first difference value=0;
The account amount of the old data of second the-the first difference value of difference value=(T-1) day, i.e.,:
10-0=2015.03.05 days variation volume=10 of A.
Therefore, in the case of being obtained in the old and new's data and deposited by above-mentioned formula, only statistics new data does not finish The order amount of money is the purpose that can reach data validity determination.
Example 2, transaction record is as shown in following table 1.4:
Compared with example 1, increased within 3.04th an old data of user H, but the data on 3.05th still Arrearage is to seller.
Assuming that the account balance at guarantee family is as shown in following table 1.5:
Assuming that family account is assured in verification in 2015.03.06 days, the scheme provided using the embodiment of the present application is carried out The operation that data validity determines can be as follows:
(T-2) difference value of remaining sum+the second=(T-2) day account balance that day new data is calculated, i.e.,:
2015.03.04 the difference value of remaining sum+the second=2015.03.04 days account balance that new data is calculated;
Difference value=25 of 5+ second;
Obtain, the second difference value=20;
(T-1) difference value of remaining sum+the first=(T-1) day account balance that day new data is calculated, i.e.,:
2015.03.05 the difference value of remaining sum+the first=2015.03.05 days account balance that new data is calculated;
Difference value=20 of 10+ first;
Obtain, the first difference value=10;
The account amount of the old data of second the-the first difference value of difference value=(T-1) day, i.e.,:
20-10=2015.03.05 days variation volume=10 of A.
Example 3, transaction record is as shown in following table 1.6:
Compared with example 1, increased within 3.04th an old data of user H, and the data 3.05 days by Guarantee family pays seller.
Assuming that the account balance at guarantee family is as shown in following table 1.7:
Assuming that 2015.03.06 days verification guarantee family account, the technical scheme provided using the embodiment of the present application Carry out data validity and determine that operation can be as follows:
(T-2) difference value of remaining sum+the second=(T-2) day account balance that day new data is calculated, i.e.,:
2015.03.04 the difference value of remaining sum+the second=2015.03.04 days account balance that new data is calculated;
Difference value=25 of 5+ second;
Obtain, the second difference value=20;
(T-1) difference value of remaining sum+the first=(T-1) day account balance that day new data is calculated, i.e.,:
2015.03.05 the difference value of remaining sum+the first=2015.03.05 days account balance that new data is calculated;
Difference value=10 of 10+ first;
Obtain, the first difference value=0;
The account amount of the old data of second the-the first difference value of difference value=(T-1) day, i.e.,:
20-0=2015.03.05 days variation volume=10 for changing volume+B of A.
Therefore, in the case of being obtained in the old and new's data and deposited by above-mentioned formula, only statistics new data does not finish The order amount of money is the purpose that can reach data validity determination.
Order status change in the embodiment of the present application can also for before system upgrade buyer's direct payment to being sold Buyer pays guarantee family and pays seller by assuring family after family, upgrading, or order before system upgrade State pays guarantee family, assures that family pays family of sharing in the benefit, guarantee family and pays seller, system including buyer Situations such as other business transition families are increased after upgrading, can be carried out accordingly in specific implementation according to service logic Change, the embodiment of the present application no longer illustrates one by one herein.
For the ease of the implementation of the application, illustrated with another example below.
Assuming that tables of data is as shown in following table 1.8 before system upgrade:
Assuming that after system upgrade, tables of data increased table 1.9, specific as follows shown:
It can be seen that table 1.8 and table 1.9 occur in that redundant data (clothes and the Column Properties of classification two), i.e. system After upgrading, primary sources increased redundant data, and secondary sources do not have redundant data.
Now, it is assumed that trading order form is as shown in following table 2.0:
Assuming that the account balance at guarantee family is as shown in following table 2.1:
Assuming that family account is assured in verification in 2015.03.08 days, the scheme provided using the embodiment of the present application is carried out Data validity determines that operation can be as follows:
2015.03.06 day -2015.03.06 days remaining sum=the first difference value of new data of family account balance is assured;
25-15=10;
2015.03.07 day -2015.03.07 days remaining sum=the second difference value of new data of family account balance is assured;
18-18=0;
The variation volume of the old data of first the-the second difference value of difference value=2015.03.07 days;
10-0=2015.03.07 days variation volume=10 of I;
As can be seen that the result that data validity determines is for data are effective.
Above-described embodiment is only that the data validity that is provided of the embodiment of the present application determines method in operation system Application in transaction data detection is illustrated, and the data validity that the embodiment of the present application is provided determines that method may be used also To be applied in other systems carry out the detection of data validity.
A kind of data validity determining device is additionally provided based on same inventive concept, in the embodiment of the present application, Because the principle of these equipment solve problems determines that method is similar to a kind of data validity, therefore these equipment Implementation may refer to the implementation of method, repeat part and repeat no more.
Fig. 5 shows the structural representation of data validity determining device in the embodiment of the present application, as illustrated, The data validity determining device can include:
First determining module 501, for the state according to primary sources in the first predetermined amount of time in system Change determines the numerical value of the first predetermined amount of time end primary sources, according to second scheduled time in system The state change of primary sources determines the numerical value of the second predetermined amount of time end primary sources in section;Institute The initial time for stating the second predetermined amount of time is the finish time of first predetermined amount of time;
Second determining module 502, for according to first predetermined amount of time end primary sources numerical value and The total value of the first predetermined amount of time end system storage determines the first difference value, according to second scheduled time The numerical value of the last primary sources of section and the total value of the second predetermined amount of time end system storage determine the second difference Value;The total value of the system storage is the numerical value of primary sources and the numerical value sum of secondary sources;
3rd determining module 503, for the difference by first difference value with second difference value and institute The change value for stating secondary sources in the second predetermined amount of time is compared;If equal, determine that data are effective; If unequal, data exception is determined.
In implementation, first determining module specifically can be used for according to primary sources in system T-2 days State change determine the T-2 days numerical value of the last primary sources, according to the first kind in system T-1 days The state change of data determines the T-1 days numerical value of the last primary sources;Wherein, T is data validity Determine the date.
In implementation, first determining module specifically can be used for according in the first predetermined amount of time in system The trading order form state change of one class data determines the numerical value of the first predetermined amount of time end primary sources, Trading order form state change according to primary sources in the second predetermined amount of time in system determines that second makes a reservation for The numerical value of the time period Mo primary sources.
In implementation, described device may further include:
Logging modle 504, in the shape according to primary sources in the first predetermined amount of time in system State change determines the numerical value of the first predetermined amount of time end primary sources, according to the in system second pre- timing Between in section the state change of primary sources determine the numerical value of the second predetermined amount of time end primary sources Before, system records the trading order form state of the primary sources according to trading order form.
In implementation, the primary sources can be the data of generation after the newest upgrading of system, described second The data that class data are produced before being the newest upgrading of system.
In implementation, trading order form state value, the pass between data form and/or data before and after the system upgrade Connection relation changes.
In implementation, the trading order form state of the primary sources can pay guarantee family, load including buyer The insured pays seller and guarantee family pays family of sharing in the benefit;The trading order form state of the secondary sources can be with Guarantee family and guarantee family are paid including buyer pay seller.
In implementation, second determining module specifically can be used for the system storage of the first predetermined amount of time end The numerical value that total value subtracts the first predetermined amount of time end primary sources obtains the first difference value, by second The total value of predetermined amount of time end system storage subtracts the number of the second predetermined amount of time end primary sources It is worth to the second difference value.
In above-described embodiment, can be implemented using existing function component module.For example, first is true Cover half block, the second determining module can use existing data processing component, at least, existing business system, Just possesses the component for realizing the function in computer or mobile terminal, those skilled in the art are by corresponding Design and develop and be capable of achieving;Then it is that any one possesses setting for data comparing function as the 3rd determining module The standby component for all possessing;And logging modle, then it is that any one equipment for possessing writing function all possesses Component.
For convenience of description, each several part of apparatus described above is divided into various modules with function or unit is distinguished Description.Certainly, can be the function of each module or unit in same or multiple softwares when the application is implemented Or realized in hardware.
It should be understood by those skilled in the art that, embodiments herein can be provided as method, system or meter Calculation machine program product.Therefore, the application can be using complete hardware embodiment, complete software embodiment or knot Close the form of the embodiment in terms of software and hardware.And, the application can be used and wherein wrapped at one or more Containing computer usable program code computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) on implement computer program product form.
The application is produced with reference to the method according to the embodiment of the present application, equipment (system) and computer program The flow chart and/or block diagram of product is described.It should be understood that can by computer program instructions realize flow chart and / or block diagram in each flow and/or the flow in square frame and flow chart and/or block diagram and/ Or the combination of square frame.These computer program instructions to all-purpose computer, special-purpose computer, insertion can be provided The processor of formula processor or other programmable data processing devices is producing a machine so that by calculating The instruction of the computing device of machine or other programmable data processing devices is produced for realizing in flow chart one The device of the function of being specified in individual flow or multiple one square frame of flow and/or block diagram or multiple square frames.
These computer program instructions may be alternatively stored in can guide computer or the treatment of other programmable datas to set In the standby computer-readable memory for working in a specific way so that storage is in the computer-readable memory Instruction produce include the manufacture of command device, the command device realization in one flow of flow chart or multiple The function of being specified in one square frame of flow and/or block diagram or multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices, made Obtain and series of operation steps is performed on computer or other programmable devices to produce computer implemented place Reason, so as to the instruction performed on computer or other programmable devices is provided for realizing in flow chart one The step of function of being specified in flow or multiple one square frame of flow and/or block diagram or multiple square frames.
Although having been described for the preferred embodiment of the application, those skilled in the art once know base This creative concept, then can make other change and modification to these embodiments.So, appended right will Ask and be intended to be construed to include preferred embodiment and fall into having altered and changing for the application scope.

Claims (16)

1. a kind of data validity determines method, it is characterised in that comprise the following steps:
State change according to primary sources in the first predetermined amount of time in system determined for first scheduled time The numerical value of the last primary sources of section, according to the state of primary sources in the second predetermined amount of time in system Change determines the numerical value of the second predetermined amount of time end primary sources;Second predetermined amount of time rise Begin the finish time that the moment is first predetermined amount of time;
Numerical value and the first predetermined amount of time end system according to first predetermined amount of time end primary sources The total value of storage determines the first difference value, according to the numerical value of second predetermined amount of time end primary sources The total value stored with the second predetermined amount of time end system determines the second difference value;The sum of the system storage It is worth the numerical value sum of the numerical value and the secondary sources for the primary sources;
By in the difference of first difference value and second difference value and second predetermined amount of time The change value of two class data is compared;If equal, determine that data are effective;If unequal, number is determined According to exception.
2. the method for claim 1, it is characterised in that first predetermined amount of time is T-2 days, Second predetermined amount of time is T-1 days, wherein, T determines the date for data validity.
3. the method for claim 1, it is characterised in that the state change tool of the primary sources Body is the trading order form state change of primary sources.
4. method as claimed in claim 3, it is characterised in that described according to the in system first pre- timing Between in section the state change of primary sources determine the numerical value of the first predetermined amount of time end primary sources, State change according to primary sources in the second predetermined amount of time in system determines the second predetermined amount of time end Before the numerical value of the primary sources, further include:
System records the trading order form state of the primary sources according to trading order form.
5. the method for claim 1, it is characterised in that the primary sources are system most new liter The data produced after level, the data that the secondary sources are produced before being the newest upgrading of system.
6. method as claimed in claim 5, it is characterised in that trading order form shape before and after the system upgrade Incidence relation between state value, data form and/or data changes.
7. the method for claim 1, it is characterised in that the trading order form shape of the primary sources State pays guarantee family, assures that family pays seller and guarantee family pays family of sharing in the benefit including buyer;Described The trading order form state of two class data pays guarantee family and guarantee family and pays seller including buyer.
8. the method for claim 1, it is characterised in that described according to first predetermined amount of time The numerical value of last primary sources and the total value of the first predetermined amount of time end system storage determine the first difference value, Numerical value and the system storage of the second predetermined amount of time end according to second predetermined amount of time end primary sources Total value determine the second difference value, specially:
The total value of the first predetermined amount of time end system storage is subtracted into the first predetermined amount of time end first The numerical value of class data obtains the first difference value, and the total value of the second predetermined amount of time end system storage is subtracted into institute The numerical value for stating the second predetermined amount of time end primary sources obtains the second difference value.
9. a kind of data validity determining device, it is characterised in that including:
First determining module, for the state change according to primary sources in the first predetermined amount of time in system The numerical value of the first predetermined amount of time end primary sources is determined, according in the second predetermined amount of time in system The state change of primary sources determines the numerical value of the second predetermined amount of time end primary sources;Described The initial time of two predetermined amount of time is the finish time of first predetermined amount of time;
Second determining module, for the numerical value and first according to first predetermined amount of time end primary sources The total value of predetermined amount of time end system storage determines the first difference value, according to second predetermined amount of time end The numerical value of primary sources and the total value of the second predetermined amount of time end system storage determine the second difference value;Institute The total value for stating system storage is the numerical value sum of the numerical value with the secondary sources of the primary sources;
3rd determining module, for by the difference and described of first difference value and second difference value The change value of secondary sources is compared in two predetermined amount of time;If equal, determine that data are effective;Such as It is really unequal, determine data exception.
10. device as claimed in claim 9, it is characterised in that first determining module is specifically for root State change according to primary sources in T-2 days in system determines the T-2 days numerical value of the last primary sources, State change according to primary sources in system T-1 days determines the T-1 days number of the last primary sources Value;Wherein, T determines the date for data validity.
11. devices as claimed in claim 9, it is characterised in that first determining module is specifically for root Determine the first pre- timing according to the trading order form state change of primary sources in the first predetermined amount of time in system Between the section end primary sources numerical value, according to the friendship of primary sources in the second predetermined amount of time in system Easy order status change determines the numerical value of the second predetermined amount of time end primary sources.
12. devices as claimed in claim 11, it is characterised in that further include:
Logging modle, for becoming in the state according to primary sources in the first predetermined amount of time in system Change the numerical value for determining the first predetermined amount of time end primary sources, according to the second predetermined amount of time in system Before the state change of interior primary sources determines the numerical value of the second predetermined amount of time end primary sources, System records the trading order form state of the primary sources according to trading order form.
13. devices as claimed in claim 9, it is characterised in that the primary sources are system most new liter The data produced after level, the data that the secondary sources are produced before being the newest upgrading of system.
14. devices as claimed in claim 13, it is characterised in that trading order form before and after the system upgrade Incidence relation between state value, data form and/or data changes.
15. devices as claimed in claim 9, it is characterised in that the trading order form shape of the primary sources State pays guarantee family, assures that family pays seller and guarantee family pays family of sharing in the benefit including buyer;Described The trading order form state of two class data pays guarantee family and guarantee family and pays seller including buyer.
16. devices as claimed in claim 9, it is characterised in that second determining module is specifically for inciting somebody to action The total value of the first predetermined amount of time end system storage subtracts the first predetermined amount of time end primary sources Numerical value obtain the first difference value, by the second predetermined amount of time end system storage total value subtract described second The numerical value of predetermined amount of time end primary sources obtains the second difference value.
CN201510974844.0A 2015-12-23 2015-12-23 Data validity determination method and device Active CN106909553B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510974844.0A CN106909553B (en) 2015-12-23 2015-12-23 Data validity determination method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510974844.0A CN106909553B (en) 2015-12-23 2015-12-23 Data validity determination method and device

Publications (2)

Publication Number Publication Date
CN106909553A true CN106909553A (en) 2017-06-30
CN106909553B CN106909553B (en) 2020-06-09

Family

ID=59200245

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510974844.0A Active CN106909553B (en) 2015-12-23 2015-12-23 Data validity determination method and device

Country Status (1)

Country Link
CN (1) CN106909553B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109615456A (en) * 2018-10-31 2019-04-12 阿里巴巴集团控股有限公司 Order information statistical method and device on way

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104182826A (en) * 2014-08-13 2014-12-03 五八同城信息技术有限公司 A method and an apparatus for processing allocation data
CN105139286A (en) * 2015-08-31 2015-12-09 国网山东省电力公司菏泽供电公司 Method for evaluating validity of SCADA data on the basis of amount of reactive unbalance
CN106559191A (en) * 2015-09-30 2017-04-05 上海摩波彼克半导体有限公司 A kind of data validity inspection method and system and mobile terminal

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104182826A (en) * 2014-08-13 2014-12-03 五八同城信息技术有限公司 A method and an apparatus for processing allocation data
CN105139286A (en) * 2015-08-31 2015-12-09 国网山东省电力公司菏泽供电公司 Method for evaluating validity of SCADA data on the basis of amount of reactive unbalance
CN106559191A (en) * 2015-09-30 2017-04-05 上海摩波彼克半导体有限公司 A kind of data validity inspection method and system and mobile terminal

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109615456A (en) * 2018-10-31 2019-04-12 阿里巴巴集团控股有限公司 Order information statistical method and device on way

Also Published As

Publication number Publication date
CN106909553B (en) 2020-06-09

Similar Documents

Publication Publication Date Title
US8744942B1 (en) Method, system and computer program product for managing funds in custodial deposit accounts
US8249987B2 (en) Methods and apparatus for funding transactions using debit cards issued by one institution and funds from accounts at other institutions
CN108959620A (en) A kind of data cleaning method and equipment
CN104951977A (en) Cumulative balance based bank card utilization method and cumulative balance based bank card utilization device
CN110276682A (en) A kind of information calculates processing method and system
CN109146148B (en) Method and device for determining reason of balance prediction deviation
CN110188990A (en) A kind of resource request and funds request shunt method, device and equipment
CN106875185A (en) A kind of air control model training method and device
CN110458691B (en) Pre-loan risk monitoring method and device
CN108614866A (en) Internetbank client's Contribution Analysis method, apparatus and system
CN111932354A (en) Method for calculating balance adjustment table
CN114022264A (en) Method, device, equipment and storage medium for generating certificate
CN110084692A (en) A kind of bookkeeping methods and device
CN109472680A (en) A kind of accounting processing method and system
CN106909553A (en) A kind of data validity determines method and device
CN111681100A (en) Method and device for checking and selling bills
CN109255616B (en) Processing method and device for refused task
CN109544254A (en) Invoice information processing method, apparatus and system
CN113064837B (en) Database benchmark test method and device based on transaction scene
CN109191101A (en) A kind of method, device and equipment ensureing customer capital safety
US20150170285A1 (en) Unexpected holiday management for debt instruments
CN113159967A (en) Data processing method and device based on financial core online transaction scene
JP6419280B1 (en) Allowable repayment amount calculation device, repayment amount determination device, financial value calculation system and program
CN109815129A (en) Test method, device, terminal and the storage medium of securities finance application software
KR102621286B1 (en) Apparatus for issuing virtual currency And the method thereof

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20200921

Address after: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Patentee after: Innovative advanced technology Co.,Ltd.

Address before: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Patentee before: Advanced innovation technology Co.,Ltd.

Effective date of registration: 20200921

Address after: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Patentee after: Advanced innovation technology Co.,Ltd.

Address before: A four-storey 847 mailbox in Grand Cayman Capital Building, British Cayman Islands

Patentee before: Alibaba Group Holding Ltd.

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20240226

Address after: Guohao Times City # 20-01, 128 Meizhi Road, Singapore

Patentee after: Advanced Nova Technology (Singapore) Holdings Ltd.

Country or region after: Singapore

Address before: 27 Hospital Road, George Town, Grand Cayman ky1-9008

Patentee before: Innovative advanced technology Co.,Ltd.

Country or region before: Cayman Islands