Kotlin connect database

I’m trying to make an e-commerce application with kotlin and I need to use relational database. What should I use? I’m looking for so long and I still can’t find a convenient database.

If you can not find a database that fit’s your need you might have some special requirements you probably want to share with us to get better recommendations. My default is PosgreSQL which is mature, fast, reliable and feature rich.

It’s an e-commerce application. Actually I don’t have special requirements but I’m pretty new at Kotlin and I just know a few databases and I can’t connect them. I try to connect MySQL but I can’t find enough sources. I was thinking Firebase but as I see ıt’s not a relational database. I search what else should I use but there’s not many sources about it as I found.

The missing keyword is probably “JDBC” (Java Data Base Connectivity). There are JDBC drivers for almost all relational databases.

Maybe it is a good idea to use a framework like Spring Boot or Quarkus that does some of the heavy lifting for you. It is for example very easy to configure a complete project including a JDBC driver online: https://start.spring.io/

It is always better to describe what did you try and what problems did you encounter. Otherwise, it sounds like you spent 30 minutes on it and then gave up. The internet is full of articles on how to connect Kotlin/Java to MySQL, so it is surprising when you say you can’t find sources.

1 Like

Thank you very much, I will use that.

I especially search for Kotlin connect to MySQL sources. There was some websites and just a few videos about it and it wasn’t enough for me to use it. There is probably more sources about java connection but I didn’t know how to use it inside kotlin. So simply my question was a relational database for kotlin and that is the only thing I’m looking for. But thank you for sharing your opinion. I will describe my problems better in my other questions.

It is basically the same for Java and Kotlin, just the syntax is probably a bit different, but the API itself is the same (since it is most likely written in Java).