[Solved] Date to text - how
-
- Posts: 5
- Joined: Wed Jul 21, 2021 5:06 pm
[Solved] Date to text - how
This is a simple problem. I used to know how to do this, but it's been years since I've worked with spreadsheets, and I've forgotten.
What I am trying to do is take some input, make some date calculations, and then have an output column. The calculations were simple enough; that came back to me. But my problem is dates. I am trying to get a cell saying "Date=yyyy-mm-dd". That's it. I tried using concatenate, with the text, and the new date (from a
different cell). but what I get is "Date=44398". I cannot get it to say "2021-07-21". I tried the Text Function, but there was no format that would work, not that I could find. I thought I remembered using Text to do this, but there are no formats given for dates. (yyyy-mm-dd just gives an error.)
I even tried just copying the column into another, with "paste special", but that just gave a blank cell. (I could have sworn that used to work, pasting everything as text. Doesn't now.)
Again, I am sure I was able to do this once upon a time. Can anyone tell me what I've forgotten?
Thanks.
What I am trying to do is take some input, make some date calculations, and then have an output column. The calculations were simple enough; that came back to me. But my problem is dates. I am trying to get a cell saying "Date=yyyy-mm-dd". That's it. I tried using concatenate, with the text, and the new date (from a
different cell). but what I get is "Date=44398". I cannot get it to say "2021-07-21". I tried the Text Function, but there was no format that would work, not that I could find. I thought I remembered using Text to do this, but there are no formats given for dates. (yyyy-mm-dd just gives an error.)
I even tried just copying the column into another, with "paste special", but that just gave a blank cell. (I could have sworn that used to work, pasting everything as text. Doesn't now.)
Again, I am sure I was able to do this once upon a time. Can anyone tell me what I've forgotten?
Thanks.
Last edited by Hagar Delest on Thu Jul 22, 2021 10:37 am, edited 1 time in total.
Reason: tagged solved.
Reason: tagged solved.
Open Office 4.1.19 on Windows 10 Pro
Re: Date to text - how
I think you want a formula like
Code: Select all
="Date = " & TEXT(A1;"YYYY-MM-DD")
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
Re: Date to text - how
You can format the cell itself (for example: A1), what contains the 44398 numeruc value by the code yyyy-mm-dd in the applied cell stlye. The number remains a numeric value when you use a style (or manual formating). You can make calculations with it.
Or you can use the
Note: the result will be a text but nut a number - you can not make any calculation with it.
Or you can use the
Code: Select all
=TEXT(A1;"yyyy-mm-dd")
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
-
- Posts: 5
- Joined: Wed Jul 21, 2021 5:06 pm
Re: Date to text - how
I tried that
=TEXT(A1;"yyyy-mm-dd")
What I got was a cell displaying the word "original".
=TEXT(A1;"yyyy-mm-dd")
What I got was a cell displaying the word "original".
Open Office 4.1.19 on Windows 10 Pro
Re: Date to text - how
Please upload your ODF type sample file here...
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
-
- Posts: 5
- Joined: Wed Jul 21, 2021 5:06 pm
Re: Date to text - how
Zizi64 wants you to upload a file illustrating your problem. It would only have to have two cells occupied, one with the date and the other with the formula you are trying to use.
To upload a file, click Post Reply and look for the Upload Attachment tab just below the box where you type a response.
To upload a file, click Post Reply and look for the Upload Attachment tab just below the box where you type a response.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
-
- Posts: 5
- Joined: Wed Jul 21, 2021 5:06 pm
Re: Date to text - how
Thanks. Actually, I just figured out what I was doing wrong.
Thank you all.
Thank you all.
Open Office 4.1.19 on Windows 10 Pro
Re: Date to text - how
Could you add your solution here in case it may help someone else with the same problem?
Cheers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers
-
- Posts: 5
- Joined: Wed Jul 21, 2021 5:06 pm
Re: [Solved] Date to text - how
It was a typo that I didn't notice. I had a single ' in one spot. That has always been aproblem for me.
Open Office 4.1.19 on Windows 10 Pro