Proc code - Solutions - VALIDATIONS Go Home

    In the spanish_v.trx you can find three very typicals validations procedures in the spanish applications. The form is called VALIDATIONS_E.
 

NIF. Fiscal Identification for Physical Person Company

The validation procedure is in the VALIDATE FIELD TRIGGER of the field NIF.

NIF is a sequence of 8 numbers finished by a letter 

1. Is not necessary but recomended (some organization requires-it) that NIF have the 8 digits (leading zeros neede). This is a non friendly option for the user but if you whant you can put the DIS(########&) syntax 

2. Some user wants see the correct check digit when an validation error occurs. User the $result 

In $result : The correct check digit or "FMT" if there are and format error

CIF. Fiscal identification for Juridic Companies

The validation procedure is in the VALIDATE FIELD TRIGGER of the field CIF

CIF is a sequence of a letter, 7 numbers finished by a letter or number

1. The first letter refers to the type of company 
("juridic type for the spanish laws")
   A . SOCIEDADES ANONIMAS (S.A.)
   B . SOCIEDADES DE RESPONSABILIDAD LIMITADA (S.R.L.)
   C . SOCIEDADES COLECTIVAS
   D . SOCIEDADES COMANDITARIAS
   E . COMUNIDADES DE BIENES (C.B.)
   F . SOCIEDADES COOPERATIVAS
   G . ASOCIACIONES Y OTROS TIPOS NO DEFINIDOS
   H . COMUNIDADES DE PROPIETARIOS EN REGIMEN DE PROPIEDAD HORIZONTAL
   P . CORPORACIONES LOCALES
   Q . ORGANISMOS AUTONOMOS ESTATALES O NO, Y ASIMILADOS, Y CONCREGACIONES RELIGIOSAS
   S . ORGANOS DE LA ADMINISTRACION DEL ESTADO

2. The last position can be a letter or a number depending of the country of the main company

3. Some user wants see the correct check digit when an validation error occurs. User the $result 

In $result : The correct check digit or "FMT" if there are and format error

Bank Account

The proc code is in the <DETAIL> TRIGGER of the field CHECK_CCC

CCC have this structure:
- BANCO (bank code) of 4 digits
- OFICINA (agency code) of 4 digits
- CONTROL (control digits) 2 digits. The first is for BANCO-OFICINA validation and the second one for CUENTA
- CUENTA (account number)

1. Note that this procedure check if the numbers are correct but not if the bank and office exists. Some banks distribute a flat file with the existing bank and agency codes.
2. Some users want see the correct check digit when an validation error occurs. User the $result 
 


Copyright © 1999-2003  $UUU  All rights reserved.
Disclaimer. | Site Comments.