cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • JMP Security Notice: CVE-2026-109618 and CVE-2026-109619

    JMP promptly initiated a review of its products, services, and relevant infrastructure for exposure to CVE-2026-109618 and CVE-2026-109619.

    Our assessment of JMP products has not identified exposure to these vulnerabilities. Where remediation was required within supporting environments, appropriate security updates and controls have been applied and validated.

    We have identified no evidence of successful exploitation or unauthorized access to JMP systems or customer information associated with these vulnerabilities.

    JMP continues to monitor the issue and relevant vendor guidance. No action is required by JMP customers at this time.

  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Graph Builder Toolbar streamlines interactive graphing. Creates shortcuts on Report and GraphBuilder Helpers toolbars. Download and install the extension.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar

Add column based on a user input.

I made a script which gives a pop box to enter suspected wafer list. Than it will add a column to the table with using If loop. This script is working fine when Wafer data type is Character but it doesn't work with Numerical type data type. How can I fix this?

dt = Current Data Table(); // Get the current data table
nw = New Window("Enter Shop order",
	<<Modal,
	<<Return Result,
	V List Box(
		Text Box(" "),
		variablebox = Text Edit Box("", <<Set N Lines(30), <<Set Width(150)),
		Spacer Box(Size(0, 10)),
		Button Box("OK"),
		Button Box("Cancel")
	)
);

unique = Collapse Whitespace(nw["variablebox"]);
sql_in = Associative Array(Words(unique, ", ")) << get keys;
myValueList = Concat Items(sql_in, ", ");



// Define a list of values to check against
//myValueList = {"1", "2"};

// Create a new column with a formula using the If statement
dt << New Column("Suspected",
	Formula(
		If(Contains(myValueList, :Name("Wafer")), 
			"Yes", 
			"No" 
		)
	)
);

Untitled.png

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
jthi
Super User

Re: Add column based on a user input.

Most likely easiest option is to wrap your :Wafer column in the formula with Char()

dt << New Column("Suspected", Formula(If(Contains(myValueList, Char(:Wafer)), "Yes", "No")));
-Jarmo

View solution in original post

1 REPLY 1
jthi
Super User

Re: Add column based on a user input.

Most likely easiest option is to wrap your :Wafer column in the formula with Char()

dt << New Column("Suspected", Formula(If(Contains(myValueList, Char(:Wafer)), "Yes", "No")));
-Jarmo

Recommended Articles