Class: ODBC::Error
- Inherits:
-
Object
- Object
- ODBC::Error
- Defined in:
- lib/marjoree/odbc.rb
Instance Method Summary collapse
Instance Method Details
#error_code ⇒ Object
34 35 36 37 38 39 |
# File 'lib/marjoree/odbc.rb', line 34 def error_code start_index = to_s =~ /(\()/ end_index = to_s =~ /(\))/ end_index -= 1 return to_s.slice( (start_index + 1 ), (end_index - start_index ) ).to_i end |
#error_message ⇒ Object
41 42 43 |
# File 'lib/marjoree/odbc.rb', line 41 def return to_s.split( /\]/ ).last.rstrip end |