wheels dbmigrate info
Display database migration status and information.
Synopsis
Description
The wheels dbmigrate info
command shows the current state of database migrations, including which migrations have been run, which are pending, and the current database version.
Options
--help
Show help information
Output
The command displays:
Current Version: The latest migration that has been run
Available Migrations: All migration files found
Migration Status: Which migrations are completed vs pending
Database Details: Connection information
Example Output
Migration Files Location
Migrations are stored in /db/migrate/
and follow the naming convention:
Example:
Understanding Version Numbers
Version numbers are timestamps in format:
YYYYMMDDHHmmss
Higher numbers are newer migrations
Migrations run in chronological order
Database Schema Table
Migration status is tracked in schema_migrations
table:
Use Cases
Check before deployment
Verify after migration
Troubleshoot issues
See which migrations have run
Identify pending migrations
Confirm database version
Common Scenarios
All Migrations Complete
Fresh Database
Partial Migration
Troubleshooting
Migration Not Showing
Check file is in
/db/migrate/
Verify
.cfc
extensionEnsure proper timestamp format
Version Mismatch
Check
schema_migrations
tableVerify migration files haven't been renamed
Look for duplicate timestamps
Connection Issues
Verify datasource configuration
Check database credentials
Ensure database server is running
Integration with CI/CD
Use in deployment scripts:
Best Practices
Always check info before running migrations
Review pending migrations before deployment
Keep migration files in version control
Don't modify completed migration files
Use info to verify production deployments
See Also
Last updated
Was this helpful?