Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Database C++

Please tell me how to connect to the database server via C ++? I tried to MySQL, but I constantly crawl errors due to the fact that ConnectorC ++ for MySQL compiled on VS2010, and I'm using VS2017. Can I use SQLite for MMO project?

Product Version: Not Selected
more ▼

asked Jan 09 '17 at 02:50 AM in C++ Programming

avatar image

129 13 22 35

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

Yes, you can use any database you want with UE4, but you have to use unmanaged C++ libraries to access the database.

Since I have been working on connecting UE4 to a backend database for the past 2 years, I will let you know some of what has worked for me and what hasn't.

So I started out like you and tried to directly connect Microsoft SQL to my dedicated UE4 server so I could build an MMO. I got it all working, but quickly realized that it doesn't scale well and was fairly ugly and hard to manage. So then I built a brand new database system that sits behind a web API and is accessed from UE4 using JSON calls. This is working much better now. It also allows me to easily scale up to dozens of servers and create a world of any size I want that can accommodate thousands of players.

The JSON server is built with ASP .NET / MVC 5. I originally used the VaREST plugin to connect to my JSON server, but now I just use direct HTTP calls.

If you have any specific questions, let me know.

more ▼

answered Jan 09 '17 at 03:02 AM

avatar image

2.6k 63 28 281

avatar image NODARYN Jan 09 '17 at 04:39 AM

Well, thank you very much for your help. I would like to know whether it is possible to build a MMO using a SQLite database? Is it possible to find a hosting with the ability to install SQLite?

avatar image Dartanlla Jan 09 '17 at 05:00 AM

I've done it, so it is definitely possible. It is a lot of work though. I spent the last 6 months building my system. For development purposes you can just run SQLite directly on your PC. When you need to do more complicated testing you can use cheap virtual hosts. Microsoft SQL Express is free, so I personally prefer it over SQLite.

avatar image NODARYN Jan 09 '17 at 05:34 AM

Well, thanks for the help. Sorry for my English, I use Google translator, I'm from Russia :) As far as I understand to use the JSON, neobhodibo work with PHP? I do not know much the whole system, you will forgive me ... I would like to work directly, using only the features of C ++.

avatar image theonecalledtom Jan 09 '17 at 05:55 AM

I've spent the last year working with AWS DynamoDB from within Unreal. Similar HTTP request with Json data approach.

The header signing process took me a while. If I were to start from scratch I'd take a much harder look at integrating a library to do it (think that the open source lib would be where I'd start looking).

No idea how the AW services map to your problem, but they definitely scale well!

avatar image NODARYN Jan 10 '17 at 01:55 AM

Sorry for these stupid questions, I am a beginner programmer: how to get a JSON string from a site using C ++? Do I need to do to use the sockets?

avatar image NODARYN Jan 10 '17 at 06:28 AM

Thank you so much!

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Hope this plugin can help you.

HiSQLite3( SQLite3 For UE4)

more ▼

answered Apr 27 '18 at 01:53 AM

avatar image

0 4 5

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question