Well, I kept trying to figure it out.
I need this table to be global. I realized that it is much less efficient to pass the TableID around ... as part of my program.
So, I tried to create a new table and then look at it:
TableID = ets:new(tb, [set,public]), put({tableUniqueID}, TableID),
Then I used:
get({tableUniqueID})
And in the same function, it returns the TableID just fine ... but when I use it in another function, it returns undefined.
What?? I thought that to receive and deliver a key global.
ALSO before that, I realized that you "can" call the table search function as such:
ets:lookup(get({tableUniqueID}), msgIn)
The same thing works in functions, but not on the outside .. Get Put problem ..
Then I realized that another way to search for a table would be by calling the table atom
ets:lookup(tb, msgIn)
But this NEVER works, not inside a function, not from.
So, my main priority would be to understand why it is impossible to find a table with your atom. But it says it is everywhere, including leadership.
To get / put I could live without it, while I can store the table, and then search for the table by its atom identifier.
Can anyone shed light on this dilemma?