So, from what I collect, you are stuck in two tables. One with the integer col, one with the string col.
Class Marker _marker_key_ primary_key
Another has
Class MarkerType _marker_type_key = primary_key name = String
When I read it, you want the Class Marker to have many lines of Class MarkerType that you can easily manipulate or invoke. Although, I'm not quite sure what you want.
If so, you can achieve this by believing that you control the seeding of the database. You can create a flag at the beginning of each name that points to the Markers primary key.
Example: MarkerType.name = 10324_Orange
I am not familiar with the use of SQLAlchemy without sessions and do not really like doing research, so I will just write my answer, assuming you are using SQLAlchemy sessions, so you can get the concept and configure it necessary.
Here you can add additional flags to the name bar. Things like attribute type.
Marker.id = 193 MarkerType.id = 1 MarkerType.name = "193_color_Black" MarkerType.id = 2 MarkerType.name = "193_style_Fine"
This optional flag allows you to search for common attributes, specific names associated with your particular string, and is much more useful, albeit a bit more complicated. It really depends on your use case.
source share