{"html_url": "https://github.com/simonw/sqlite-utils/issues/77#issuecomment-580527238", "issue_url": "https://api.github.com/repos/simonw/sqlite-utils/issues/77", "id": 580527238, "node_id": "MDEyOklzc3VlQ29tbWVudDU4MDUyNzIzOA==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2020-01-31T00:34:02Z", "updated_at": "2020-01-31T00:34:02Z", "author_association": "OWNER", "body": "Documentation: https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-conversions", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 557825032, "label": "Ability to insert data that is transformed by a SQL function"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/sqlite-utils/issues/77#issuecomment-580515506", "issue_url": "https://api.github.com/repos/simonw/sqlite-utils/issues/77", "id": 580515506, "node_id": "MDEyOklzc3VlQ29tbWVudDU4MDUxNTUwNg==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2020-01-30T23:48:41Z", "updated_at": "2020-01-30T23:48:41Z", "author_association": "OWNER", "body": "Potential design: a `conversions={}` option. Used like this:\r\n```python\r\ndb[table].insert(record, conversions={\"geom\": \"GeomFromText(?, 4326)\"})\r\n```\r\nThe `conversions=` key would be supported on `.insert()`, `.insert_all()`, `.upsert()` etc. It could also be passed to the `db.table()` constructor function:\r\n```python\r\ntable = db.table(\r\n \"features\",\r\n pk=\"id\",\r\n conversions={\r\n \"geom\": \"GeomFromText(?, 4326)\"\r\n }\r\n)\r\n# Then used like this:\r\ntable.insert(record)\r\n```", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 557825032, "label": "Ability to insert data that is transformed by a SQL function"}, "performed_via_github_app": null}