0

We have a select query to build a dataset and bind to a datagrid. The code runs well on my local computer, it runs well on development testing server too. But after we deploy to a User Acceptance Testing server, we get the error in title.

I extracted the query and ran it in sql developer, pointed to User Acceptance Testing DB, no error either.

Please help.

Cal
  • 747
  • 1
  • 13
  • 30
  • Did you run the query from the UAT server? Can you profile the ORCL instance to see if the query is even executed? It may be executing with parameters different than you are assuming. – StingyJack Nov 28 '12 at 19:49
  • Yes I have just run it from the UAT application server, using sqlplus, it returns the result dataset with no problem. – Cal Nov 28 '12 at 20:04
  • Then it is likely issuing a different query than you are expecting. Try one of these to see what queries are actually being issued to your server. http://stackoverflow.com/q/148648/16391 – StingyJack Nov 28 '12 at 20:06

1 Answers1

0

Its possible that one or more of the columns in your resultset is null. Try using NVL on your columns to substitute a null-valued column with a 'default' value.

select NVL(supplier_city, 'n/a') 
from suppliers;

This will return 'n/a' if supplier_city is null

http://www.techonthenet.com/oracle/functions/nvl.php

Andy Refuerzo
  • 3,312
  • 1
  • 31
  • 38