This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Update goes into a CTE, the CTE will become the source of data to our insert into product_log | |
WITH logs AS ( | |
UPDATE product | |
SET price = price * 1.1 | |
, date_updated = NOW() | |
RETURNING product.id, product.price | |
) | |
INSERT INTO product_log (product_id, price) | |
SELECT id, price | |
FROM logs; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://processing.org/ | |
float inc = 0.05; | |
float zinc = 0.0001; | |
int particleSize = 2; | |
int particleCount = 5000; | |
float pmod = 500; // particle mod for hue increment | |
float hincm = 0.1; // hue increment multiplier |
OlderNewer