You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm getting a segfault if I do a query that has no results and then try to #fetch it. Is there a way to safely check if a result exists before doing a #fetch?
Thanks,
Patrick
For example (a result is found):
$ rails runner "p Firebird::Address._connection.execute('select ADDRESS_ID from TBL_ADDRESS where ADDRESS_ID = 1').fetch(:hash)"
{"ADDRESS_ID"=>1}
The text was updated successfully, but these errors were encountered:
plainlystated
changed the title
Possible to check for results before #fetch? (segfault)
Possible to check for results before #fetch(:hash)? (segfault)
Apr 14, 2016
I'm getting a segfault if I do a query that has no results and then try to #fetch it. Is there a way to safely check if a result exists before doing a #fetch?
Thanks,
Patrick
For example (a result is found):
(no result found, segfault):
The text was updated successfully, but these errors were encountered: