CN103544317B - The treating method and apparatus of dimension table data - Google Patents

The treating method and apparatus of dimension table data Download PDF

Info

Publication number
CN103544317B
CN103544317B CN201310544476.7A CN201310544476A CN103544317B CN 103544317 B CN103544317 B CN 103544317B CN 201310544476 A CN201310544476 A CN 201310544476A CN 103544317 B CN103544317 B CN 103544317B
Authority
CN
China
Prior art keywords
dimension
data
dimension table
preset value
row
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
CN201310544476.7A
Other languages
Chinese (zh)
Other versions
CN103544317A (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.)
Beijing Gridsum Technology Co Ltd
Original Assignee
Beijing Gridsum Technology 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 Beijing Gridsum Technology Co Ltd filed Critical Beijing Gridsum Technology Co Ltd
Priority to CN201310544476.7A priority Critical patent/CN103544317B/en
Publication of CN103544317A publication Critical patent/CN103544317A/en
Application granted granted Critical
Publication of CN103544317B publication Critical patent/CN103544317B/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/22Indexing; Data structures therefor; Storage structures
    • 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/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/283Multi-dimensional databases or data warehouses, e.g. MOLAP or ROLAP

Landscapes

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

Abstract

The invention discloses a kind for the treatment of method and apparatus of dimension table data.Wherein, the processing method of dimension table data includes:Increase data row in the database belonging to dimension table, wherein, the size of data row is less than the first preset value;The display text attribute of target dimension in dimension table is set to point to data row;And control dimension table is loaded into data again.By the present invention, solve the problems, such as that dimension table data is well over limitation, and then reduce the effect that file size limitation brings adverse effect.

Description

The treating method and apparatus of dimension table data
Technical field
The present invention relates to database field, in particular to a kind for the treatment of method and apparatus of dimension table data.
Background technology
Analysis Services(Hereinafter referred to as SSAS)It is the multi-dimensional database of Microsoft, from traditional database extraction number According to, and change into the database of oneself.For each dimension in SSAS, there are two attribute columns of Key and Name, Key row represent Unique key assignments, Name row represent the text for showing(Show text attribute).It is right in database this two row can be pointed to The table row answered.If Name attributes do not point to a certain row, the value of Key row is converted to character string as display text category by acquiescence The value of property, that is, show text.Because Name Column Properties are text formatting, and SSAS uses a kind of special file format(Band There is duplicate removal logic)To store the row of text formatting, the size that this file format has 4GB limits.
If a dimension is continuous integer, numerical value is from 1 to several hundred million, then the Name of this dimension row be exactly " 1 ", " 2 ", " 3 ", " 4 " are up to character string as several hundred million, because these character strings are all characters that is unduplicated, finally storing String size can easily exceed 4GB file size limitation, cause the failure in SSAS processing.Especially, in each dimension table In have the dimension of one " group key ", its Key row are exactly the continuous integral number since 1, and in default situations, its Name, which is arranged, is exactly The continuous integral number since 1 of text formatting.When the data row of dimension table is a lot, the Name row of " group key " can easily exceed 4GB。
The problem of being well over file size limitation for the data in dimension table in correlation technique, not yet propose have at present The solution of effect.
The content of the invention
It is a primary object of the present invention to provide a kind for the treatment of method and apparatus of dimension table data, to solve dimension table number According to being well over file size restricted problem.
To achieve these goals, according to an aspect of the invention, there is provided a kind of processing method of dimension table data, Including:Increase data row in the database belonging to dimension table, wherein, the size of data row is less than the first preset value;Dimension is set The display text attribute for spending target dimension in table points to data row;And control dimension table is loaded into data again.
Further, target dimension is determined in the following manner:Obtain the size of each dimension in dimension table;Judge respectively Whether the size of each dimension is more than the second preset value, wherein, the second preset value is more than or equal to the first preset value;And determine The dimension that the size judged is more than the second preset value is target dimension.
Further, data are classified as calculating row.
Further, the quantity of target dimension is multiple that the display text attribute for setting target dimension in dimension table is pointed to Data row include:The display text attribute of each target dimension is set to be directed to data row.
To achieve these goals, according to another aspect of the present invention, there is provided a kind of processing unit of dimension table data, The processing unit is mainly used in performing the processing method for any dimension table data that the above of the present invention is provided.
To achieve these goals, according to another aspect of the present invention, there is provided a kind of processing unit of dimension table data, Including:Unit is established, for increasing data row in the database belonging to dimension table, wherein, the size of data row is less than first Preset value;Setting unit, the display text attribute for setting target dimension in dimension table point to data row;And control is single Member, data are loaded into again for control dimension table.
Further, the processing unit of dimension table data also includes:Acquiring unit, for obtaining each dimension in dimension table Size;Judging unit, for judging whether the size of each dimension is more than the second preset value respectively, wherein, the second preset value More than or equal to the first preset value;And determining unit, the dimension that the size for determining to judge is more than the second preset value are Target dimension.
Further, data are classified as calculating row.
Further, the quantity of target dimension is multiple that setting unit is used for the display text for setting each target dimension Attribute is directed to data row.
The present invention uses increases data row in the database belonging to dimension table, wherein, the size of data row is less than first Preset value;The display text attribute of target dimension in dimension table is set to point to data row;And control dimension table is loaded into number again According to.By the way that the display text attribute of dimension all in dimension table may determine that in dimension table into which compared with default size The display text attribute of a little dimensions then exceedes at the dimension row of size limitation beyond the limitation of file size to these Reason, i.e., these display text attributes are pointed into newly-increased data row, its size is not broken through the limitation of file size, solve dimension Degree table data are well over the problem of limitation, and then reduce the effect that file size limitation brings adverse effect.
Brief description of the drawings
The accompanying drawing for forming the part of the application is used for providing a further understanding of the present invention, schematic reality of the invention Apply example and its illustrate to be used to explain the present invention, do not form inappropriate limitation of the present invention.In the accompanying drawings:
Fig. 1 is the flow chart of the processing method of dimension table data according to embodiments of the present invention;And
Fig. 2 is the structural representation of the processing unit of dimension table data according to embodiments of the present invention.
Embodiment
It should be noted that in the case where not conflicting, the feature in embodiment and embodiment in the application can phase Mutually combination.Describe the present invention in detail below with reference to the accompanying drawings and in conjunction with the embodiments.
The embodiment of the present invention provides a kind of processing method of dimension table data, below to the dimension table number of the embodiment of the present invention According to processing method be introduced:
Fig. 1 is the flow chart of the processing method of dimension table data according to embodiments of the present invention, as shown in figure 1, this method Including steps S102 to step S106:
Step S102, increase data row in the database belonging to dimension table, wherein, the size of data row is pre- less than first If value.Specifically, row can be calculated by increasing by one into the database belonging to dimension table, it can pass through logarithm to calculate row Obtained according to other row in storehouse by same calculation formula, calculate row name, constant or function that row can be non-computational row, can also It is the combination of above-mentioned element.But preset value should be less than by calculating the length of row, and Analysis Services are to the big of text Small to be limited to be no more than 4GB, then the first preset value is not more than 4GB.
Step S104, the display text attribute of target dimension in dimension table is set(That is, Name is arranged)Point to data row.Due to The file format of Key row does not have size limitation, therefore only change shows the attribute of text attribute.
Step S106, control dimension table are loaded into data again.After showing that text attribute points to the data row newly increased, Again data are loaded into, then shows that the size of text attribute is equal with the data newly increased row, that is, shows the size of text attribute not More than preset value.Specifically, Process Full operations can be performed in Analysis Services, make database again It is loaded into data.When performing Process Full operations, all unique values for showing text attribute are first extracted from database, will These values are converted into Analysis Services text formatting.
Further, it is determined that the method for target dimension includes step S1 to S3:
Step S1, obtain the size of each dimension in dimension table.Limited due to only having Name to exceed file size, Therefore only obtain and show text attribute size.
Step S2, judges whether the size of each dimension is more than the second preset value respectively, and second preset value can be more than Or equal to the first preset value, but likewise not greater than 4GB.
Step S3, it is determined that the dimension that the size judged is more than the second preset value is target dimension.
By the way that the display text attribute of dimension all in dimension table may determine that into dimension compared with default size The display text attribute of which dimension is then arranged these dimensions more than size limitation beyond the limitation of file size in table Handled, i.e., these display text attributes are pointed into newly-increased data row, its size is not broken through the limitation of file size, solve Dimension table data of having determined is well over the problem of limitation, and then reduces the effect that file size limitation brings adverse effect Fruit.
The embodiment of the present invention also provides a kind of processing unit of dimension table data, and the processing unit is mainly used in performing this hair The processing method for the dimension table data that bright embodiment the above is provided, the dimension table provided below the embodiment of the present invention The processing unit of data is specifically introduced:
Fig. 2 is the structural representation of the processing unit of the dimension table data of the embodiment of the present invention, as shown in Fig. 2 the device Including establishing unit 10, setting unit 20 and control unit 30:
Unit 10 is established to be used to increase data row in the database belonging to dimension table, wherein, the size of data row is less than First preset value.Specifically, row can be calculated by increasing by one into the database belonging to dimension table by establishing unit, row are calculated It can be by being obtained to other row in database by same calculation formula, calculate row name that row can be non-computational row, often The combination of amount or function or above-mentioned element.But preset value, Analysis should be less than by calculating the length of row Services is limited to be no more than 4GB to the size of text, then the first preset value is not more than 4GB.
Setting unit 20 is used to set the display text attribute of target dimension in dimension table to point to data row.
Control unit 30 is loaded into data again for control dimension table.Because the file format of Key row does not have size limitation, Therefore only change shows the attribute of text attribute.After showing that text attribute points to the data row newly increased, data are loaded into again, Then show that the size of text attribute is equal with the data newly increased row, that is, show that the size of text attribute is no more than preset value.Tool Body, Process Full operations can be performed in Analysis Services, database is loaded into data again.Perform When Process Full are operated, all unique values for showing text attribute are first extracted from database, these values are converted For Analysis Services text formatting.
Further, the processing unit of the dimension table data of the embodiment of the present invention also include acquiring unit, judging unit and Determining unit, wherein:
Acquiring unit is used for the size for obtaining each dimension in dimension table.Due to only having Name to exceed file size Limitation, therefore only obtain and show text attribute size,
Judging unit is used to judge whether the size of each dimension is more than the second preset value respectively, and second preset value can be with More than or equal to the first preset value, but likewise not greater than 4GB.
The dimension that the size that determining unit is used to determine to judge is more than preset value is target dimension.
By the way that the display text attribute of dimension all in dimension table may determine that into dimension compared with default size The display text attribute of which dimension is then arranged these dimensions more than size limitation beyond the limitation of file size in table Handled, i.e., these display text attributes are pointed into newly-increased data row, its size is not broken through the limitation of file size, solve Dimension table data of having determined is well over the problem of limitation, and then reduces the effect that file size limitation brings adverse effect Fruit.
As can be seen from the above description, the present invention solves the problems, such as that dimension table data is well over limitation, and then Reach and reduced the effect that file size limitation brings adverse effect.
Obviously, those skilled in the art should be understood that above-mentioned each module of the invention or each step can be with general Computing device realize that they can be concentrated on single computing device, or be distributed in multiple computing devices and formed Network on, alternatively, they can be realized with the program code that computing device can perform, it is thus possible to they are stored Performed in the storage device by computing device, either they are fabricated to respectively each integrated circuit modules or by they In multiple modules or step be fabricated to single integrated circuit module to realize.So, the present invention is not restricted to any specific Hardware and software combines.
The preferred embodiments of the present invention are the foregoing is only, are not intended to limit the invention, for the skill of this area For art personnel, the present invention can have various modifications and variations.Within the spirit and principles of the invention, that is made any repaiies Change, equivalent substitution, improvement etc., should be included in the scope of the protection.

Claims (6)

  1. A kind of 1. processing method of dimension table data, it is characterised in that including:
    Increase data row in the database belonging to the dimension table, wherein, the size of the data row is less than the first preset value;
    The display text attribute of target dimension in the dimension table is set to point to the data row;And
    The dimension table is controlled to be loaded into data again,
    Wherein, the target dimension is determined in the following manner:
    Obtain the size of each dimension in the dimension table;
    Judge whether the size of each dimension is more than the second preset value respectively, wherein, second preset value is more than or waited In first preset value;And
    It is determined that the dimension that the size judged is more than second preset value is the target dimension,
    Wherein, first preset value and second preset value, which are respectively less than, is equal to 4GB.
  2. 2. the processing method of dimension table data according to claim 1, it is characterised in that the data are classified as calculating row.
  3. 3. the processing method of dimension table data according to claim 1, it is characterised in that the quantity of the target dimension is Multiple, setting the display text attribute of target dimension in the dimension table to point to the data row includes:Each mesh is set The display text attribute of mark dimension is directed to the data row.
  4. A kind of 4. processing unit of dimension table data, it is characterised in that including:
    Unit is established, for increasing data row in the database belonging to the dimension table, wherein, the data arrange big slight In the first preset value;
    Setting unit, the display text attribute for setting target dimension in the dimension table point to the data row;
    And
    Control unit, for controlling the dimension table to be loaded into data again,
    Wherein, the processing unit of the dimension table data also includes:
    Acquiring unit, for obtaining the size of each dimension in the dimension table;
    Judging unit, for judging whether the size of each dimension is more than the second preset value respectively, wherein, described second is pre- If value is more than or equal to first preset value;And
    Determining unit, the dimension that the size for determining to judge is more than second preset value is the target dimension,
    Wherein, first preset value and second preset value, which are respectively less than, is equal to 4GB.
  5. 5. the processing unit of dimension table data according to claim 4, it is characterised in that the data are classified as calculating row.
  6. 6. the processing unit of dimension table data according to claim 4, it is characterised in that the quantity of the target dimension is Multiple, the setting unit is used to set the display text attribute of each target dimension to be directed to the data row.
CN201310544476.7A 2013-11-05 2013-11-05 The treating method and apparatus of dimension table data Active CN103544317B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310544476.7A CN103544317B (en) 2013-11-05 2013-11-05 The treating method and apparatus of dimension table data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310544476.7A CN103544317B (en) 2013-11-05 2013-11-05 The treating method and apparatus of dimension table data

Publications (2)

Publication Number Publication Date
CN103544317A CN103544317A (en) 2014-01-29
CN103544317B true CN103544317B (en) 2017-12-19

Family

ID=49967769

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310544476.7A Active CN103544317B (en) 2013-11-05 2013-11-05 The treating method and apparatus of dimension table data

Country Status (1)

Country Link
CN (1) CN103544317B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104182546B (en) * 2014-09-09 2017-10-27 北京国双科技有限公司 The data query method and device of database
CN108804917B (en) * 2017-12-22 2022-03-18 安天科技集团股份有限公司 File detection method and device, electronic equipment and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102063502A (en) * 2011-01-06 2011-05-18 天津神舟通用数据技术有限公司 Method for realizing synchronization of data in heterogeneous database
CN102171648A (en) * 2008-10-07 2011-08-31 渣普控股有限公司 Synchronization of relational databases with OLAP cubes

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8161374B2 (en) * 2009-10-23 2012-04-17 Microsoft Corporation Butterfly diagrams enabling multi-dimensional performance analysis

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102171648A (en) * 2008-10-07 2011-08-31 渣普控股有限公司 Synchronization of relational databases with OLAP cubes
CN102063502A (en) * 2011-01-06 2011-05-18 天津神舟通用数据技术有限公司 Method for realizing synchronization of data in heterogeneous database

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
"SSAS-String Storage Calculator";CoDe is chronic Farse!;《https://francescodechirico.wordpress.com/2012/07/04/ssas-string-storage-calculator》;20120704;第一页第5段-第一页结束即第2页页首的图片 *
"SSAS系列——【06】多维数据(创建Cube)";蔡辰;《http://www.cnblogs.com/caichen/archive/2010/06/29/1767388.html》;20100629;第1页的"2、创建数据源、数据源视图、维度、定义和部署多维数据集"和"图 按SDK操作界面",第3页-第4页的"b、添加命名计算",第6页的"3、修改度量值、属性和层次结构"和"图 设置显示值" *

Also Published As

Publication number Publication date
CN103544317A (en) 2014-01-29

Similar Documents

Publication Publication Date Title
CN106681921B (en) Method and device for realizing data parameterization
US20160062963A1 (en) Synchronizing DOM Element References
US20150040098A1 (en) Systems and methods for developing and delivering platform adaptive web and native application content
CN108334515A (en) The method, apparatus and system of stack address in file are collapsed in a kind of processing
CN104036187B (en) Method and system for determining computer virus types
CN103888254A (en) Network information verification method and apparatus
CN107885540A (en) A kind of method, apparatus and terminal of loading application programs static resource
CN105760361B (en) A kind of language model method for building up and device
US10503811B2 (en) Acquisition of a font portion using a compression mechanism
CN107908442B (en) Spring-based resource loading method and device, terminal equipment and computer-readable storage medium
KR20170128431A (en) Method and system for user device identification
CN109284326A (en) A kind of data bank access method and device
CN109522332A (en) Customer profile data merging method, device, equipment and readable storage medium storing program for executing
CN110909168A (en) Knowledge graph updating method and device, storage medium and electronic device
CN108255976B (en) Data sorting method and device, storage medium and electronic equipment
CN103544317B (en) The treating method and apparatus of dimension table data
EP2843626A2 (en) Image rendering method using layers
CN106991090A (en) The analysis method and device of public sentiment event entity
CN105302827B (en) A kind of searching method and equipment of event
WO2019041525A1 (en) Method, electronic apparatus, and computer readable storage medium for identifying entities having identical name
CN113128168A (en) Pad parameter checking and correcting method and device, computer equipment and storage medium
CN112306473B (en) Program interface parameter transmission method, system and related equipment
CN108376146A (en) Influence scoring based on domain
CN106844377B (en) Processing method and device of multidimensional database
CN109960553A (en) A kind of more window context rendering methods and system

Legal Events

Date Code Title Description
C06 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
PE01 Entry into force of the registration of the contract for pledge of patent right

Denomination of invention: Dimension table data processing method and device

Effective date of registration: 20190531

Granted publication date: 20171219

Pledgee: Shenzhen Black Horse World Investment Consulting Co.,Ltd.

Pledgor: BEIJING GRIDSUM TECHNOLOGY Co.,Ltd.

Registration number: 2019990000503

PE01 Entry into force of the registration of the contract for pledge of patent right
CP02 Change in the address of a patent holder

Address after: 100083 No. 401, 4th Floor, Haitai Building, 229 North Fourth Ring Road, Haidian District, Beijing

Patentee after: BEIJING GRIDSUM TECHNOLOGY Co.,Ltd.

Address before: 100086 Beijing city Haidian District Shuangyushu Area No. 76 Zhichun Road cuigongfandian 8 layer A

Patentee before: BEIJING GRIDSUM TECHNOLOGY Co.,Ltd.

CP02 Change in the address of a patent holder
PP01 Preservation of patent right

Effective date of registration: 20240604

Granted publication date: 20171219

PP01 Preservation of patent right