CN112182011A - Data operation method and device, electronic equipment and storage medium - Google Patents

Data operation method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112182011A
CN112182011A CN202011037816.3A CN202011037816A CN112182011A CN 112182011 A CN112182011 A CN 112182011A CN 202011037816 A CN202011037816 A CN 202011037816A CN 112182011 A CN112182011 A CN 112182011A
Authority
CN
China
Prior art keywords
data
target
data table
target operation
authority
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202011037816.3A
Other languages
Chinese (zh)
Other versions
CN112182011B (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.)
Ping An Property and Casualty Insurance Company of China Ltd
Original Assignee
Ping An Property and Casualty Insurance Company of China 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 Ping An Property and Casualty Insurance Company of China Ltd filed Critical Ping An Property and Casualty Insurance Company of China Ltd
Priority to CN202011037816.3A priority Critical patent/CN112182011B/en
Publication of CN112182011A publication Critical patent/CN112182011A/en
Application granted granted Critical
Publication of CN112182011B publication Critical patent/CN112182011B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/30Authentication, i.e. establishing the identity or authorisation of security principals
    • G06F21/45Structures or tools for the administration of authentication
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/62Protecting access to data via a platform, e.g. using keys or access control rules
    • G06F21/6218Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Computational Linguistics (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Storage Device Security (AREA)

Abstract

The invention relates to big data technology, and discloses a data operation method, which comprises the following steps: receiving a data operation request of a user, wherein the data operation request comprises a target operation and a target operation data table; acquiring an operation authority data table determined according to the role information of the user; selecting an operation authority data table matched with the target operation as a matched operation data table; inquiring the target operation data in a target operation data table and judging whether the target operation data exists in the matching operation data table or not; if the target operation data exist, performing data processing on the target operation data; and if the target operation data does not exist, sending an operation prompt for prohibiting the target operation from being executed. The invention also provides a data operating device and a storage medium. In addition, the invention also relates to a block chain technology, and the target operation data table can be stored in the block chain node. The invention can improve the efficiency and the safety of data operation.

Description

Data operation method and device, electronic equipment and storage medium
Technical Field
The present invention relates to the field of big data technologies, and in particular, to a data operation method and apparatus, an electronic device, and a computer-readable storage medium.
Background
In the prior art, when data in a system is operated, different data operation authorities are usually configured for different users, for example, in a medical management system, doctors in different departments can only check cases of patients in departments of the department, but a leader layer at an institution level can check all cases, and a patient can only check related cases in the management system. The safety of data stored in the system is improved through the division of data operation permission. However, in this way, when data operation is performed, each time a data operation request is received to perform data operation, roles need to be queried and then data operation needs to be performed, so that the efficiency of data operation is low; moreover, when a user has multiple roles, operations exceeding the data authority corresponding to a specific role may be successfully executed, so that the security of the data operations may be reduced.
Disclosure of Invention
The invention provides a data operation method, a data operation device, electronic equipment and a computer readable storage medium, and mainly aims to improve the efficiency and the safety of data operation.
In order to achieve the above object, the present invention provides a data operation method, including:
receiving a data operation request of a user, wherein the data operation request comprises a target operation and a target operation data table;
acquiring at least two operation authority data tables determined in advance according to the role information of the user;
selecting an operation authority data table matched with the target operation from the at least two pieces of operation authority data as a matched operation data table;
inquiring target operation data in the target operation data table and judging whether the target operation data exists in the matching operation data table or not;
if the target operation data exist in the matching operation data table, performing data processing on the target operation data according to the target operation;
and if the target operation data does not exist in the matching operation data table, sending an operation prompt for forbidding the execution of the target operation.
Optionally, before receiving a data operation request of a user, the method further includes:
acquiring role information of the user;
determining the operation authority of the user according to the role information of the user, wherein the operation authority comprises permission operation and a permission operation data table corresponding to the permission operation;
if the number of the permission operations is at least two and the number of the permission operation data tables corresponding to each permission operation is at least two, the permission operation data tables corresponding to the permission operations of different types are respectively combined into different operation authority data tables to obtain at least two operation authority data tables corresponding to the user.
Optionally, the merging the permission operation data tables corresponding to the different types of permission operations into different operation permission data tables respectively includes:
when the permission operation is query operation, merging repeated data in a plurality of permission operation data tables corresponding to the query operation to obtain an operation authority data table for the query operation; or
When the permission operation is a deletion operation, collecting a plurality of permission operation data tables corresponding to the deletion operation as deletion data tables, and deleting repeated data in the deletion data tables to obtain an operation authority data table for the deletion operation.
Optionally, the determining the operation authority of the user according to the role information of the user includes:
acquiring role identification fields contained in the role information;
and determining the operation authority of the user according to the role identification field.
Optionally, the selecting, from the at least two pieces of operation authority data, an operation authority data table matched with the target operation as a matched operation data table includes:
if the target operation is a query operation, selecting an operation authority data table used for the query operation in the at least two operation authority data tables as the matching operation data table; or
And if the target operation is a deletion operation, selecting the operation authority data table used for the deletion operation from the at least two operation authority data tables as the matching operation data table.
Optionally, the querying the target operation data in a target operation data table and determining whether the target operation data exists in the matching operation data table include:
generating a target query statement according to the target operation data table and the target operation data;
generating a sub-query statement according to the target operation data and the matching operation data table;
merging the sub query statement serving as a constraint condition of the target query statement with the target query statement to obtain a data query statement;
executing the data query statement to obtain a result data set;
if the result data set is not empty, determining that the target operation data exists in the matching operation data table;
and if the result data set is empty, determining that the target operation data does not exist in the matching operation data table.
Optionally, the performing data processing on the target operation data according to the target operation includes:
if the target operation is a query operation, returning the target operation data to the user end equipment;
and if the target operation is a deletion operation, deleting or modifying the target operation data.
In order to solve the above problem, the present invention also provides a data manipulation apparatus, comprising:
the data operation request receiving module is used for receiving a data operation request of a user, wherein the data operation request comprises a target operation and a target operation data table;
the operation authority acquisition module is used for acquiring at least two operation authority data tables which are determined in advance according to the role information of the user;
a matching operation data table determining module, configured to select, from the at least two pieces of operation authority data, an operation authority data table matching the target operation as a matching operation data table;
the target operation data judgment module is used for inquiring target operation data in the target operation data table and judging whether the target operation data exists in the matching operation data table or not;
the data processing module is used for processing the target operation data according to the target operation if the target operation data exists in the matching operation data table;
and the reminding module is used for sending an operation reminding for forbidding the execution of the target operation if the target operation data does not exist in the matching operation data table.
In order to solve the above problem, the present invention also provides an electronic device, including:
a memory storing at least one computer program instruction; and
a processor executing computer program instructions stored in the memory to implement the data manipulation method described above.
In order to solve the above problem, the present invention also provides a computer-readable storage medium storing a computer program, which is executed by a processor to implement the data manipulation method described above.
After receiving a data operation request of a user, the data operation request comprises a target operation and a target operation data table, at least two operation permission data tables determined in advance according to role information of the user are obtained, whether the target operation is performed on target operation data in the target operation table or not is determined directly according to the at least two operation permission data tables, the role of the user does not need to be obtained each time, permission is determined according to the role of the user, and then the data operation is performed according to the permission, so that the efficiency of the data operation is improved; meanwhile, when determining whether to perform the target operation, the embodiment of the invention selects the operation authority data table matched with the target operation from the at least two operation authority data as the matched operation data table, and determines whether to perform the target operation according to whether the target operation data exists in the matched operation data table, but not performs the target operation when the target operation exists in the target operation data table, thereby improving the safety of the operation data. Therefore, the data operation method, the data operation device and the computer readable storage medium provided by the invention can realize the purpose of efficient and safe data operation.
Drawings
Fig. 1 is a schematic flow chart illustrating a data operation method according to an embodiment of the present invention;
FIG. 2 is a block diagram of a data manipulation device according to an embodiment of the present invention;
fig. 3 is a schematic internal structural diagram of an electronic device implementing a data operation method according to an embodiment of the present invention;
the implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The embodiment of the application provides a data operation method. The execution subject of the data operation method includes, but is not limited to, at least one of electronic devices such as a server and a terminal that can be configured to execute the method provided by the embodiments of the present application. In other words, the data operation method may be performed by software or hardware installed in the terminal device or the server device, and the software may be a block chain platform. The server includes but is not limited to: a single server, a server cluster, a cloud server or a cloud server cluster, and the like.
Fig. 1 is a schematic flow chart of a data operation method according to an embodiment of the present invention. In this embodiment, the data operation method includes:
s1, receiving a data operation request of a user, wherein the data operation request comprises a target operation and a target operation data table.
In this embodiment, the data operation request of the user may be a data operation request triggered by the user based on a system client or a front-end page operation, such as a data operation request for viewing data of a certain subsystem or performing operations such as deleting a certain piece of data.
Wherein the data operation request comprises a target operation and a target operation data table. The target operation is a specific operation performed on data by a user, and comprises a query operation and a deletion operation (comprising a modification operation or a deletion operation); the target operation data table is a data table related to target operation data, which is an operation object corresponding to the target operation.
Preferably, the target operational data table is stored in a node of a blockchain.
By storing the target operation data table in the block chain, the safety of the target operation data table can be improved.
Specifically, the data operation request may include a plurality of parameters related to the data operation request, such as a module code, a user ID, a table name, a field name, a start time, an end time, a specified operation, and the like.
Optionally, in this embodiment of the present invention, the target operation may further determine the target operation according to the designated role ID in the parameter set, where the determining specifically includes: judging whether the designated role ID is empty or not; if the designated role ID is null, determining the target operation as a query operation; and if the designated role ID is not null, determining the target operation as a deletion operation.
And S2, acquiring at least two operation authority data tables determined in advance according to the role information of the user.
Preferably, before receiving a data operation request of a user, at least two operation authority data tables corresponding to the user are determined according to role information of the user. Then, when receiving the data operation request of the user each time, at least two operation authority data tables corresponding to the user can be directly obtained.
For example, when a user is created, at least two operation authority data tables corresponding to the user are determined according to the role assigned to the user.
Preferably, before receiving a data operation request of a user, the method further includes:
and determining at least two operation authority data tables corresponding to the user according to the role information of the user.
The determining of the at least two operation authority data tables corresponding to the user according to the role information of the user comprises:
acquiring role information of the user;
determining the operation authority of the user according to the role information of the user, wherein the operation authority comprises permission operation and a permission operation data table corresponding to the permission operation;
if the number of the permission operations is at least two and the number of the permission operation data tables corresponding to each permission operation is at least two, the permission operation data tables corresponding to the permission operations of different types are respectively combined into different operation authority data tables to obtain at least two operation authority data tables corresponding to the user.
Wherein the role information is a set of all roles owned by the user.
Preferably, the permission operation in the embodiment of the present invention includes a query operation and a deletion operation. The operation authority data table correspondingly comprises an operation authority data table used for inquiring operation and an operation authority data table used for deleting operation.
Further, the determining the operation authority of the user according to the role information of the user includes:
acquiring role identification fields contained in the role information;
and determining the operation authority of the user according to the role identification field.
Preferably, the merging the permission operation data tables corresponding to the different types of permission operations into different operation permission data tables respectively includes:
when the permission operation is query operation, merging repeated data in a plurality of permission operation data tables corresponding to the query operation to obtain an operation authority data table for the query operation;
when the permission operation is a deletion operation, collecting a plurality of permission operation data tables corresponding to the deletion operation as deletion data tables, and deleting repeated data in the deletion data tables to obtain an operation authority data table for the deletion operation.
In the embodiment of the invention, when data operation is carried out, the data operation can be directly limited according to the operation authority data without paying attention to the role owned by the user, so that the efficiency of the data operation is improved.
And S3, selecting an operation authority data table matched with the target operation from the at least two operation authority data as a matched operation data table.
In detail, the selecting an operation authority data table matched with the target operation from the at least two operation authority data as a matched operation data table includes:
if the target operation is a query operation, selecting an operation authority data table used for the query operation in the at least two operation authority data tables as the matching operation data table; or
And if the target operation is a deletion operation, selecting the operation authority data table used for the deletion operation from the at least two operation authority data tables as the matching operation data table.
S4, inquiring the target operation data in the target operation data table and judging whether the target operation data is in the matching operation data table.
In the embodiment of the present invention, the target operation data is specific data that needs to be operated in the data operation request, and is also an operation object corresponding to the target operation.
In detail, the S4 includes:
generating a target query statement according to the target operation data table and the target operation data;
generating a sub-query statement according to the target operation data and the matching operation data table;
merging the sub query statement serving as a constraint condition of the target query statement with the target query statement to obtain a data query statement;
executing the data query statement to obtain a result data set;
if the result data set is not empty, determining that the target operation data exists in the matching operation data table;
and if the result data set is empty, determining that the target operation data does not exist in the matching operation data table.
And S5, if the target operation data exist in the matching operation data table, processing the target operation data according to the target operation.
In this embodiment, if the target operation data exists in the matching operation data table, it indicates that the user has a corresponding operation authority for the target operation data, and the target operation data may be further processed.
In detail, the data processing on the target operation data according to the target operation includes:
if the target operation is a query operation, returning the target operation data to the user end equipment;
and if the target operation is a deletion operation, deleting or modifying the target operation data.
And S6, if the target operation data does not exist in the matching operation data table, sending an operation prompt for prohibiting the target operation.
In detail, if the target operation data does not exist in the matching operation data table, it indicates that the user has no operation authority for the target operation data, sends an operation prompt for prohibiting the execution of the target operation, for example, sends a prompt message of "no authority operation", and displays the prompt message on a human-computer interaction interface of a user end device.
After receiving a data operation request of a user, the data operation request comprises a target operation and a target operation data table, at least two operation permission data tables determined in advance according to role information of the user are obtained, whether the target operation is performed on target operation data in the target operation table or not is determined directly according to the at least two operation permission data tables, the role of the user does not need to be obtained each time, permission is determined according to the role of the user, and then the data operation is performed according to the permission, so that the efficiency of the data operation is improved; meanwhile, when determining whether to perform the target operation, the embodiment of the invention selects the operation authority data table matched with the target operation from the at least two operation authority data as the matched operation data table, and determines whether to perform the target operation according to whether the target operation data exists in the matched operation data table, but not performs the target operation when the target operation exists in the target operation data table, thereby improving the safety of the operation data. The data operation method provided by the invention can be applied to the fields of medical science and technology, financial business management and the like, and can realize the purpose of efficient and safe data operation.
Fig. 2 is a functional block diagram of the data manipulation device according to the present invention.
The data operation device 100 of the present invention can be installed in an electronic device. According to the realized functions, the data operation device can comprise a data operation request receiving module 101, an operation authority acquiring module 102, a matching operation data table determining module 103, a target operation data judging module 104, a data processing module 105 and a reminding module 106. A module according to the present invention, which may also be referred to as a unit, refers to a series of computer program segments that can be executed by a processor of an electronic device and that can perform a fixed function, and that are stored in a memory of the electronic device.
In the present embodiment, the functions regarding the respective modules/units are as follows:
the data operation request receiving module 101 is configured to receive a data operation request of a user, where the data operation request includes a target operation and a target operation data table.
In this embodiment, the data operation request of the user may be a data operation request triggered by the user based on a system client or a front-end page operation, such as a data operation request for viewing data of a certain subsystem or performing operations such as deleting a certain piece of data.
Wherein the data operation request comprises a target operation and a target operation data table. The target operation is a specific operation performed on data by a user, and comprises a query operation and a deletion operation (comprising a modification operation or a deletion operation); the target operation data table is a data table related to target operation data, which is an operation object corresponding to the target operation.
Preferably, the target operational data table is stored in a node of a blockchain.
By storing the target operation data table in the block chain, the safety of the target operation data table can be improved.
Specifically, the data operation request may include a plurality of parameters related to the data operation request, such as a module code, a user ID, a table name, a field name, a start time, an end time, a specified operation, and the like.
Optionally, in this embodiment of the present invention, the target operation may further determine the target operation according to the designated role ID in the parameter set, where the determining specifically includes: judging whether the designated role ID is empty or not; if the designated role ID is null, determining the target operation as a query operation; and if the designated role ID is not null, determining the target operation as a deletion operation.
The operation authority obtaining module 102 is configured to obtain at least two operation authority data tables determined in advance according to the role information of the user.
Preferably, before receiving a data operation request of a user, at least two operation authority data tables corresponding to the user are determined according to role information of the user. Then, when receiving the data operation request of the user each time, at least two operation authority data tables corresponding to the user can be directly obtained.
For example, when a user is created, at least two operation authority data tables corresponding to the user are determined according to the role assigned to the user.
Preferably, the apparatus further comprises an operation authority data table determining module, and the operation authority data table determining module comprises:
before receiving a data operation request of a user, determining at least two operation authority data tables corresponding to the user according to role information of the user.
The operation permission data table determination module is specifically configured to:
before receiving a data operation request of a user, acquiring role information of the user;
determining the operation authority of the user according to the role information of the user, wherein the operation authority comprises permission operation and a permission operation data table corresponding to the permission operation;
if the number of the permission operations is at least two and the number of the permission operation data tables corresponding to each permission operation is at least two, the permission operation data tables corresponding to the permission operations of different types are respectively combined into different operation authority data tables to obtain at least two operation authority data tables corresponding to the user.
Wherein the role information is a set of all roles owned by the user.
Preferably, the permission operation in the embodiment of the present invention includes a query operation and a deletion operation. The operation authority data table correspondingly comprises an operation authority data table used for inquiring operation and an operation authority data table used for deleting operation.
Further, the determining the operation authority of the user according to the role information of the user includes:
acquiring role identification fields contained in the role information;
and determining the operation authority of the user according to the role identification field.
Preferably, the merging the permission operation data tables corresponding to the different types of permission operations into different operation permission data tables respectively includes:
when the permission operation is query operation, merging repeated data in a plurality of permission operation data tables corresponding to the query operation to obtain an operation authority data table for the query operation;
when the permission operation is a deletion operation, collecting a plurality of permission operation data tables corresponding to the deletion operation as deletion data tables, and deleting repeated data in the deletion data tables to obtain an operation authority data table for the deletion operation.
In the embodiment of the invention, when data operation is carried out, the data operation can be directly limited according to the operation authority data without paying attention to the role owned by the user, so that the efficiency of the data operation is improved.
The matching operation data table determining module 103 is configured to select an operation authority data table matching the target operation from the at least two pieces of operation authority data as a matching operation data table.
In detail, the matching operation data table determining module 103 is specifically configured to: if the target operation is a query operation, selecting an operation authority data table used for the query operation in the at least two operation authority data tables as the matching operation data table; or
And if the target operation is a deletion operation, selecting the operation authority data table used for the deletion operation from the at least two operation authority data tables as the matching operation data table.
The target operation data determining module 104 is configured to query the target operation data in the target operation data table and determine whether the target operation data exists in the matching operation data table.
In the embodiment of the present invention, the target operation data is specific data that needs to be operated in the data operation request, and is also an operation object corresponding to the target operation.
In detail, the target operation data determining module 104 is specifically configured to:
generating a target query statement according to the target operation data table and the target operation data;
generating a sub-query statement according to the target operation data and the matching operation data table;
merging the sub query statement serving as a constraint condition of the target query statement with the target query statement to obtain a data query statement;
executing the data query statement to obtain a result data set;
if the result data set is not empty, determining that the target operation data exists in the matching operation data table;
and if the result data set is empty, determining that the target operation data does not exist in the matching operation data table.
The data processing module 105, if the target operation data exists in the matching operation data table, performs data processing on the target operation data according to the target operation.
In this embodiment, if the target operation data exists in the matching operation data table, it indicates that the user has a corresponding operation authority for the target operation data, and the target operation data may be further processed.
In detail, the data processing module 105 is specifically configured to:
if the target operation data exist in the matching operation data table and the target operation is query operation, returning the target operation data to the user end equipment;
and if the target operation data exists in the matching operation data table and the target operation is a deleting operation, deleting or modifying the target operation data.
The reminding module 106 is configured to send an operation reminder for prohibiting the target operation from being executed if the target operation data does not exist in the matching operation data table.
In detail, if the target operation data does not exist in the matching operation data table, it indicates that the user has no operation authority for the target operation data, sends an operation prompt for prohibiting the execution of the target operation, for example, sends a prompt message of "no authority operation", and displays the prompt message on a human-computer interaction interface of a user end device.
After receiving a data operation request of a user, the data operation request comprises a target operation and a target operation data table, at least two operation permission data tables determined in advance according to role information of the user are obtained, whether the target operation is performed on target operation data in the target operation table or not is determined directly according to the at least two operation permission data tables, the role of the user does not need to be obtained each time, permission is determined according to the role of the user, and then the data operation is performed according to the permission, so that the efficiency of the data operation is improved; meanwhile, when determining whether to perform the target operation, the embodiment of the invention selects the operation authority data table matched with the target operation from the at least two operation authority data as the matched operation data table, and determines whether to perform the target operation according to whether the target operation data exists in the matched operation data table, but not performs the target operation when the target operation exists in the target operation data table, thereby improving the safety of the operation data. Therefore, the data operation device provided by the invention can realize the purpose of efficient and safe data operation.
Fig. 3 is a schematic structural diagram of an electronic device implementing the data operation method according to the present invention.
The electronic device 1 may comprise a processor 10, a memory 11 and a bus, and may further comprise a computer program, such as a data operating program 12, stored in the memory 11 and executable on the processor 10.
The memory 11 includes at least one type of readable storage medium, which includes flash memory, removable hard disk, multimedia card, card-type memory (e.g., SD or DX memory, etc.), magnetic memory, magnetic disk, optical disk, etc. The memory 11 may in some embodiments be an internal storage unit of the electronic device 1, such as a removable hard disk of the electronic device 1. The memory 11 may also be an external storage device of the electronic device 1 in other embodiments, such as a plug-in mobile hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the electronic device 1. Further, the memory 11 may also include both an internal storage unit and an external storage device of the electronic device 1. The memory 11 may be used not only to store application software installed in the electronic device 1 and various types of data, such as codes of the data operating program 12, but also to temporarily store data that has been output or is to be output.
The processor 10 may be composed of an integrated circuit in some embodiments, for example, a single packaged integrated circuit, or may be composed of a plurality of integrated circuits packaged with the same or different functions, including one or more Central Processing Units (CPUs), microprocessors, digital Processing chips, graphics processors, and combinations of various control chips. The processor 10 is a Control Unit (Control Unit) of the electronic device, connects various components of the electronic device by using various interfaces and lines, and executes various functions and processes data of the electronic device 1 by running or executing programs or modules (e.g., executing data operation programs and the like) stored in the memory 11 and calling data stored in the memory 11.
The bus may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. The bus is arranged to enable connection communication between the memory 11 and at least one processor 10 or the like.
Fig. 3 shows only an electronic device with components, and it will be understood by those skilled in the art that the structure shown in fig. 3 does not constitute a limitation of the electronic device 1, and may comprise fewer or more components than those shown, or some components may be combined, or a different arrangement of components.
For example, although not shown, the electronic device 1 may further include a power supply (such as a battery) for supplying power to each component, and preferably, the power supply may be logically connected to the at least one processor 10 through a power management device, so as to implement functions of charge management, discharge management, power consumption management, and the like through the power management device. The power supply may also include any component of one or more dc or ac power sources, recharging devices, power failure detection circuitry, power converters or inverters, power status indicators, and the like. The electronic device 1 may further include various sensors, a bluetooth module, a Wi-Fi module, and the like, which are not described herein again.
Further, the electronic device 1 may further include a network interface, and optionally, the network interface may include a wired interface and/or a wireless interface (such as a WI-FI interface, a bluetooth interface, etc.), which are generally used for establishing a communication connection between the electronic device 1 and other electronic devices.
Optionally, the electronic device 1 may further comprise a user interface, which may be a Display (Display), an input unit (such as a Keyboard), and optionally a standard wired interface, a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display, which may also be referred to as a display screen or display unit, is suitable for displaying information processed in the electronic device 1 and for displaying a visualized user interface, among other things.
It is to be understood that the described embodiments are for purposes of illustration only and that the scope of the appended claims is not limited to such structures.
The data manipulation program 12 stored in the memory 11 of the electronic device 1 is a combination of instructions that, when executed in the processor 10, enable:
receiving a data operation request of a user, wherein the data operation request comprises a target operation and a target operation data table;
acquiring at least two operation authority data tables determined in advance according to the role information of the user;
selecting an operation authority data table matched with the target operation from the at least two pieces of operation authority data as a matched operation data table;
inquiring target operation data in the target operation data table and judging whether the target operation data exists in the matching operation data table or not;
if the target operation data exist in the matching operation data table, performing data processing on the target operation data according to the target operation;
and if the target operation data does not exist in the matching operation data table, sending an operation prompt for forbidding the execution of the target operation.
Further, the integrated modules/units of the electronic device 1, if implemented in the form of software functional units and sold or used as separate products, may be stored in a computer readable storage medium. The computer-readable medium may include: any entity or device capable of carrying said computer program code, recording medium, U-disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM).
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus, device and method can be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the modules is only one logical functional division, and other divisions may be realized in practice.
The modules described as separate parts may or may not be physically separate, and parts displayed as modules may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
In addition, functional modules in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional module.
It will be evident to those skilled in the art that the invention is not limited to the details of the foregoing illustrative embodiments, and that the present invention may be embodied in other specific forms without departing from the spirit or essential attributes thereof.
The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein. Any accompanying claims should not be construed as limiting the claim concerned.
Furthermore, it is obvious that the word "comprising" does not exclude other elements or steps, and the singular does not exclude the plural. A plurality of units or means recited in the system claims may also be implemented by one unit or means in software or hardware. The terms second, etc. are used to denote names, but not any particular order.
Finally, it should be noted that the above embodiments are only for illustrating the technical solutions of the present invention and not for limiting, and although the present invention is described in detail with reference to the preferred embodiments, it should be understood by those skilled in the art that modifications or equivalent substitutions may be made on the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention.

Claims (10)

1. A method of data manipulation, the method comprising:
receiving a data operation request of a user, wherein the data operation request comprises a target operation and a target operation data table;
acquiring at least two operation authority data tables determined in advance according to the role information of the user;
selecting an operation authority data table matched with the target operation from the at least two pieces of operation authority data as a matched operation data table;
inquiring target operation data in the target operation data table and judging whether the target operation data exists in the matching operation data table or not;
if the target operation data exist in the matching operation data table, performing data processing on the target operation data according to the target operation;
and if the target operation data does not exist in the matching operation data table, sending an operation prompt for forbidding the execution of the target operation.
2. The method of claim 1, wherein prior to receiving the user's request for the data operation, the method further comprises:
acquiring role information of the user;
determining the operation authority of the user according to the role information of the user, wherein the operation authority comprises permission operation and a permission operation data table corresponding to the permission operation;
if the number of the permission operations is at least two and the number of the permission operation data tables corresponding to each permission operation is at least two, the permission operation data tables corresponding to the permission operations of different types are respectively combined into different operation authority data tables to obtain at least two operation authority data tables corresponding to the user.
3. The data operation method of claim 2, wherein the merging the permission operation data tables corresponding to the permission operations of different types into different operation authority data tables respectively comprises:
when the permission operation is query operation, merging repeated data in a plurality of permission operation data tables corresponding to the query operation to obtain an operation authority data table for the query operation; or
When the permission operation is a deletion operation, collecting a plurality of permission operation data tables corresponding to the deletion operation as deletion data tables, and deleting repeated data in the deletion data tables to obtain an operation authority data table for the deletion operation.
4. The data operation method of claim 2, wherein the determining the operation authority of the user according to the role information of the user comprises:
acquiring role identification fields contained in the role information;
and determining the operation authority of the user according to the role identification field.
5. The data operation method of any one of claims 1 to 4, wherein the selecting the operation authority data table matched with the target operation from the at least two operation authority data as a matched operation data table comprises:
if the target operation is a query operation, selecting an operation authority data table used for the query operation in the at least two operation authority data tables as the matching operation data table; or
And if the target operation is a deletion operation, selecting the operation authority data table used for the deletion operation from the at least two operation authority data tables as the matching operation data table.
6. The data manipulation method of any one of claims 1 to 4 wherein said querying target manipulation data in a target manipulation data table and determining whether target manipulation data is present in said matching manipulation data table comprises:
generating a target query statement according to the target operation data table and the target operation data;
generating a sub-query statement according to the target operation data and the matching operation data table;
merging the sub query statement serving as a constraint condition of the target query statement with the target query statement to obtain a data query statement;
executing the data query statement to obtain a result data set;
if the result data set is not empty, determining that the target operation data exists in the matching operation data table;
and if the result data set is empty, determining that the target operation data does not exist in the matching operation data table.
7. The data manipulation method of any one of claims 1 to 4 wherein said data processing of said target manipulation data in accordance with said target manipulation comprises:
if the target operation is a query operation, returning the target operation data to the user end equipment;
and if the target operation is a deletion operation, deleting or modifying the target operation data.
8. A data manipulation device, said device comprising:
the data operation request receiving module is used for receiving a data operation request of a user, wherein the data operation request comprises a target operation and a target operation data table;
the operation authority acquisition module is used for acquiring at least two operation authority data tables which are determined in advance according to the role information of the user;
a matching operation data table determining module, configured to select, from the at least two pieces of operation authority data, an operation authority data table matching the target operation as a matching operation data table;
the target operation data judgment module is used for inquiring target operation data in the target operation data table and judging whether the target operation data exists in the matching operation data table or not;
the data processing module is used for processing the target operation data according to the target operation if the target operation data exists in the matching operation data table;
and the reminding module is used for sending an operation reminding for forbidding the execution of the target operation if the target operation data does not exist in the matching operation data table.
9. An electronic device, characterized in that the electronic device comprises:
a memory storing at least one computer program instruction; and
a processor executing computer program instructions stored in the memory to perform a method of data manipulation according to any of claims 1 to 7.
10. A computer-readable storage medium, storing a computer program, wherein the computer program, when executed by a processor, implements a data manipulation method according to any one of claims 1 to 7.
CN202011037816.3A 2020-09-28 2020-09-28 Data operation method, device, electronic equipment and storage medium Active CN112182011B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011037816.3A CN112182011B (en) 2020-09-28 2020-09-28 Data operation method, device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011037816.3A CN112182011B (en) 2020-09-28 2020-09-28 Data operation method, device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112182011A true CN112182011A (en) 2021-01-05
CN112182011B CN112182011B (en) 2023-08-15

Family

ID=73945289

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011037816.3A Active CN112182011B (en) 2020-09-28 2020-09-28 Data operation method, device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112182011B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106484892A (en) * 2016-10-19 2017-03-08 凌云天博光电科技股份有限公司 Data manipulation method and device
CN107545047A (en) * 2017-08-17 2018-01-05 平安科技(深圳)有限公司 The querying method and terminal device of user right data
CN109409119A (en) * 2017-08-17 2019-03-01 北京京东尚科信息技术有限公司 Data manipulation method and device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106484892A (en) * 2016-10-19 2017-03-08 凌云天博光电科技股份有限公司 Data manipulation method and device
CN107545047A (en) * 2017-08-17 2018-01-05 平安科技(深圳)有限公司 The querying method and terminal device of user right data
CN109409119A (en) * 2017-08-17 2019-03-01 北京京东尚科信息技术有限公司 Data manipulation method and device

Also Published As

Publication number Publication date
CN112182011B (en) 2023-08-15

Similar Documents

Publication Publication Date Title
CN111400363A (en) Index data processing method and device, electronic equipment and storage medium
CN113239106B (en) Excel file export method and device, electronic equipment and storage medium
CN111932562A (en) Image identification method and device based on CT sequence, electronic equipment and medium
CN114979120B (en) Data uploading method, device, equipment and storage medium
CN113434901A (en) Intelligent data query method and device, electronic equipment and storage medium
CN113506045A (en) Risk user identification method, device, equipment and medium based on mobile equipment
CN112256783A (en) Data export method and device, electronic equipment and storage medium
CN112015815A (en) Data synchronization method, device and computer readable storage medium
CN115129753A (en) Data blood relationship analysis method and device, electronic equipment and storage medium
CN114491646A (en) Data desensitization method and device, electronic equipment and storage medium
CN111858604B (en) Data storage method and device, electronic equipment and storage medium
CN113468175A (en) Data compression method and device, electronic equipment and storage medium
CN111985194A (en) Data storage method and device, electronic equipment and storage medium
CN111932147A (en) Visualization method and device for overall index, electronic equipment and storage medium
CN112182011B (en) Data operation method, device, electronic equipment and storage medium
CN114201466B (en) Anti-cache breakdown method, device, equipment and readable storage medium
CN113515265B (en) Site configuration method, device, equipment and computer readable storage medium
CN114547011A (en) Data extraction method and device, electronic equipment and storage medium
CN114911479A (en) Interface generation method, device, equipment and storage medium based on configuration
CN114491196A (en) Information granularity-based information export method, device, equipment and medium
CN113342867A (en) Data distribution and management method and device, electronic equipment and readable storage medium
CN114820132A (en) Order distribution method and device, electronic equipment and storage medium
CN114547696A (en) File desensitization method and device, electronic equipment and storage medium
CN114611046A (en) Data loading method, device, equipment and medium
CN114185776A (en) Big data point burying method, device, equipment and medium for application program

Legal Events

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