471,090 Members | 1,371 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,090 software developers and data experts.

comparison: smallint & 2^extract(dow from date)


I used the & operator to evaluate whether a certain day would match the
days of operation of a flight.

In v7.2.3 I could use the following to do that:

select 127::smallint & 2^extract(dow from '17-7-2004'::date) != 0 );

In v7.3.4 I get now:

ERROR: Unable to identify an operator '&' for types 'smallint' and 'double precision'
You will have to retype this query using an explicit cast

I realise that the docs do say that extract returns a double but how am
I to figure this out ie recast I suppose but how should I do that?

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Nov 12 '05 #1
0 1510

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Tim | last post: by
1 post views Thread by Keith Crooks | last post: by
1 post views Thread by Pooja Raisingani via AccessMonster.com | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.