Solved

CaseCreate Error

  • 26 March 2020
  • 4 replies
  • 125 views

Hi!

I have just build my first model on AIMMS and when I tried to run the model, the next following error appeared:

 

If the option “Data management style” is set to “Disk files and folders”, the procedure CaseCreate is not valid.

 

Would anyone know how I can solve this problem?

 

Thank you very much in advance!

icon

Best answer by mateusarakawa 26 March 2020, 23:31

View original

4 replies

Hi @mohansx, thank you very much for your answer and help!

Userlevel 5
Badge +5

@Max Lomba Vrouenraets , you should remove all usage of functions like CaseCreate, CaseSave in your code as they are not available with the current(and default) disk management style . 

 

The error message is referring to the string parameter CaseName. It should end with an extension .data. 

 

CaseName := “A1-2020 Allocation”; 

must be 

CaseName := “A1-2020 Allocation.data”;

Hi @mateusarakawa,

 

First of all, thank you very much for your answer. It helps me to understand the root of the problem.

What I also understand from your answer is that I need to use another function that works like the CaseCreate that I used. I am right?

Which one do you recommend to me from the list? I attach you here the core of my model. I tried to replace CaseCreate with the function CaseFileSave and the error that I got was the one shown on the screen. I would be extremely grateful if you can help me to substitute my current formulation with the new one!

Again, thank you so much for your help @mateusarakawa!!

 

Userlevel 5
Badge +2

Hi, @Max Lomba Vrouenraets.

 

Basically, the function CaseCreate is related to AIMMS old case management style (single file where your data is stored).

This function doesn’t work because your AIMMS project is configured to the new management style ‘disk files and folders’.

 

In order to understand the difference between both, please read:

AIMMS 3.0 stores cases were in so-called “data manager files”. AIMMS 3.12 introduced the .data format as an alternative.

This change was made for several reasons.

  • Data manager files (.dat) became difficult to manage when maintaining several cases.
  • Case files (.data) avoid the risk of data corruption in one case affecting other cases stored in the same file.
  • Storing multiple case files in a folder makes it easy to copy cases from multiple users in the same folder, and compare scenarios. (See the AIMMS User’s Guide, Section “Managing multiple case selections”.)

In projects created with AIMMS version before 3.14, a single data manager file (.dat) contains zero, one or more cases. From AIMMS version 3.14, a case file (.data) only stores one case, but multiple cases may be stored in the same folder.

Before AIMMS 3 AIMMS 3.14 and later
.dat .data
Single data manager file contains zero, one or more cases Disk files and folders store multiple files, with one case per file
Source: https://how-to.aimms.com/Articles/314/314-from-dat-to-data.html

 

If you want to save your data, you can use other functions.

 

Hope it helps.

Reply


Didn't find what you were looking for? Try searching on our documentation pages:

AIMMS Developer & PRO | AIMMS How-To | AIMMS SC Navigator