I am trying to write a home made database, and my approach is to use a linked list of linked lists. The first linked list is the db and the underlying linked lists are the db tables. I am having trouble in my display method finding a table by name.
Line 35: You can't do an assignment in a class declaration. You need to do this in Link's constructor.
Line 131: You're modifying the head of your list. This is a memory leak. You will lose the entries you pass.
You need to investigate inheritance. You're intermixing functions related to tables within your database along with columns within a table within the same class (Link). This is poor design.
You need to look at using std::list. There is no reason to write your own linked list class when one already exists.
I suggest you rethink your class structure. Consider a DataBase class which contains a std::list of dbTables. A dbTable should contain a std::list of columns.
Line 136: Why are you passing L in? You're not using it.
Line 140: What's the point of creating a new dbTable instance here?
Line 141: dbTable has no default constructor, so current->table points to an uninitialized dbTable entry.
Line 149: The only way to get here is if current == NULL, therefore, you're trying to delete a NULL pointer. Guaranteed to crash your program.
Line 152: Why are you passing in L? You never use it.
Line 154: Link has no default constructor, therefore all variables in current and temp are undefined.
Line 156: What's the point of creating a new dbTable here?
Line 157: What's the point of this statement? It does nothing.
Line 161,168: Members of current are initialized.