Bug 146841 - Feature Request: Convert Text to Table: "Number of Columns" option
Summary: Feature Request: Convert Text to Table: "Number of Columns" option
Status: RESOLVED DUPLICATE of bug 99035
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.2.5.2 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-01-18 15:39 UTC by brian.the2brit2
Modified: 2022-01-31 18:25 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
A list of countries, plus covid-19 stats, each on own line (16.57 KB, application/vnd.oasis.opendocument.text)
2022-01-31 18:05 UTC, brian.the2brit2
Details

Note You need to log in before you can comment on or make changes to this bug.
Description brian.the2brit2 2022-01-18 15:39:45 UTC
Description:
It would be useful to be able to make a multi-column table when using the "Convert-text-to-Table" operation.
I have a document where there is a list of countries and each country has some data related to it.  The each item of the data is on its own line following the country name. Hence the file is a lot of lines grouped in blocks of 6.
When I do "Convert text to table" I get a table with a single column, each row being one of the items in the text.

I have played around with the "Find & Replace" tool, but it's been quite hard work (with the reported "possible bug" throwing up a smokescreen).  It would be so much more efficient if the "Convert" tool would do it.
What I have in mind is an option to choose the number of columns that the created table would have. Then the items of text would be fed into the table row by row.  In my case, each row would begin with the name of the country and the other columns would have the 5 numbers related to that country.
I suppose it would be the responsibility of the user to ensure that the data structure of the input text was well-formed, but you could also have some sort of "end-of-block" character to trigger "Go to next row" in case you had a missing item in one block.

Actual Results:
Request


Expected Results:
A table of several columns (many rows), number of columns corresponding to the number of data items in a block in the input text 


Reproducible: Always


User Profile Reset: No



Additional Info:
I tried reading the text file into "Calc".  It put all the data into a single cell! 😂
Comment 1 Dieter 2022-01-31 15:52:41 UTC
Ican't confirm it with

Version: 7.3.0.3 (x64) / LibreOffice Community
Build ID: 0f246aa12d0eee4a0f7adcefbf7c878fc2238db3
CPU threads: 4; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: de-DE (de_DE); UI: de-DE
Calc: CL

I have tabstops as separators and it works. So could you please add a sample document, so this would make it easier for us to reproduce the bug. Thank you.
=> NEEDINFO
Comment 2 brian.the2brit2 2022-01-31 18:05:52 UTC
Created attachment 177944 [details]
A list of countries, plus covid-19 stats, each on own line

Dieter has said that "with tab-stops it works".  I tried it and I can see that it does create many columns.
So, there are two problems with using the tab-stops approach:
1)  I would have to go through the file converting every CR-LF to tab;
2)  I would have to have some way of grouping the blocks of 5 lines so that each block formed its own row in the table.
This is why I was suggesting that we need a parameter in the convert-interface to say how many columns the table should have.

BTW, have I misunderstood how this reporting system works?  I thought I put this in as a feature request (improvement?) but the response referred to it as a bug.
Comment 3 Dieter 2022-01-31 18:25:52 UTC
Brian, thank you for your attachment. That makes the problem more visible.

Seems to me like a duplicate of bug 99035.
=> RESOLVED DUPLICATE

Feel free to change it back to UNCONFIRMED with a short reasoning, if you disagree.

*** This bug has been marked as a duplicate of bug 99035 ***