ATTENTION

This FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices.


flexsim.com

Go Back   FlexSim Community Forum > FlexSim Software > Q&A
Downloads

Q&A Using Flexsim and building models

  #1  
Old 07-03-2014
Esther Bennett Esther Bennett is offline
Flexsim User
 
Join Date: Mar 2008
Posts: 115
Downloads: 27
Uploads: 0
Thanks: 103
Thanked 116 Times in 50 Posts
Rep Power: 271
Esther Bennett is a name known to allEsther Bennett is a name known to allEsther Bennett is a name known to allEsther Bennett is a name known to allEsther Bennett is a name known to allEsther Bennett is a name known to all
Default Data loss when importing from excel

Hello,

I seem to lose data when I read an excel sheet into a table. i.e. a value in a cell of excel is 0.00000462. After reading the table into excel, the value is 0.00 even if I increase the number precision to 10. Is there a way to prevent this loss?

Esther
The Following User Says Thank You to Esther Bennett For This Useful Post:
Carsten Seehafer (07-03-2014)
  #2  
Old 07-03-2014
Carsten Seehafer's Avatar
Carsten Seehafer Carsten Seehafer is offline
FlexSim Geek
 
Join Date: Oct 2008
Location: Ritterhude, Deutschland
Posts: 230
Downloads: 45
Uploads: 1
Thanks: 474
Thanked 320 Times in 143 Posts
Rep Power: 379
Carsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud of
Default

Hello Esther,

I've tried 3 import options:
- import with flexsim commands -> correct behavior
- import with excel import interface and data distinction automatic -> numbers are rounded at the 6th decimal place
- import with excel import interface and data distinction numeric -> correct behavior

Maybe this is a little help
The Following 6 Users Say Thank You to Carsten Seehafer For This Useful Post:
Tom David (07-07-2014)
  #3  
Old 07-03-2014
Matt Long Matt Long is offline
FlexSim Development
 
Join Date: Apr 2012
Posts: 66
Downloads: 37
Uploads: 29
Thanks: 2
Thanked 150 Times in 40 Posts
Rep Power: 192
Matt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of light
Default

Which version of FlexSim are you running?
  #4  
Old 07-03-2014
Carsten Seehafer's Avatar
Carsten Seehafer Carsten Seehafer is offline
FlexSim Geek
 
Join Date: Oct 2008
Location: Ritterhude, Deutschland
Posts: 230
Downloads: 45
Uploads: 1
Thanks: 474
Thanked 320 Times in 143 Posts
Rep Power: 379
Carsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud ofCarsten Seehafer has much to be proud of
Default

@Matt: In my case it was FlexSim GP 7.1.4. I've used the number "8888.00000462".
  #5  
Old 07-04-2014
Esther Bennett Esther Bennett is offline
Flexsim User
 
Join Date: Mar 2008
Posts: 115
Downloads: 27
Uploads: 0
Thanks: 103
Thanked 116 Times in 50 Posts
Rep Power: 271
Esther Bennett is a name known to allEsther Bennett is a name known to allEsther Bennett is a name known to allEsther Bennett is a name known to allEsther Bennett is a name known to allEsther Bennett is a name known to all
Default

@Matt I am using Flexsim 7.1.4 32 bit version on a windows 7 64 bit machine. I will try the first option of Carsten later today and let you know if this works for me, the third option is not applicable for me, because I have (large) tables with both string and numeric columns.

I managed to read in a specific number the way Carsten did. Only we have very large table to import, so reading in separate numbers (and strings) is not really an option.


Esther

Last edited by Esther Bennett; 07-04-2014 at 09:06 AM.
  #6  
Old 07-07-2014
Matt Long Matt Long is offline
FlexSim Development
 
Join Date: Apr 2012
Posts: 66
Downloads: 37
Uploads: 29
Thanks: 2
Thanked 150 Times in 40 Posts
Rep Power: 192
Matt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of light
Default

Using FlexSim 7.1.4 32-bit on a 64-bit machine, I was able to reproduce the issue and solve it.

When doing Automatic Data Distinction, the Excel Importer reads in all data as a string taking in to account Excel's cell format. So FlexSim now imports what you see in Excel, rather than the data Excel stores behind the scenes. This means the cell must be formatted correctly in order for FlexSim to read in the data as you want it to. Reading the cell format is a change from previous versions of FlexSim that now allows you to properly import dates as strings rather than as numbers.

In order to properly import your number data in this case, you need to increase the precision of the cell's with long numbers in them. This can be done by selecting the cells and clicking the Increase Decimal button found under the Number Format box in the main toolbar.

This of course is not an issue when using Numeric Data Distinction as all data is read in as a number.
The Following 8 Users Say Thank You to Matt Long For This Useful Post:
Tom David (07-08-2014)
  #7  
Old 07-08-2014
Matt Long Matt Long is offline
FlexSim Development
 
Join Date: Apr 2012
Posts: 66
Downloads: 37
Uploads: 29
Thanks: 2
Thanked 150 Times in 40 Posts
Rep Power: 192
Matt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of lightMatt Long is a glorious beacon of light
Default

We're going to make a change in version 7.3 (being released within the next month) that will address this change in the Automatic Data Distinction. The importer will still import all data in a string, and then check to see if it's a number or a string as previously described. However, if it finds that the imported value is a number, it will reimport the value from Excel as a number. This will give you the full precision of the number without the need to increase the decimal precision of each cell.
The Following 7 Users Say Thank You to Matt Long For This Useful Post:
Tom David (07-09-2014)


Thread Thread Starter Forum Replies Last Post
Importing Timetables/Shift Patterns into Flexsim from Excel Daniel Braund Q&A 2 08-19-2011 03:00 AM
How to export model data to excel? zhang xin Container Terminal (CT) Library 3 04-16-2011 01:21 AM
Excel Data Import Sung Kim Q&A 2 07-16-2010 10:41 AM
Excel File Importing John Kim Container Terminal (CT) Library 0 08-06-2009 03:21 PM
Problem with importing Excel data David Chan Q&A 5 03-05-2009 01:49 AM


All times are GMT -6.
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Copyright 1993-2018 FlexSim Software Products, Inc.