June 18, 2013

Post: PHP vs. BIGINT vs. float conversion caveat

… big numbers in PHP (gulp). For example, sometimes 32-bit identifiers are not enough and you have to use BIGINT 64-bit….0: s1=1125899906842625 s2=1125899906842625 However 32-bit FreeBSD with PHP 4.4.7 produces different results: s1=1.1258999068426E+15… all digits but still incorrectly: s1=1125899906842600 s2=1125899906842625 And PHP 5.2.2 on Windows produces yet another variant: s1…

Comment: PHP vs. BIGINT vs. float conversion caveat

… on PHP vs. BIGINT vs. float conversion caveatHere’s a quick excerpt Sometimes you need to work with big numbers in PHP (gulp). For example, sometimes 32-bit identifiers are not enough and you have to use BIGINT 64-bit… fully, floats might save the day. The trick is that PHP floats are in fact doubles, i.e. double-precision 64…

Comment: Flexviews is a working scalable database transactional memory example

… identifier for a change set in a database cluster. The PHP mysqlnd replication and load balancing plugin could learn to do… a MEMORY table which is replicated with a single UNSIGNED BIGINT and increment it at the end of each transaction…CREATE TABLE trx .trx id BIGINT UNSIGNED NOT NULL. ENGINE memory ..INSERT INTO trx VALUES 0…

Comment: PHP vs. BIGINT vs. float conversion caveat

… Performance Blog wrote an interesting post today on Comment on PHP vs. BIGINT vs. float conversion caveat by Windows…Here’s a…[…] MySQL Performance Blog wrote an interesting post today on PHP vs. BIGINT vs. float conversion caveatHere’s a quick excerpt Sometimes…

Post: Flexviews - part 3 - improving query performance using materialized views

… script to convert SQL to the Flexviews API (see convert.php below) Refresh methods The incremental refresh method The incremental refresh…_id) group by customer_id, customer_name, sale_when; $ php convert.php demo < sales.sql CALL flexviews.create('demo', 'dashboard_customer_sales... a special column `mview$pk` which is an auto_increment BIGINT surrogate key for the table. For complete refresh views which…

Comment: Database problems in MySQL/PHP Applications

…’s not as common. > I would also note for many PHP applications abstraction layer is > not the main performance problem, also… primary key taking up far more space than even a BIGINT UNSIGNED will and gaining no benefit from it. I’ve… growth it will however start > to crawl. > So developing you PHP applications use test database with reasonable > amount of data in…