error c2227 left of NewNodeType-> must point to class/struct/union/generic type

191 views
Skip to first unread message

Marwa Elabri

unread,
May 30, 2015, 11:25:23 AM5/30/15
to spar...@googlegroups.com
Hello
i'm new in sparksee i tried the creation of HelloSparksee graph database but when i typed code ginven in the starting guide
#include "stdafx.h"
#include "gdb/Sparksee.h"
#include "gdb/Database.h"
#include "gdb/Session.h"
#include "gdb/Graph.h"
#include "gdb/Objects.h"
#include "gdb/ObjectsIterator.h"

using namespace sparksee::gdb;
int main(int argc , char *argv[])
{
SparkseeConfig cfg;
Sparksee *sparksee = new Sparksee(cfg);
Database * db = sparksee ->Create(L"HelloSparksee.gdb", L"HelloSparksee");
Session * sess = db->NewSession();
Graph * graph = sess ->GetGraph();
// Add a node type for the movies , with a unique identifier and two indexed attributes
type_t movieType = g->NewNodeType(L"MOVIE");
attr_t movieIdType = g->NewAttribute(movieType , L"ID", Long , Unique);
attr_t movieTitleType = g->NewAttribute(movieType , L"TITLE", String , Indexed);
attr_t movieYearType = g->NewAttribute(movieType , L"YEAR", Integer , Indexed);


i get these errors:
error c2065 c++ undeclared identifier
error c2227 left of NewNodeType-> must point to class/struct/union/generic type
error c2227 left of NewAttributee-> must point to class/struct/union/generic type

please can you help me

c3po.ac

unread,
Jun 2, 2015, 5:32:08 AM6/2/15
to spar...@googlegroups.com, marwa...@gmail.com
Hi,

It looks like the compiler can't find the Sparksee includes.
Please check that you have included the right path in the compiler additional includes:
http://www.sparsity-technologies.com/UserManual/Installation.html#windows-users

Best regards.

El dissabte, 30 maig de 2015 17:25:23 UTC+2, Marwa Elabri va escriure:

Marwa Elabri

unread,
Jun 2, 2015, 8:18:01 AM6/2/15
to spar...@googlegroups.com, marwa...@gmail.com
hi
i checked but i have included the right path because i followed the same document that you gave to me 
always the same errors :(

c3po.ac

unread,
Jun 3, 2015, 8:47:11 AM6/3/15
to spar...@googlegroups.com, marwa...@gmail.com
Hi,

I just tried the same HelloSparksee with VS2010 following the same instructions and worked fine for me.
If you send your Visual Studio project to dam...@sparsity-technologies.com we may try to check if any settings are causing the errors.

Thanks.


El dimarts, 2 juny de 2015 14:18:01 UTC+2, Marwa Elabri va escriure:
Reply all
Reply to author
Forward
0 new messages