Skip to content

Commit fc62d61

Browse files
committed
odbc: unlimited column size by default
1 parent e548f4a commit fc62d61

File tree

1 file changed

+2
-11
lines changed
  • sqlx-core/src/odbc/options

1 file changed

+2
-11
lines changed

sqlx-core/src/odbc/options/mod.rs

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,8 @@ pub struct OdbcBufferSettings {
7070
impl Default for OdbcBufferSettings {
7171
fn default() -> Self {
7272
Self {
73-
batch_size: 128,
74-
max_column_size: Some(4096),
73+
batch_size: 64,
74+
max_column_size: None,
7575
}
7676
}
7777
}
@@ -140,16 +140,7 @@ impl OdbcConnectOptions {
140140
///
141141
/// - When set to `Some(value)`: Enables buffered mode with batch fetching
142142
/// - When set to `None`: Enables unbuffered mode with row-by-row processing
143-
///
144-
/// # Panics
145-
/// Panics if `max_column_size` is less than 1024 or greater than 4096 (when Some).
146143
pub fn max_column_size(&mut self, max_column_size: Option<usize>) -> &mut Self {
147-
if let Some(size) = max_column_size {
148-
assert!(
149-
(1024..=4096).contains(&size),
150-
"max_column_size must be between 1024 and 4096"
151-
);
152-
}
153144
self.buffer_settings.max_column_size = max_column_size;
154145
self
155146
}

0 commit comments

Comments
 (0)