04-01-2009 07:00 PM
Hi,
I try to create a custom RME report with simple fields and I receive an error message who tells me to look into invreports.log file.
Check my jpeg attachments :
server1:/var/adm/CSCOpx/log #tail -f invreports.log
...
[ Wed Apr 01 21:53:45 EDT 2009 ],INFO ,[TP-Processor11],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,55,Entered into CustomTemplateAction class
[ Wed Apr 01 21:53:45 EDT 2009 ],INFO ,[TP-Processor11],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,78,Entered into custom templatesCreate
[ Wed Apr 01 21:53:45 EDT 2009 ],INFO ,[TP-Processor11],com.cisco.nm.rmeng.inventory.reports.custom.UITemplateData,isTemplateExists,475,Entered into isTemplateExists() method in add mode
[ Wed Apr 01 21:53:46 EDT 2009 ],INFO ,[TP-Processor11],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,297,Getting groups data UITemplateData class
[ Wed Apr 01 21:53:46 EDT 2009 ],INFO ,[TP-Processor11],com.cisco.nm.rmeng.inventory.reports.custom.UITemplateData,getInventoryGroups,60,Entered getInventoryGroups
[ Wed Apr 01 21:53:46 EDT 2009 ],INFO ,[TP-Processor11],com.cisco.nm.rmeng.inventory.reports.custom.UITemplateData,getInventoryGroups,86,Test = 20
[ Wed Apr 01 21:53:46 EDT 2009 ],INFO ,[TP-Processor11],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,308,Forwarding to from customTemplateActionInvRptTemplSummary
[ Wed Apr 01 21:53:49 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,55,Entered into CustomTemplateAction class
[ Wed Apr 01 21:53:49 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,78,Entered into custom templatesCreate
[ Wed Apr 01 21:53:49 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,147,You clicked finish to complte your action
[ Wed Apr 01 21:53:49 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.custom.QueryBuild,populateMappings,1344,executing finally block
[ Wed Apr 01 21:53:49 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.custom.QueryBuild,getCriterion,66,getCriterion method called to construct Array of ReportCriterion Objects
[ Wed Apr 01 21:53:49 EDT 2009 ],ERROR,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,165,Template could not store in database!
[ Wed Apr 01 21:53:49 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.ui.action.CustomTemplateAction,perform,173,Forwarding to main screen /CriCrtm.do
[ Wed Apr 01 21:53:49 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.custom.IRCrtmImpl,getCrtList,45,called getCrtList to get list of Inventory Custom Templates
[ Wed Apr 01 21:53:50 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.custom.IRCrtmImpl,getCrtList,51,Connection is not null
[ Wed Apr 01 21:53:50 EDT 2009 ],INFO ,[TP-Processor2],com.cisco.nm.rmeng.inventory.reports.custom.IRCrtmImpl,getCrtList,70,Number of templates returning: 2
Any ideas, the log file says :
Template could not store in database
but why and how to correct that.
Thanks.
Patrick Vignaud.
Solved! Go to Solution.
04-02-2009 04:55 AM
you missed to select a value for the 'Operator' and 'Value' fields while creating the rule.
It is interesting that the 'Add' button does not perform a syntax check on all the fields for the search string instead it seems that it is just checking for the 'Association' field not to be empty.
I assume you wanted to generate something like this if you left the operatorand value field empty:
System:System Object ID:equals:All
AND:Chassis:Chassis Model Name:equals:All
AND:Chassis:Chassis Version:equals:All
with this your rule should be valid.
04-01-2009 08:13 PM
It's impossible to tell from this. You will need to enable InvReports and CRI debugging under RME > Admin > System Preferences > Application Loglevel Settings, then reproduce the problem.
04-02-2009 04:55 AM
you missed to select a value for the 'Operator' and 'Value' fields while creating the rule.
It is interesting that the 'Add' button does not perform a syntax check on all the fields for the search string instead it seems that it is just checking for the 'Association' field not to be empty.
I assume you wanted to generate something like this if you left the operatorand value field empty:
System:System Object ID:equals:All
AND:Chassis:Chassis Model Name:equals:All
AND:Chassis:Chassis Version:equals:All
with this your rule should be valid.
04-02-2009 10:04 AM
Good catch. These rulesets are turned into an SQL query on the backend which clearly would fail when you leave out a value and operator:
SELECT * FROM TABLE WHERE sysObjectID -- ERROR!
04-02-2009 10:19 AM
Correct.
I do this, because I use to do it in another version (2.5 or 2.6). I just make a test in a similar way on a 2.6 version and it works without equals all.
The 3.1 requires all fields.
Thanks.
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: