One way to validate the SQL Override in a Source or Lookup is to create a view from the SQL in the database then import this view as a source and compare the two objects.
Create a view in the database based on the SQL Override.
In the database use the CREATE VIEW command to create the view based on the SQL from the Override.
Create a Source Definition in the Repository.
Import the View from the database and create a Source Definition in Source Analyzer. The new source definition will be created based on the column datatypes and sizes returned by the SELECT clause in the view.
Compare the Source based on the view with the original Source or Lookup.
Compare the sources using the Sources > Compare option.
What can we do to improve this information (2000 or fewer characters)