Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Day of the week

653 views
Skip to first unread message

Daniele

unread,
Dec 10, 2016, 6:17:20 AM12/10/16
to
Hi to all,
i'm new in this group and new with sql.

I'm reading a firebird (2.5) database, in a table there is a field DATE
where is stored the record date and time.
In my sql request i need to select all records saved on each day of week = 1
(monday)

I tried with DAYOFWEEK but it's a unknow function.

My query, which does not work in FlameRobin and DBeaver (Error: Function
unknow DAYOFWEEK).

Selcet * from Table1 where DayOfWeek(Table1."DATE")=1

Can you help me?

Thank's for all

Daniele

The Natural Philosopher

unread,
Dec 10, 2016, 6:23:52 AM12/10/16
to
On 10/12/16 13:17, Daniele wrote:
> selcet * from Table1 where DayOfWeek(Table1."DATE")=1

select * from Table1 where DayOfWeek(Table1.DATE)=1 ;


perhaps?

Daniele

unread,
Dec 10, 2016, 6:45:16 AM12/10/16
to
Hi,

>> selcet * from Table1 where DayOfWeek(Table1."DATE")=1

> select * from Table1 where DayOfWeek(Table1.DATE)=1 ;
> perhaps?

No, after searching, reading and understanding i got the soluction !! here
the correct query for Firbird

Selcet * Table1."DATE" From Table1 Where EXTRACT(WEEKDAY From
Table1."DATE)=1 and Table1.Year=2016 and Table1.Month=12

(To extract all monday for year 2016 and December month ; Result 5)

Thank's for helping me !

Good WeekEnd

Daniele

PS: Here the link
http://mujweb.cz/iprenosil/interbase/ip_ib_code_timestamp.htm

Jerry Stuckle

unread,
Dec 10, 2016, 8:02:48 AM12/10/16
to
If you post in the appropriate place, you'll get a good answer. This
newsgroup is for the MySQL database (hence the "mysql" in its name).
You won't generally get good answers for firebird here (as the
well-known troll TNP just proved).

--
==================
Remove the "x" from my email address
Jerry Stuckle
jstu...@attglobal.net
==================

The Natural Philosopher

unread,
Dec 10, 2016, 8:30:53 AM12/10/16
to
On 10/12/16 15:02, Jerry Stuckle wrote:
> On 12/10/2016 6:17 AM, Daniele wrote:
>> Hi to all,
>> i'm new in this group and new with sql.
>>
>> I'm reading a firebird (2.5) database, in a table there is a field DATE
>> where is stored the record date and time.
>> In my sql request i need to select all records saved on each day of week
>> = 1 (monday)
>>
>> I tried with DAYOFWEEK but it's a unknow function.
>>
>> My query, which does not work in FlameRobin and DBeaver (Error: Function
>> unknow DAYOFWEEK).
>>
>> Selcet * from Table1 where DayOfWeek(Table1."DATE")=1
>>
>> Can you help me?
>>
>> Thank's for all
>>
>> Daniele
>
> If you post in the appropriate place, you'll get a good answer. This
> newsgroup is for the MySQL database (hence the "mysql" in its name).
> You won't generally get good answers for firebird here (as the
> well-known troll TNP just proved).
>
Fuck off and die Jerry, you total cunt.

Guess what: I tried to help, all you had was a sneer and criticism.

Jerry Stuckle

unread,
Dec 10, 2016, 12:23:57 PM12/10/16
to
And you have the wrong answer because your head is so far up your arse
you can see your tonsils.

My message was more help. I didn't give a wrong answer. I tried to
direct her to where she could get GOOD help. Something you are totally
incapable of providing.

I suggest you break your laptop again. Usenet was so much nicer when
you weren't around - as people in several newsgroups will attest.

Luuk

unread,
Dec 10, 2016, 12:41:03 PM12/10/16
to
On 10-12-16 18:23, Jerry Stuckle wrote:
....

you did forget to set the folow-up...

Jerry Stuckle

unread,
Dec 10, 2016, 4:36:10 PM12/10/16
to
No, I didn't, Luuk. I don't play those games.

Thomas 'PointedEars' Lahn

unread,
Dec 10, 2016, 6:35:59 PM12/10/16
to
Daniele wrote:

> i'm new in this group and new with sql.
>
> I'm reading a firebird (2.5) database, […]

This newsgroup is _not_ about *any* SQL implementation, it is about
*MySQL*/MariaDB.

Also, the address part of the From header field of your postings so far is
in violation of RFC 5536, §3.1.2 [1] (otherwise it would have been possible
to notify you of your first mistake via e-mail [2]).

Scorefile adjusted accordingly.

_______
[1] <https://tools.ietf.org/html/rfc5536#section-3.1.2>
[2] <http://www.interhack.net/pubs/munging-harmful/>
--
PointedEars

Twitter: @PointedEars2
Please do not cc me. / Bitte keine Kopien per E-Mail.

Luuk

unread,
Dec 11, 2016, 8:23:20 AM12/11/16
to
On 10-12-16 22:36, Jerry Stuckle wrote:
> On 12/10/2016 12:41 PM, Luuk wrote:
>> On 10-12-16 18:23, Jerry Stuckle wrote:
>> ....
>>
>> you did forget to set the folow-up...
>
> No, I didn't, Luuk. I don't play those games.
>

;-)

Luuk

unread,
Dec 11, 2016, 8:29:59 AM12/11/16
to
On 10-12-16 12:45, Daniele wrote:
> Hi,
>
>>> selcet * from Table1 where DayOfWeek(Table1."DATE")=1
>
>> select * from Table1 where DayOfWeek(Table1.DATE)=1 ;
>> perhaps?
>
> No, after searching, reading and understanding i got the soluction !!
> here the correct query for Firbird
>
> Selcet * Table1."DATE" From Table1 Where EXTRACT(WEEKDAY From
> Table1."DATE)=1 and Table1.Year=2016 and Table1.Month=12
>

It's 'SELECT' and not 'Selcet'

Also monday's can be selected in MySQL like this:
select current_date, mod(current_date-cast('2016-12-12' as date),7)=0
monday;

Here monday will be 1 on mondays.

In FireBurd casting is noe differently, so you can rewrite it to this:
select current_date, mod(current_date - date '2016-12-12',7)=0 monday
from test;

Daniele

unread,
Dec 12, 2016, 3:55:58 AM12/12/16
to
Hi,

>> i'm new in this group and new with sql.
>> I'm reading a firebird (2.5) database, […]

> This newsgroup is _not_ about *any* SQL implementation, it is about
> *MySQL*/MariaDB.

I'm very sorry about this.
I'm disconnected from this group.

Daniele

PS: Thank's for the help you negate to me !



Jerry Stuckle

unread,
Dec 12, 2016, 9:07:03 AM12/12/16
to
Don't worry about "Pointed Head". He's a well-known troll in many
newsgroups. He never has anything positive to contribute to a discussion.

You are welcome in this newsgroup. Just beware this group is
specifically about the MySQL database, so you won't get good answers on
another database.

Luuk

unread,
Dec 13, 2016, 2:15:46 AM12/13/16
to
On 12-12-16 15:07, Jerry Stuckle wrote:
> On 12/12/2016 3:55 AM, Daniele wrote:
>> Hi,
>>
>>>> i'm new in this group and new with sql.
>>>> I'm reading a firebird (2.5) database, […]
>>
>>> This newsgroup is _not_ about *any* SQL implementation, it is about
>>> *MySQL*/MariaDB.
>>
>> I'm very sorry about this.
>> I'm disconnected from this group.
>>
>> Daniele
>>
>> PS: Thank's for the help you negate to me !
>>
>>
>>
>
> Don't worry about "Pointed Head". He's a well-known troll in many
> newsgroups. He never has anything positive to contribute to a discussion.
>
> You are welcome in this newsgroup. Just beware this group is
> specifically about the MySQL database, so you won't get good answers on
> another database.
>

and Jerry is only here to do something that not contributes to a discussion.

The Natural Philosopher

unread,
Dec 13, 2016, 2:42:01 AM12/13/16
to
Correct. IN over 15 years I have never seen Jerry do anything more
constructive than direct someone to a manual page. I have never ever
seen him contribute a single line of SQL.

I am not sure he knows how to write it.

Those who can, do.

Those who cant teach.

Jerry was a poor instructor years ago.

Pointed Head is weird, but he does often talk sense and can actually
construct SQL statements.

Jerry Stuckle

unread,
Dec 13, 2016, 9:54:36 AM12/13/16
to
Wrong answer, Luuk. I started out by trying to *nicely* direct the OP
to a better place to get an answer. And I'm not apologizing for letting
the OP (and others who might read this) that Pointed Head is a
well-known troll in multiple newsgroups.

Jerry Stuckle

unread,
Dec 13, 2016, 9:58:48 AM12/13/16
to
On 12/13/2016 2:41 AM, The Natural Philosopher wrote:
> On 13/12/16 09:15, Luuk wrote:
>> On 12-12-16 15:07, Jerry Stuckle wrote:
>>> On 12/12/2016 3:55 AM, Daniele wrote:
>>>> Hi,
>>>>
>>>>>> i'm new in this group and new with sql.
>>>>>> I'm reading a firebird (2.5) database, […]
>>>>
>>>>> This newsgroup is _not_ about *any* SQL implementation, it is about
>>>>> *MySQL*/MariaDB.
>>>>
>>>> I'm very sorry about this.
>>>> I'm disconnected from this group.
>>>>
>>>> Daniele
>>>>
>>>> PS: Thank's for the help you negate to me !
>>>>
>>>>
>>>>
>>>
>>> Don't worry about "Pointed Head". He's a well-known troll in many
>>> newsgroups. He never has anything positive to contribute to a
>>> discussion.
>>>
>>> You are welcome in this newsgroup. Just beware this group is
>>> specifically about the MySQL database, so you won't get good answers on
>>> another database.
>>>
>>
>> and Jerry is only here to do something that not contributes to a
>> discussion.
>
> Correct. IN over 15 years I have never seen Jerry do anything more
> constructive than direct someone to a manual page. I have never ever
> seen him contribute a single line of SQL.
>

ROFLMAO! You have proven time and time again you can't read, and a
search of the archives shows how wrong you are. That's unlike you, who,
when you give an answer, is either incorrect (as it was here) or a copy
of someone else's answer from a couple of days earlier.

But sometimes the best help you can give someone is to direct them to
the correct manual entry.

> I am not sure he knows how to write it.
>
> Those who can, do.
>
> Those who cant teach.
>
> Jerry was a poor instructor years ago.
>
> Pointed Head is weird, but he does often talk sense and can actually
> construct SQL statements.
>

And in teaching I made more per hour than you could ever dream of -
because to teach in a corporate environment, you have to be good.

But then that's why you have to hide behind a pseudonym with a fake
email address. You're deathly afraid your boss will find out you're
sluffing off from your ditch digging.

That is, if you ever figured out which end of the shovel to use.

The Natural Philosopher

unread,
Dec 13, 2016, 10:41:41 AM12/13/16
to
I saw your company accounts Jerry. You can lie. If you want.

> But then that's why you have to hide behind a pseudonym with a fake
> email address. You're deathly afraid your boss will find out you're
> sluffing off from your ditch digging.
>
> That is, if you ever figured out which end of the shovel to use.
>
Poor old Stucklehead Still hung up on being seen to be a Success, when
real successes already know how pointless it is.

How's that narcissistic personality disorder thing working for ya?

Jerry Stuckle

unread,
Dec 13, 2016, 11:11:28 AM12/13/16
to
ROFLMAO! So you should be able to post those accounts right here then.
If you don't, we know you're lying.

>> But then that's why you have to hide behind a pseudonym with a fake
>> email address. You're deathly afraid your boss will find out you're
>> sluffing off from your ditch digging.
>>
>> That is, if you ever figured out which end of the shovel to use.
>>
> Poor old Stucklehead Still hung up on being seen to be a Success, when
> real successes already know how pointless it is.
>
> How's that narcissistic personality disorder thing working for ya?

Hey, I hear you got fired from your dish washing job because you were
licking the plates clean.

Did you ever find out which end of the shovel to use so you could get
your ditch digging job back?

Poor old TNP - so afraid his boss will find out how stoopid he really is
he won't use a real name or email address. But that's what trolls do.

Usenet was so much nicer when you were gone.

Luuk

unread,
Dec 13, 2016, 4:01:08 PM12/13/16
to
Maybe, just maybe, you two should meet IRL, shake hands and become
friende for life!
Don't forget to bring a knife, both of you!, just in case the other one
does ...

But, honestly, stop reading the post of one another....

The Natural Philosopher

unread,
Dec 14, 2016, 3:08:28 AM12/14/16
to
Oh I hadn't gone jerry, I just killfiled you.

This is a new machine as I am ...away from home...

I use an anonymous identity because, unlike you, I do not crave
unsolicited attention.

I have not been employed by a third party since 1999.


Jerry Stuckle

unread,
Dec 14, 2016, 5:00:37 AM12/14/16
to
I don't crave unsolicited attention, either. But unlike you, I'm not
ashamed to say who I am.

And no, you haven't been employed by ANYONE since 1999, when you lost
your ditch digging job because you couldn't figure out which end of the
shovel to use.

Now how about posting my company accounts that you said you've seen?

Luuk

unread,
Dec 14, 2016, 2:17:53 PM12/14/16
to
Jerry is an a.....

--
Sorry for being rude, really i am,
But it's plain and simple,
he is a <<<pieep>>>

Thanks for reading,
i will not need a reply
i dont know how to killfile (yes i'm honest about that)
But i REFUSE to reply on ANY messages you send.

0 new messages