Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««123»»

Bit data Expand / Collapse
Author
Message
Posted Wednesday, May 7, 2008 9:03 AM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Thursday, September 25, 2014 1:21 PM
Points: 3,143, Visits: 139
Thank you.

I myself have trouble noticing everything in the questions! (LOL)

I did give an AdventureWorks example so people could actually test for the result.

)
Post #496418
Posted Wednesday, May 7, 2008 11:12 AM
Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: Tuesday, December 14, 2010 3:35 PM
Points: 509, Visits: 96
Good Question Dr.Dee! I guess writing our queries like SalariedFlag = 'TRUE' makes it more readable. But I wonder if there would be any performance degrade when we use 'TRUE' instead of 1?

KK
Post #496540
Posted Wednesday, May 7, 2008 11:38 AM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Thursday, September 25, 2014 1:21 PM
Points: 3,143, Visits: 139
I suppose one could test whether the implicit conversion has a cost by creating a table with several million rows and running the query each way.

Unfortunately, I'm too busy (translation: I don't care enough!)

)
Post #496555
Posted Wednesday, May 7, 2008 2:44 PM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Tuesday, October 7, 2014 2:56 AM
Points: 2,842, Visits: 3,876
Good Question!

Although I doubt that this new implicit conversion is an improvement for SQL Server.

I would be interested to know why they have not allowed TRUE or FALSE as bool keywords so far.
Does anyone know if this is a technical restriction?

(But at least they (TRUE and FALSE) have been reserved as "FUTURE KEYWORDS")


Best Regards,
Chris Büttner
Post #496700
Posted Thursday, May 8, 2008 1:06 AM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Monday, December 15, 2014 4:15 AM
Points: 5,471, Visits: 1,402
Another goodie...............:)


Post #496898
Posted Thursday, May 8, 2008 7:40 AM
SSCarpal Tunnel

SSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal Tunnel

Group: General Forum Members
Last Login: Friday, December 12, 2014 7:23 AM
Points: 4,113, Visits: 1,231
A good question.
Post #497102
Posted Thursday, May 8, 2008 7:59 AM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Thursday, September 25, 2014 1:21 PM
Points: 3,143, Visits: 139
Thank you, Anirban and David.

)
Post #497118
Posted Thursday, May 8, 2008 9:39 AM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Monday, December 15, 2014 4:15 AM
Points: 5,471, Visits: 1,402
Dr. Diana Dee (5/8/2008)
Thank you, Anirban and David.

)


You are welcome........:)



Post #497206
Posted Friday, May 9, 2008 7:02 AM
SSC Journeyman

SSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC Journeyman

Group: General Forum Members
Last Login: Tuesday, October 12, 2010 5:56 AM
Points: 79, Visits: 45
This was a very good question. I did not know that 'true' and 'false' can not be used with bit columns in SQL 2005. I can now stop having to write DECLARE @TRUE BIT SET @TRUE = 1 statements in my procedures:)
Post #497830
Posted Sunday, May 11, 2008 9:55 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Monday, November 10, 2014 6:56 AM
Points: 4, Visits: 111
sql 2000 with error
Msg 245, Level 16, State 1, Line 1
Syntax error converting the varchar value 'true' to a column of data type bit.
sql 2005 without error
Post #498531
« Prev Topic | Next Topic »

Add to briefcase ««123»»

Permissions Expand / Collapse