CN104462361B - The method and apparatus of data in a kind of matched data table - Google Patents

The method and apparatus of data in a kind of matched data table Download PDF

Info

Publication number
CN104462361B
CN104462361B CN201410743256.1A CN201410743256A CN104462361B CN 104462361 B CN104462361 B CN 104462361B CN 201410743256 A CN201410743256 A CN 201410743256A CN 104462361 B CN104462361 B CN 104462361B
Authority
CN
China
Prior art keywords
data
field
record
privately owned
association identification
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.)
Active
Application number
CN201410743256.1A
Other languages
Chinese (zh)
Other versions
CN104462361A (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.)
Guangzhou Pubang Landscape Design & Construction Co ltd
Original Assignee
Guangzhou Pubang Landscape Design & Construction Co 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 Guangzhou Pubang Landscape Design & Construction Co ltd filed Critical Guangzhou Pubang Landscape Design & Construction Co ltd
Priority to CN201410743256.1A priority Critical patent/CN104462361B/en
Publication of CN104462361A publication Critical patent/CN104462361A/en
Application granted granted Critical
Publication of CN104462361B publication Critical patent/CN104462361B/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
    • G06F16/24553Query execution of query operations
    • G06F16/24554Unary operations; Data partitioning operations
    • 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/22Indexing; Data structures therefor; Storage structures
    • G06F16/2282Tablespace storage structures; Management thereof

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Software Systems (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a kind of method and apparatus of data in matched data table, its method comprises the following steps:Field in tables of data is divided into public field region and privately owned field area, a field in public field region is designated as associate field;Association identification is created for the associate field, one privately owned field area of an association identification correspondence association, association identification is added in the data of associate field;User is received to the inquiry request of the tables of data, qualified record is filtered out, the record after screening is designated as filter record;According to the association identification in this filter record, the field name and data in the privately owned field area associated by it are combined into a data splitting, then the data in corresponding public field region and data splitting composition matching are recorded;A form is created, by the data duplication matched in record into form.By above-mentioned method and step, make the data of return very succinct directly perceived, be conducive to raising user's to check efficiency.

Description

The method and apparatus of data in a kind of matched data table
Technical field
The present invention relates to data query field, and in particular to the method and apparatus of data in a kind of matched data table.
Background technology
In Database Systems, tables of data is the basic element in composition data storehouse, and the data that are stored with tables of data.It is existing Data base query method in, when user want inquire about tables of data in some field in data content be XXX record when, just The function is completed by data base query language, and the record returned includes fields all in database, further, If merely desiring to see the data of certain several field in this record, it is necessary to write code as requested in inquiry.
In real many situations, user is in inquiry and needs not look at the data in tables of data in all fields, and And there are some fields to be probably not associate with this record, or be the unconcerned field of user.Existing method may These can not be had the field of association or the unconcerned field of user to show that influence user checks efficiency to data.
The content of the invention
In order to overcome the deficiencies in the prior art, it is an object of the invention to provide a kind of method of data in matched data table And device, realize that the data in the record that is returned of querying condition for user are only user's data of concern, will be with This records unrelated Field Sanitization and fallen, finally returned data in table form, makes the presentation of data very succinct directly perceived, has Efficiency is checked beneficial to raising user.
To solve the above problems, the technical solution adopted in the present invention is as follows:
Scheme one:
The method of data, comprises the following steps in a kind of matched data table:
Step A:Field in tables of data is divided into a public field region and multiple privately owned field areas, wherein, A field in public field region is designated as associate field;
Step B:Created and privately owned field area quantity identical association identification, an association identification for the associate field One privately owned field area of correspondence association, association identification is added in the data of associate field;
Step C:User is received to the inquiry request of the tables of data, inquiry request carries querying condition, according to the inquiry Conditional filtering goes out qualified record, and the record after screening is designated as into filter record;Performed if only one filter record Step D, step D is performed if having a plurality of filter record successively from first to the last item filter record;
Step D:According to the association identification in this filter record, by the field name in the privately owned field area associated by it It is combined with the data in this filter record corresponding to the field name, to form a data splitting;By this filter record In correspond to public field region in data and data splitting constitute a new record, by the new record be designated as matching note Record;Wherein, if field name has n, n is the integer more than 1, then field name data corresponding with its are constituted in data splitting A part, whole data splitting by n part constitute;
Step E:A form is created, by the data duplication matched in record into form.
In stepb, association identification is added to the head of the data of associate field.
In step C, querying condition, which refers to using the data in a certain field, is used as key word of the inquiry.
Scheme two:
The device of data in a kind of matched data table, including with lower module:
Modules A:For the field in tables of data to be divided into a public field region and multiple privately owned field areas, its In, a field in public field region is designated as associate field;
Module B:For being created and privately owned field area quantity identical association identification, an association for the associate field One privately owned field area of mark correspondence association, association identification is added in the data of associate field;
Module C:For receiving inquiry request of the user to the tables of data, inquiry request carries querying condition, according to this Querying condition filters out qualified record, and the record after screening is designated as into filter record;If only one filter record A step D is performed, step D is performed successively from first to the last item filter record if having a plurality of filter record;
Module D:For the association identification in this filter record, by the word in the privately owned field area associated by it The data for corresponding to the field name in section name and this filter record are combined, to form a data splitting;By this screening The data and data splitting corresponded in record in public field region constitute a new record, and the new record is designated as With record;Wherein, if field name has n, n is the integer more than 1, then field name data corresponding with its constitute number of combinations A part in, whole data splitting is made up of n parts;
Module E:For creating a form, by the data duplication matched in record into form.
In module B, association identification is added to the head of the data of associate field.
In module C, querying condition, which refers to using the data in a certain field, is used as key word of the inquiry.
Compared with prior art, the beneficial effects of the present invention are:By carrying out region division to the data in tables of data, when After user is by input inquiry condition, the data in the record of return are only user's data of concern, will be recorded with this Unrelated Field Sanitization falls, finally returned data in table form, makes the presentation of data very succinct directly perceived, is conducive to improving User's checks efficiency.
Brief description of the drawings
Fig. 1 is the flow chart of the method for data in matched data table of the invention.
Embodiment
Below, with reference to accompanying drawing and embodiment, the present invention is described further:
With reference to Fig. 1, a kind of method of data in matched data table, the method in order to more fully understand the program below will It is described with reference to specific example.
Data in an existing tables of data, tables of data are as shown in table 1 below:
Table 1:
Material code Name of material Quantity Project name Contract number Color Thickness Voltage Wattage Highly Planting patterns
YJ0103 Granite 100 A hotels 1234 Ash 40
SD0201 Ceiling lamp 50 B hotels 1011 220 100
LH0309 Camphor tree 100 C parks 1414 4 Ground seedling
SD0202 Wall lamp 80 A hotels 1234 220 80
YJ0103 Granite 80 D gardens 1331 Ash 40
In tables of data, field refers to the row in tables of data, and record refers to the row in tables of data, for example, " material in table 1 This row of title " are referred to as a field, and " SD0201 " this line is referred to as a record.The method of the present invention is as follows:
Step A:Field in tables of data is divided into a public field region and at least two privately owned field areas, its In, a field in public field region is designated as associate field.
It is according to step A that " material code ", " name of material ", " quantity ", " project name " and " contract number " in table 1 is common 5 fields are divided into public field region, and " color " and " thickness " is divided into the first privately owned field area, " voltage " and " watt Number " is divided into the second privately owned field area, and " height " and " planting patterns " is divided into the 3rd privately owned field area.By public field " material code " field in region is designated as associate field.
Step B:Created and privately owned field area quantity identical association identification, an association identification for the associate field One privately owned field area of correspondence association, association identification is added in the data of associate field.Preferably, association identification is added to The head of the data of associate field, and these association identifications are to input to add by user.
Three association identifications are created, are respectively " YJ ", " SD " and " LH ", " YJ " is associated with the first privately owned field area, " SD " is associated with the second privately owned field area, and " LH " is associated with the 3rd privately owned field area, in the data of " material code " field Middle addition association identification.Before association identification is not added with, the data in " material code " field be respectively " 0103 ", " 0201 ", " 0309 ", " 0202 " and " 0103 ", adds " YJ ", i.e. data when the head in " 0103 " and is changed into " YJ0103 ", now " YJ0103 " sets up incidence relation with the first privately owned field area.
Step C:User is received to the inquiry request of the tables of data, inquiry request carries querying condition, according to the inquiry Conditional filtering goes out qualified record, and the record after screening is designated as into filter record;Performed if only one filter record Step D, step D is performed if having a plurality of filter record successively from first to the last item filter record.Preferably, look into Inquiry condition, which refers to using the data in a certain field, is used as key word of the inquiry.
For example, the querying condition in the inquiry request of user is, the data in " name of material " field are " granite " Record, obtains after record, the inquiry request for having responded user particular by query sentence of database is performed, meets filtering out The record of querying condition, from table 1, meeting the filter record of querying condition has two.
Step D:According to the association identification in this filter record, by the field name in the privately owned field area associated by it It is combined with the data in this filter record corresponding to the field name, to form a data splitting;By this filter record In correspond to public field region in data and data splitting constitute a new record, by the new record be designated as matching note Record;Wherein, if field name has n, n is the integer more than 1, then field name data corresponding with its are constituted in data splitting A part, whole data splitting by n part constitute.
In step C, the record of inquiry " granite " has two, then needs to perform successively twice from first to Article 2 Step D.For example, in first filter record, as known from Table 1, the association identification in this filter record is in " material code " In field, it is specially " YJ ", associated by " YJ " is the first privately owned field area, i.e. " color " and " thickness " field.
To be combined " color " and " ash " according to step D content corresponding to table 1, specifically can by " color " and " ash " is combined into " color ash ", or further, a symbol is added between " color " and " ash ", " color is combined into: Ash ", its form combined is not limited to above-mentioned described form.Following description for convenience, by unified with " field name:It is right This form of the data answered " is described.
Because having " color " and " thickness " two field names, therefore " color:Ash " is the part in data splitting, " thick Degree:40 " be also the part in data splitting, " color:Ash " and " thickness:40 " this two parts have been combined into a number of combinations According to.Preferably, it can be distinguished between every two parts with a separator, can specifically add between the two sections ";", i.e. shape Into " color:Ash;Thickness:40 " this form.
The data and data splitting that correspond in this filter record in public field region are constituted into a new record, The new record is designated as matching record.Then it is recorded as according to the matching obtained by first filter record, " ' YJ0103 ', ' flower Gang Yan ', ' 100 ', ' A hotels ', ' 1234 ', ' color:Ash;Thickness:40’”.Then one is performed for Article 2 filter record again Secondary step D, just can obtain another matching and is recorded as, " ' YJ0103 ', ' granite ', ' 80 ', ' D gardens ', ' 1331 ', ' face Color:Ash;Thickness:40’”.
By step D, useful field (field in public field region and corresponding is exactly extracted in filter record Field in privately owned field area), the field in other privately owned field areas can be regarded as unrelated number in this filter record According to or unconcerned data, it is filtered.
Step E:A form is created, by the data duplication matched in record into form.Further, the first of form In capable each cell, the attribute-name for the data being respectively filled in the row represented where the cell.Wherein, attribute-name is in wound Just it is located therein when building form.
Specifically, with reference to above-mentioned two resulting matched datas, resulting form and its data are such as in this step Shown in table 2.
Table 2:
It is sub as another example below in order to which the flow of this method is better described.
It is still for table 1, carries out after step A and step B, the querying condition of user is in step C, " contract number " Data in field are the record of " 1234 ".Two matching records are got by step D, then by the form of step E generations And its data are as shown in table 3.
Table 3:
Technical scheme has the advantages that it can be seen from above-mentioned method:By in tables of data Data carry out region division, the incidence relation between preset data and data, after user is by input inquiry condition, return Record in data be only user's data of concern, fall unrelated Field Sanitization is recorded with this, finally with form Form returned data, make the presentations of data very succinct directly perceived, be conducive to improving user checks efficiency.If for example, one There are 10 privately owned field areas in individual tables of data, if return in the tables of data one of querying condition inputted for user is complete Complete record, then this record will be very long, and the inside can record unrelated field including some with this.Therefore this is filtered out A little fields can make the data of return all be user's data of concern.
Corresponding to above-mentioned method, a kind of device of data in matched data table is also disclosed below, including with lower module:
Modules A:, will for the field in tables of data to be divided into a public field region and multiple privately owned field areas A field in public field region is designated as associate field;
Module B:For being created and privately owned field area quantity identical association identification, an association for the associate field One privately owned field area of mark correspondence association, association identification is added in the data of associate field;
Module C:For receiving inquiry request of the user to the tables of data, inquiry request carries querying condition, according to this Querying condition filters out qualified record, and the record after screening is designated as into filter record;If only one filter record A step D is performed, step D is performed successively from first to the last item filter record if having a plurality of filter record;
Module D:For the association identification in this filter record, by the word in the privately owned field area associated by it The data for corresponding to the field name in section name and this filter record are combined, to form a data splitting;By this screening The data and data splitting corresponded in record in public field region constitute a new record, and the new record is designated as With record;Wherein, if field name has n, n is the integer more than 1, then field name data corresponding with its constitute number of combinations A part in, whole data splitting is made up of n parts;
Module E:For creating a form, by the data duplication matched in record into form.
In module B, association identification is added to the head of the data of associate field.
In module C, querying condition, which refers to using the data in a certain field, is used as key word of the inquiry.
It will be apparent to those skilled in the art that technical scheme that can be as described above and design, make other various It is corresponding to change and deformation, and all these change and deformation should all belong to the protection domain of the claims in the present invention Within.

Claims (6)

1. a kind of method of data in matched data table, it is characterised in that comprise the following steps:
Step A:Field in tables of data is divided into a public field region and multiple privately owned field areas, by public field A field in region is designated as associate field;
Step B:Created and privately owned field area quantity identical association identification, an association identification correspondence for the associate field A privately owned field area is associated, association identification is added in the data of associate field;
Step C:User is received to the inquiry request of the tables of data, inquiry request carries querying condition, according to the querying condition Qualified record is filtered out, filter record is designated as by qualified after screening;If only one filter record A step D is performed, step D is performed successively from first to the last item filter record if having a plurality of filter record;
Step D:According to the association identification in this filter record, by the field name in the privately owned field area associated by it and this Data in bar filter record corresponding to the field name are combined, to form a data splitting;Will be right in this filter record A new record should be constituted in the data in public field region and data splitting, the new record is designated as matching record; Wherein, if field name has n, n is the integer more than 1, then field name data corresponding with its are constituted in data splitting A part, whole data splitting is made up of n parts;
Step E:A form is created, by the data duplication matched in record into form.
2. the method for data in matched data table according to claim 1, it is characterised in that in stepb, association identification Added to the head of the data of associate field.
3. the method for data in matched data table according to claim 1, it is characterised in that in step C, querying condition Finger is used as key word of the inquiry using the data in a certain field.
4. the device of data in a kind of matched data table, it is characterised in that including with lower module:
Modules A:, will be public for the field in tables of data to be divided into a public field region and multiple privately owned field areas A field in field area is designated as associate field;
Module B:For being created and privately owned field area quantity identical association identification, an association identification for the associate field One privately owned field area of correspondence association, association identification is added in the data of associate field;
Module C:For receiving inquiry request of the user to the tables of data, inquiry request carries querying condition, according to the inquiry Conditional filtering goes out qualified record, and filter record is designated as by qualified after screening;If only one screening note Record then performs a step D, and step D is performed successively from first to the last item filter record if having a plurality of filter record;
Module D:For the association identification in this filter record, by the field name in the privately owned field area associated by it It is combined with the data in this filter record corresponding to the field name, to form a data splitting;By this filter record In correspond to public field region in data and data splitting constitute a new record, by the new record be designated as matching note Record;Wherein, if field name has n, n is the integer more than 1, then field name data corresponding with its are constituted in data splitting A part, whole data splitting by n part constitute;
Module E:For creating a form, by the data duplication matched in record into form.
5. the device of data in matched data table according to claim 4, it is characterised in that in module B, association identification Added to the head of the data of associate field.
6. the device of data in matched data table according to claim 4, it is characterised in that in module C, querying condition Finger is used as key word of the inquiry using the data in a certain field.
CN201410743256.1A 2014-12-05 2014-12-05 The method and apparatus of data in a kind of matched data table Active CN104462361B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410743256.1A CN104462361B (en) 2014-12-05 2014-12-05 The method and apparatus of data in a kind of matched data table

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410743256.1A CN104462361B (en) 2014-12-05 2014-12-05 The method and apparatus of data in a kind of matched data table

Publications (2)

Publication Number Publication Date
CN104462361A CN104462361A (en) 2015-03-25
CN104462361B true CN104462361B (en) 2017-10-31

Family

ID=52908396

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410743256.1A Active CN104462361B (en) 2014-12-05 2014-12-05 The method and apparatus of data in a kind of matched data table

Country Status (1)

Country Link
CN (1) CN104462361B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107220266B (en) * 2016-03-22 2021-03-19 创新先进技术有限公司 Method and device for creating service database, storing service data and determining service data
CN108228691B (en) * 2017-06-30 2023-06-23 勤智数码科技股份有限公司 Processing method of data elements in government information management
CN109636582B (en) * 2018-10-31 2024-03-12 平安科技(深圳)有限公司 Credit information management method, apparatus, device and storage medium
CN111241053B (en) * 2018-11-29 2022-08-23 中国移动通信集团四川有限公司 Data table creating method, device, equipment and storage medium
CN111309721A (en) * 2018-12-11 2020-06-19 北京京东尚科信息技术有限公司 Method and device for determining association relation of data table
CN111831964B (en) * 2019-04-10 2024-06-07 阿里巴巴集团控股有限公司 Data report information processing method and device and computer system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101354723A (en) * 2008-09-10 2009-01-28 金蝶软件(中国)有限公司 Method and apparatus for implementing combined field
CN102243664A (en) * 2011-08-22 2011-11-16 西北大学 Data storage and query method for compound fields
CN102346785A (en) * 2011-11-15 2012-02-08 北京创腾科技有限公司 Method and device for directly self-defining field of database
CN102541529A (en) * 2010-12-30 2012-07-04 北京亿阳信通软件研究院有限公司 Query page generating device and method

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2368929B (en) * 2000-10-06 2004-12-01 Andrew Mather An improved system for storing and retrieving data

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101354723A (en) * 2008-09-10 2009-01-28 金蝶软件(中国)有限公司 Method and apparatus for implementing combined field
CN102541529A (en) * 2010-12-30 2012-07-04 北京亿阳信通软件研究院有限公司 Query page generating device and method
CN102243664A (en) * 2011-08-22 2011-11-16 西北大学 Data storage and query method for compound fields
CN102346785A (en) * 2011-11-15 2012-02-08 北京创腾科技有限公司 Method and device for directly self-defining field of database

Also Published As

Publication number Publication date
CN104462361A (en) 2015-03-25

Similar Documents

Publication Publication Date Title
CN104462361B (en) The method and apparatus of data in a kind of matched data table
CN103530327B (en) A kind of data migration method from non-relational database to relevant database
CN103699638B (en) Method for realizing cross-database type synchronous data based on configuration parameters
CN104991975B (en) The data query method and its system of power business system
CN102819536B (en) Tree type data disposal route and device
CN103390015B (en) Based on mass data stored in association method and the search method of unified index
CN104063361B (en) Report design method and Report Form Design system
CN101719135A (en) Administrative resource catalog control system and method
WO2006107772A3 (en) System and methods for facilitating a linear grid database with data organization by dimension
EP1585036A3 (en) Management of parameterized database queries
CN103631969A (en) Generation method and device of report data
CN102254029A (en) View-based data access system and method
CN104111955A (en) Combined inquiring method oriented to Hbase database
CN102902777A (en) Cross data source inquiry device and cross data source inquiry method
CN107291925A (en) A kind of examination & approval data intermediate processing based on business model
CN104462421A (en) Multi-tenant expanding method based on Key-Value database
CN102819609A (en) Modeling method for persisting data model
WO2003030032A3 (en) An index structure to access hierarchical data in a relational database system
CN102314480A (en) Distributed data storage method specific to mass data
CN110837506A (en) Mycat-based data fragmentation and read-write separation method and system
CN103605663A (en) General database checking and metadata loading method
CN102982186A (en) Method and system for maintaining range partitioning table based on oracle database system
CN102024182A (en) System for managing asset information
CN103927168B (en) A kind of method and device of object-oriented data model persistence
CN101110858A (en) Telecommunication report generation system and method thereof

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CB03 Change of inventor or designer information
CB03 Change of inventor or designer information

Inventor after: Guo Yingtao

Inventor after: Zhong Fei

Inventor after: Huang Xueying

Inventor after: Gan Lijun

Inventor after: Peng Huilan

Inventor after: Liu Ling

Inventor after: Liu Xiaodan

Inventor after: Zhuo Ying

Inventor after: Chen Ying

Inventor after: Xu Genrong

Inventor after: Zhou Zhuotao

Inventor after: Su Zhubao

Inventor before: Guo Yingtao

Inventor before: Zhong Fei

Inventor before: Huang Xueying

Inventor before: Gan Lijun

Inventor before: Liu Xiaodan

Inventor before: Liu Ling

Inventor before: Peng Huilan

Inventor before: Zhuo Ying

Inventor before: Chen Ying

Inventor before: Xu Genrong

Inventor before: Zhou Zhuotao

Inventor before: Su Zhubao