Bug 133677 - importing/inserting data from a file into the current sheet EDITING, FILEOPEN
Summary: importing/inserting data from a file into the current sheet EDITING, FILEOPEN
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.4.3.2 release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-04 15:22 UTC by OldSurferDude
Modified: 2020-06-07 19:02 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
data file (65.88 KB, text/plain)
2020-06-04 21:34 UTC, OldSurferDude
Details
CALC file used to analyze data file (65.49 KB, application/vnd.oasis.opendocument.spreadsheet)
2020-06-04 21:53 UTC, OldSurferDude
Details

Note You need to log in before you can comment on or make changes to this bug.
Description OldSurferDude 2020-06-04 15:22:05 UTC
Description:
The reason for logging data is to analyze it later.  Yes, a two step approach is a work around (open data file with text editor, copy and paste into sheet), but it cannot be automated, unless a third, OS level, program is employed.

I envision something like "file-->insert from file" which can be included in a macro.

This would not necessarily be just for Calc, I could see uses in Writer and Impress

Steps to Reproduce:
1. 

Actual Results:
not possible to import/insert data from file

Expected Results:
data is put into document in the place desired


Reproducible: Always


User Profile Reset: No



Additional Info:
Been able to insert/import data from a file
Comment 1 m_a_riosv 2020-06-04 20:58:58 UTC
Please attach a sample for both files, and detailing what data want to import and where want to be put.
Comment 2 OldSurferDude 2020-06-04 21:34:11 UTC
Created attachment 161622 [details]
data file

This is the .CSV file into which the data logger writes.
The first line describes the columns.
DateTime and DigitalTime are time representations.
There are four locations, each with three sensors (ON/off)
A change of state of sensor is logged.

It is desired to determine how long a sensor is in a particular state.

I will upload and describe the .ods file used for analyzing the data in the next post
Comment 3 OldSurferDude 2020-06-04 21:53:45 UTC
Created attachment 161623 [details]
CALC file used to analyze data file

With this spread sheet I can determine the length of time a sensor is on or off.

To get the data into the spreadsheet:
1. open up data in a text document
2. select all and copy date.
3. in the CALC document, move to cell A1
4. paste
5. change the first column type to Date(YMD)
6. OK
7. sort the five columns by location(C), sensor(D), time(B)
8. go to the first entry in seconds on(F) column
9. Select that entry and the one in secondsoff(G)
10. Copy
11. Select all the cells in (F) that have data data location 1, and sensor 2
12. paste

the pasted cells now show how many seconds the sensor was on in column (F) and hours off in column (G)
Comment 4 QA Administrators 2020-06-05 03:46:23 UTC Comment hidden (obsolete)
Comment 5 m_a_riosv 2020-06-05 07:17:25 UTC
I don't understand what are you talking about.

You can insert the data in a calc file in two ways.

Menu/Sheet/Insert Sheet from file, that adds a new sheet with the source data, and marking it a permanent link can be selected.
Meny/Sheet/Link to external data, with this you can add the data where you like.

Both can be updated when the file is open and on Menu/Edit/Link to external files.

No macros are needed.

https://help.libreoffice.org/6.4/en-US/text/scalc/guide/webquery.html?DbPAR=CALC#bm_id3154346

Please this is the site for bug report, better is always do the question in ask.libreoffice.org
Comment 6 OldSurferDude 2020-06-06 16:53:54 UTC
Thank you for showing me that feature

sheets-->Insert Sheet From File-->enter file name-->>select import text options-->[OK]-->select all text-->copy-->select original sheet-->paste-->delete insert to sheet

The way I was doing it was:

locate file-->open with text editor-->select all-->copy-->select original sheet-->paste-->select import options-->[OK]

One might consider the enhancement request was to make it less awkward.

I am having problems putting the LibreOffice insertion technique into a macro, but at this point I suspect that is my problem.

Truly, I appreciate the support.  Thank you.
Comment 7 m_a_riosv 2020-06-07 19:02:09 UTC
Also, if there is a question, please before to report a bug, go to ask.libreoffice.org, there are very expertise users to help, so you can get some certainty it is really a bug

Bugzilla it's not a help system.

BTW the first should take a quick look to the manual.