Skip to content

Add BLB_write function to allow modification of data in a BLOB#9066

Open
Noremos wants to merge 1 commit into
FirebirdSQL:masterfrom
Noremos:blob_data_modification_function
Open

Add BLB_write function to allow modification of data in a BLOB#9066
Noremos wants to merge 1 commit into
FirebirdSQL:masterfrom
Noremos:blob_data_modification_function

Conversation

@Noremos

@Noremos Noremos commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

This PR is part of the JSON implementation. Efficiently writing binary JSON requires modifying a blob. Otherwise, TempSpace is required to use it and convert the data to a blob, significantly increasing overhead.

@hvlad

hvlad commented Jun 17, 2026

Copy link
Copy Markdown
Member

Whats wrong or not enough with seek + putSegment ?

@Noremos

Noremos commented Jun 17, 2026

Copy link
Copy Markdown
Contributor Author

Whats wrong or not enough with seek + putSegment ?

BLB_lseek works only for BLB_get_segment

@hvlad

hvlad commented Jun 17, 2026

Copy link
Copy Markdown
Member

Whats wrong or not enough with seek + putSegment ?

BLB_lseek works only for BLB_get_segment

So why not make it work with put too? I suppose it's been done in your PR anyway.

@Noremos

Noremos commented Jun 17, 2026

Copy link
Copy Markdown
Contributor Author

Whats wrong or not enough with seek + putSegment ?

BLB_lseek works only for BLB_get_segment

So why not make it work with put too? I suppose it's been done in your PR anyway.

Initially, I wanted to implement the same read/write interface as for TempSpace. But I can do this within the BLB_get_segment function.

@hvlad

hvlad commented Jun 17, 2026

Copy link
Copy Markdown
Member

Whats wrong or not enough with seek + putSegment ?

BLB_lseek works only for BLB_get_segment

So why not make it work with put too? I suppose it's been done in your PR anyway.

Initially, I wanted to implement the same read/write interface as for TempSpace.

You still speak about blobs here ?

But I can do this within the BLB_get_segment function.

I'm lost your point here, sorry. How it answers on my question ?

@hvlad

hvlad commented Jun 17, 2026

Copy link
Copy Markdown
Member

BTW, code in blb.cpp (at least) requires comments. It have none too small useful comments, imo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants