Commit 733aeee8 authored by Cristiano Urban's avatar Cristiano Urban
Browse files

Added parent_relative_path field into insertNode() method in db_connector.py.

parent 4397cf57
Loading
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -43,8 +43,8 @@ class DbConnector(object):
            out.write(f"parentPath: {node.parentPath}\n\n")
            out.close()
            #print(f"parentLtreePath: {parentLtreePath}, type: {type(parentLtreePath)}")
            self.cursor.execute("INSERT INTO Node(parent_path, name, type, owner_id, creator_id, content_md5) VALUES (%s, %s, %s, %s, %s, %s);", 
                                (parentLtreePath, node.name, node.type, node.ownerID, node.creatorID, node.contentMD5,))
            self.cursor.execute("INSERT INTO Node(parent_path, parent_relative_path, name, type, owner_id, creator_id, content_md5) VALUES (%s, %s, %s, %s, %s, %s, %s);", 
                                (parentLtreePath, parentLtreePath, node.name, node.type, node.ownerID, node.creatorID, node.contentMD5,))
            self.conn.commit()

    def selectNode(self):
+26 −26

File changed.

Contains only whitespace changes.