Hola,
estoy con sql server 2005 express, y quieero crear un script inicialización
de datos para varias aplicaciones
ID_APLICACION = 1, 2, 3... n
Para la aplicación 1 tengo estos insert
insert Campos_Busqueda (
ID_APLICACION,ID_CAMPO,DESCRIPCION,ID_TIPO,OBLIGATORIO,LONGITUD,ID_EntidadNegocio,EsInterno,EsIdentificador ) select 1,1,'NumeroPrestamo',1,0,10,1,0,0
insert Campos_Busqueda (
ID_APLICACION,ID_CAMPO,DESCRIPCION,ID_TIPO,OBLIGATORIO,LONGITUD,ID_EntidadNegocio,EsInterno,EsIdentificador ) select 1,2,'DNI',1,0,9,1,0,0
insert Campos_Busqueda (
ID_APLICACION,ID_CAMPO,DESCRIPCION,ID_TIPO,OBLIGATORIO,LONGITUD,ID_EntidadNegocio,EsInterno,EsIdentificador ) select 1,3,'Intervinientes',1,1,10,1,0,0
Cómo podría generar los insert de forma parametrizada por ID_APLICACION a
partir de una lista de valores ID_APLICACION (1,2,3, ..n) o a partir de una
consulta a la tabla Aplicaciones (select ID_APLICACION from aplicaciones)
Gracias de antemano y saludos.
http://www.alhambra-eidos.es/web2005/index.html
www.kiquenet.com/churrosoft
http://www.setbb.com/putainformatic...opic.php?p3
www.trabajobasura.com/solusoft
Leer las respuestas