Subscribe Bookmark RSS Feed

Problems running JSL calling Microsoft SQL from Add-in

winfried_theis

Community Trekker

Joined:

Jun 30, 2014

Hello!

Has anyone else ever encountered problems running JSL code from within an Add-In? I have encounter right now the following issue: I have a working JSL code that should be downloading data from a database, i.e. is connecting to Microsoft SQL server and sending an SQL query to it. When I run it from the Script window it works fine, when I put it into the add-in, re-install the add-in and try to run, the SQL server says "Error near ',' ". Any ideas?

Cheers,

Winfried

PS: I'm using JMP 11.2.0

1 REPLY
Eric_Hill

Staff

Joined:

Oct 1, 2013

In my experience, issues like this usually come down to namespaces.  In the script editor, if you haven't explicitly called NamesDefaultToHere(), you will be defaulting to the global namespace.  By default, scripts from an add-in run in the Here namespace.  There may just be a variable in your addin that needs a scope modifier in front ("::" I think).  Or, in the Menu Editor, I believe there is a check box you can set for an item to determine if its script runs in the Here namespace or not.  That's where I would start looking.

HTH,

Eric