Rocksolid Light

Welcome to RetroBBS

mail  files  register  newsreader  groups  login

Message-ID:  

All great ideas are controversial, or have been at one time.


devel / comp.databases.mysql / Re: how to get the date from the first date

SubjectAuthor
* how to get the date from the first dateNiraj Kothari
`- Re: how to get the date from the first dateJ.O. Aho

1
how to get the date from the first date

<b62ae77e-1dbf-42e3-9d9c-9d2b904043d4n@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=23&group=comp.databases.mysql#23

  copy link   Newsgroups: comp.databases.mysql
X-Received: by 2002:a37:9a47:: with SMTP id c68mr4038883qke.37.1627549917883;
Thu, 29 Jul 2021 02:11:57 -0700 (PDT)
X-Received: by 2002:a0c:ea91:: with SMTP id d17mr1033847qvp.0.1627549917682;
Thu, 29 Jul 2021 02:11:57 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!4.us.feeder.erje.net!2.eu.feeder.erje.net!feeder.erje.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.databases.mysql
Date: Thu, 29 Jul 2021 02:11:57 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=106.210.228.125; posting-account=TmXSqAoAAACb7Mw5P6c0P7r0jlqXeHVX
NNTP-Posting-Host: 106.210.228.125
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <b62ae77e-1dbf-42e3-9d9c-9d2b904043d4n@googlegroups.com>
Subject: how to get the date from the first date
From: niraj.kothari@abmra.in (Niraj Kothari)
Injection-Date: Thu, 29 Jul 2021 09:11:57 +0000
Content-Type: text/plain; charset="UTF-8"
 by: Niraj Kothari - Thu, 29 Jul 2021 09:11 UTC

what is the sql query to find out the full date where we put the starting date means 09/08/2020 We Only put 09. and how i will get 09/08/2020 This date

Re: how to get the date from the first date

<imfk5oFii61U1@mid.individual.net>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=25&group=comp.databases.mysql#25

  copy link   Newsgroups: comp.databases.mysql
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From: user@example.net (J.O. Aho)
Newsgroups: comp.databases.mysql
Subject: Re: how to get the date from the first date
Date: Thu, 29 Jul 2021 14:10:31 +0200
Lines: 25
Message-ID: <imfk5oFii61U1@mid.individual.net>
References: <b62ae77e-1dbf-42e3-9d9c-9d2b904043d4n@googlegroups.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Trace: individual.net tTk/Cp3Wt2uwMqUgqWJnSggvurt/ddikjxkCTbTi0P367XcHq8
Cancel-Lock: sha1:5TCCdLDh20zdRHWPgI/laTYeuHg=
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101
Thunderbird/78.12.0
In-Reply-To: <b62ae77e-1dbf-42e3-9d9c-9d2b904043d4n@googlegroups.com>
Content-Language: en-US-large
 by: J.O. Aho - Thu, 29 Jul 2021 12:10 UTC

On 29/07/2021 11.11, Niraj Kothari wrote:
> what is the sql query to find out the full date where we put the starting date means 09/08/2020 We Only put 09. and how i will get 09/08/2020 This date

select day_column_name + "/08/2020" from table_name;

To get a whole date you have to store the whole data, change the column
type VarChar(2) to one of the following:

- Date [Format: YYYY-MM-DD, Range: '1000-01-01' to '9999-12-31']

- DateTime [Format: 'YYYY-MM-DD hh:mm:ss[.fraction]', Range: '1000-01-01
00:00:00.000000' to '9999-12-31 23:59:59.999999']

- TimeStamp [Format: 'YYYY-MM-DD hh:mm:ss[.fraction]', Range:
'1970-01-01 00:00:01.000000' to '2038-01-19 03:14:07.999999']

Then you can use DAY(date_column_name) to get the day from the
Date/DateTime/TimeStamp and DATE_FORMAT(date_column_name, '%d/%m/%Y') to
be sure to get it in the odd format you want to get it in.

--

//Aho

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor