sqlboiler icon indicating copy to clipboard operation
sqlboiler copied to clipboard

Sqlite view model has wrong type and can't be replaced

Open ShinyZero0 opened this issue 3 months ago • 3 comments

If you're having a generation problem please answer these questions before submitting your issue. Thanks!

What version of SQLBoiler are you using (sqlboiler --version)?

4.16.1

What is your database and version (eg. Postgresql 10)

3.44.2

If this happened at generation time what was the full SQLBoiler command you used to generate your models? (if not applicable leave blank)

sqlboiler sqlite3

If this happened at runtime what code produced the issue? (if not applicable leave blank)

What is the output of the command above with the -d flag added to it? (Provided you are comfortable sharing this, it contains a blueprint of your schema)

Please provide a relevant database schema so we can replicate your issue (Provided you are comfortable sharing this)

Further information. What did you do, what did you expect?

It generates the entity for client_balance with balance as nullable string, which is a float actually. E.g. if i do a query with sqlite3 -json it is float

There is the whole repo

ShinyZero0 avatar Mar 30 '24 19:03 ShinyZero0

UPD: it's the same for client_statuses view too. Also, the values are valid, but i have to parse them with strconv

ShinyZero0 avatar Mar 30 '24 20:03 ShinyZero0

I will label this as a bug, but I need more information

The title says it can't be replaced, can you share how you are configuring the type replacement?

stephenafamo avatar Apr 02 '24 00:04 stephenafamo

like that

AFAIR i also tried matching the capitalized name and it didn't work too

ShinyZero0 avatar Apr 02 '24 02:04 ShinyZero0