Get Started

Where Syntax

Query

Transaction

Advanced

PDO object

Debug

Information

version: 1.1.3

last_query

Return the last query performed.

last_query()
Return: [string]
Like log(), but just return the last query.
$database->select("account", [
	"user_name",
	"email"
], [
	"user_id[<]" => 20
]);

$database->insert("account", [
	"user_name" => "foo",
	"email" => "foo@bar.com"
]);

echo $database->last_query();
// INSERT INTO "account" ("user_name", "email") VALUES ('foo', 'foo@bar.com')