By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,570 Members | 970 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,570 IT Pros & Developers. It's quick & easy.

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

P: n/a

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
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.