Home
last modified time | relevance | path

Searched refs:sql (Results 26 – 50 of 186) sorted by last modified time

12345678

/plugin/sqlite/_test/
H A DHelperTest.php47 $sql = "SELECT * FROM testdata WHERE keyword='music'";
48 $res = $SqliteHelper->query($sql);
61 $sql = "INSERT INTO testdata VALUES(20,'glass','Purple')";
62 $res = $SqliteHelper->query($sql);
H A DSQLiteDBTest.php42 $sql = "SELECT * FROM testdata WHERE keyword=?";
44 $stmt = $db->query($sql, ['music']);
55 $sql = "SELECT ? AS first, ? AS second, ? AS third";
57 $result = $db->queryRecord($sql, ['one', 'two', 'three']);
60 $result = $db->queryRecord($sql, 'one', 'two', 'three');
63 $sql = "SELECT :first AS first, :second AS second, :third AS third";
65 $result = $db->queryRecord($sql, ['first' => 'one', 'second' => 'two', 'third' => 'three']);
73 $sql = "INSERT INTO testdata (keyword, value) VALUES (?, ?)";
74 $insid = $db->exec($sql, ['test', 'test']);
77 $sql
[all...]
/plugin/sqlite/
H A Dadmin.php56 $exportfile = $conf['tmpdir'] . '/' . $this->db->getDbName() . '.sql';
58 header('Content-Type: text/sql');
59 header('Content-Disposition: attachment; filename="' . $this->db->getDbName() . '.sql";');
71 $sql = Tools::SQLstring2array(file_get_contents($importfile));
74 foreach ($sql as $s) {
85 $this->querySaver->saveQuery($INPUT->str('name'), $INPUT->str('sql'));
122 $form->addTextarea('sql')->addClass('edit');
130 if ($INPUT->has('sql')) $this->showQueryResults($INPUT->str('sql'));
171 * @param string $sql
163 showQueryResults($sql) global() argument
[all...]
H A DSQLiteDB.php136 * @param string $sql
141 public function query($sql, ...$parameters)
149 $stmt = $this->pdo->prepare($sql);
155 'sql' => &$sql,
168 'sql' => $sql,
182 * @param string $sql
187 public function exec($sql, ...$parameters)
189 $stmt = $this->query($sql,
112 query($sql, ...$parameters) global() argument
158 exec($sql, ...$parameters) global() argument
181 queryAll($sql, ...$params) global() argument
197 queryRecord($sql, ...$params) global() argument
253 queryValue($sql, ...$params) global() argument
271 queryKeyValueList($sql, ...$params) global() argument
[all...]
H A DTools.php8 * Split sql queries on semicolons, unless when semicolons are quoted
13 * @param string $sql
14 * @return string[] sql queries
16 public static function SQLstring2array($sql) argument
19 $len = strlen($sql);
21 // Simple state machine to "parse" sql into single statements
26 $prev = $i ? $sql[$i - 1] : "\n";
27 $char = $sql[$i];
28 $next = $i < ($len - 1) ? $sql[$i + 1] : '';
H A Dhelper.php159 * @param string ...$args - the arguments of query(), the first is the sql and others are values
167 $sql = $this->prepareSql($args);
168 return $this->adapter->query($sql);
182 * - string $sql - the statement
190 $sql = trim(array_shift($args));
191 $sql = rtrim($sql, ';');
193 if (!$sql) {
204 $qmc = substr_count($sql, '?');
207 'Expected ' . $qmc . ' got ' . $argc . ' - ' . hsc($sql));
392 SQLstring2array($sql) global() argument
403 doTransaction($sql, $sqlpreparing = true) global() argument
[all...]
/plugin/structstatus/
H A Daction.php63 $sql = "SELECT MAX(id) AS id, tbl FROM schemas GROUP BY tbl";
64 $schemas= $sqlite->queryAll($sql);
77 $sql = 'REPLACE INTO opts(opt,val) VALUES ("dbversion_structstatus", ' . $version . ')';
78 $sqlite->query($sql);
143 $sql = 'SELECT opt, val FROM opts WHERE opt=? OR opt=?';
144 $vals = $sqlite->queryAll($sql, ['dbversion', 'dbversion_structstatus']);
/plugin/starred/
H A Dhelper.php60 $sql = "DELETE FROM stars WHERE pid = ? AND login = ?";
61 $db->exec($sql, [$pageid, $user]);
65 $db->exec($sql, [$pageid, $user, time()]);
90 $sql = "SELECT stardate FROM stars WHERE pid = ? AND login = ?";
91 return (int)$db->queryValue($sql, [$pageid, $user]);
115 $sql = "SELECT pid, stardate FROM stars WHERE ";
118 $sql .= 'lower(login) = lower(?)';
120 $sql .= 'login = ?';
122 $sql .= " ORDER BY stardate DESC";
124 $sql .= ' LIMIT ' . $limit;
[all …]
/plugin/aichat/vendor/mehrab-wj/tiktoken-php/data/
H A Dvocab.bpe48507 Ġmy sql
/plugin/bez/mdl/
H A DTask.php346 $sql = 'SELECT * FROM task_participant WHERE';
352 $sql .= " $filter=1 AND";
354 $sql .= ' task_id=? AND removed=0 ORDER BY user_id';
356 $r = $this->model->sqlite->query($sql, $this->id);
413 $sql = "UPDATE task_participant SET $set WHERE task_id=? AND user_id=?";
414 $this->model->sqlite->query($sql, $this->id, $user_id);
H A DTaskFactory.php53 $sql = "SELECT task.id, task.type, task.content_html, task.state, task.cost, task.plan_date, task.close_date,
60 $stmt = $this->model->sqlite->query($sql, $thread->id);
82 $sql = "SELECT task_participant.user_id,
90 $r = $this->model->sqlite->query($sql, $from, $to);
92 $sql = "SELECT user_id,
99 $r = $this->model->sqlite->query($sql);
110 $sql = "SELECT task_program_name,
125 $r = $this->model->sqlite->query($sql, $from, $to);
127 $sql = "SELECT task_program_name,
141 $r = $this->model->sqlite->query($sql);
[all...]
H A DThread.php201 $sql = 'SELECT * FROM thread_participant WHERE';
207 $sql .= " $filter=1 AND";
209 $sql .= ' thread_id=? AND removed=0 ORDER BY user_id';
211 $r = $this->model->sqlite->query($sql, $this->id);
268 $sql = "UPDATE thread_participant SET $set WHERE thread_id=? AND user_id=?";
269 $this->model->sqlite->query($sql, $this->id, $user_id);
H A DThreadFactory.php33 $sql = "SELECT thread_participant.user_id,
42 $r = $this->model->sqlite->query($sql, $from, $to);
44 $sql = "SELECT user_id,
53 $r = $this->model->sqlite->query($sql);
63 $sql = "SELECT COUNT(*)*1.0/COUNT(DISTINCT thread_id) AS kpi
66 $r = $this->model->sqlite->query($sql, $from, $to);
68 $sql = "SELECT COUNT(*)*1.0/COUNT(DISTINCT thread_id) AS kpi
71 $r = $this->model->sqlite->query($sql);
82 $sql = "SELECT COUNT(DISTINCT user_id)
90 $r = $this->model->sqlite->query($sql,
[all...]
H A DThread_commentFactory.php117 $sql = "SELECT type, COUNT(type) AS 'cnt'
122 $r = $this->model->sqlite->query($sql, $from, $to);
124 $sql = "SELECT type, COUNT(type) AS 'cnt'
128 $r = $this->model->sqlite->query($sql);
/plugin/bez/struct/
H A DBezType.php140 $sql = "SELECT " . implode(',', $fields) . " FROM $table WHERE id LIKE ? LIMIT $max";
141 $res = $sqlite->query($sql, $id . '%');
/plugin/bez/action/
H A Dmigration.php49 $sql = file_get_contents($file);
50 if($sql === false) {
55 preg_match_all('/.*?(?(?=BEGIN)BEGIN.*?END)\s*;/is', $sql, $matches);
82 $sql = file_get_contents($file);
83 if($sql === false) {
88 preg_match_all('/.*?(?(?=BEGIN)BEGIN.*?END)\s*;/is', $sql, $matches);
123 $sql = file_get_contents($file);
124 if ($sql === false) {
129 preg_match_all('/.*?(?(?=BEGIN)BEGIN.*?END)\s*;/is', $sql, $matches);
/plugin/sql/
H A DDB.php22 function query($sql, $mode = null, ...$params) { argument
25 if ($ALOCAL['debug']) error_log($sql, 3, '/tmp/php.log');
26 $stmt = parent::prepare($sql);
H A DREADME5 * http://dokuwiki.org/plugin:sql
H A Dplugin.info.txt1 base sql
5 name sql plugin
7 url http://dokuwiki.org/plugin:sql
/plugin/tagging/
H A Dhelper.php687 $sql = 'SELECT pid from taggings where CLEANTAG(tag) = CLEANTAG(?)';
688 $res = $db->query($sql, $tid);
/plugin/tagging/helper/
H A Dquerybuilder.php171 $sql = "SELECT $this->field AS item, COUNT(*) AS cnt
180 $sql .= ' LIMIT ?';
184 return $sql;
/plugin/authwordpress/
H A Dauth.php214 $sql = $this->sql_wp_user_data
217 $stmt = $this->db->prepare($sql);
219 $this->logDebug("Retrieving data for user '$user'\n$sql");
/plugin/combo/db/combo-secondary/
H A DREADME.md8 * Create a file `updateXXXXX.sql` where `XXXXX` = `XXXX+1`
/plugin/combo/ComboStrap/
H A DPageSql.php19 const CANONICAL = "sql";
21 private $sql; variable in ComboStrap\\PageSql
30 $this->sql = $text;
35 * @param MarkupPath|null $contextualPage - the page where the sql applies to
51 $input = InputStream::fromString($this->sql);
63 $this->listener = new PageSqlTreeListener($lexer, $parser, $this->sql, $contextualPage);
85 return $this->sql;
H A DPageSqlTreeListener.php89 * @param string $sql
92 public function __construct(PageSqlLexer $lexer, PageSqlParser $parser, string $sql, MarkupPath $pageContext = null) argument
96 $this->pageSqlString = $sql;

12345678