OraDataReader.GetString — oracle-tech

    Forum Stats

  • 3,715,830 Users
  • 2,242,890 Discussions
  • 7,845,632 Comments

Discussions

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

OraDataReader.GetString

238632
238632 Member Posts: 4
When you call the GetString method on a column containing a null value you get an exception, as stated in the documentation. You also get an exception when you call the GetOraString method. This is a pain, you have to call "IsDBNull(colindex)" before every read of every nullable string column!

Can I suggest you change GetOraString to return an empty (zero length) string for a null string value. If you make coding much simpler.

Regards

Chris
This discussion has been closed.