VolkovLabs / business-table

The Business Table panel is a Grafana plugin that allows to summarize large amounts of data from various data sources.
https://docs.volkovlabs.io
Apache License 2.0
13 stars 1 forks source link

BUG : error when editing a string field in text area mode #170

Closed Bruutal closed 6 days ago

Bruutal commented 1 week ago

Datasource type : PostreSQL database query exemple : select null as string_field

Layout config : layout

Edit config : edit

Error : error

When I click edit on a row containing an editable string field and the current string value is null, I get the error "Cannot read properties of null (reading 'replaceAll')". The error appears whether there is an update request or not.

vitPinchuk commented 1 week ago

@Bruutal Thank you for the open issue

What data type is contained in the field you use for string_field Can you please provide more details using “table view” mode (screenshot) ? image

Thank you

KaungMAung commented 1 week ago

For this issue, remedy before update is that use your query to assign "" or " " if value is NULL. I think it would work. @Bruutal

Bruutal commented 1 week ago

@Bruutal Thank you for the open issue

What data type is contained in the field you use for string_field Can you please provide more details using “table view” mode (screenshot) ? image

Thank you

It is a string type : image

But it occurs with other data types aswell (numeric, text, etc)

For this issue, remedy before update is that use your query to assign "" or " " if value is NULL. I think it would work. @Bruutal

I know, it works just fine by using coalesce(string_field,'') as string_field, but it is a bit painful when I have to do it on big queries😊