There is nothing particularly magic about JDBC. It's just an implementation of a RDBMS' communication protocol either implemented in Java or a Java wrapper around a C library that implements the protocol. If you have access to the source of the JDBC driver in question, you could probably use that for inspiration in creating a driver in golang. If not, I'd look to see if there are C drivers for the RDBMS.
You could interface with a JDBC driver but then you have to deal with making sure there is a Java runtime installed. You have to deal with the headache of native-to-java library calls. It's a mess, really. One final option could be to write yourself a restful or some other kind of service in Java which will run the queries for you and return your results. All the typical warnings about security risks, injection attacks, etc. It would be better to write an actual service than something that just consumed SQL and returned results. It's not pure Go, but that's OK. Use Java where it makes sense and use Go where it makes sense. On Sat, Apr 14, 2018 at 7:51 AM, Asif Jalil <asif.m.ja...@gmail.com> wrote: > If Netezza can work with IBM CLI interface, then you can check out the Go > CLI driver that I wrote for DB2: https://github.com/asifjalil/cli. > > Thanks. > > On Friday, April 13, 2018 at 2:49:59 PM UTC-4, Ken Bailey wrote: >> >> So at my new Job I'm the only one using Go and it's going quite well, but >> i'm having to extract data from our Netezza database using java or python, >> load it into .csv files and then work with it using Go. I'd much rather use >> Go for everything, especially as I'm planning to build some tools that >> would require me to have direct DB access. >> >> I've done some research and I haven't been able to find any Go JDBC >> drivers that are currently being developed or full featured. The closest >> I've found is >> https://github.com/japettyjohn/go-jdbc but development >> stopped about 3 years ago. >> >> I'd definitely be willing to dedicate the time and write this myself so >> the community can benefit, but I have a couple questions before I get >> started. >> 1. Am I missing something? Is there a library out there that allows for >> what I'm trying to do? >> 2. Does anyone have any experience writing a JDBC driver? >> 3. Is this a worthwhile endeavor? Is there a reason a full featured Go >> JDBC driver doesn't exist? >> 4. Would anyone like to join me on this journey? >> >> I appreciate your time. >> >> Ken >> > -- > You received this message because you are subscribed to the Google Groups > "golang-nuts" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to golang-nuts+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/d/optout. > -- Philip A. Chapman Java Software Development Enterprise, Web, and Desktop -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.