Can I use the same database that I use at mysite.com also to my subdomain
Yes, as long as the table names don’t clash you’re fine, some people have multiple WP instances using the same database, but with different table prefixes.
However, keep in mind that there is a security risk as now 2 sites have access to eachothers data.
or I will destroy the current database?
If you run a destructive query yes! But why would you do that.
I don’t think you have anything to fear here, but, it would be much easier to just create a local dev environment and test it out. This would give you the confidence and a practice run to do it in production
Related Posts:
- Sub-domain or 2nd, temporary different domain?
- Auto login subdomain from main domain on single sites with different DB
- Use same database on main domain & sub domain
- Exclude Statement in SQL
- 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
- what is the wp_5_posts table in the database?
- Migrating data between local and development server
- WordPress Database Charset/Collate
- What is the database table for pages?
- Using Dynamic Data Pulled from a MySQL Table in a WordPress Page
- Migrating non-WordPress CMS to WordPress, lots of data to move — possible solutions?
- storing database in version control
- Is deleting orphaned wp_options entries safe?
- How to build a movie database with wordpress?
- Is database safe after merging a branch of a more recent version over an older one?
- Hook to be used when creating a database table
- Delete all post meta except featured image
- 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
- Merging WordPress posts from different databases
- Why can’t I swap a DB in a WP install? [closed]
- How to replace values in WordPress DB using phpMyAdmin
- How do I reset a self-hosted WordPress URL?
- Is it possible to split database tables using HyperDB?
- Show content from database
- Customize JSON output
- CRUD operations using WordPress database API
- Display SQL that wordpress is running
- “Error establishing a database” connection on some sites
- change wp user status from wp_users table
- How to resolve Connections using insecure transport are prohibited while –require_secure_transport=ON
- Is MariaDB’s Aria storage engine suitable for WordPress?
- Difficulty importing my live site to local
- Slow queries constantly getting stuck on WordPress database of ~100,000 posts
- 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
- WordPress running SQL query to update database from form
- How to fix database error duplicate entry
- WPDB SQL query with prepare() returning variable, not db value
- Get value form wordpress database
- Moving to another server database connection error [closed]
- Why this query is not showing any result on wordpresss home page?
- Best practice to limit results in get_row()?
- How to display content from external db with relevant urls
- Is there an easy way of exporting posts with their category already asigned and pictures from localhost?
- Connect to another WP install and grab post based on custom field
- Which table (and column) has the content of configured get_post_meta?
- Serialize data before inserting into the DB
- WordPress Multisites or Multiple WP Single sites?
- how to count click tab menu and insert to database
- Adding prefix to WordPress database tables breaks admin capabilities?
- What is the best way to resurrect and update my old WordPress site?
- Pages from custom table
- content disappearing minutes after it’s published
- What is the most efficient way to reset a WordPress site?
- Add pdf to a website
- Optimizing function that automatically creates internal links based on post title string
- Can I customised default WP table
- WordPress where clauses in db select
- How to display data from db in select list [closed]
- Will adding & modifying default WordPress table index break future WordPress update
- echo site_url() returns a different value than what is in the database siteurl field
- Can two domains use the same database?
- Native timestamp on wp_options option
- _wp_attachment_metadata is not being added to database when PDF files uploaded
- SELECT rows between two datetimes when the range is dynamic [closed]
- adding user_id and name to a separate table whenever a user register based on role
- How do I loop/iterate through posts to edit all img tags?
- error establishing a database connection 3
- How to edit posts/pages without making the change live?
- Correct and secure way to access a custom SQL database in a custom PHP template file
- How to optimise this database query?
- How to retrieve user data based on role using SQL?
- Adding featured for post using database
- Does WordPress Support Using Named Pipes on the Windows Operating System?
- Missing latest posts and options after DB migration via phpMyAdmin
- Store id from database query in cookie
- Split database on large site?
- Store the wordpress “featured image” under »wp_posts« Database table
- Custom metabox does not store data
- Return image urls with specific base string?
- What WordPress file is saving new users to database
- wordpress database error
- How do i get value from wp_postmeta?
- Local host to server import problem
- featured image not showing up with mysql_connect
- Options of accessing wordpress data from mobile app
- WP Multisite Users Not Linking
- Query a meta key using an array of values where the database value is a string