CN103365909A - Method for sequentially generating accumulated values one by one in data table - Google Patents
Method for sequentially generating accumulated values one by one in data table Download PDFInfo
- Publication number
- CN103365909A CN103365909A CN 201210099663 CN201210099663A CN103365909A CN 103365909 A CN103365909 A CN 103365909A CN 201210099663 CN201210099663 CN 201210099663 CN 201210099663 A CN201210099663 A CN 201210099663A CN 103365909 A CN103365909 A CN 103365909A
- Authority
- CN
- China
- Prior art keywords
- successively
- accumulated value
- generate
- tables
- data according
- 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.)
- Pending
Links
Images
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
In a Foxpro system, in order to sequentially generate accumulated values one by one in a data table, a compound expression is used for conducting index and rank ordering to complete various complex ordering modes. Bilayer loop nesting is utilized, current record field content is used for conducting valuation accumulation on middle memory variables, and the operation of sequentially generating the accumulated values one by one is achieved. The system automatically judges whether file names and field names which are relevant to source and target parameters exist, and whether types are matched, and prompts relevant information. Parameters in last time accumulated operation are recorded for correction in next accumulated operation. The input process of the parameters in next time is simplified.
Description
Affiliated technical field
The present invention relates in the computer data base management system software, realize generating one by one successively in the tables of data technology of accumulated value.
Background technology
Carry out data management with computing machine, generate various form, particularly financial statement, the numeric type data of depositing loan for revenue and expenditure need to generate one by one successively accumulated value.If in custom-designed form, other adds such function, as long as can realize very soon with simple cumulative expression formula.But, will be in a general database, generate one by one successively accumulated value after the numerical classification ordering to certain numeric type field, and deposit in the other numeric type field, just relatively more difficult, in excel spreadsheet lattice software, also find no the method that numerical value is generated successively one by one accumulated value.The present invention discloses a kind of in the Foxpro system, when designing middle-size and small-size data management software, realizes generating one by one successively the universal programming method of accumulated value.
Summary of the invention
Owing to containing a lot of different parameters in the cumulative program designed in the Foxpro system, and when carrying out different cumulative operations, general needing only adjusted a small amount of key parameter, therefore the present invention can remember the parameter when adding up operation last time, revises during for next cumulative the operation.Simplified the input process of each parameter next time.Whether system can automatic decision exists with source, each filename, field name that target component is relevant, and whether type mates, when it does not exist or does not mate, and the information that automatic-prompting is correlated with.For finishing the data accumulation operation of various complexity, after the present invention uses " its master index field name " to the database classification dexterously, carry out the ordering of various complexity by " secondary index expression formula " again, and use double-deck loop nesting, only by with the current record field contents assignment to middle memory variable, just finished the operation that classification and ordination generates accumulated value successively one by one.
Description of drawings
Fig. 1 is the process flow diagram that generates one by one successively accumulated value in the tables of data.
Specific embodiment
Be the versatility of realization program and the simplification of operation, the present invention has set several systems and has kept variable name in program circuit, and the environment of system's operation has been carried out relevant setting.
When finding the file ZCM_LJ.MEM of the most recent parameters deposited is arranged, then access original each parameter, suitably revise.When not having, just re-enter.The character of depositing among the aiming field name X_BMB is changed into capitalization, and the space character before and after the deletion, remaining similar.Whether judgement and source, each filename, field name that target component is relevant exist respectively again, and particularly whether the condition of screening is logical expression, that is, X_BTTX is the conditional expression of logical type whether.Guarantee that various Bag do not appear in final the execution when adding up operation.
Before carrying out cumulative operation, the content that detailed prompting will operate, the user can stop or retouching operation, prevents maloperation.Intermediate variable X_BZCXX deposits the compound expression of " its master index field name " and " secondary index expression formula ", and press compound expression X_BZCXX index order, when the length of " secondary index expression formula " is 0, when only depositing " its master index field name " among the X_BZCXX, actual in " its master index field name " index order, when " its master index field name ", when " secondary index expression formula " length is 0 simultaneously, actual in the former order ordering of database (not sorting), so adopt compound expression X_BZCXX can finish the sortord of various complexity.
At LEN (X_BZXX)>=1, when namely being arranged, uses the master index key word double-deck loop nesting, by with the accumulative total assignment of current record field contents to middle memory variable X_BXJ, finish the operation that generates one by one successively accumulated value.By the variation of current class label X_BNB, finish different classifications is re-started successively cumulative.At LEN (X_BZXX)=0, namely there is not the master index key word, when not needing to classify accumulative total, use single cycle, by with the accumulative total assignment of current record field contents to middle memory variable X_BXJ, finish the operation that generates one by one successively accumulated value.The final correlation parameter of preserving this operation is revised when moving for next time in the ZCM_LJ.MEM file.
The following source program of * is write with Foxpro.Function: cumulative one by one successively to the record of the numeric type in the database
。
Claims (5)
1. generate one by one successively the method for accumulated value in the tables of data, in the Foxpro system, use double-deck loop nesting, by cumulative to the assignment of middle memory variable with the current record field contents, finish and generate one by one successively the accumulated value operation.
2. generate one by one successively the method for accumulated value in a kind of tables of data according to claim 1, it is characterized in that: can remember alternative parameter last time, revise during for next replacement operation.
3. generate one by one successively the method for accumulated value in a kind of tables of data according to claim 1, it is characterized in that: whether system can automatic decision exists with source, each filename, field name that target component is relevant, whether type mates, when it does not exist or does not mate, the information that automatic-prompting is relevant.
4. generate one by one successively the method for accumulated value in a kind of tables of data according to claim 1, it is characterized in that: carry out index order with compound expression, finish the sortord of various complexity.
5. generate one by one successively the method for accumulated value in a kind of tables of data according to claim 1, it is characterized in that: can remember the parameter when adding up operation last time, revise when operating for adding up next time.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 201210099663 CN103365909A (en) | 2012-04-09 | 2012-04-09 | Method for sequentially generating accumulated values one by one in data table |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 201210099663 CN103365909A (en) | 2012-04-09 | 2012-04-09 | Method for sequentially generating accumulated values one by one in data table |
Publications (1)
Publication Number | Publication Date |
---|---|
CN103365909A true CN103365909A (en) | 2013-10-23 |
Family
ID=49367273
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN 201210099663 Pending CN103365909A (en) | 2012-04-09 | 2012-04-09 | Method for sequentially generating accumulated values one by one in data table |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103365909A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018161403A1 (en) * | 2017-03-10 | 2018-09-13 | 深圳市科脉技术股份有限公司 | Data statistics method and system for report forms |
CN113553339A (en) * | 2021-07-13 | 2021-10-26 | 杭州安恒信息技术股份有限公司 | Data query method, middleware, electronic device and storage medium |
-
2012
- 2012-04-09 CN CN 201210099663 patent/CN103365909A/en active Pending
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018161403A1 (en) * | 2017-03-10 | 2018-09-13 | 深圳市科脉技术股份有限公司 | Data statistics method and system for report forms |
CN113553339A (en) * | 2021-07-13 | 2021-10-26 | 杭州安恒信息技术股份有限公司 | Data query method, middleware, electronic device and storage medium |
CN113553339B (en) * | 2021-07-13 | 2024-03-19 | 杭州安恒信息技术股份有限公司 | Data query method, middleware, electronic device and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101601012B (en) | Producer graph oriented programming framework with scenario support | |
Klein et al. | Advances in probabilistic model checking with PRISM: variable reordering, quantiles and weak deterministic Büchi automata | |
CN101208695B (en) | Managing metadata for graph-based computations | |
Jia et al. | Enhancing reuse of constraint solutions to improve symbolic execution | |
Tocher | Review of simulation languages | |
US8196126B2 (en) | Methods and systems for dynamically generating and optimizing code for business rules | |
CN101887365B (en) | Method and system for constructing executable code for component-based applications | |
CN102426582B (en) | Data manipulation management devices and data manipulation management method | |
Anderson et al. | Studying lean-kanban approach using software process simulation | |
US20140108433A1 (en) | Ordered Access Of Interrelated Data Files | |
CN105593818A (en) | Apparatus and method for scheduling distributed workflow tasks | |
CN104685497A (en) | Hardware implementation of the aggregation/group by operation: filter method | |
CN110458324A (en) | Calculation method, device and the computer equipment of risk probability | |
CN103136263A (en) | Method for automatic generation of structured query language (SQL) sentences | |
CN102456188A (en) | Data management system and design method thereof | |
CN109510852A (en) | The method and device of gray scale publication | |
CN103077192A (en) | Data processing method and system thereof | |
JP7223097B2 (en) | Journal data creation device, journal data creation method and journal data creation program | |
CN103365909A (en) | Method for sequentially generating accumulated values one by one in data table | |
Jaghoori et al. | Modere: The model-checking engine of Rebeca | |
CN107315652A (en) | A kind of data back up method and cloud HDFS systems | |
Braune et al. | Applying genetic algorithms to the optimization of production planning in a real-world manufacturing environment | |
JP6130645B2 (en) | Production plan generation device, production plan generation method, program, and recording medium | |
CN103210389B (en) | A kind for the treatment of method and apparatus of metadata | |
CN109242682A (en) | Monetary exchange rate conversion method, device, computer equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C02 | Deemed withdrawal of patent application after publication (patent law 2001) | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20131023 |