CN106909633A - A kind of data by oracle database imported into the method and system of mongodb databases - Google Patents
A kind of data by oracle database imported into the method and system of mongodb databases Download PDFInfo
- Publication number
- CN106909633A CN106909633A CN201710059105.8A CN201710059105A CN106909633A CN 106909633 A CN106909633 A CN 106909633A CN 201710059105 A CN201710059105 A CN 201710059105A CN 106909633 A CN106909633 A CN 106909633A
- Authority
- CN
- China
- Prior art keywords
- data
- imported
- tables
- databases
- bson
- 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
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/25—Integrating or interfacing systems involving database management systems
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/27—Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
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)
- Computing Systems (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The present invention relates to the method and system that a kind of data by oracle database imported into mongodb databases, the method includes:Read SQL configuration and bson forms are configured in internal memory;Configured by SQL derived tables of data will be imported into text from oracle database;It is bson forms that the data table transmition that will be imported into text is configured by bson forms;The host node of mongodb databases is searched by the configuration of mongodb databases, and performs tables of data import operation on the primary node, be converted into the tables of data of bson forms and imported into mongdb databases.A kind of system is further related to, the system includes:Information collocation module, info conversion module, information import modul.By present invention eliminates a large amount of manually-operated intermediate links, and can control to imported into the data structure of mongodb databases, simplify the operation that table data are moved in mongodb databases by oracle database, reduce the complexity of Data Migration, save time cost.
Description
Technical field
The present invention relates to the technical field of Data Migration, more particularly to a kind of data by oracle database are imported
To the method and system of mongodb databases.
Background technology
In present technology, as business item develops, demand is by the part table Data Migration mongodb numbers in oracle
According to storehouse, but it is imported into mongodb databases from oracle database, does not have the technology of ready-made completion whole flow process.Often
Secondary first all to be derived from oracle step by step by hand, then in mongodb databases are imported into, complex steps, operation is multiple
It is miscellaneous, import the data structure also bad control of mongodb databases.Therefore, simplify oracle data and imported into mongodb data
The step of during storehouse, the importing of data is realized by simple configuration, control imported into the data structure of mongodb databases
Become extremely urgent.
The content of the invention
The technical problems to be solved by the invention are:Current oracle data imported into mongodb data base procedures complexity,
And import the more difficult control of the data structure of mongodb databases.
To solve technical problem above, it is imported into the invention provides a kind of data by oracle database
The method of mongodb databases, the method comprises the following steps:
S1, configured by SQL derived tables of data will imported into text from oracle database
In;
S2, it is the tables of data of bson forms to configure the data table transmition that will be imported into text by bson forms;
S3, searches the host node of mongodb databases, and perform on the primary node by the configuration of mongodb databases
Tables of data import operation, is converted into the tables of data of bson forms and imported into mongdb databases.
Further, also include in the step S1:Read SQL configuration and bson forms are configured to internal memory
In.
Further, described SQL configuration and the configuration of bson forms is read using shell scripts.
Further, also include in the S2:Be converted to the data in the tables of data holding bson form configurations of bson forms
Structure.
Further, the S2 includes:By the derived tables of data from oracle database be converted to bson forms
Tables of data, carries out the contrast of data volume, and when contrast occurs inconsistent, return re-executes the process of step S1.
Above-mentioned further beneficial effect:It is able to ensure that data are not lost, if go out active can notify in time, data
Completely it is guaranteed.
Further, after tables of data is imported into mongdb databases in S3, verification is imported into mongdb databases
Whether tables of data is consistent with the tables of data of bson forms.
Beneficial effect:Eliminate a large amount of manually-operated intermediate links, it is possible to which control imported into mongodb databases
Data structure, simplifies the operation that table data are moved in mongodb databases by oracle, reduces the complexity of Data Migration
Degree, saves time cost.
The invention further relates to the system that a kind of data by oracle database imported into mongodb databases, this is
System includes:Information collocation module, info conversion module, information import modul;Described reading information collocation module, information conversion
Module, information import modul are sequentially connected;Information collocation module, matches somebody with somebody for reading SQL configuration and bson forms
In putting internal memory;Info conversion module, for will from oracle database derived data table transmition data form;Information is led
Enter the tables of data after module will be changed by info conversion module to imported into mongdb databases.
Further, described information collocation module includes:SQL dispensing unit and the configuration of bson forms are single
Unit, the SQL dispensing unit, is configured in internal memory for reading SQL;Bson forms are configured
Unit, is configured in internal memory for reading bson forms.
Further, described info conversion module includes:SQL converting unit and the conversion of bson forms are single
Unit, described SQL converting unit derived tables of data will imported into text from oracle database
In;Data table transmition in text is bson formatted data tables by described bson format conversion units.
Further, after described information import modul is additionally operable to imported into tables of data in mongdb databases, verification is led
Enter whether consistent with the tables of data of bson forms to the tables of data in mongdb databases.
Beneficial effects of the present invention:Using such data import system, a large amount of manually-operated intermediate links are eliminated,
And can control to imported into the data structure of mongodb databases, simplify table data and mongodb databases are moved to by oracle
In operation, reduce the complexity of Data Migration, save time cost.
Brief description of the drawings
Fig. 1 is the method flow that a kind of data by oracle database of the invention imported into mongodb databases
Schematic diagram;
Fig. 2 is the system signal that a kind of data by oracle database of the invention imported into mongodb databases
Figure.
Specific embodiment
Principle of the invention and feature are described below in conjunction with accompanying drawing, example is served only for explaining the present invention, and
It is non-for limiting the scope of the present invention.
As shown in figure 1, a kind of method that data by oracle database imported into mongodb databases, the method
Comprise the following steps:
First, by using shell scripts with read oracle database it is related SQL configuration and
Bson forms are configured in internal memory;
Then, configure and will be derived from oracle database using oraclespool methods by SQL
Tables of data imported into text;
Secondly, it is bson forms to be configured the data table transmition in text by bson forms, while being changed to bson
The tables of data of form to keep bson forms configure in data structure, in addition when will from oracle database derived data
Table carries out the contrast of data volume with the tables of data for being converted to bson forms, when contrast occurs inconsistent, can exit importing
Process;
Finally, the host node of mongodb databases is searched by the configuration of mongodb databases, and is held on the primary node
Row tables of data import operation, the tables of data for being converted into bson forms by mongoimport is imported into mongodb, by number
After being imported into mongdb databases according to table, verification imported into the tables of data of the tables of data and bson forms in mongdb databases
It is whether consistent, step S1 is restarted when inconsistent.
As shown in Fig. 2 the system that a kind of data by oracle database imported into mongodb databases, the system
Including:Information collocation module, info conversion module, information import modul;Described reading information collocation module, information modulus of conversion
Block, information import modul are sequentially connected;Information collocation module, for reading SQL configuration and the configuration of bson forms
To in internal memory;Info conversion module, for will from oracle database derived data table transmition data form;Information is imported
Tables of data after module will be changed by info conversion module is imported into mongdb databases.
Information collocation module includes:SQL dispensing unit and bson form dispensing units, the structuring
Query language dispensing unit, is configured in internal memory for reading SQL;Bson form dispensing units, for reading
Bson forms are configured in internal memory.
Info conversion module includes:SQL converting unit and bson format conversion units, described structure
Change query language converting unit derived tables of data will imported into text from oracle database;Described bson lattice
Data table transmition in text is bson formatted data tables by formula converting unit.
After information import modul is additionally operable to imported into tables of data in mongdb databases, verification imported into mongdb data
Whether the tables of data in storehouse is consistent with the tables of data of bson forms.
In this manual, the schematic representation to above-mentioned term is necessarily directed to identical embodiment or example.
And, the specific features of description, structure, material or feature can be in any one or more embodiments or example with suitable
Mode is combined.Additionally, in the case of not conflicting, those skilled in the art can be by the difference described in this specification
The feature of embodiment or example and different embodiments or example is combined and combines.
The foregoing is only presently preferred embodiments of the present invention, be not intended to limit the invention, it is all it is of the invention spirit and
Within principle, any modification, equivalent substitution and improvements made etc. should be included within the scope of the present invention.
Claims (10)
1. a kind of method that data by oracle database imported into mongodb databases, it is characterised in that the method bag
Include following steps:
S1, will derive tables of data from oracle database and imported into text by SQL configuration;
S2, it is the tables of data of bson forms to be configured the data table transmition in text by bson forms;
S3, searches the host node of mongodb databases, and perform data on the primary node by the configuration of mongodb databases
Table import operation, is converted into the tables of data of bson forms and imported into mongdb databases.
2. the method that a kind of data by oracle database according to claim 1 imported into mongodb databases,
Characterized in that, also including in the step S1:Read SQL configuration and bson forms are configured in internal memory.
3. the method that a kind of data by oracle database according to claim 2 imported into mongodb databases,
Characterized in that, described SQL configuration and the configuration of bson forms are read using shell scripts.
4. a kind of data by oracle database according to claim 1 or 3 imported into the side of mongodb databases
Method, it is characterised in that also include in the S2:Be converted to the tables of data of bson forms to keep bson forms configure in data
Structure.
5. the method that a kind of data by oracle database according to claim 4 imported into mongodb databases,
Characterized in that, the S2 includes:By the derived tables of data from oracle database and the data for being converted to bson forms
Table, carries out the contrast of data volume, when contrast occurs inconsistent, return to step S1.
6. the method that a kind of data by oracle database according to claim 5 imported into mongodb databases,
Characterized in that, in step S3, after tables of data is imported into mongdb databases, verification is imported into mongdb databases
Whether tables of data is consistent with the tables of data of bson forms.
7. a kind of system that data by oracle database imported into mongodb databases, it is characterised in that the system bag
Include:Information collocation module, info conversion module, information import modul;Described reading information collocation module, information modulus of conversion
Block, information import modul are sequentially connected;Information collocation module, for reading SQL configuration and the configuration of bson forms
To in internal memory;Info conversion module, for will derived data table transmition be bson data forms from oracle database;Letter
Tables of data after breath import modul will be changed by info conversion module is imported into mongdb databases.
8. the system that a kind of data by oracle database according to claim 7 imported into mongodb databases,
Characterized in that, described information collocation module includes:SQL dispensing unit and bson form dispensing units, institute
SQL dispensing unit is stated, is configured in internal memory for reading SQL;Bson form dispensing units,
It is configured in internal memory for reading bson forms.
9. the system that a kind of data by oracle database according to claim 8 imported into mongodb databases,
Characterized in that, described info conversion module includes:SQL converting unit and bson format conversion units, institute
The SQL converting unit stated derived tables of data will be imported into text from oracle database;It is described
Bson format conversion units by the data table transmition in text for bson forms tables of data.
10. what a kind of data by oracle database according to claim 9 imported into mongodb databases is
System, it is characterised in that after described information import modul is additionally operable to imported into tables of data in mongdb databases, verification is imported
It is whether consistent with the tables of data of bson forms to the tables of data in mongdb databases.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710059105.8A CN106909633A (en) | 2017-01-23 | 2017-01-23 | A kind of data by oracle database imported into the method and system of mongodb databases |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710059105.8A CN106909633A (en) | 2017-01-23 | 2017-01-23 | A kind of data by oracle database imported into the method and system of mongodb databases |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106909633A true CN106909633A (en) | 2017-06-30 |
Family
ID=59207698
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710059105.8A Pending CN106909633A (en) | 2017-01-23 | 2017-01-23 | A kind of data by oracle database imported into the method and system of mongodb databases |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106909633A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109189761A (en) * | 2018-08-31 | 2019-01-11 | 中国农业银行股份有限公司 | A kind of data migration method and device |
CN109522307A (en) * | 2018-09-25 | 2019-03-26 | 中国平安人寿保险股份有限公司 | Server, the declaration form data query method based on Mongodb and storage medium |
CN114138714A (en) * | 2022-02-08 | 2022-03-04 | 上海金仕达软件科技有限公司 | Data migration method and device, storage medium and electronic equipment |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102982130A (en) * | 2012-11-16 | 2013-03-20 | 深圳市融创天下科技股份有限公司 | Synchronized method for not only structured query language (NOSQL) and relational database management system (RDBMS) database and system thereof |
CN103309945A (en) * | 2013-05-15 | 2013-09-18 | 上海证券交易所 | Device for importing data to database |
CN103914458A (en) * | 2012-12-29 | 2014-07-09 | 中国移动通信集团河北有限公司 | Mass data migration method and device |
CN105373599A (en) * | 2015-10-28 | 2016-03-02 | 北京汇商融通信息技术有限公司 | Data migration system based on various data storage platforms |
US20160188710A1 (en) * | 2014-12-29 | 2016-06-30 | Wipro Limited | METHOD AND SYSTEM FOR MIGRATING DATA TO NOT ONLY STRUCTURED QUERY LANGUAGE (NoSOL) DATABASE |
-
2017
- 2017-01-23 CN CN201710059105.8A patent/CN106909633A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102982130A (en) * | 2012-11-16 | 2013-03-20 | 深圳市融创天下科技股份有限公司 | Synchronized method for not only structured query language (NOSQL) and relational database management system (RDBMS) database and system thereof |
CN103914458A (en) * | 2012-12-29 | 2014-07-09 | 中国移动通信集团河北有限公司 | Mass data migration method and device |
CN103309945A (en) * | 2013-05-15 | 2013-09-18 | 上海证券交易所 | Device for importing data to database |
US20160188710A1 (en) * | 2014-12-29 | 2016-06-30 | Wipro Limited | METHOD AND SYSTEM FOR MIGRATING DATA TO NOT ONLY STRUCTURED QUERY LANGUAGE (NoSOL) DATABASE |
CN105373599A (en) * | 2015-10-28 | 2016-03-02 | 北京汇商融通信息技术有限公司 | Data migration system based on various data storage platforms |
Non-Patent Citations (1)
Title |
---|
C209ZHANG: "Oracle数据库如何导入到mongodb当中", 《百度知道》 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109189761A (en) * | 2018-08-31 | 2019-01-11 | 中国农业银行股份有限公司 | A kind of data migration method and device |
CN109522307A (en) * | 2018-09-25 | 2019-03-26 | 中国平安人寿保险股份有限公司 | Server, the declaration form data query method based on Mongodb and storage medium |
CN114138714A (en) * | 2022-02-08 | 2022-03-04 | 上海金仕达软件科技有限公司 | Data migration method and device, storage medium and electronic equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104123374B (en) | The method and device of aggregate query in distributed data base | |
CN106909633A (en) | A kind of data by oracle database imported into the method and system of mongodb databases | |
US20160092527A1 (en) | Data processing apparatus and data mapping method thereof | |
CN103488752B (en) | A kind of search method of POI intelligent retrievals | |
CN105373469A (en) | Interface based software automation test method | |
CN103577591B (en) | Method and device for generating accounting voucher | |
CN106250543A (en) | A kind of automation data inquiry synchronous storage method | |
JP6850806B2 (en) | Annotation system for extracting attributes from electronic data structures | |
CN107783950A (en) | Package insert processing method and processing device | |
CN104298769B (en) | Domain variance data synchronization system and method are had between a kind of database | |
CN104750795A (en) | Intelligent semantic searching system and method | |
CN106547729A (en) | A kind of dynamic creation method and system of data sheet | |
CN112328675A (en) | Heterogeneous data conversion method, device, equipment and storage medium | |
CN101174237B (en) | Automatic test method, system and test device | |
CN103605663B (en) | General database checking and metadata loading method | |
CN110442516A (en) | Information processing method, equipment and computer readable storage medium | |
US20170052882A1 (en) | Test scenario generation support device and test scenario generation support method | |
CN111460019A (en) | Data conversion method and middleware of heterogeneous data source | |
CN103095726A (en) | Processing method and device of protocol interpreter | |
CN104657554B (en) | A kind of rocket threedimensional model design information quick extraction system | |
CN105335466A (en) | Audio data retrieval method and apparatus | |
CN106503457B (en) | Clinical data based on translational medicine analysis platform integrates technical data introduction method | |
CN107798139A (en) | A kind of master/slave data isomery method based on CIM/XML | |
CN107451114A (en) | A kind of archaic Chinese semantic analysis and its system | |
CN102135954A (en) | Method for describing bill conversion relationships in service management software based on extensive markup language (XML) |
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 | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170630 |