Steps to reproduce
User.role is a CLOB. Takes 80ms.
User.select(User.column_names).all.to_a
D, [2018-08-13T12:03:31.270377 #56195] DEBUG -- : User Load (78.8ms)
Without User.role it takes 5ms.
User.select(User.column_names - %w(roles)).all.to_a
D, [2018-08-13T12:03:23.412199 #56195] DEBUG -- : User Load (4.5ms)
Expected behavior
Running a SELECT query that includes a CLOB column should be roughly as fast as running a SELECT query without the CLOB column.
Actual behavior
Running a SELECT query that includes a CLOB column is about 15x slower than without the CLOB column.
System configuration
Rails version: 5.2.1
Oracle enhanced adapter version: 5.2.3
Ruby version: 2.4.2p198
Oracle Database version: Oracle Database 11g Release 11.2.0.4.0 - 64bit Production
Steps to reproduce
User.role is a CLOB. Takes 80ms.
User.select(User.column_names).all.to_a
D, [2018-08-13T12:03:31.270377 #56195] DEBUG -- : User Load (78.8ms)
Without User.role it takes 5ms.
User.select(User.column_names - %w(roles)).all.to_a
D, [2018-08-13T12:03:23.412199 #56195] DEBUG -- : User Load (4.5ms)
Expected behavior
Running a SELECT query that includes a CLOB column should be roughly as fast as running a SELECT query without the CLOB column.
Actual behavior
Running a SELECT query that includes a CLOB column is about 15x slower than without the CLOB column.
System configuration
Rails version: 5.2.1
Oracle enhanced adapter version: 5.2.3
Ruby version: 2.4.2p198
Oracle Database version: Oracle Database 11g Release 11.2.0.4.0 - 64bit Production