2shady4u / godot-sqlite

GDExtension wrapper for SQLite (Godot 4.x+)
MIT License
956 stars 82 forks source link

Noob Question: Is it possible to open db in GUI? #45

Closed bananabrann closed 3 years ago

bananabrann commented 3 years ago

Hey y'all!

I'm new to Godot and this SQLite plugin, and I'm running into some issues with opening the database in a GUI. I have a strong hunch I'm misunderstanding the plugin, or missing some basic knowledge.

I'm making my little game as a side project to learn something new. The goal that I have in mind is that there's an items table that the game would read from. From Godot's code, I wouldn't really manipulate items in this table, it would act mostly read-only. To edit those items, I figured I could just open it in a GUI and add some test items and columns, then reference those via what the docs say in the plugin.

Appreciate any response, thank you! :smiley:

2shady4u commented 3 years ago

Hello @bananabrann

If I'm understanding you correctly, you are searching for an external database editing tool? I highly recommend using SQLiteStudio for that purpose.

When you open a database using the plugin (and it doesn't exist yet) it creates a new *.db-file at the "path"-variable. This *.dbfile can then be opened and edited by SQLiteStudio. Alternatively you can also just create a new database using SQLiteStudio from scratch and then open/edit it in Godot. (Or a combination of both ofc)

bananabrann commented 3 years ago

Oh wow, I feel dumb. I had assumed the plugin created the database on creation. I didn't even consider that possibility in my head. Thank you! @2shady4u :smile: