pentaho/pentaho-kettle · error · KettleException
MySQLBulkLoaderMeta.Exception.ErrorGettingFields
MySQLBulkLoaderMeta.Exception.ErrorGettingFields
Error message
MySQLBulkLoaderMeta.Exception.ErrorGettingFields
What it means
getRequiredFields wraps its table lookup in a try/catch; any exception raised while connecting to the database, checking table existence, or reading the table fields is rethrown as a KettleException with the message 'MySQLBulkLoaderMeta.Exception.ErrorGettingFields' and the original exception as the cause. It is a wrapper error indicating the required-fields lookup failed for an underlying reason.
Solutions
- Inspect the chained cause of this KettleException to find the real failure (connect error, missing table, etc.)
- Fix the underlying cause: verify host/port/credentials, create the table, or set the table name
- Test the database connection in the step dialog before re-running
Defensive patterns
Strategy: try-catch
Validate before calling
if ( databaseMeta == null ) throw new KettleException( "No connection defined" ); // then verify connectivity db.connect(); db.disconnect();
Try / catch
try {
meta.getRequiredFields( transMeta );
} catch ( KettleException e ) {
Throwable cause = e.getCause();
logError( "Required fields lookup failed: " + cause.getMessage(), e );
} Prevention
- Always inspect getCause() — this is a wrapper exception
- Test the DB connection in the step dialog first
- Ensure the DB user has privileges to read table metadata
When it happens
Trigger: Calling getRequiredFields when the inner block throws: connection failure (db.connect), checkTableExists/getTableFields SQL errors, or the TableNotFound/TableNotSpecified exceptions from the same method.
Common situations: Database unreachable or credentials wrong; SQL syntax/privilege error reading table metadata; the TableNotFound or TableNotSpecified conditions being wrapped.
Understand the failure class
Background: Database query failed: Internal Server Error 500s wrapping SQL, Prisma, and connection failures — what to check first — this error's family across 16 libraries.
Related errors
- GPBulkLoaderMeta.Exception.ErrorGettingFields
- GPBulkLoaderMeta.Exception.ErrorGettingFields
- MySQLBulkLoaderMeta.Exception.TableNotFound
- SynchronizeAfterMergeMeta.Exception.ErrorGettingFields
- TableCompare.Exception.UnexpectedErrorComparingTables
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/eac0bc1772198ded.
Report an issue: GitHub.
Appendix: source
Thrown at plugins/mysql-bulk-loader/impl/src/main/java/org/pentaho/di/trans/steps/mysqlbulkloader/MySQLBulkLoaderMeta.java:646
if ( databaseMeta != null ) {
Database db = new Database( loggingObject, databaseMeta );
try {
db.connect();
if ( !Utils.isEmpty( realTableName ) ) {
String schemaTable = databaseMeta.getQuotedSchemaTableCombination( realSchemaName, realTableName );
// Check if this table exists...
if ( db.checkTableExists( schemaTable ) ) {
return db.getTableFields( schemaTable );
} else {
throw new KettleException( BaseMessages.getString( PKG, "MySQLBulkLoaderMeta.Exception.TableNotFound" ) );
}
} else {
throw new KettleException( BaseMessages.getString( PKG, "MySQLBulkLoaderMeta.Exception.TableNotSpecified" ) );
}
} catch ( Exception e ) {
throw new KettleException( BaseMessages.getString( PKG, "MySQLBulkLoaderMeta.Exception.ErrorGettingFields" ), e );
} finally {
db.close();
}
} else {
throw new KettleException( BaseMessages.getString( PKG, "MySQLBulkLoaderMeta.Exception.ConnectionNotDefined" ) );
}
}
/**
* @return the schemaName
*/
public String getSchemaName() {
return schemaName;
}
/**
* @param schemaNameView on GitHub (pinned to f3058517a1)