3 ms·
> Human-readable text, file paths, SQL statements, and others are all conceptually different, and this should be represented as different types at the language
by mpweiher 11y ago
> Human-readable text, file paths, SQL statements, and others are all conceptually different, and this should be represented as different types at the language level.
Objective-Smalltalk[1] has Polymorphic Identifiers[2][3], which are URIs used as identifiers in the language. So that handles file paths and web addresses. SQL is not solved directly, but XPath can be encoded in the URI and there are mappings from relational DB APIs to URIs[4][5][6].
I hope we can get rid of identifiers encoded as strings once and for all.
[1] http://objective.st/URIs http://objective.st/URIs
[2] http://dl.acm.org/citation.cfm?id=2508169 http://dl.acm.org/citation.cfm?id=2508169
[3] https://www.hpi.uni-potsdam.de/hirschfeld/publications/media/WeiherHirschfeld_2013_PolymorphicIdentifiersUniformResourceAccessInObjectiveSmalltalk_AcmDL.pdf https://www.hpi.uni-potsdam.de/hirschfeld/publications/media...
[4] http://blog.dreamfactory.com/add-a-rest-api-to-any-sql-db-in-minutes http://blog.dreamfactory.com/add-a-rest-api-to-any-sql-db-in...
[5] http://restsql.org/doc/Overview.html http://restsql.org/doc/Overview.html
[6] http://www.slashdb.com http://www.slashdb.com