CREATE USER ‘myuser’@’localhost’ IDENTIFIED BY ‘mypass’; GRANT ALL ON *.* TO ‘myuser’@’localhost’; CREATE USER ‘myuser’@’%’ IDENTIFIED BY ‘mypass GRANT ALL ON *.* TO ‘myuser’@’%’; flush privileges;
credits to: http://joezack.com/2008/10/20/mysql-capitalize-function/ create a function: CREATE FUNCTION CAP_FIRST (input VARCHAR(255)) RETURNS VARCHAR(255) DETERMINISTIC BEGIN DECLARE len INT; DECLARE i INT; SET len = CHAR_LENGTH(input); SET input = LOWER(input); SET i = 0; WHILE (i < len) DO […]
surprisingly, to find the min date per company, which is a super basic query, on mysql you need to do a complicated query. SELECT a.id, a.company, a.email, a.custom_last_email FROM leads a INNER JOIN ( SELECT company, MIN(custom_last_email) mindate FROM […]
https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-elasticsearch-on-ubuntu-20-04 To test: Run from the local server to see if the server can connect to the elasticsearch cluster: curl -X GET ‘http://localhost:9200’ Run a test from a remote server, to see if a remote user can access […]
ubuntu-s-1vcpu-1gb-sgp1-01*CLI> core show help ! — Execute a shell command acl show — Show a named ACL or list all named ACLs ael reload — Reload AEL configuration ael set debug {read|tokens|macros|contexts|off} — Enable AEL debugging flags agent logoff — […]
Goals Truncate the Recent Post’s Length Add the post id (may be unsafe), ideally I would like to add another sequence (separate from the post id), but for now I’ll just add the post id (no time for the former) […]