#13 Neat!

Open
opened 3 years ago by gabe · 6 comments
gabe commented 3 years ago

Got your email this morning, but haven't been able to write back, as my mail servers hard drive died completely last week (: I have mail delivery working again, but haven't gotten sending back online yet!

This is cool... I'll check it out. I wrote something somewhat similar back in the day... with php but it would write the db schema out to xml and then you could apply an xslt transform to it to make data access objects in any language you wanted to take the time to write all that xslt in!

I only ever used it for generating code for php, but it definitely was a time saver.

Got your email this morning, but haven't been able to write back, as my mail servers hard drive died completely last week (: I have mail delivery working again, but haven't gotten sending back online yet! This is cool... I'll check it out. I wrote something somewhat similar back in the day... with php but it would write the db schema out to xml and then you could apply an xslt transform to it to make data access objects in any language you wanted to take the time to write all that xslt in! I only ever used it for generating code for php, but it definitely was a time saver.
otremblay commented 3 years ago
Owner

In principle you could achieve this with autoapi as well, just, using go templates and a few parameters. I now kinda see that my generators are redundant in nature, they basically all grab table data, a few custom parameters that I pass to the view, and a view to which everything is passed. For my own intents and purposes, this is really just a way of not writing yet another piece of DB code looking exactly like the three pieces of DB code I wrote last. :P Also as a bonus I map them to an HTTP endpoint, which is really the bulk of the job. Then I can focus on writing my business logic.

In principle you could achieve this with autoapi as well, just, using go templates and a few parameters. I now kinda see that my generators are redundant in nature, they basically all grab table data, a few custom parameters that I pass to the view, and a view to which everything is passed. For my own intents and purposes, this is really just a way of not writing yet another piece of DB code looking exactly like the three pieces of DB code I wrote last. :P Also as a bonus I map them to an HTTP endpoint, which is really the bulk of the job. Then I can focus on writing my business logic.
otremblay commented 2 years ago
Owner

Trying out upload, please ignore

Trying out upload, please ignore
otremblay commented 2 years ago
Owner

Trying out upload, please ignore

Trying out upload, please ignore
otremblay commented 2 years ago
Owner

Trying out upload, please ignore

Trying out upload, please ignore
otremblay commented 2 years ago
Owner

Please ignore test

Please ignore test
otremblay commented 2 years ago
Owner

Please ignore, upload test

Please ignore, upload test
Sign up for free to join this conversation. Already have an account? Sign in to comment
No Milestone
No assignee
Loading...
Cancel
Save
There is no content yet.