Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 12/26/2020 in all areas

  1. Forgot to provide feedback on my eventual approach. Turned out I was looking for Bézier curves and splines.
    1 point
  2. php is a server-side scripting language. if you are not making a http(s) request to a web server for the .php file, the php language engine isn't being invoked. when you directly enter the URL of the .php file in question in your browser's address bar, do you get the expected output?
    1 point
  3. 1 ) Why are you searching for "amprsand" when there are no ampersands (&) in your code. 2) the numeric value of a string is value of the numeric chars up to the first non-numeric character echo intval('12@3'); // 12 echo intval('@123'); // 0
    1 point
  4. I thought I would check out the impact of the larger key. I creted two tables, one with a smallint PK and the other using bigint. CREATE TABLE `keytest_si` ( `id` smallint(5) unsigned NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; CREATE TABLE `keytest_bi` ( `id` bigint(20) unsigned NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; Then I looked for my largest table that would fit in a smallint. I then wrote the ids from this table to each of the two new tables. mysql> select count(*) from production_status; +----------+ | count(*) | +----------+ | 60000 | +----------+ 1 row in set (0.01 sec) mysql> insert into keytest_si (id) select id from production_status; Query OK, 60000 rows affected (1.67 sec) Records: 60000 Duplicates: 0 Warnings: 0 mysql> insert into keytest_bi (id) select id from production_status; Query OK, 60000 rows affected (1.86 sec) Records: 60000 Duplicates: 0 Warnings: 0 That's a difference of 0.2 seconds over 60,000 records. The added cost per record insert is therefore 0.000003 seconds. Do you really think that's worth the worry and the extra processing it's causing you? (Which probably takes far longer than the time saved) And Merry Christmas to you too.
    1 point
This leaderboard is set to New York/GMT-04:00
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.