JMP help Validation Column causing JMP to stop responding - sas-jmp

JMP is timing out and not responding when I am tryng to create a validation column. The data set is large 560,000 rows but for whatever reason it causes JMP to freeze when I create this. If it does manage to generate a validation column every row has a " ." in it instead of training,validation and test.
Any suggestions to prevent this from happeneing? I've never had this issue before
I've tried removing irrelevant columns to shrink some of the data down yet almost every time I try and generate the validation column the program stops responding and I have to close it. I have no issue though with building plots.

Related

Lazarus DBGrid totally blank after record commit

I have been using Lazarus 2.x (free pascal) with firebird 3 (via flamerobin) and i try to commit records via TSQLConnection, TSQLQuery, TDBConnection in data module (appeals) etc.
I run the following code snippet and the records are successfully commited to firebird, but unfortunately DB connection afterwards is lost and thus there is not any record to be seen via DBGrid (not even column headers - totally blank). I have to terminate the application and reopen it to gain visual insight of my firebird via DBGrid.
Button click event
appeals.SQLTransaction1.Active:=false;
appeals.SQLQuery1.SQL.Text:='UPDATE appeals set name=:name,date_entry=:entry,date_suspended=:suspended,'+
'date_court=:court,date_judgement=:judgement where id='+IntToStr(row_num);
appeals.SQLQuery1.Params.ParamByName('name').AsString:=Trim(Edit1.Text);
appeals.SQLQuery1.Params.ParamByName('entry').AsDate:=DateTimePicker1.Date;
appeals.SQLQuery1.Params.ParamByName('suspended').AsDate:=IncDay(DateTimePicker1.Date,10);
appeals.SQLQuery1.Params.ParamByName('court').AsDate:=DateTimePicker2.Date;
appeals.SQLQuery1.Params.ParamByName('judgement').AsDate:=IncDay(DateTimePicker2.Date,20);
appeals.SQLTransaction1.StartTransaction;
appeals.SQLQuery1.ExecSQL;
appeals.SQLTransaction1.Commit;
I have also used .CommitRetaining as exactly mentioned in lazarus forum without success. Any idea what could i do in order to see my records live in DBGrid after commit.
Regards
The reason the DBgrid shows nothing is that SqlQuery1.ExecSQL does not return a result set, so SqlQuery1 cannot supply any records for the DBGrid to display. So call SqlQuery1.Open after your Commit.
However, before you can call SqlQuery1.Open, you need to give it a SELECT statement to Execute, because a SQL UPDATE statement does not return a result set, as you have already found. So, do something like:
[...]
appeals.SQLTransaction1.StartTransaction;
appeals.SQLQuery1.ExecSQL;
appeals.SQLTransaction1.Commit;
appeals.SQLQuery1.Sql.Text := 'Select * from appeals where ...';
appeals.SQLQuery1.Open;
obviously replacing '...' in the 'where' clause by something appropriate. Normally. a SELECT query should be parameterised to limit the number of rows returned and the amount of time the table is locked on the server.

Oracle Apex Application manual tabular form

I have an interactive report, where the query is combined, so I can't use editable interactive grid. That's why I have to use manual form in my query.
I've found some nice tips about the APEX_ITEMs, but I have problem with my process.
In my query there are columns like:
APEX_ITEM.HIDDEN(1,coursestudent.id)
...
APEX_ITEM.SELECT_LIST(2,coursestudent.signed,'Signed;1,Failed;0')
I have a submit button, and here is my process:
FOR i in 1..apex_application.g_f01.count LOOP
UPDATE coursestudent
SET signed=apex_application.g_f02(i)
WHERE id=apex_application.g_f01(i);
END LOOP;
I've thought that it's not too difficult, but after I press Submit nothing happens, except that the Success message is written out the page.
What should I do?
I'm using the Oracle Apex version: 5.1.1.00.08
Thanks to Jeffrey, I found the error: it is a bug.
I had to copy-paste the sql query again, and it works now. Ok, really, in that case I always put a select 1 from dual in it's place, save, and just after that paste back the query.
I've faced this bug before that, sometimes the new columns just don't showing in the page. Since I put the hidden column after I first create the query, it hadn't shown in the page, so the loop in the process never worked.

How to get the grid view for query results using oracle sql developer in mac?

When I issue a query like select * from city; using oracle sql developer in mac I get the output that is not aligned and it is very hard to read. How do I get the grid view and set it as default?
Sounds like you're getting the script output. You can have that formatted nicely by using SET SQLFORMAT ansiconsole, we'll make the columns line up as nice as possible based on the size of the display.
But if you want the data back in a grid, use Ctrl+Enter or F9 or the first execute button in the toolbar to execute.
This will get you the output in a grid, like this:
I talk about both executing as a script or statement here.
If your issue is with formatting, you may want to look at this link
If your issue is with records not getting inserted, please note these.
Records inserted in one session will not be visible in another session unless they are committed.
If you are checking the count in the same session where you inserted the records, then check for errors in insert. Add a show errors command at the end of your script, "path_to_file.sql" to check if any errors occurred while inserting the records.
Hope this helps.

Setting uniq number in instead-of-trigger using EF

I'm using ASP.NET MVC3 and Entity Framework with Database first aproach.
I have a table with id(key), number and description columns. I need to generate a number after item insertion. I created instead of trigger where I generate number that I need (it depends on last number that allready exists in database).
The problem is: When users insert items at same time the number in both cases is the same. So for both inserted items trigger fires and inside the trigger select returns same last number of item that allready exsist.
What is the best practice to solve this kind of issue?
Thanks.
I believe this will help you.
http://www.sqlteam.com/article/custom-auto-generated-sequences-with-sql-server
Also, if you're using SQL Server 2012, there is a new feature called SQL Sequence. It's something that Oracle databases have for a long time.
If you need those numbers without any gap, I'd suggest you to lock the table (prevent write), query it, update the row with max(number) and unlock it.

FileMaker Pro 10 - How to have cursor be in first field on new record?

When I start a new record in FileMaker is there a way for the cursor to automatically be in the first field so I can just start typing? And to specify which field that should be?
Background:
I'm trying to set up a FileMaker layout for use with a barcode scanner. So someone can scan in one record (there are two fields on the layout). After scanning it should go to a new record and place the cursor in the scan field so it's ready to scan again.
I put a trigger on the scan field to run a script to create a new record after hitting the enter key in the one field. After the new record statement I put a "go to field" statement but it doesn't seem to do anything. It always goes to the other field instead of the scan field.
Updates
I just tried using a "set selection" statement in the script instead of "go to field" (I also tried using both one after the other). Neither of those seemed to work.
I tried changing the tab order but it still goes to the other field instead of the scan field.
The default behavior when you create a new record is to go to the first field in the tab order, so this should work without you having to do anything.
The fact that it's not sounds to me like there might be a script trigger, either at the layout or field level, that's interfering with this or exiting the record. Try turning on the script debugger, create a new record, and see if a script runs.
I ended up doing a workaround.
I have just one field on the scan layout. After a user scans, a script fires which changes the layout to one which shows all the information about the scanned record that was just entered. It pauses for 1 second and then goes back to the scan layout for the next scan.
You may be able to set your scanner to submit pre and post data keystrokes. We routinely use this to invoke a filemaker script pre-scan to "go to field", enter the data, then post-scan to "perform a find"
I eventually devised a decent workaround with a second trigger script which seems to have no disadvantages.
However the tabs are set, I have found that an OnObjectExit trigger or an OnObjectSave trigger set up on the scan field will perform a script to process the scanned data, but the the step to return the cursor to the scan field will NOT work, probably because that field is still active in some way.
Rather than banging my head against I brick wall, I decided to set up an OnObjectExit trigger on the field to which the cursor is always deflected. This fires off a script to clear the scan field and then return the cursor to the scan field, ready for the next scan. This way, the cursor DOES arrive back where I want it.
Perhaps rather inelegant, but it works fine!

Resources