Hi,
I'm experiencing something strange when passing from ->create mode of the db to ->open mode of the db..
/QuestionMark$ ls -a
. .. CGraph.cpp sparksee.cfg
Database *db = sparksee->Create(L"CGraph.gdb", L"CGraph");
std::array<std::string, 3> FrankArray = {"FatherOf", "Spouse", "BrotherOf"};
std::wstring RelationshipType( FrankArray[0].begin(), FrankArray[0].end() );
time ./CGraph
CNODE has to be created from scratch
RelationshipType= FatherOf
relTypeId= 0
FatherOf HAS TO BE INSERTED in DB
I switch to the open mode:
Database *db = sparksee->Open(L"CGraph.gdb", L"CGraph");
but with the same edge type
time ./CGraph
CNODE already present
RelationshipType= FatherOf
relTypeId= 9
FatherOf already present
Bu when still in open mode but with a new edge to insert:
std::array<std::string, 3> FrankArray = {"FatherOf", "Spouse", "BrotherOf"};
std::wstring RelationshipType( FrankArray[1].begin(), FrankArray[1].end() );
I have a crash:
time ./CGraph
CNODE already present
RelationshipType= Spouse
relTypeId= 0
Spouse HAS TO BE INSERTED in DB
terminate called after throwing an instance of 'sparksee::gdb::Error'
**** CRITICAL ERROR (SIGNAL NUM 6)
------- Begin of call stack ------
/home/frank/sparkseecpp-5.2.0/lib/linux64/libsparksee.so(_ZN13sparksee_core21CallStackTraceHandler13SignalHandlerEi+0x28) [0x7fd8233319a8]
/lib/x86_64-linux-gnu/libc.so.6(+0x36d40) [0x7fd822944d40]
/lib/x86_64-linux-gnu/libc.so.6(gsignal+0x39) [0x7fd822944cc9]
/lib/x86_64-linux-gnu/libc.so.6(abort+0x148) [0x7fd8229480d8]
/usr/lib/x86_64-linux-gnu/libstdc++.so.6(_ZN9__gnu_cxx27__verbose_terminate_handlerEv+0x15d) [0x7fd822f536dd]
/usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x67746) [0x7fd822f51746]
/usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x67791) [0x7fd822f51791]
/usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x679a8) [0x7fd822f519a8]
/home/frank/sparkseecpp-5.2.0/lib/linux64/libsparksee.so(_ZN8sparksee3gdb5Graph11NewEdgeTypeERKSbIwSt11char_traitsIwESaIwEEbb+0x74) [0x7fd8232e9e54]
./CGraph() [0x4019d8]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf5) [0x7fd82292fec5]
./CGraph() [0x401b59]
-------- End of call stack -------
So...
what to do in order to be able to insert new edges into an already existing DB?
Attached the file used.
Looking forward to hearing from you for this important matter.
Frank