Re: [Jprogramming] Is is good idea to use J for reading large XML files ?

2021-09-09 Thread Mariusz Grasko
Raul, Thank you very much for helping me out ! I have managed to tweak expat.jis so it now works stream-parsing style. It took me a long time to realise the fact that api/expat/expat.jis in addons directory was being constatnly overwritten by J to default version all the time. So now I just load m

Re: [Jprogramming] Is is good idea to use J for reading large XML files ?

2021-09-09 Thread Mariusz Grasko
Repasting it with small fix and without my comments. expat_parse_file=: 3 : 0 '' expat_parse_file y : expat_init x parser=. XML_ParserCreate <<0 f=. [: 15!:13 (IFWIN#'+') , ' x' $~ +:@>: XML_SetElementHandler parser, (f 3), (f 2) XML_SetCharacterDataHandler parser, (f 4) size =. 1!:4 y [

Re: [Jprogramming] Is is good idea to use J for reading large XML files ?

2021-09-09 Thread Raul Miller
That looks plausible (though I have not tested it). That said, I would like to recommend that when using gmail you use "paste and match style" rather than the default "paste" mechanism. Perhaps like this: expat_parse_file=: 3 : 0 '' expat_parse_file y : expat_init x parser=. XML_ParserCreate <<0

[Jprogramming] Command line flag "-prompt" not in ARGV_z_

2021-09-09 Thread Devon McCormick
Looking at the command line flags in my J session, I realized that even though I start jconsole with a "-prompt" flag, I do not see this in ARGV_z_. The other strings on my startup line are present, just not that one. Has anyone else noticed this? We see this line from the batch file I invoke to

Re: [Jprogramming] Command line flag "-prompt" not in ARGV_z_

2021-09-09 Thread Eric Iverson
I don't know all the details, but -prompt (like a few others) is a flag to jconsole, not JE. It looks like these flags are processed by the front end and not passed on to JE. On Thu, Sep 9, 2021 at 10:45 AM Devon McCormick wrote: > Looking at the command line flags in my J session, I realized th

Re: [Jprogramming] Command line flag "-prompt" not in ARGV_z_

2021-09-09 Thread Devon McCormick
Thanks for the explanation. I see that this was implied here - https://code.jsoftware.com/wiki/System/Starting_J#Command_line_parameters - but I just made it explicit. On Thu, Sep 9, 2021 at 11:16 AM Eric Iverson wrote: > I don't know all the details, but -prompt (like a few others) is a flag t

[Jprogramming] Change in ODBC ddcol on SQLServer

2021-09-09 Thread John Baker
It seems the recent change to the ODBC addon has changed how ddcol works on SQLServer. ddcol normally returns information about the columns of a table given a connection. Now it's returning nothing but header columns. Has anyone else noticed this? -- John D. Baker [email protected] --

Re: [Jprogramming] Change in ODBC ddcol on SQLServer

2021-09-09 Thread John Baker
Here's a workaround for ddcol if anyone else hits this: hd=. ;:'TABLE_NAME COLUMN_NAME' NB. NOTE: code broken by recent changes to NB. (ddcol) Sep 9, 2021 NB. NB. d=. PDIprodland ddcol ch NB. tc=. }.((0{d) i. hd) {"1 d NB. d=. PDIorgland ddcol ch NB. tc=. tc , }.((0{d) i. hd) {"1 d NB. d=

Re: [Jprogramming] Is is good idea to use J for reading large XML files ?

2021-09-09 Thread Raul Miller
Ok, I went ahead and tested it, and it looks good. And, also, you can see an issue... which has to do with memory allocation and nested xml elements... here's my test code: require 'api/expat' cocurrent 'jexpat' expat_parse_file=: 3 : 0 '' expat_parse_file y : expat_init x parser=. XML_ParserCr