Yes, we can use existing tables in WordPress for storing the values.
Post meta fields are stored in the {$wpdb->prefix}_postmeta table (depending on the table prefix; wp_postmeta by default). If the meta key "like_count" is already present in the table along with the post ID then update_post_meta() will update this, and otherwise this function will insert a new row with this key.
For more reference you can check here : https://codex.wordpress.org/Function_Reference/update_post_meta
Related Posts:
- Why WordPress choose data serialization over json_encode?
- Dealing with Many Meta Values, 30+
- What is the most secure way to store post meta data in WP?
- How to delete outdated, wrongly sized images in _wp_attachment_metadata?
- Meta query interfering with orderby relevance
- Migrating non-WordPress CMS to WordPress, lots of data to move — possible solutions?
- How to solve slow WordPress site caused by attachment_metadata
- Delete all post meta except featured image
- Is it possible to store visitors IPs in wp_postmeta table?
- Multiple postmeta with same name for one post in wp_postmeta table
- Delete all post meta except featured image Using SQL
- One post carries 30 postmeta values, is this too much?
- delete post meta from db, even if does not exist?
- WordPress and MySQL: how to transfer Meta_key and Meta_Value from one post_id to another
- Storing data for a wordpress plugin
- Structure of postmeta meta_value for woocommerce product download
- Routine to convert custom post meta from old to new value
- Saving zero as meta value
- Uknown meta entries in wp_postmeta
- Does post_meta data need to be unserialzed?
- Link image with data from the wpdb
- Custom Post Type not showing anything added by code anymore?
- Compare User meta_value with Product meta_value
- How to save EXIF metadata in WordPress database?
- _wp_attachment_metadata is not being added to database when PDF files uploaded
- “BS_” rows in postmeta table
- Migrating meta_key and meta_value from old theme to new one
- Database structure for thousands of posts
- How much post meta data is too much?
- How do i get value from wp_postmeta?
- Recommended Post Structure for DB Storage
- SQL query : Select a thumbnail for a media
- Is it fine to have foreign key as primary key?
- Custom form that store input in database
- Restoring WordPress posts from database only
- Can a post ID be 0?
- Issue with wp_insert_post and post_content field error Could not update post in the database
- wp_posts – guid update
- So much data in postmeta
- what is the wp_5_posts table in the database?
- Migrating data between local and development server
- WordPress Database Charset/Collate
- storing database in version control
- Is deleting orphaned wp_options entries safe?
- How to build a movie database with wordpress?
- Sub-domain or 2nd, temporary different domain?
- Where is custom template file chosen for a post stored in the DB?
- How do i get user data from a custom table in the wordpress database by user ID?
- Converting WordPress into Android or iPhone app
- Safe way to find last inserted id in a table?
- Delete duplicate rows from wordpress database where a column is duplicate in phpmyadmin
- WooCommerce sku location in DB
- WordPress DATABASE Update Manually?
- I don’t see site_url and home_url fields in wp_options table (phpMyAdmin)?
- Which is more efficient? Using usermeta, or creating a new MySQL table?
- Can I have multiple database users within WordPress?
- Is MariaDB’s Aria storage engine suitable for WordPress?
- Difficulty importing my live site to local
- WordPress returns to an old version
- data (html) migration to posts
- Super slow queries from author archive pages killing my database
- localize elements in database
- Historic WordPress database connection
- Check if an option exists and get its value in one hit
- $wpdb error (Call to a member function insert() on a non-object)
- How To Run A Temporary Instance Of a WordPress Backup Without a Database?
- Share users across multiple sites on same database, but with different domains
- Global__r connection timed out
- Connect to database in the header of my WordPress website
- WordPress url transformation script
- Moving WordPress site to new domain – database import [duplicate]
- Location of WP default mySQL tables creation file?
- Installation question
- Disable Database Update Required ? break my website
- Select From wpdb – Author/User Directory page
- Just created a WordPress Table can’t get $wpdb get row to work – need help
- $wpdb->insert not inserting all rows
- Best Practice? – Saving multiple Values as Serialized Data / Saving each Value per Row / Dedicated Table
- Insert NULL value using prepare()
- How can I find user role in Mysql?
- How would I see which wordpress posts have a revision history without opening each one?
- Troubles when I want to connect to another DB
- Intermittent Yet Problematic Error – “Error Establishing A Database Connection”
- Communication in between WordPress database and another (not WordPress) database
- Is it possible to separate databases in WordPress site – one for orders and the other for all non-orders related
- Featured image from custom to WordPress database
- WordPress Database Query works in phpMyAdmin but not in the code
- Delete all users meta that named: user_avatar
- How to save dropdown slection by a user in the DB
- Accessing Information From Vendor Database On The Basis Of Customer Query
- spambot registering without providing email or password, bypassing registration process
- Widgets with *internal* links do not display after database migration
- Options table – where does my values go?
- WordPress ERD mistake?
- Copy site on same server?
- How to use remote db tables in current config? [duplicate]
- How to solve notorious ‘Error Establishing a Database Connection’ [closed]
- WordPress can’t fetch the posts from the database after moving to new server [closed]
- why you don’t Implement PDO for access every thing to database
- What’s the cleanest way to transfer WordPress to a new server