Commit 9f483ec3 by Luis Gangas

[add] new branch

parent 5c0eab31
......@@ -435,7 +435,7 @@ public class FichaMysqlDAO implements FichaDAO {
sql = "UPDATE personal "
+ "SET sexo = UPPER(?), "
+ " codigo_estado_civil = UPPER(?), "
+ " fechanacimiento = UPPER(?), "
+ " fechanacimiento = STR_TO_DATE( ? ,'%d/%m/%Y'), "
+ " codigo_nacionalidad = UPPER(?), "
+ " codigo_ubigeo_nacimiento = UPPER(?), "
+ " dni = UPPER(?), "
......@@ -511,7 +511,7 @@ public class FichaMysqlDAO implements FichaDAO {
+ " nombre = UPPER (?), "
+ " sexo = UPPER (?), "
+ " codigo_estado_civil = UPPER (?), "
+ " fechanacimiento = UPPER (?), "
+ " fechanacimiento = STR_TO_DATE( ? ,'%d/%m/%Y'), "
+ " codigo_nacionalidad = UPPER (?), "
+ " codigo_ubigeo_nacimiento = UPPER (?), "
+ " direccion_documento = UPPER (?), "
......@@ -578,7 +578,7 @@ public class FichaMysqlDAO implements FichaDAO {
+ " nombre = upper(?), "
+ " sexo = upper(?), "
+ " codigo_estado_civil = upper(?), "
+ " fechanacimiento = upper(?), "
+ " fechanacimiento = STR_TO_DATE( ? ,'%d/%m/%Y'), "
+ " codigo_nacionalidad = upper(?), "
+ " codigo_ubigeo_nacimiento = upper(?), "
+ " direccion_documento = upper(?), "
......@@ -713,7 +713,7 @@ public class FichaMysqlDAO implements FichaDAO {
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
+ " STR_TO_DATE( ? ,'%d/%m/%Y'), "
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
......@@ -779,8 +779,8 @@ public class FichaMysqlDAO implements FichaDAO {
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
+ " STR_TO_DATE( ? ,'%d/%m/%Y'), "
+ " STR_TO_DATE( ? ,'%d/%m/%Y'), "
+ " NULL, "
+ " NULL, "
+ " 1 "
......@@ -847,8 +847,8 @@ public class FichaMysqlDAO implements FichaDAO {
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
+ " upper(?), "
+ " STR_TO_DATE( ? ,'%d/%m/%Y'), "
+ " STR_TO_DATE( ? ,'%d/%m/%Y'), "
+ " upper(?), "
+ " 1 "
+ " )";
......
......@@ -41,6 +41,9 @@ import trismegistoplanilla.dao.UbigeoDAO;
import trismegistoplanilla.dao.VacanteDAO;
public class MysqlDAOFactory extends DAOFactory {
public static void main(String[] args) {
new MysqlDAOFactory().obtenerConexion("nuevo");
}
static {
try {
......@@ -57,11 +60,14 @@ public class MysqlDAOFactory extends DAOFactory {
String url;
if (base.equalsIgnoreCase("nuevo")) {
user = "juan";
pwd = "jose";
url = "jdbc:mysql://172.16.2.43:3306/nuevo";
user = "juanjose";
pwd = "juanjose";
// url = "jdbc:mysql://172.16.2.43:3306/nuevo";
url = "jdbc:mysql://172.16.2.37:3306/nuevo";
// url = "jdbc:mysql://localhost:3306/nuevo";
try {
conexion = DriverManager.getConnection(url, user, pwd);
System.out.println("Conexion existosa.");
} catch (SQLException e) {
e.printStackTrace();
}
......
......@@ -162,6 +162,7 @@ public class PersonaMysqlDAO implements PersonaDAO {
+ " upper(rtrim(ltrim(?))), "
+ " upper(rtrim(ltrim(?))), "
+ " upper(rtrim(ltrim(?))), "
+ " upper(rtrim(ltrim(?))), "
+ " 0 "
+ " )";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment