Playing with the database library functions, trying to understand how it all works before I migrate my existing workflow over to it. (KiCAD 7.0 release build)
I have a sqlite database named “2_passives.sqlite” and an accompanying JSON file named 2_passives.kicad_dbl. I am only messing with the capacitor data at this point, its “fields” section in the JSON file reads:
{
“column”: “PN”,
“name”: “PN”,
“visible_on_add”: false,
“visible_in_chooser”: true
},
{
“column”: “Manufacturer”,
“name”: “Manufacturer”,
“visible_on_add”: false,
“visible_in_chooser”: false
},
{
“column”: “MPN”,
“name”: “MPN”,
“visible_on_add”: false,
“visible_in_chooser”: true
},
{
“column”: “Capacitance”,
“name”: “Value”,
“visible_on_add”: true,
“visible_in_chooser”: true
},
{
“column”: “Dielectric Type”,
“name”: “Dielectric”,
“visible_on_add”: true,
“visible_in_chooser”: false
},
{
“column”: “Voltage Rating”,
“name”: “Voltage Rating”,
“visible_on_add”: true,
“visible_in_chooser”: true
},
{
“column”: “Datasheet”,
“name”: “Datasheet”,
“visible_on_add”: false,
“visible_in_chooser”: true
}
The visible_on field setting works as advertised, the visible_in_chooser perhaps not - I might just not understand it. This is a screen capture of the chooser at some point:
My main issue is that though the JSON field settings include e.g. Voltage Rating / visible_in_chooser == true, it does not show in the columns of the list (No additional columns here). Also the two columns that do show are not sortable (by click on column header). What mistake am I making?
Lesser important (to me) is the repetition of the pre/post fix “cap”, this is just annoying there is no need to show this everywhere. If the database is called “2_passives” and the table inside it is “cap”, showing this as “2_passives - cap” makes sense, then cap/CAP-001 can just be listed as “CAP-001”, no? Sorry for being anal.
The bottom info section is great but there is no control over what shows and in which order, is there? I thought this would also be controlled by the JSON file.