close
Warning:
Can't synchronize with repository "(default)" (/var/svn/tolp does not appear to be a Subversion repository.). Look in the Trac log for more information.
- Timestamp:
-
May 31, 2010, 4:59:29 PM (16 years ago)
- Author:
-
Víctor de Buen Remiro
- Comment:
-
Se han añadido argumentos opcionales a Tokenizer para mantener la compatibilidad hacia atrás:
Set Tokenizer(Text string, Text separator [, Text quote="", Text scape=""])
Divide un texto en cada una de las partes separadas por el caracter de separacion dado.
Si se especifica el argumento <quote>, entonces los campos que comiencen por ese caracter podrán incluir el caracter separador sin que les afecte el mismo.
Si además se especifica el argumento <quote>, entonces el par <scape><quote> será tratado como <quote>
De eta forma, la sentencia siguiente devuelve el resultado esperado
Set aux = Tokenizer("1,\"Par (\"Producto\",\"Dirección\")\",3",",","\"","\\");
Set View(aux,"");
Legend:
- Unmodified
- Added
- Removed
- Modified
-
-
Property
Status
changed from
new
to
closed
-
Property
Resolution
changed from
to
fixed
-
|
initial
|
v2
|
|
| 3 | 3 | Por ejemplo, este código |
| 4 | 4 | {{{ |
| 5 | | Set aux = Tokenizer("1,'Par (Producto,Dirección)',3",","); |
| | 5 | Set aux = Tokenizer("1,\"Par (\"Producto\",\"Dirección\")\",3",","); |
| | 6 | //Set aux = Tokenizer("1,\"Par (\"Producto\",\"Dirección\")\",3",",","\"","\\"); |
| 6 | 7 | Set View(aux,""); |
| 7 | 8 | }}} |
| … |
… |
|
| 10 | 11 | {{{ |
| 11 | 12 | $tmp$="1" |
| 12 | | $tmp$="'Par (Producto" |
| 13 | | $tmp$="Dirección)'" |
| | 13 | $tmp$=""Par ("Producto"" |
| | 14 | $tmp$=""Dirección")"" |
| 14 | 15 | $tmp$="3" |
| 15 | 16 | }}} |
| … |
… |
|
| 19 | 20 | {{{ |
| 20 | 21 | $tmp$="1" |
| 21 | | $tmp$="'Par (Producto,Dirección)'" |
| | 22 | $tmp$=""Par ("Producto","Dirección")"" |
| 22 | 23 | $tmp$="3" |
| 23 | 24 | }}} |