Skip to content

Instantly share code, notes, and snippets.

View jrichardsz's full-sized avatar

JRichardsz jrichardsz

View GitHub Profile
@jrichardsz
jrichardsz / ireport-01-example-xml
Last active August 29, 2015 14:13
Report 01 example in Ireport 4.5.0
<?xml version="1.0" encoding="UTF-8"?>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="report1" language="groovy" pageWidth="595" pageHeight="842" columnWidth="535" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20">
<property name="template.type" value="columnar"/>
<style name="Title" forecolor="#000000" fontName="Times New Roman" fontSize="50" isBold="false" pdfFontName="Times-Bold"/>
<style name="SubTitle" forecolor="#666666" fontName="Times New Roman" fontSize="18" isBold="false" pdfFontName="Times-Roman"/>
<style name="Column header" forecolor="#666666" fontName="Times New Roman" fontSize="14" isBold="true" pdfFontName="Times-Roman"/>
<style name="Detail" mode="Transparent" fontName="Times New Roman" pdfFontName="Times-Roman"/>
<style name="Row" mode="Transparent" fontName
@jrichardsz
jrichardsz / ireport-02-example.xml
Created January 11, 2015 15:54
Report 02 in Ireport 4.5.0
<?xml version="1.0" encoding="UTF-8"?>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="report2" language="groovy" pageWidth="595" pageHeight="842" columnWidth="535" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20">
<style name="Title" fontName="Arial" fontSize="26" isBold="true" pdfFontName="Helvetica-Bold"/>
<style name="SubTitle" forecolor="#666666" fontName="Arial" fontSize="18"/>
<style name="Column header" forecolor="#666666" fontName="Arial" fontSize="12" isBold="true"/>
<style name="Detail" fontName="Arial" fontSize="12"/>
<group name="Group1">
<groupExpression><![CDATA[(int)($V{REPORT_COUNT}/15)]]></groupExpression>
<groupHeader>
<band height="40">
@jrichardsz
jrichardsz / autoit random HotKeySet mouse move.au3
Created February 3, 2015 03:42
This script shows how use this autoit functions: autoit random HotKeySet mouseMove random MsgBox
HotKeySet("{ESC}", "stop")
main()
Func main()
; Set the counter
$count = 0
; Execute the loop "While" the counter is less than 5
@jrichardsz
jrichardsz / pdi-spoon-error-java.lang.ClassNotFoundException: org.osjava.sj.SimpleContextFactory.log
Last active October 6, 2015 17:29
Error produced when a transformation that uses a jndi datasource is invoked from java : javax.naming.NoInitialContextException: Cannot instantiate class: org.osjava.sj.SimpleContextFactory [Root exception is java.lang.ClassNotFoundException: org.osjava.sj.SimpleContextFactory]
2015/10/06 12:26:36 - transformation_with_jndi - Dispatching started for transformation [transformation_with_jndi]
2015/10/06 12:26:36 - Table input.0 - ERROR (version 5.0.0.1.19046, build 1 from 2013-09-11_13-51-13 by buildguy) : An error occurred, processing will be stopped:
2015/10/06 12:26:36 - Table input.0 - Error occured while trying to connect to the database
2015/10/06 12:26:36 - Table input.0 -
2015/10/06 12:26:36 - Table input.0 - javax.naming.NoInitialContextException: Cannot instantiate class: org.osjava.sj.SimpleContextFactory [Root exception is java.lang.ClassNotFoundException: org.osjava.sj.SimpleContextFactory]
2015/10/06 12:26:36 - Table input.0 - Cannot instantiate class: org.osjava.sj.SimpleContextFactory
2015/10/06 12:26:36 - transformation_with_jndi - ERROR (version 5.0.0.1.19046, build 1 from 2013-09-11_13-51-13 by buildguy) : Something went wrong while trying to stop the transformation: org.pentaho.di.core.exception.KettleDatabaseException:
2015/10/06 12:26:36 - transformation_with_
@jrichardsz
jrichardsz / pdi-spoon-error-Unable to get database metadata from this database connection.log
Created October 6, 2015 17:36
Error produced when a transformation that uses a jndi datasource is invoked from java : Error occured while trying to connect to the database, Unable to get database metadata from this database connection
2015/10/06 12:30:01 - transformation_with_jndi - Dispatching started for transformation [transformation_with_jndi]
2015/10/06 12:30:01 - Table input.0 - ERROR (version 5.0.0.1.19046, build 1 from 2013-09-11_13-51-13 by buildguy) : An error occurred, processing will be stopped:
2015/10/06 12:30:01 - Table input.0 - Error occured while trying to connect to the database
2015/10/06 12:30:01 - Table input.0 - java.io.File parameter must be a directory. [D:\opt\workspace-eclipse\invoke-ktr-jndi\simple-jndi]
2015/10/06 12:30:01 - transformation_with_jndi - ERROR (version 5.0.0.1.19046, build 1 from 2013-09-11_13-51-13 by buildguy) : Something went wrong while trying to stop the transformation: org.pentaho.di.core.exception.KettleDatabaseException:
2015/10/06 12:30:01 - transformation_with_jndi - Unable to get database metadata from this database connection
2015/10/06 12:30:01 - transformation_with_jndi - at java.lang.Thread.run (null:-1)
2015/10/06 12:30:01 - transformation_with_jndi - at org.pentaho.di.trans.st
/*******************************************************************************
*
* Pentaho Data Integration
*
* Copyright (C) 2002-2012 by Pentaho : http://www.pentaho.com
*
*******************************************************************************
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with
@jrichardsz
jrichardsz / inflexible_system.java
Last active October 15, 2015 17:59
Inflexible System Example
class Producto {
method1()
method2()
method3()
submit() {
genericSubmit()
}
}
@jrichardsz
jrichardsz / flexible_system.java
Created October 15, 2015 17:57
System that supports dynamic behavior.
Desarrollar la clase Producto para que soporte procesos o reglas dinamicas:
class Producto {
method1()
method2()
method3()
submit() {
@jrichardsz
jrichardsz / setup_sshkeys.sh
Created January 19, 2016 17:31 — forked from cedricziel/setup_sshkeys.sh
Openshift git wrapper script creation for being able to use private git repos
#!/usr/bin/env bash
# copy this script to your gear, make it executable and run it once
# make the appropriate directory
mkdir -p "$OPENSHIFT_DATA_DIR/.ssh"
# generate a key
ssh-keygen -q -t rsa -f $OPENSHIFT_DATA_DIR/.ssh/id_rsa -N ""
@jrichardsz
jrichardsz / _IEFormElementSetValue example.au3
Created March 28, 2016 00:31
Function _IEFormElementSetValue - AutoIt
#include <IE.au3>
Call ("SignIn")
Func SignIn()
Global $oIE = _IECreate ("http://www.google.com")
Local $username = _IEGetObjByName ($oIE, "user")
Local $password = _IEGetObjByName ($oIE, "pass")
_IEFormElementSetValue($username,"jyjtrans")
_IEFormElementSetValue($password,"tucontraseña")