Skip to content

Segmentation fault occurs while using on-disk database #15

Closed
@ismailtzn

Description

@ismailtzn

Hi,
I was trying to use CrossDB. However, when I try to open the on-disk database , I get a segmentation fault.

I changed line 8 of example.c to xdb_conn_t *pConn = xdb_open("tmp/test_123_db");. When I try to run the executable twice, it gives the following error messages for the second run:

[XDB Error] 9: 'CREATE TABLE student (  id               INT,  name             CHAR(16),  age              INT,  class            CHAR(16),  score            FLOAT,  info             CHAR(255),  PRIMARY KEY (id) XOID=0) XOID=0' ERROR 1 : Failed to create table 'student'
[XDB Error] 17: 'CREATE TABLE teacher (  id               INT,  name             CHAR(16),  age              INT,  info             CHAR(255),  PRIMARY KEY (id) XOID=0,  KEY         name_2 (name) XOID=1) XOID=1' ERROR 1 : Failed to create table 'teacher'
[1]    173601 segmentation fault (core dumped)

Instead of using xdb_open("tmp/test_123_db") I tried using xdb_exec(pConn, "OPEN DATABASE 'tmp/test_123_db'"); and it still gives a segmentation fault.

Can you investigate the problem?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions