Garry's Mod Wiki

Revision Difference

sql#527452

<type name="sql" category="libraryfunc" is="library"> <summary>The SQL library allows you to access powerful database software included with Garry's Mod. It is the preferred and fastest method of storing large amounts of data. The database is located in sv.db serverside and cl.db clientside, both in the Garry's Mod base folder. SQL is a whole scripting language in itself although relatively simple, it's something you'll need to read up on before using this library. ⤶ That start to use it, download the latest module for your server's operating system and architecture using the links from this page: https://github.com/FredyH/MySQLOO . Then you should download zip and move catalog `lua` from archive to `GarrysMod/garrysmod`. For DarkRP mode - open `addons/darkrpmodification/lua/darkrp_config/mysql.lua` and change `RP_MySQLConfig.EnableMySQL = true`⤶ Known GMod SQL settings: * No `ATTACH` and `DETACH` operations (`SQLITE_OMIT_ATTACH = 1`) * No Virtual Tables (`SQLITE_OMIT_VIRTUALTABLE = 1`) * Temp files are stored in memory (`SQLITE_TEMP_STORE = 3`) * No `VACUUM` operation</summary> </type>