Unix Technical Forum

BUG #3861: cannot cast type smallint to bit

This is a discussion on BUG #3861: cannot cast type smallint to bit within the pgsql Bugs forums, part of the PostgreSQL category; --> The following bug has been logged online: Bug reference: 3861 Logged by: Marc mamin Email address: m.mamin@intershop.de PostgreSQL version: ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Bugs

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-10-2008, 11:13 AM
Marc mamin
 
Posts: n/a
Default BUG #3861: cannot cast type smallint to bit


The following bug has been logged online:

Bug reference: 3861
Logged by: Marc mamin
Email address: m.mamin@intershop.de
PostgreSQL version: 8.2.4
Operating system: Linux
Description: cannot cast type smallint to bit
Details:

Hello,

This is more a feature request than a bug, but I guess there is no reason
why this should not be possible:

select 1::int2::bit(16)
=> ERROR: cannot cast type smallint to bit

I guess the correct way to workaround would be:

select (1::int4::bit(32)<<16)::bit(16)

which is a bit complicated :-)

HTH,

Marc Mamin

---------------------------(end of broadcast)---------------------------
TIP 7: You can help support the PostgreSQL project by donating at

http://www.postgresql.org/about/donate

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 01:00 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com