[Gambas-user] databases
David Silverwood
the_watchmann at yahoo.com
Thu Oct 14 18:17:48 CEST 2021
Found the bug... it was me... instead of db I typed gb... TWICE!!! Apologies... and thanks for taking the time to reply, Benoit.
On Thursday, October 14, 2021, 01:35:36 PM GMT+2, Benoît Minisini <g4mba5 at gmail.com> wrote:
Le 14/10/2021 à 12:56, David Silverwood via User a écrit :
> Hi All
>
> I came across a very strange occurrence, not sure what the problem may be.
> I have a couple of database interfaces (sqlite3), however (and this is
> only the second time this has occurred) I found that when creating
> tables gb _sometimes_ kicks out 'gbSerial' as in the following code:
>
> hTable.Fields.Add("REF", gb.Serial)
> hTable.Fields.Add("DATE", gb.Date)
> hTable.Fields.Add("INVOICE", gb.String)
> hTable.Fields.Add("QUANTITY", gb.Float)
> hTable.Fields.Add("DESCRIPTION", gb.String)
> hTable.Fields.Add("PRICE", gb.Float)
> hTable.PrimaryKey = ["REF"]
> hTable.Update
>
> I can only assume I am missing a library somewhere, however, when I
> checked the components on the other interfaces, they were all the
> same... so I have two interfaces that don't work and the rest do... (not
> in the same program). Can someone shed some light on this, please? What
> exactly have I done wrong on the 2 'problem children'?
> PS. I used the gb.db and gb.db.form components
>
> Thanks
>
> David
>
I can't tell without a full project that could reproduce the bug.
You can set the environment variable GB_DB_DEBUG=1, to see all SQL
requests that are sent to the sqlite backend. Maybe you will get more
information about the problem?
Regards,
--
Benoît Minisini
----[ http://gambaswiki.org/wiki/doc/netiquette ]----
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20211014/a59d1213/attachment.htm>
More information about the User
mailing list