]> gitweb.factorcode.org Git - factor.git/commitdiff
new accessors
authorDoug Coleman <doug.coleman@gmail.com>
Sun, 31 Aug 2008 07:59:33 +0000 (02:59 -0500)
committerDoug Coleman <doug.coleman@gmail.com>
Sun, 31 Aug 2008 07:59:33 +0000 (02:59 -0500)
extra/odbc/odbc.factor

index 5faca7109ad4bb2595c5361ae81298508030c5fa..faa6c4835470d5141d9b5009d23cb0d3939c0fed 100644 (file)
@@ -213,7 +213,7 @@ C: <column> column
   ] if ;
 
 : dereference-type-pointer ( byte-array column -- object )
-  column-type {
+  type>> {
     { SQL-CHAR [ ascii alien>string ] }
     { SQL-VARCHAR [ ascii alien>string ] }
     { SQL-LONGVARCHAR [ ascii alien>string ] }
@@ -235,7 +235,7 @@ TUPLE: field value column ;
 C: <field> field
 
 : odbc-get-field ( statement column -- field )
-  dup column? [ dupd odbc-describe-column ] unless dup >r column-number
+  dup column? [ dupd odbc-describe-column ] unless dup >r number>>
   SQL-C-DEFAULT
   8192 CHAR: \space <string> ascii string>alien dup >r
   8192
@@ -244,15 +244,15 @@ C: <field> field
   ] [
     r> drop r> [
       "SQLGetData Failed for Column: " %
-      dup column-name %
-      " of type: " % dup column-type name>> %
+      dup name>> %
+      " of type: " % dup type>> name>> %
     ] "" make swap <field>
   ] if ;
 
 : odbc-get-row-fields ( statement -- seq )
   [
     dup odbc-number-of-columns [
-      1+ odbc-get-field field-value ,
+      1+ odbc-get-field value>> ,
     ] with each
   ] { } make ;