Skip to content

Commit

Permalink
eliminate another use of SingleColumnRowSetBuffer
Browse files Browse the repository at this point in the history
  • Loading branch information
pacman82 committed Sep 5, 2022
1 parent 739d30b commit 44ad96f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions odbc-api/tests/integration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -437,12 +437,13 @@ fn bind_varchar(profile: &Profile) {

let sql = format!("SELECT a FROM {};", table_name);
let cursor = conn.execute(&sql, ()).unwrap().unwrap();
let mut buf = SingleColumnRowSetBuffer::with_text_column(1, 100);
let mut buf = TextRowSet::from_max_str_lens(1, [100]).unwrap();
// let mut buf = SingleColumnRowSetBuffer::with_text_column(1, 100);
let mut row_set_cursor = cursor.bind_buffer(&mut buf).unwrap();
row_set_cursor.fetch().unwrap();
drop(row_set_cursor);

assert_eq!(Some(&b"Hello, World!"[..]), buf.value_at(0));
assert_eq!(Some(&b"Hello, World!"[..]), buf.column(0).get(0));
}

/// Bind a VARCHAR column to a wchar buffer
Expand Down

0 comments on commit 44ad96f

Please sign in to comment.