This file contains hidden or 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
const AWS = require('aws-sdk'); | |
//Define aws region | |
AWS.config.update({ | |
region:'us-east-1' | |
}); | |
const TABLE = 'dc_test'; |
This file contains hidden or 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
const AWS = require('aws-sdk'); | |
AWS.config.update({ | |
region: 'us-east-1' | |
}); | |
const SQS = new AWS.SQS(); | |
const { | |
Consumer |
This file contains hidden or 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
const AWS = require('aws-sdk'); | |
AWS.config.update({ | |
region: 'us-east-1' | |
}); | |
const sqs = new AWS.SQS({ | |
apiVersion: '2012-11-05' | |
}); |
This file contains hidden or 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
/* | |
Return the sets intersection. | |
Params | |
arrA : array | |
arrB : array | |
Return | |
array | |
*/ | |
const intersection = (arrA,arrB) => arrA.filter(x => arrB.includes(x)); |
This file contains hidden or 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
/* | |
Transponer una matriz | |
Entrada: | |
1 2 3 4 | |
5 6 7 8 | |
Salida | |
1 5 | |
2 6 |
This file contains hidden or 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
// Se espera que el resultado lo muestres en un console.log | |
const arbol = { | |
num: 25, | |
izq: { | |
num: 23, | |
izq: { | |
num: 10, | |
}, | |
der: { | |
num: 80, |
This file contains hidden or 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
const year = { | |
num: 2019, | |
month: { | |
num: 1, | |
avgDollarValue: 90, | |
month: { | |
num: 2, | |
avgDollarValue: 105, | |
month: { | |
num: 0, |
This file contains hidden or 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
# Descargar el instalador desde aqui:https://www.microsoft.com/en-us/download/details.aspx?id=101064 bajar ".exe" | |
# Version SQL SERVER 2019 - EXPRESS | |
# Basado en esta web: https://silentinstallhq.com/microsoft-sql-server-2019-express-silent-install-how-to-guide | |
@echo off | |
echo "1) Creo directorio temporal..." | |
mkdir c:\crypton-install-tmp | |
echo "Ok" | |
echo "2) Extraigo instalador .exe..." |
This file contains hidden or 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
drop table testtb; | |
drop table test_duplicated; | |
drop table test_unique; | |
create temporary table testtb ( | |
entity varchar(10) not null, | |
duplicate varchar(10) not null | |
); | |
insert into testtb |
This file contains hidden or 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
#Extract project field name package.json | |
export PACKAGE_NAME="$(cat package.json | grep name | head -1 | awk -F: '{ print $2 }' | sed 's/[",]//g')" | |
#Extract version field from package.json | |
export PACKAGE_VERSION="$(cat package.json | grep version | head -1 | awk -F: '{ print $2 }' | sed 's/[",]//g')" | |
#Set the package tag name | |
export PACKAGE_TAG="$(echo ${PACKAGE_NAME}:${PACKAGE_VERSION} | tr -d ' ')" |