Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TODO: add support for custom serialization exception when read bool column type #85

Closed
DevDmitryN opened this issue Feb 20, 2024 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@DevDmitryN
Copy link

DevDmitryN commented Feb 20, 2024

I try read bool column type, but get NotImplementedException "TODO: add support for custom serialization.". In same time nullable bool column type works fine.

Can you solve this problem?

FROM YOUR SOURCE CODE:

ClickHouseTcpClient row 421

if (_client.ServerInfo.Revision >= ClickHouseProtocolRevisions.MinRevisionWithCustomSerialization)
{
     var hasCustom = await reader.ReadBool(async, cancellationToken);
      if (hasCustom)
          throw new NotImplementedException("TODO: add support for custom serialization.");
}

PS: clickhouse version 24.1.5.6

@alec-anikin
Copy link
Contributor

alec-anikin commented Feb 22, 2024

It's sparse column serialization which was enabled by default in v23.7+
As a workaround, you can disable it on the server: see more about merge tree option ratio_of_defaults_for_sparse_serialization

@victor-sushko victor-sushko self-assigned this Mar 4, 2024
@victor-sushko victor-sushko added the bug Something isn't working label Mar 4, 2024
@valeravorobjev
Copy link

valeravorobjev commented Mar 4, 2024

Not only a Boolean value. I've got an integer column with zero value (0) or column array of integers. And I get this error in both cases. Yes, setting the value of ratio_of_defaults_for_sparse_serialization=1.0 helps me when creating a table, but this is a bad way to solve the problem

Clickhouse latest version

@SergeyMirvoda
Copy link
Contributor

but this is a bad way to solve the problem

sure, we will fix this ASAP

@victor-sushko
Copy link
Contributor

The bug was fixed in the version 3.1.2.

@Yerkon
Copy link

Yerkon commented Mar 11, 2024

@victor-sushko, Is any change log will be added to see changes, improvements, some breaking list?
Is it safe to upgrade for the latest version ?

@victor-sushko
Copy link
Contributor

Is any change log will be added to see changes, improvements, some breaking list?

I updated the changelog, but have not merged it to the main branch yet.
https://github.com/Octonica/ClickHouseClient/blob/v3.1.2/CHANGELOG.md

Is it safe to upgrade for the latest version ?

Yes, it should be safe. There were mostly additions for the sparse serialization mode.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants