MySQL tables and "Regenerate Structure"

Hello,

Each time I use "regenerate structure" on my mysql tables, every row with default value "null" has initial value in app: "NULL" as text. Would be great to recieve empty value instead of that... I need to remove those each time I regenrate structure, so with many rows, many tables.. at app design stage its horrible and very time consuming.

Wojciech_Redman_0-1666167402394.png

 

1 14 287
14 REPLIES 14

I have dealt with few databases, each having some columns nullable and not nullable.  I have never seen this issue.

Have you by chance accidentally configured the database such that it assigns the text "NULL" as a default value?  If so, then that will carry into the AppSheet regeneration as an Initial Value.

This is an example row structure: 

Wojciech_Redman_2-1666189175788.png

 

Hmm, that's weird. I also use MySQL regularly, and regenerate often, and have never had this happen to me. I just checked and almost all of my tables use NULL as the default in MySQL. Only difference I see is that we use utf8mb4 charset.

I've just checked that and changed to utf8mb4 charset. Unfortunately still the same problem...

Haven't ever had this issue either and have been using MySQL for about 2 years with many regenerates in between

in Mysq all your columns are as varchar?

With the varchar type in appsheet I can get the box as empty, but with the dates, numbers and decimals I can't find the way to return the empty boxes (only null)

with more than 40 columns it becomes tedious to add or modify a column type.

It does not save the price or decimal type configuration either.

Yes, I generally use varchar for my column types in the table at least until I have a solid handling on the user inputs I’ll be receiving.  So I can say having used both varchar and specific column types I haven’t had much issues other than one. which I will ask about here 

 

what are your column headers? The only time I’ve struggled with regenerations is when the editor decides to use the headers to determine the column type for me. For example I made an app with a header cook_time with the type duration but every regeneration changed it to type time quite annoyingly (erasing formulas too). 

do you have any examples of the headers? Are they innocuous? Might the editor be trying to auto fill types? 

I think the problem is only with MariaDB - which my company uses... I've tested the same databases on the MySQL test server from google cloud and this type of problem did not occur there... 🙄 

Well I’m glad you were able to narrow down the problem. So sorry that you are pigeonholed into that database service. I’ve been there before with companies and it can be difficult 

Thanks for the reply.

I use specific types since I consult the database from other platforms

image (2).jpg

Interesting. I can’t say much on here as to why it is doing that. I would likely raise a support ticket to see if you can iron it out 

I use MariaDB, could be that's the problem?

Still I coudln't find any solution or answer for that 😔

Anything ?

Top Labels in this Space