Hi,
I've a table on SqlServer where a column type should be undefined, I mean, it should be able to contain any kind of type (string, int, boolean and datetime).
This because my users should be able to define which type the column is for each record. In the past when I encountered this problem I decided to create it as nvachar(MAX). When I accessed the value I automatically casted the string to the correct type. I know that this method wastes a lot of memory and has a performance implications.
Maybe is possible to create a different table for each type but I never had the time to test that.
Do you have any thoughts?
Thanks!