Skip to main content
Asked a question last year

Why am I getting "Object Reference not set to an instance of an object."

Where am I?

In Yurbi you can ask and answer questions and share your experience with others!

We admit that It's not a very useful error message, but it does have a very common reason.  The error is most likely caused by one of these errors in the Architect (and one potentially due to formulas in the Builder):

  • Applying a math function to a non-numeric field. While a count() function can be applied to anything, trying to a sum, average, or other numeric operation requires the field to be a number.  So if you got this error after applying a formula, this is most likely the reason.  Now if the field is actually a number,  you may have it set as a datatype of cha (character) in the Architect.  The solution, edit the field in the Architect and change it to a num data type. If the field is defined in the database as text, but you really store numbers in there and want to use calculations,  the solution will be to apply a CAST function in the formula dialogue of the Composer prior to doing your sum, average, or other numeric operation.
  • Setting an incorrect Table Owner field when adding the database table.  The Table Owner field is listed as optional, so you may have added something in there.  Most of the time, it should be blank.  The opposite could be true, you left it blank, but your database actually does have a table owner or schema owner for that database table.  Going into the Architect and editing the table to add or remove the table owner is a potential solution.
  • A bad join between tables.  If you get this after adding a field to an already working report, odds are you have a bad join between tables in the Architect.  Going into the Architect and editing or removing the join is a potential solution.
  • The database was updated and a field was removed/change. This is rare but does happen if you have a quickly changing database environment.  You may have added a field in the Architect that used to be in the database, and someone changed the database on you.  Expand the database table and check out the list of fields, see if the one you added is still there.

If these don't resolve your issue, please zip up the LOGS directory under c:\program files (x86)\yurbi to support@yurbi.com248 and our team can help troubleshoot.