src/Query/SqlQuery.php
public function injectSpecialBindings(
		string $sql,
		array $bindings
	):string {
		foreach(self::SPECIAL_BINDINGS as $special) {
			$specialPlaceholder = ":" . $special;

			if(!array_key_exists($special, $bindings)) {
				continue;
			}

			$replacement = $this->escapeSpecialBinding(
				$bindings[$special],
				$special
			);

			$sql = str_replace(
				$specialPlaceholder,
				$replacement,
				$sql
			);
			unset($bindings[$special]);
		}

		foreach($bindings as $key => $value) {
			if(is_array($value)) {
				$inString = "";

				foreach($value as $i => $innerValue) {
					$newKey = $key . "__" . $i;
					$keyParamString = ":$newKey";
					$inString .= "$keyParamString, ";
				}

				$inString = rtrim($inString, " ,");
				$sql = str_replace(
					":$key",
					$inString,
					$sql
				);
			}
		}

		return $sql;
	}
public function injectSpecialBindings(
		string $sql,
		array $bindings
	):string {
		foreach(self::SPECIAL_BINDINGS as $special) {
			$specialPlaceholder = ":" . $special;

			if(!array_key_exists($special, $bindings)) {
				continue;
			}

			$replacement = $this->escapeSpecialBinding(
				$bindings[$special],
				$special
			);

			$sql = str_replace(
				$specialPlaceholder,
				$replacement,
				$sql
			);
			unset($bindings[$special]);
		}

		foreach($bindings as $key => $value) {
			if(is_array($value)) {
				$inString = "";

				foreach($value as $i => $innerValue) {
					$newKey = $key . "__" . $i;
					$keyParamString = ":$newKey";
					$inString .= "$keyParamString, ";
				}

				$inString = rtrim($inString, " ,");
				$sql = str_replace(
					":$key",
					$inString,
					$sql
				);
			}
		}

		return $sql;
	}
Certain words are reserved for use by different SQL engines, such as "limit"
and "offset", and can't be used by the driver as bound parameters. This
function returns the SQL for the query after replacing the bound parameters
manually using string replacement.