24 lines
600 B
JavaScript
24 lines
600 B
JavaScript
const { query, connectDB } = require('./src/database/connection');
|
|
|
|
async function checkSchema() {
|
|
await connectDB();
|
|
const result = await query(
|
|
`SELECT column_name, data_type
|
|
FROM information_schema.columns
|
|
WHERE table_name = 'pan_verifications'
|
|
ORDER BY ordinal_position`
|
|
);
|
|
|
|
console.log('Columns in pan_verifications table:');
|
|
result.rows.forEach(col => {
|
|
console.log(` - ${col.column_name}: ${col.data_type}`);
|
|
});
|
|
|
|
process.exit(0);
|
|
}
|
|
|
|
checkSchema().catch(err => {
|
|
console.error('Error:', err.message);
|
|
process.exit(1);
|
|
});
|