Skip to content

Instantly share code, notes, and snippets.

View legarnica's full-sized avatar
💭
I may be slow to respond.

Luis Herrera legarnica

💭
I may be slow to respond.
  • Santiago de chile
View GitHub Profile
public class HolaMundo{
public static void main(String[] agrs){
System.out.print("Hola mundo");
}
}
pubic class Principal{
public static void main(String[] args){
System.out.println("Hola gist");
}
}
@legarnica
legarnica / fackerjsexample
Last active June 12, 2020 16:37
faker-vanillajs-html-example
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Facker</title>
</head>
INSERT INTO estado (id, descripcion) VALUES(1, 'En curso');
INSERT INTO estado (id, descripcion) VALUES(2, 'Finalizado');
INSERT INTO departamento (id, numero) VALUES(1, 101);
INSERT INTO departamento (id, numero) VALUES(2, 102);
INSERT INTO departamento (id, numero) VALUES(3, 201);
INSERT INTO departamento (id, numero) VALUES(4, 202);
INSERT INTO departamento (id, numero) VALUES(5, 301);
INSERT INTO departamento (id, numero) VALUES(6, 302);
@legarnica
legarnica / schema.sql
Created August 9, 2020 21:14
esquema para el proyecto final JFS
-- descomentar línea de abajo, después de la primera ejecución.
-- DROP table arriendo_quincho; DROP table departamento; DROP table estado; DROP table hibernate_sequence;
-- arriendo_quincho definition
CREATE TABLE arriendo_quincho (
id integer not null,
fecha date_time,
departamento_id integer,
estado_id integer,
package cl.lherrera.configuracion;
import javax.sql.DataSource;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;
import org.springframework.core.env.Environment;
/*
* The author disclaims copyright to this source code. In place of
* a legal notice, here is a blessing:
*
* May you do good and not evil.
* May you find forgiveness for yourself and forgive others.
* May you share freely, never taking more than you give.
*
*/
package cl.lherrera.configuracion;
driverClassName=org.sqlite.JDBC
url=jdbc:sqlite:certificacion.db
username=user
password=1234
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee
http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
version="3.1">
<display-name>Certification</display-name>
<servlet>
@legarnica
legarnica / finalHRdatos.sql
Created August 10, 2020 00:27
Datos de la base HR
alter table "JOB_HISTORY" disable constraint "JHIST_DEPT_FK";
alter table "JOB_HISTORY" disable constraint "JHIST_EMP_FK";
alter table "JOB_HISTORY" disable constraint "JHIST_JOB_FK";
alter table "EMPLOYEES" disable constraint "EMP_DEPT_FK";
alter table "EMPLOYEES" disable constraint "EMP_JOB_FK";
alter table "EMPLOYEES" disable constraint "EMP_MANAGER_FK";
alter table "EMPLOYEES" disable constraint "EMP_MANAGER_FK";
alter table "EMPLOYEES" disable constraint "EMP_MANAGER_FK";