PHP-based method for realizing dynamic storage of media asset cataloguing metadata

By introducing the structure of attribute tables and attribute group tables, and dynamically configuring the metadata structure, the problem of poor performance of metadata databases when processing multiple types of metadata is solved, realizing efficient organization and flexible management of metadata, and improving query performance and data consistency.

CN122019528APending Publication Date: 2026-05-12SHANGHAI MEDIA TECH
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHANGHAI MEDIA TECH
Filing Date
2025-12-17
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

Existing metadata databases have poor performance when processing multiple types of metadata, with inconsistent data and weak type constraints, which affects query performance.

Method used

It adopts an attribute table and attribute group table structure, supports dynamic configuration of metadata, stores metadata attribute information through the attribute table, and organizes similar attributes through the attribute group table, so as to realize dynamic adjustment of the metadata structure and adapt to different business needs without modifying the code.

Benefits of technology

It improves support for and effective correlation of different types of metadata structures, enhances query performance, and ensures data consistency and system flexibility.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122019528A_ABST
    Figure CN122019528A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of databases, in particular to a PHP-based method for realizing dynamic storage of media asset cataloguing metadata, which comprises the following steps: for newly added metadata, creating a primary key ID field of a data table and setting a material index associated with media asset materials; extracting attribute information from the metadata, and configuring field information according to the attribute information; and establishing an attribute table corresponding to the metadata according to the field information, and organizing the attribute table into an attribute group table. Aiming at the problem that a metadata database in the prior art is poor in performance during processing of multi-type metadata, effective organization of the metadata is realized by introducing an attribute table and an attribute group table, dynamic configuration of a metadata structure is supported, different business requirements can be met without code modification, and the dynamic configuration of the metadata structure is supported. The support for different types of metadata structures is improved, and effective association for multiple types of metadata is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of database technology, and specifically to a method for dynamically storing media asset cataloging metadata based on PHP. Background Technology

[0002] With the explosive growth of digital media content, media resource management systems have been widely used in broadcasting, new media, education and training, and other fields. Metadata, as core data describing information such as the content, format, and source of media resources, is managed in a way that directly impacts the flexibility and scalability of the entire system.

[0003] With the explosive growth of digital media content, media resource management systems have been widely used in broadcasting, new media, education and training, and other fields. Metadata, as core data describing information such as the content, format, and source of media resources, is managed in a way that directly impacts the flexibility and scalability of the entire system.

[0004] For example, patent application CN202211213840.7 discloses a metadata storage method, apparatus, and database. The method is applied to a database, which includes at least one storage group (SG) for storing metadata and a service interface. Each SG is paired with multiple storage nodes (DSDs), and each SG includes a master storage node. The master storage node is used to write metadata sent by a client into the DSD paired with that SG. The method includes: determining the storage service to which the metadata belongs as a target storage service; obtaining metadata storage consistency conditions set for the target storage service through the service interface; and if the metadata already written to the DSD by the master storage node satisfies the metadata storage consistency conditions, then sending a storage result indicating that the metadata has been successfully stored to the client through the master storage node. This improves the applicability of the database.

[0005] For example, patent application CN202080004394.1 discloses a system, method, and apparatus for organizing multi-level metadata in a database system. One system includes multiple shared storage devices that jointly store database data across multiple tables, each table comprising one or more micro-partitions constituting an immutable storage device. The system includes a resource manager configured to manage the storage of database data stored in tables across one or more of the multiple shared storage devices. The resource manager is configured to manage the storage of metadata for the tables. The metadata includes list representation attributes having information about data stored in columns, micro-partition representation attributes having information about data stored in micro-partitions, group representation attributes having information about data stored in two or more micro-partitions, and cumulative table metadata having global information about all micro-partitions of the table.

[0006] However, in actual implementation, the inventors found that this type of technical solution is prone to data inconsistency and weak data type constraints when dealing with metadata that has an unstable structure, large data volume, and diverse types, which affects query performance. Summary of the Invention

[0007] To address the aforementioned problems in existing technologies, a method for dynamically storing media asset cataloging metadata based on PHP is provided.

[0008] The specific technical solution is as follows: A method for dynamically storing media asset cataloging metadata based on PHP includes a table creation process, which includes: Step A1: For the newly added metadata, create a primary key ID field in the data table and set a material index associated with the media asset material; Step A2: Extract attribute information from the metadata and configure field information according to the attribute information; Step A3: Create an attribute table corresponding to the metadata based on the field information and organize the attribute table into the attribute group table.

[0009] On the other hand, it also includes a table update process, which includes: Step B1: Extract the attribute information from the newly added metadata, and match the corresponding attribute group table and attribute table in sequence according to the attribute information; Step B2: Extract historical attribute configuration information from the existing attribute table; Step B3: Modify the historical attribute configuration information according to the attribute information, and store the newly added metadata.

[0010] On the other hand, in step A3, the attribute table includes: attribute ID, field name, attribute name, data type, component style, attribute length, controlled word ID, creation time, and update time; The attribute group table includes: attribute group ID, attribute group table name, attribute group name, creation time, and update time; In step A3, the association between the attribute group and the attribute table is established using the attribute group attribute association table.

[0011] On the other hand, step A2 includes: Step A21: Parse the metadata to obtain the attribute information; Step A22: Create corresponding business fields one by one according to the attribute information, and parse the data type corresponding to the business fields; Step A23: Add the business field to the field information and automatically map the corresponding field type according to the data type.

[0012] On the other hand, step B3 includes: Step B31: Compare the historical attribute configuration information and the attribute information to confirm the differences; Step B32: Match the corresponding update strategy based on the difference data; The update strategy includes adding attributes, deleting attributes, and modifying attributes; Step B33: Modify the difference data sequentially according to the update strategy, and store the newly added metadata.

[0013] On the other hand, when the deletion of an attribute is triggered in step B32, step B33 includes: The differential data is searched for correlation information, and the existence of sub-dependencies is confirmed based on the correlation information. If no sub-dependency exists, the differential data is deleted. The sub-dependencies include whether they are referenced by any metadata category, whether they are contained in any attribute group, and whether there is a corresponding data record in the data table.

[0014] On the other hand, in step B1, when multiple attribute group tables or attribute tables are matched, the process of executing step B3 further includes: Step B031: Start a database transaction for the attribute group table or the attribute table and record the modification actions; Step B032: When a modification action is triggered, perform a status check on the attribute group table or the attribute table, and retain the changes only if the operation result meets expectations; Step B033: Return to step B032 until all the modification actions have been performed.

[0015] On the other hand, it also includes a display process, which includes: Step C1: Extract the attribute information from the attribute table, and match the corresponding controlled word from the controlled word dictionary according to the attribute information; Step C2: Maintain a controlled word list according to the controlled words, and establish the association between the controlled words and the attribute information; Step C3: Generate and display front-end tags using the controlled vocabulary.

[0016] A storage medium includes computer instructions that, when executed by a computer device, perform the method described above.

[0017] The above technical solution has the following advantages or beneficial effects: To address the issue of poor performance in existing metadata databases when processing multiple types of metadata, this paper introduces attribute tables and attribute group tables to achieve effective organization of metadata, support dynamic configuration of metadata structures, and adapt to different business needs without modifying the code. This improves support for different types of metadata structures and enhances the effective association of multiple types of metadata. Attached Figure Description

[0018] Embodiments of the invention will be described more fully with reference to the accompanying drawings. However, the drawings are for illustration and explanation only and do not constitute a limitation on the scope of the invention.

[0019] Figure 1 This is a schematic diagram of the table creation process according to an embodiment of the present invention; Figure 2 This is a schematic diagram of the table update process in an embodiment of the present invention; Figure 3 This is a schematic diagram of step A2 in an embodiment of the present invention; Figure 4 This is a schematic diagram of step B3 in an embodiment of the present invention; Figure 5 This is a schematic diagram of the transaction control process in an embodiment of the present invention; Figure 6 This is a schematic diagram showing the process in an embodiment of the present invention; Detailed Implementation

[0020] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0021] It should be noted that, unless otherwise specified, the embodiments and features described in the present invention can be combined with each other.

[0022] The present invention will be further described below with reference to the accompanying drawings and specific embodiments, but this is not intended to limit the scope of the invention.

[0023] This invention includes: A method for dynamically storing media asset cataloging metadata based on PHP, such as Figure 1 As shown, this includes the table creation process, which includes: Step A1: For the newly added metadata, create a primary key ID field in the data table and set a material index associated with the media asset material; Step A2: Extract attribute information from the metadata and configure field information according to the attribute information; Step A3: Create attribute tables corresponding to the metadata based on the field information, and organize attribute tables with similar attribute information into attribute group tables.

[0024] like Figure 2 As shown, it also includes a table update process, which includes: Step B1: Extract attribute information from the newly added metadata, and match the corresponding attribute group table and attribute table in sequence based on the attribute information; Step B2: Extract historical attribute configuration information from the existing attribute table; Step B3: Modify the historical attribute configuration information based on the attribute information and store the newly added metadata.

[0025] Specifically, addressing the issue of poor performance in existing metadata databases when processing multiple types of metadata, this paper introduces attribute tables and attribute group tables to achieve effective organization of metadata, support dynamic configuration of metadata structures, adapt to different business needs without modifying the code, improve support for different types of metadata structures, and enhance the effective association of multiple types of metadata.

[0026] Specifically, to achieve effective organization of metadata, this solution constructs an attribute table and an attribute group table for maintaining approximate attributes.

[0027] Regarding the attribute table (sc_metadata_properties): The attribute table is the core of the entire system, storing all available metadata attribute definitions. Each attribute contains complete configuration information to guide the creation of dynamic table structures and data storage constraints.

[0028] The structure of the attribute table includes the following fields: attribute ID (property_id), field name (field name), attribute name (property_name), data type (data_type), component style (property_style), attribute length (property_length), controlled word ID (dictionary_id), creation time (created_at), and update time (updated_at).

[0029] Field names follow the format of "field_" followed by a numeric sequence, such as "field_1" and "field_2", ensuring uniqueness and standardization as field names within the database. When creating a new attribute, the system automatically queries the largest sequence number and increments it.

[0030] Data types support multiple formats, each corresponding to a different database field type: • String: A string type that maps to a VARCHAR field and supports maximum length configuration. • Number: A numeric type, mapped to an INT field, supporting minimum and maximum value constraints. • Date: Date type, mapped to a DATE field, formatted as YYYY-MM-DD • Datetime: Date and time type, mapped to a DATETIME field, accurate to the second. • Text: Long text type, mapped to a LONGTEXT field. • LW: Controlled word type, stores the value of the controlled word, associated with dictionary_id. • Json: JSON type, mapped to JSON fields, supports complex data structures. The component styles support single-line input boxes, long text input boxes, number input boxes, drop-down radio selectors, drop-down multi-selectors, cascading selectors, date selectors, and date and time selectors.

[0031] Regarding the attribute group table (sc_metadata_propertygroups): Attribute group tables are used to organize related attributes together to form a reusable set of attributes, and are particularly suitable for data entry in tabular form.

[0032] The structure of the property group table includes the following fields: property group ID (propertygroup_id), property group table name (propertygroup_code), property group name (propertygroup_name), creation time (created_at), and update time (updated_at).

[0033] The attribute group table names use the prefix "cob_ag_", such as "cob_ag_basic" and "cob_ag_technical", to ensure the uniqueness and standardization of the field names in the database and to create the corresponding storage tables. Each attribute group has its own independent data table, and the table structure is dynamically generated based on the attributes within the group.

[0034] The association between attribute groups and attributes is managed through the attribute group attribute association table. The structure of the attribute group attribute association table includes the following fields: primary key ID (id), attribute group ID (propertygroup_id), attribute ID (property_id), attribute alias (alias), sort number (index_num), creation time (created_at), and update time (updated_at).

[0035] Based on the above settings, when metadata that needs to be stored appears, the information of the metadata is first extracted, and the attribute group table is searched to determine whether a relevant attribute table already exists that can be used to store the metadata of that group. If it does not exist, the table creation process is triggered. If it exists, the table update process is triggered.

[0036] When new metadata needs to be added, a primary key ID field is created in the data table to establish the attribute table. Simultaneously, a preset field, "Unique ID for Media Asset," is added for the corresponding media asset, and a default index is set to record the association between the metadata and the asset.

[0037] In one embodiment, such as Figure 3 As shown, step A2 includes: Step A21: Parse the metadata to obtain attribute information; Step A22: Create the corresponding business fields one by one according to the attribute information, and parse the data type corresponding to the business fields; Step A23: Add the business fields to the field information and automatically map the corresponding field types according to the data types.

[0038] Specifically, to add metadata, after establishing the primary key, corresponding business fields are created one by one according to the attribute configuration of the metadata category. The data type of the attribute is parsed and automatically mapped to the corresponding field type of the data storage. For example, string type is mapped to VARCHAR, number type is mapped to INT, date type is mapped to DATE, date and time type is mapped to DATETIME, long text type is mapped to LONGTEXT, controlled word type is mapped to VARCHAR, and JSON type is mapped to JSON. During the process of adding attributes, the maximum length constraint of the field is set according to the attribute length.

[0039] In step A3, the above field information is first added to the attribute table, and then the attribute tables with similar attribute information are added to the attribute group table.

[0040] This process relies on the metadata category table (sc_metadata_category) and the metadata category attribute association table (sc_metadata_category_properties): The metadata category table defines the metadata classification of different types of media assets, with each metadata category corresponding to an independent data storage table. The metadata category table contains the following fields: metadata category ID (category_id), metadata category table name (category_code), metadata category name (category_name), material type (material_type), creation time (created_at), and update time (updated_at).

[0041] Metadata category table names use the "cob_" prefix, such as "cob_video" and "cob_audio," to ensure the uniqueness and standardization of field names in the database and to create corresponding storage tables. Each metadata category has its own independent data table, and the table structure is dynamically generated based on the attributes.

[0042] The media types support multiple media formats, including video, audio, image, image gallery, and document types.

[0043] The metadata category attribute association table establishes a many-to-many relationship between metadata categories and attributes / attribute groups, supporting flexible configuration combinations. The metadata category attribute association table includes the following fields: primary key ID (id), metadata category ID (category_id), attribute ID or attribute group ID (property_id), type identifier (type), required field (is_must), alias (alias), creation time (created_at), and update time (updated_at).

[0044] The type identifier field distinguishes between attributes and attribute groups, enabling flexible configuration methods: • Type identifier of 1: indicates a single attribute, associated with the base attribute table. • Type identifier 2: indicates an attribute group, associated with the attribute group table, indirectly containing multiple attributes. Each associated record contains detailed configuration parameters: • Required: Indicates whether this attribute is required, used for data validation. • Alias: The display alias under the current metadata category, allowing the same attribute to have different display names in different metadata categories. Dynamic management of relationships is achieved through service classes. When a user configures the relationship between metadata categories and attributes, the system checks whether there are any new, deleted, or updated relationships, and performs data insertion, deletion, and update operations accordingly to ensure the accuracy and real-time nature of the relationships.

[0045] Furthermore, for newly added metadata, the category configuration information is first extracted. Based on this information, the associated attribute tables and attribute group tables are checked to determine if a corresponding target table exists. If the target table exists, historical attribute configuration information is extracted from the existing attribute tables, matched, and updated for any discrepancies. Specifically, this includes: In one embodiment, such as Figure 4 As shown, step B3 includes: Step B31: Compare the historical attribute configuration information and attribute information to confirm the differences in data; Step B32: Match the corresponding update strategy based on the difference data; Update strategies include adding attributes, deleting attributes, and modifying attributes; Step B33: Modify the difference data sequentially according to the update strategy and store the newly added metadata.

[0046] Specifically, table structure modifications support adding, deleting, and modifying fields, ensuring real-time synchronization between the database structure and metadata configuration. When the attribute configuration of a metadata category changes, the system compares the new attribute configuration with the existing table structure to identify the fields that need to be added, deleted, or modified.

[0047] For newly added fields, the system parses the data type of the attribute based on the newly added attribute and adds the corresponding field to the existing table; for fields that need to be deleted, the system removes the corresponding field from the table according to the attribute to be deleted; for fields that need to be modified, the system adjusts the corresponding field according to the attribute configuration.

[0048] In one embodiment, when the deletion of an attribute is triggered in step B32, step B33 includes: Find the correlation information for the discrepancies, and confirm whether there are sub-dependencies between the discrepancies based on the correlation information. If no sub-dependencies exist, delete the discrepancies. Sub-dependencies include whether they are referenced by any metadata category, whether they are included in any attribute group, and whether a corresponding data record exists in the data table.

[0049] Specifically, to ensure the security of deletion operations, in this embodiment, when a metadata category is deleted, the system will safely delete the corresponding data table. Before performing the deletion operation, the system will first back up the table structure information for possible recovery, and then perform the table deletion operation.

[0050] During the deletion operation, the system performs multi-level reference relationship checks to ensure that the data integrity is not compromised due to the deletion operation.

[0051] Before deleting an attribute, the system checks whether the attribute is referenced by any metadata category, contained in any attribute group, and whether a corresponding data record exists in an existing dynamic data table. The system only allows deletion if it confirms that the attribute is completely unused. Similarly, the system performs corresponding reference relationship checks before deleting attribute groups and metadata categories.

[0052] In one embodiment, such as Figure 5 As shown, in step B1, when multiple attribute group tables or attribute tables are matched, the process of executing step B3 also includes: Step B031: Start a database transaction for the attribute group table or attribute table and record the modification actions; Step B032: After a modification action is triggered, perform a status check on the attribute group table or attribute table, and retain the changes only if the operation result meets expectations; Step B033: Return to step B032 until all modifications have been performed.

[0053] Specifically, during metadata configuration changes, the system faces a complex scenario where multiple data tables are modified simultaneously. To ensure data consistency, the system employs an atomic operation mechanism based on database transactions. When a user modifies the metadata category configuration, the system simultaneously involves structural changes to the metadata category table, the metadata category attribute association table, and dynamic data tables. These operations must succeed or fail as a whole.

[0054] The system first initiates a database transaction, then executes operations sequentially according to a predefined sequence: updating basic metadata category information, handling the addition, deletion, and modification of attribute relationships, and performing physical changes to the dynamic table structure. After each critical step, the system performs a status check to ensure the operation results meet expectations. If any step encounters an anomaly, the system immediately rolls back all executed operations, restoring the database state to its pre-operational consistency and returning detailed error information to the user.

[0055] This transaction safety mechanism not only guarantees data consistency but also ensures system stability under high concurrency scenarios. When multiple users perform metadata configuration operations simultaneously, the database's locking mechanism and transaction isolation level ensure the serial execution of operations, avoiding data races and inconsistent states.

[0056] In one embodiment, a display process is also included, such as... Figure 6 As shown, the display process includes: Step C1: Extract attribute information from the attribute table and match the corresponding controlled words from the controlled word dictionary according to the attribute information; Step C2: Maintain the controlled word list according to the controlled words, and establish the association between the controlled words and attribute information; Step C3: Generate and display front-end tags using a controlled vocabulary.

[0057] Furthermore, to facilitate effective management of relevant metadata and tags by the front-end system, this solution also introduces a dynamic management mechanism based on controlled words. This mechanism mainly includes supporting CRUD operations on controlled words; separate storage of controlled word values, including display tags and actual values; dynamic adjustment of controlled word length while updating the field length of associated attributes; and checking whether controlled words are referenced by attributes before deletion to prevent damage to data integrity.

[0058] The maintenance process of controlled words is based on the controlled word management system.

[0059] The controlled word system provides data source management for selective attributes, including the controlled word table (sc_dict) and the controlled word dictionary value table (sc_dict_value).

[0060] The controlled word table is used to store basic information about controlled words, including fields such as controlled word ID (dictionary_id), controlled word name (dictionary_name), controlled word length (dictionary_length), creation time (created_at), and update time (updated_at).

[0061] The controlled word dictionary value table is used to store the specific option values ​​of controlled words, and includes the fields of dictionary value ID (dict_value_id), controlled word ID (dictionary_id), display label (dict_label), stored value (dict_value), sorting number (index_num), creation time (created_at), and update time (updated_at).

[0062] The controlled word system supports separate storage of tags and values. Display tags are used for front-end presentation, while stored values ​​are used for actual data storage. This design allows for the display of user-friendly Chinese tags while maintaining standardized English or numeric encoding in the database.

[0063] The controlled word dynamic management function includes: supporting the creation, deletion, modification, and query operations of controlled words; separate storage of controlled word values, including display labels and actual values; supporting dynamic adjustment of the length of controlled words, while updating the field length of associated attributes; and checking whether controlled words are referenced by attributes before deletion to prevent damage to data integrity.

[0064] As an optional implementation, considering that the query frequency of metadata configuration information is much higher than the modification frequency, the system implements a multi-level caching optimization strategy to improve performance. First, at the application level, the system establishes an in-memory cache for basic configuration information such as metadata attributes, attribute groups, and controlled terms, with a cache validity period set to 1 hour. This basic configuration information is relatively stable during system operation, and caching can significantly reduce the number of database queries.

[0065] The system utilizes a distributed caching middleware to store serialized complex query results. In particular, for metadata configuration queries involving multiple table joins, the system will shard and cache the query results according to the metadata category dimension. When the data in a certain shard changes, only the corresponding cache shard needs to be cleared, without affecting the caching effect of other data.

[0066] The system also implements an intelligent cache update mechanism. When metadata configuration changes, the system automatically identifies the affected cache items and performs precise cleanup or updates. This gradual cache update strategy ensures data real-time performance while maximizing cache hit rate, significantly improving system response speed.

[0067] The system was designed with scalability and compatibility in mind from the outset. The dynamic table structure management utility class adopts a plug-in architecture, supporting extensions to different database types. Currently, the system primarily supports MySQL, but the architecture allows for expansion to support other databases such as PostgreSQL and Oracle without modifying the core logic.

[0068] The system also implements a version compatibility management mechanism. When significant changes occur to the metadata model, the system can automatically handle version upgrades and data migrations, ensuring a smooth transition for existing business processes. This design philosophy enables the system to evolve over the long term, continuously optimizing and improving it as business needs change.

[0069] A storage medium includes computer instructions that, when executed by a computer device, perform the method described above.

[0070] The beneficial effects of the above technical solution are as follows: High flexibility: Supports dynamic configuration of metadata structure, adapting to different business needs without code modification. The system adopts a configuration-driven approach, allowing adjustments to the metadata model through the management interface, greatly improving the system's adaptability.

[0071] Excellent scalability: After adding a new attribute or modifying the configuration of an existing attribute, the system automatically updates the database structure. The expansion process is seamless and unaffected by business operations, avoiding the downtime risks associated with traditional system upgrades.

[0072] Highly adaptable to various business needs: Different types of media assets can be configured with completely different metadata structures to meet diverse business requirements. The system supports differentiated metadata management for various media asset types such as video, audio, and images.

[0073] Low maintenance costs: Through visual configuration, business personnel can directly adjust the metadata structure, reducing the need for developer intervention. The system provides a comprehensive configuration management interface, lowering the technical barrier to entry.

[0074] Excellent performance: Compared to the EAV model, this solution uses a traditional relational table structure, ensuring query performance. Through reasonable index design and caching strategies, the system can support large-scale concurrent access.

[0075] Good data consistency: By leveraging the constraint mechanisms of relational databases, the system ensures data integrity and consistency. It implements a complete reference checking and cascading update mechanism to prevent data inconsistency issues.

[0076] High system stability: Through transaction control and exception handling mechanisms, system stability is ensured under complex operational scenarios. The system has comprehensive logging and monitoring capabilities, facilitating troubleshooting and performance optimization.

[0077] Those skilled in the art will understand that various aspects, or possible implementations of various aspects, of the present invention can be embodied as systems, methods, or computer program products. Therefore, various aspects, or possible implementations of various aspects, of the present invention can take the form of entirely hardware embodiments, entirely software embodiments (including firmware, resident software, etc.), or embodiments combining software and hardware aspects, all collectively referred to herein as "circuit," "module," or "system." Furthermore, various aspects, or possible implementations of various aspects, of the present invention can take the form of computer program products, which are computer instructions stored in memory.

[0078] The memory can be a computer-readable signal medium or a computer-readable storage medium. Computer-readable storage media include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or apparatuses, or any suitable combination thereof, such as random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, and portable read-only memory (CD-ROM).

[0079] A processor in a computer reads computer instructions stored in memory, enabling the processor to execute the functional actions specified in each step or combination of steps in a flowchart; and to generate means for implementing the functional actions specified in each block or combination of blocks in a flowchart.

[0080] It should be understood that a processor in a computer can be understood as one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), general-purpose processors, controllers, microcontrollers (MCUs), microprocessors, or other electronic components used to execute the aforementioned computer instructions.

[0081] Computer instructions may be executed entirely on the user's local computer, partially on the user's local computer, as a separate software package, partially on the user's local computer and partially on a remote computer, or entirely on a remote computer or server. It should also be noted that in some alternative implementations, the functions indicated by the steps in the flowchart or the blocks in the block diagram may not occur in the order shown in the diagram. For example, depending on the functions involved, two consecutive steps or blocks may actually be executed approximately simultaneously, or these blocks may sometimes be executed in reverse order.

[0082] Of course, in practical applications, the various components of a computer system are coupled together through a bus system. The bus system is used to enable communication and connection between these components. In addition to the data bus, the bus system also includes a power bus, a control bus, and a status signal bus.

[0083] The above are merely preferred embodiments of the present invention and are not intended to limit the implementation methods and protection scope of the present invention. Those skilled in the art should recognize that any equivalent substitutions and obvious changes made based on the description and illustrations of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for dynamically storing media asset cataloging metadata based on PHP, characterized in that, This includes a table creation process, which includes: Step A1: For the newly added metadata, create a primary key ID field in the data table and set a material index associated with the media asset material; Step A2: Extract attribute information from the metadata and configure field information according to the attribute information; Step A3: Create an attribute table corresponding to the metadata based on the field information, and organize the attribute tables with similar attribute information into the attribute group table.

2. The method according to claim 1, characterized in that, It also includes a table update process, which includes: Step B1: Extract the attribute information from the newly added metadata, and match the corresponding attribute group table and attribute table in sequence according to the attribute information; Step B2: Extract historical attribute configuration information from the existing attribute table; Step B3: Modify the historical attribute configuration information according to the attribute information, and store the newly added metadata.

3. The method according to claim 1, characterized in that, In step A3, the attribute table includes: attribute ID, field name, attribute name, data type, component style, attribute length, controlled word ID, creation time, and update time; The attribute group table includes: attribute group ID, attribute group table name, attribute group name, creation time, and update time.

4. The method according to claim 1, characterized in that, Step A2 includes: Step A21: Parse the metadata to obtain the attribute information; Step A22: Create corresponding business fields one by one according to the attribute information, and parse the data type corresponding to the business fields; Step A23: Add the business field to the field information and automatically map the corresponding field type according to the data type.

5. The method according to claim 1, characterized in that, Step B3 includes: Step B31: Compare the historical attribute configuration information and the attribute information to confirm the differences; Step B32: Match the corresponding update strategy based on the difference data; The update strategy includes adding attributes, deleting attributes, and modifying attributes; Step B33: Modify the difference data sequentially according to the update strategy, and store the newly added metadata.

6. The method according to claim 5, characterized in that, When the deletion of an attribute is triggered in step B32, step B33 includes: The differential data is searched for correlation information, and the existence of sub-dependencies is confirmed based on the correlation information. If no sub-dependencies exist, the differential data is deleted. The sub-dependencies include whether they are referenced by any metadata category, whether they are contained in any attribute group, and whether there is a corresponding data record in the data table.

7. The method according to claim 2, characterized in that, In step B1, when multiple attribute group tables or attribute tables are matched, the process of executing step B3 further includes: Step B031: Start a database transaction for the attribute group table or the attribute table and record the modification actions; Step B032: When a modification action is triggered, perform a status check on the attribute group table or the attribute table, and retain the changes only if the operation result meets expectations; Step B033: Return to step B032 until all the modification actions have been performed.

8. The method according to claim 1, characterized in that, It also includes a display process, which includes: Step C1: Extract the attribute information from the attribute table, and match the corresponding controlled word from the controlled word dictionary according to the attribute information; Step C2: Maintain a controlled word list according to the controlled words, and establish the association between the controlled words and the attribute information; Step C3: Generate and display front-end tags using the controlled vocabulary.

9. A storage medium comprising computer instructions, characterized in that, When the computer device executes the computer instructions, it performs the method as described in any one of claims 1-8.