Sergey Tsalkov
f82f0cc208
add another queryWalk() test case
...
make sure we're using $is_buffered=false for queryWalk() like we're supposed to
2021-08-14 05:08:41 +00:00
Sergey Tsalkov
7febdbd1f5
since queryRaw() is deprecated, it was a mistake to change its behavior
...
return it to using $is_buffered=true, and restore queryRawUnbuf() for $is_buffered=false
both queryRaw() and queryRawUnbuf() are deprecated, and it's recommended that you use queryWalk() instead
2021-08-14 05:02:27 +00:00
Sergey Tsalkov
57b7527a46
fix bug in columnList(), add test
2021-08-08 14:15:19 +00:00
Sergey Tsalkov
e30c240d54
cleanup README, add note about $logfile
v2.4
2021-06-29 04:31:23 +00:00
Sergey Tsalkov
13f249f200
update readme for new version
2021-06-28 22:37:53 +00:00
Sergey Tsalkov
f7a52ca410
DATE_FORMAT() tests for %% escaping
2021-06-28 22:20:59 +00:00
Sergey Tsalkov
d944430401
drop DBHelper
2021-06-27 05:35:28 +00:00
Sergey Tsalkov
a10b76b2de
cleanup some error-checking code
...
add lots more tests for that code
2021-06-27 03:17:47 +00:00
Sergey Tsalkov
50ed9675f3
fix pre_parse and pre_run hooks
...
add testing for all hooks (roll into previous ErrorTest group)
2021-06-26 00:52:37 +00:00
Sergey Tsalkov
1724b7276b
cleanup MeekroDBWalk a bit
2021-06-25 23:48:44 +00:00
Sergey Tsalkov
aad5cbbbac
cleanup and better test queryWalk()
2021-06-25 18:23:59 +00:00
Sergey Tsalkov
5108480e03
drop unused code
2021-06-25 17:40:41 +00:00
Sergey Tsalkov
cd64dd724b
add tests for queryWalk()
2021-06-25 17:35:39 +00:00
Sergey Tsalkov
15f40efe5d
add DB::queryWalk() -- still untested
...
add DB::lastQuery() (with tests)
2021-06-24 03:05:46 +00:00
Sergey Tsalkov
30f3d9454a
DB::debugMode() is now deprecated (but still works)
...
recommended debug system will use $logfile to log SQL to a file
2021-06-23 21:23:20 +00:00
Sergey Tsalkov
dc21f646af
DB::$logfile can be used to log all queries to either a resource or a file
...
DB::debugMode() is now a shorthand for "DB::$logfile = STDOUT"
2021-06-23 03:05:22 +00:00
Sergey Tsalkov
50fd6ed6d2
actually bring back deprecated methods, keep them for now to maintain backwards compatability
2021-06-23 01:27:03 +00:00
Sergey Tsalkov
6487873c68
new hook-based system for inserting callbacks to run before and after a query
...
debugMode() now works through the new system
2021-06-22 06:01:28 +00:00
Sergey Tsalkov
ac626b0795
simplify parser a bit
2021-06-20 20:53:31 +00:00
Sergey Tsalkov
bac5503d5a
PHP 8 complains when trying to access closed $mysqli object, not sure how to test this properly
...
I don't think we need this test very much, anyway
2021-06-20 03:13:11 +00:00
Sergey Tsalkov
42894b70ae
re-design query parser, new model has cleaner code and allows for %% escaping of % characters
2021-06-20 03:12:15 +00:00
Sergey Tsalkov
20c7acd8a4
DB::parse() lets you generate queries without running them
2021-06-20 02:32:56 +00:00
Sergey Tsalkov
c0f3a7f31d
restore to working in PHP 5.3
2021-06-20 02:32:56 +00:00
Sergey Tsalkov
1d2ad974f8
drop deprecated methods:
...
queryOneRow (alias of queryFirstRow)
queryOneList (alias of queryFirstList)
queryOneColumn
queryOneField
2021-06-20 02:32:56 +00:00
Sergey Tsalkov
2ea4c4c539
__callStatic() should have proper exception thrown if invalid method is used
2021-06-20 02:32:56 +00:00
Sergey Tsalkov
7c1f9bc226
DB::$usenull is removed, it makes no sense in a modern PHP context
2021-06-20 02:32:56 +00:00
Sergey Tsalkov
dab71efacd
DB::columnList() now returns details
2021-06-20 02:28:26 +00:00
Sergey Tsalkov
38545ddb3a
remove more PHP 5.2 cruft, we now require PHP 5.3+
2021-06-20 02:28:26 +00:00
Sergey Tsalkov
0fb0071314
use __callStatic() to clean up code a bit
...
next release will require PHP 5.3+ (up from 5.2)
2021-06-20 02:26:21 +00:00
Sergey Tsalkov
03ff51a997
fix composer.json
...
packagist demands lowercase package names now
2021-01-23 22:27:10 -06:00
Sergey Tsalkov
4ff57845e4
Update README.md
...
Remove old broken link.
2020-07-11 10:23:08 -05:00
Sergey Tsalkov
e8c19ca2f8
clean up update() and delete(), both will now be compatible with named and numbered arguments
...
resolves #54
v2.3.1
2020-07-10 01:13:31 +00:00
Sergey Tsalkov
fa46824df1
get_class_vars() is broken in PHP 7.4 with opcache enabled, so stop using it
...
looks like this fix actually works with PHP 5.2 after all, so not dropping backwards compatibility
resolves #64
2020-07-10 00:00:27 +00:00
Sergey Tsalkov
226a08611f
small test fix to pass on PHP 7.3
2020-07-09 19:51:28 +00:00
wadih
031901f8b6
Add a warning to prevent accidents ( #65 )
2020-07-08 21:19:59 -05:00
Magnus Månsson
30c7343bae
Pre sql handler ( #59 )
...
Add a pre_sql_handler
2020-02-06 22:32:29 -06:00
Magnus Månsson
b99ed41c94
Implemented param char ssb and sse ( #58 )
2020-02-06 22:20:53 -06:00
Sergey Tsalkov
18d9ab2337
make sure insertOrReplace() gets valid input, throw an error if it doesn't
2020-01-27 08:45:36 -08:00
Sergey Tsalkov
027681b350
bugfix: strtolower() doesn't work with certain locales, so work around that
2020-01-24 15:42:43 -08:00
Sergey Tsalkov
677d5659bb
Update README.md
2019-01-26 11:46:13 -06:00
Sergey Tsalkov
621f2e7a86
Update README.md
2019-01-26 11:45:50 -06:00
Sergey Tsalkov
6e1c252702
Update README.md
2019-01-26 10:23:50 -06:00
Sergey Tsalkov
8e19d9d6c3
bugfix in WhereClause: negate didn't wrap multiple clauses in extra parens
...
Fixes #41
2017-10-15 19:10:35 +00:00
Sergey Tsalkov
22e49b280e
clarify that project is LGPLv3
2017-10-15 18:20:37 +00:00
Sergey Tsalkov
b41887505d
fix to last commit
2017-10-15 17:56:10 +00:00
Mike Damm
cb10e249b2
Add support for custom unix sockets ( #49 )
...
Add support for custom unix sockets
2017-10-08 21:04:22 -07:00
Sergey Tsalkov
aabc77b116
Update README.md
2016-11-21 17:01:59 -08:00
Sergey Tsalkov
8bef6d6618
fix bug with hhvm
2015-03-04 00:43:54 +00:00
Sergey Tsalkov
da46a1eacc
DB::insert() and the like should use __toString() value for objects whenever possible
2014-11-27 01:30:42 +00:00
Sergey Tsalkov
076a7e2b9b
oops
2014-10-27 02:02:32 +00:00