mirror of
https://github.com/Kingsrook/qqq.git
synced 2025-07-18 05:01:07 +00:00
Add explicit log (Rather than NPE) for unknown table name
This commit is contained in:
@ -533,10 +533,16 @@ public class QueryStatManager
|
||||
////////////////////////
|
||||
if(getOutput.getRecord() == null)
|
||||
{
|
||||
QTableMetaData tableMetaData = getInstance().qInstance.getTable(tableName);
|
||||
if(tableMetaData == null)
|
||||
{
|
||||
LOG.info("No such table", logPair("tableName", tableName));
|
||||
return (null);
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////
|
||||
// insert the record (into the table, not the cache) //
|
||||
///////////////////////////////////////////////////////
|
||||
QTableMetaData tableMetaData = getInstance().qInstance.getTable(tableName);
|
||||
InsertInput insertInput = new InsertInput();
|
||||
insertInput.setTableName(QQQTable.TABLE_NAME);
|
||||
insertInput.setRecords(List.of(new QRecord().withValue("name", tableName).withValue("label", tableMetaData.getLabel())));
|
||||
|
Reference in New Issue
Block a user