Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [Default]
- Version = 7
- Number of Inputs = 0
- ; Default Value = 0
- Sanitize Input Value Check = false
- ; Default Value = True
- Sanitize Output Value Check = false
- ; Default Value = True
- String Datatype Check = false
- ; Default Value = True
- ; If Database Type is String adds Quotations around Text / VarChar DataTypes when retrieving Values
- ; Note: This Doesn't Work for Text DataTypes for MySQL but with Poco
- ; Important try to avoid this, will break whenever extDB updates to 1.6/1.7 Poco
- Strip = true
- ;Enable / Disable Strip
- Strip Chars = /\|;{}<>'
- ; Can't Strip Char : since its used as a divider in extDB.
- ; If you need it stripped you will need todo it in SQF Code.
- ; Note: if value contains divider :
- ; It will result in extDB reading to many input values + will return an error anyway.
- ; Important if you are using $INPUT_STRING_x, recommended you strip the char `
- ; That is the quotation char used to wrap strings
- Strip Chars Action = STRIP+LOG
- ; Actions NONE / STRIP / STRIP+LOG / STRIP+ERROR
- ; None
- ; Strip
- ; Strip + Add Logs to extDB Logs
- ; Strip + Error, doesnt execute SQL, reports error back to server
- Prepared Statement Cache = true
- ; Allows you disable to Caching Prepared Statements,
- ; Useful to disable Per Call, for the SQL Statements you are only going to run once i.e at server startup
- ; Also useful to disable global during testing, if you are altering Database Scheme on Live Server.
- ;; [CALL_NAME] INFO
- ;; ---------------------------------------
- ;; ---------------------------------------
- ;; SQLx_y x = SQL Statement Line y = SQL Statement Line x Part y
- ;; This allows for to define multiple SQL Prepared Statements to run with a single callextension.
- ;; Number of Inputs is the number of total inputs. If inputs received doesnt match this number. SQL Statement wont run.
- ;; SQLx_INPUTS is INPUTS to use for SQL Line x
- ;; OUPUT is same as SQLx_INPUTS
- ;; INPUT / OUTPUT Options
- ;; STRING Removes " from VALUE + then add " to either end of VALUE i.e "VALUE"
- ;; BEGUID Converts Value to BEGUID
- ;; CHECK Sanitize Check
- ;; NOCHECK
- ;; STRIP Strip Chars (overrides Default Setting)
- ;; STRIP
- ;; AltisLifeRPG_Array Converts Array format to Altis Life RPG format, for legacy support
- ;; They are separated by comma ,
- ;; Options themselves are tokenized by -
- ;; So the Option 1-STRING-BEGUID means INPUT VALUE 1 -> converted to BEGUID + quotes added (order of tokens makes no difference)
- ;;**************************************************************
- ;;**************************************************************
- ;; PROCEDURE CALLS
- ;;
- ;;______________________________________________________________
- [resetLifeVehicles]
- ;;
- SQL1_1 = CALL resetLifeVehicles;
- Number of Inputs = 0
- Prepared Statement Cache = false
- ;;______________________________________________________________
- [deleteDeadVehicles]
- ;;
- SQL1_1 = CALL deleteDeadVehicles;
- Number of Inputs = 0
- Prepared Statement Cache = false
- ;;______________________________________________________________
- [deleteOldHouses]
- ;;
- SQL1_1 = CALL deleteOldHouses;
- Number of Inputs = 0
- Prepared Statement Cache = false
- ;;______________________________________________________________
- [deleteOldGangs]
- ;;
- SQL1_1 = CALL deleteOldGangs;
- Number of Inputs = 0
- Prepared Statement Cache = false
- ;;**************************************************************
- ;;**************************************************************
- ;; GANGS
- ;;
- ;;______________________________________________________________
- [gangIDPlayer]
- ;;
- SQL1_1 = SELECT id FROM gangs WHERE members LIKE ? AND active='1';
- Number of Inputs = 1
- SQL1_INPUTS = 1
- ;;______________________________________________________________
- [gangNameSelectID]
- ;;
- SQL1_1 = SELECT id FROM gangs WHERE name=? AND active=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [gangOwnerSelectID]
- ;;
- SQL1_1 = SELECT id FROM gangs WHERE owner=? AND active=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [gangInsert]
- ;;
- SQL1_1 = INSERT INTO gangs (owner, name, members) VALUES(?,?,?);
- SQL1_INPUTS = 1, 2, 3-AltisLifeRPG_Array
- Number of Inputs = 3
- ;;______________________________________________________________
- [gangUpdate]
- ;;
- SQL1_1 = UPDATE gangs SET active=1, owner=?,members=? WHERE id=?;
- Number of Inputs = 3
- SQL1_INPUTS = 1, 2, 3-AltisLifeRPG_Array
- ;;______________________________________________________________
- [gangRemove]
- ;;
- SQL1_1 = UPDATE gangs SET active='0' WHERE id=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- ;;______________________________________________________________
- [gangInfo]
- ;; Get Gang Info
- ;;
- SQL1_1 = SELECT id, owner, name, maxmembers, bank, members FROM gangs WHERE active='1' AND members LIKE ?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1, 2-String, 3-String, 4, 5, 6-AltisLifeRPG_Array
- ;;______________________________________________________________
- [gangBankInfoUpdate]
- ;; Update Gang Bank
- ;;
- SQL1_1 = UPDATE gangs SET bank=? WHERE id=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [gangInfoUpdate]
- ;; Update Gang Info
- ;;
- SQL1_1 = UPDATE gangs SET bank=?, maxmembers=?, owner=? WHERE id=?;
- SQL1_INPUTS = 1, 2, 3-String, 4
- Number of Inputs = 4
- ;;______________________________________________________________
- [gangMaxMembersUpdate]
- ;; Update Gang Max Members
- ;;
- SQL1_1 = UPDATE gangs SET maxmembers=? WHERE id=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [gangMembersUpdate]
- ;; Update Gang Members
- ;;
- SQL1_1 = UPDATE gangs SET members=? WHERE id=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [gangOwnerUpdate]
- ;; Update Gang Owner
- ;;
- SQL1_1 = UPDATE gangs SET owner=? WHERE id=?;
- SQL1_INPUTS = 1,2
- Number of Inputs = 2
- ;;**************************************************************
- ;;**************************************************************
- ;; PLAYERS
- ;;
- ;;______________________________________________________________
- [playerInfo]
- ;;
- SQL1_1 = SELECT playerid, name FROM players WHERE playerid=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1, 2
- ;;______________________________________________________________
- [playerInfoInsert]
- ;;
- SQL1_1 = INSERT INTO players
- ;; 1 2 3 4 5 6 7 8 9 10 11
- SQL1_2 = (playerid, name, cash, bankacc, aliases, cop_licenses, med_licenses, civ_licenses, civ_gear, cop_gear, med_gear)
- SQL1_3 = VALUES(?,?,?,?,?,?,?,?,?,?,?)
- SQL1_INPUTS = 1, 2-STRING, 3, 4, 5, 6, 7, 8, 9, 10, 11
- Number of Inputs = 11
- ;;______________________________________________________________
- [playerWestInfo]
- ;;
- 1 2 3 4 5 6 7 8 9 10
- SQL1_1 = SELECT playerid, name, cash, bankacc, adminlevel, donatorlvl, cop_licenses, coplevel, cop_gear, blacklist FROM players WHERE playerid=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-String, 2-String, 3, 4, 5-String, 6-String, 7-AltisLifeRPG_Array, 8-String, 9-AltisLifeRPG_Array, 10
- ;;______________________________________________________________
- [playerCivInfo]
- ;;
- ;; 1 2 3 4 5 6 7 8 9
- SQL1_1 = SELECT playerid, name, cash, bankacc, adminlevel, donatorlvl, civ_licenses, arrested, civ_gear FROM players WHERE playerid=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-String, 2-String, 3, 4, 5-String, 6-String, 7-AltisLifeRPG_Array, 8-String, 9-AltisLifeRPG_Array
- ;;______________________________________________________________
- [playerIndependentInfo]
- ;;
- 1 2 3 4 5 6 7 8 9
- SQL1_1 = SELECT playerid, name, cash, bankacc, adminlevel, donatorlvl, med_licenses, mediclevel, med_gear FROM players WHERE playerid=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-String, 2-String, 3, 4, 5-String, 6-String, 7-AltisLifeRPG_Array, 8-String, 9-AltisLifeRPG_Array
- ;;______________________________________________________________
- [playerWestUpdate]
- ;;
- SQL1_1 = UPDATE players
- ;; 1 2 3 4 5 6
- SQL1_2 = SET name=?, cash=?, bankacc=?, cop_gear=?, cop_licenses=? WHERE playerid=?
- SQL1_INPUTS = 1, 2, 3, 4-AltisLifeRPG_Array, 5-AltisLifeRPG_Array, 6
- Number of Inputs = 6
- ;;______________________________________________________________
- [playerCivilianUpdate]
- ;;
- SQL1_1 = UPDATE players
- ;; 1 2 3 4 5 6 7
- SQL1_2 = SET name=?, cash=?, bankacc=?, civ_licenses=?, civ_gear=?, arrested=? WHERE playerid=?;
- SQL1_INPUTS = 1, 2, 3, 4-AltisLifeRPG_Array, 5-AltisLifeRPG_Array, 6, 7
- Number of Inputs = 7
- ;;______________________________________________________________
- [playerIndependentUpdate]
- ;;
- SQL1_1 = UPDATE players
- ;; 1 2 3 4 5 6
- SQL1_2 = SET name=?, cash=?, bankacc=?, med_licenses=?, med_gear=?, WHERE playerid=?;
- SQL1_INPUTS = 1, 2, 3, 4-AltisLifeRPG_Array, 5-AltisLifeRPG_Array, 6
- Number of Inputs = 6
- ;;______________________________________________________________
- [playerUpdateCash]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET cash=? WHERE playerid=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateBank]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET bankacc=? WHERE playerid=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateBank+Cash]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET cash=?, bankacc=? WHERE playerid=?;
- SQL1_INPUTS = 1, 2, 3
- Number of Inputs = 3
- ;;______________________________________________________________
- [playerUpdateCopLicense]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET cop_licenses=? WHERE playerid=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateCivLicense]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET civ_licenses=? WHERE playerid=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateMedLicense]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET med_licenses=? WHERE playerid=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateCopGear]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET cop_gear=? WHERE playerid=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateCivGear]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET civ_gear=? WHERE playerid=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateMedGear]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET med_gear=? WHERE playerid=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateAlive]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET alive=? WHERE playerid=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [playerUpdateArrested]
- ;;
- SQL1_1 = UPDATE players
- SQL1_2 = SET arrested=? WHERE playerid=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- ;;**************************************************************
- ;;**************************************************************
- ;; VEHICLES
- ;;
- ;;______________________________________________________________
- [vehicleDead]
- ;;
- SQL1_1 = UPDATE vehicles SET alive=? WHERE pid=? AND plate=?;
- SQL1_INPUTS = 1, 2, 3
- Number of Inputs = 3
- ;;______________________________________________________________
- [vehicleInsert]
- ;;
- SQL1_1 = INSERT INTO vehicles
- ;; 1 2 3 4 5 6 7 8 9
- SQL1_2 = (side, classname, type, pid, alive, active, inventory, color, plate)
- SQL1_3 = VALUES (?,?,?,?,?,?,?,?,?);
- SQL1_INPUTS = 1, 2, 3, 4, 5, 6, 7-AltisLifeRPG_Array, 8, 9
- Number of Inputs = 9
- ;;______________________________________________________________
- [vehicleInfo]
- ;;
- ;; 1 2 3 4 5 6 7 8 9
- SQL1_1 = SELECT id, side, classname, type, pid, alive, active, plate, color
- SQL1_2 = FROM vehicles WHERE id=? AND pid=?;
- SQL1_INPUTS = 1, 2
- Number of Inputs = 2
- OUTPUT = 1, 2-String, 3-String, 4-String, 5-String, 6, 7, 8, 9
- ;;______________________________________________________________
- [vehiclesInfo]
- ;;
- ;; 1 2 3 4 5 6 7 8 9
- SQL1_1 = SELECT id, side, classname, type, pid, alive, active, plate, color
- SQL1_2 = FROM vehicles WHERE pid=? AND alive=1 AND active = 0 AND side=? AND type=?;
- SQL1_INPUTS = 1, 2, 3
- Number of Inputs = 3
- OUTPUT = 1, 2-String, 3-String, 4-String, 5-String, 6, 7, 8, 9
- ;;______________________________________________________________
- [vehicleUpdateActive]
- ;;
- SQL1_1 = UPDATE vehicles SET active=? WHERE pid=? AND id=?;
- SQL1_INPUTS = 1, 2, 3
- Number of Inputs = 3
- ;;______________________________________________________________
- [vehicleUpdateActivePlate]
- ;;
- SQL1_1 = UPDATE vehicles SET active=? WHERE pid=? AND plate=?;
- SQL1_INPUTS = 1, 2, 3
- Number of Inputs = 3
- ;;______________________________________________________________
- [vehicleUpdateAlive]
- ;;
- SQL1_1 = UPDATE vehicles SET alive=? WHERE pid=? AND id=?;
- SQL1_INPUTS = 1, 2, 3
- Number of Inputs = 3
- ;;______________________________________________________________
- [vehicleUpdateAlivePlate]
- ;;
- SQL1_1 = UPDATE vehicles SET alive=? WHERE pid=? AND plate=?;
- SQL1_INPUTS = 1, 2, 3
- Number of Inputs = 3
- ;;**************************************************************
- ;;**************************************************************
- ;; Wanted System
- ;;
- ;;______________________________________________________________
- [housingCount]
- ;;
- SQL1_1 = SELECT COUNT(*) FROM houses WHERE owned='1';
- Number of Inputs = 0
- ;;______________________________________________________________
- [housingInit]
- ;;
- SQL1_1 = SELECT houses.id, houses.pid, houses.pos, players.name FROM houses INNER JOIN players ON houses.pid=players.playerid WHERE houses.owned='1' LIMIT ?,10;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1, 2-String, 3-String, 4-String
- ;;______________________________________________________________
- [housingFetchPlayerHouse]
- ;;
- SQL1_1 = SELECT pid, pos, inventory, containers FROM houses WHERE pid=? AND owned='1';
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-String, 2-String, 3-AltisLifeRPG_Array, 4-AltisLifeRPG_Array
- ;;______________________________________________________________
- [housingCheckHouse]
- ;;
- SQL_1 = SELECT id FROM houses WHERE pos=? AND owned='1';
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1
- ;;______________________________________________________________
- [housingAddHouse]
- ;;
- SQL1_1 = INSERT INTO houses (pid, pos, inventory, containers, owned)
- SQL1_2 = VALUES(?,?,?,?,?);
- SQL1_INPUTS = 1, 2, 3-AltisLifeRPG_Array, 4-AltisLifeRPG_Array, 5
- SQL2_1 = SELECT id FROM houses WHERE pos=? AND pid=? AND owned='1';
- SQL2_INPUTS = 2, 1
- Number of Inputs = 5
- OUTPUT = 1
- ;;______________________________________________________________
- [housingSellHouse]
- ;;
- SQL1_1 = UPDATE houses SET owned='0', pos='[]' WHERE pid=? AND pos=? AND owned='1';
- SQL1_INPUTS = 1, 2, 3
- Number of Inputs = 3
- ;;______________________________________________________________
- [housingSellHouse2]
- ;;
- SQL1_1 = UPDATE houses SET owned='0', pos='[]' WHERE id=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- ;;______________________________________________________________
- [houseUpdateContainer]
- ;;
- SQL1_1 = UPDATE houses SET containers=? WHERE id=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [housingUpdateInventory]
- ;;
- SQL1_1 = UPDATE houses SET inventory=? WHERE id=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2
- Number of Inputs = 2
- ;;______________________________________________________________
- [housingCleanup]
- ;;
- SQL1_1 = SELECT pid, pos, inventory, containers FROM houses WHERE pid=? AND owned='1';
- SQL1_INPUTS = 1
- Number of Inputs = 1
- ;;**************************************************************
- ;;**************************************************************
- ;; Wanted System
- ;;
- ;;______________________________________________________________
- [wantedGetCrimes]
- ;;
- SQL1_1 = SELECT wantedID, wantedCrimes FROM wanted WHERE wantedID=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-String, 2-AltisLifeRPG_Array
- ;;______________________________________________________________
- [wantedUpdateCrimes]
- ;;
- SQL1_1 = UPDATE wanted SET wantedCrimes = ?, wantedBounty = wantedBounty + ?, active = '1' WHERE wantedID=?;
- SQL1_INPUTS = 1-AltisLifeRPG_Array, 2, 3
- Number of Inputs = 3
- ;;______________________________________________________________
- [wantedInsertCrimes]
- ;;
- SQL1_1 = INSERT INTO wanted (wantedID, wantedName, wantedCrimes, wantedBounty, active)
- SQL1_2 = VALUES(?,?,?,?,?);
- SQL1_INPUTS = 1, 2, 3, 4-AltisLifeRPG_Array, 5
- Number of Inputs = 5
- ;;______________________________________________________________
- [wantedFetchBounty]
- ;;
- SQL1_1 = SELECT wantedID, wantedName, wantedCrimes, wantedBounty FROM wanted WHERE active='1' AND wantedID=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-String, 2-String, 3-AltisLifeRPG_Array, 4
- ;;______________________________________________________________
- [wantedFetchCrimes]
- ;;
- SQL1_1 = SELECT wantedCrimes, wantedBounty FROM wanted WHERE active='1' AND wantedID=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-AltisLifeRPG_Array, 2
- ;;______________________________________________________________
- [wantedFetchID]
- ;;
- SQL1_1 = SELECT wantedID, wantedName FROM wanted WHERE active='1' AND wantedID in (?);
- SQL1_INPUTS = 1-STRIP
- Number of Inputs = 1
- OUTPUT = 1-String, 2-String
- ;;______________________________________________________________
- [wantedFetchPerson]
- ;;
- SQL1_1 = SELECT wantedID, wantedName, wantedBounty FROM wanted WHERE wantedID=? AND active='1';
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-String, 2-String, 3
- ;;______________________________________________________________
- [wantedFetchName]
- ;;
- SQL1_1 = SELECT wantedName FROM wanted WHERE wantedID=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
- OUTPUT = 1-String
- ;;______________________________________________________________
- [wantedUpdateName]
- ;;
- SQL1_1 = UPDATE wanted SET wantedName=? WHERE wantedID=?;
- SQL1_INPUTS = 1,2
- Number of Inputs = 2
- ;;______________________________________________________________
- [wantedRemoveCrimes]
- ;;
- SQL1_1 = UPDATE wanted SET active = 0, wantedCrimes = '[]', wantedBounty = 0 WHERE wantedID=?;
- SQL1_INPUTS = 1
- Number of Inputs = 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement