[quoted text, click to view] > But How Do I Find that? Is there any Environment Variable?
select Collation = convert(sysname,databasepropertyex(db_name(),'Collation'))
[quoted text, click to view] > Does the Search oc Character Field Differ if that is RUN on a Case Sensitive
> DB or on a Case IN Sensitive DB?
select
*
from
(
select cast('Smith' as varchar(25))
union all
select cast('smith' as varchar(25))
) as t(colA)
where
colA collate SQL_Latin1_General_CP1_CS_AS like 'S%'
select
*
from
(
select cast('Smith' as varchar(25))
union all
select cast('smith' as varchar(25))
) as t(colA)
where
colA collate SQL_Latin1_General_CP1_CI_AS like 'S%'
AMB
[quoted text, click to view] "Prabhat" wrote:
> Hi All?
>
> I know that My SQL Server 2000 (Default Installtion) DB is Case insensitive.
> But How Do I Find that? Is there any Environment Variable?
>
> And I have One Doubt...
>
> Does the Search oc Character Field Differ if that is RUN on a Case Sensitive
> DB or on a Case IN Sensitive DB? If Yes what is the Difference? and which
> One is Faster?
>
> Thanks
> Prabhat
>
>
Hi,
Good example, But will the Case Sensitive Search will be faster then the
Default case InSensitive?
I will also Try to find that.
Prabhat
[quoted text, click to view] "Alejandro Mesa" <AlejandroMesa@discussions.microsoft.com> wrote in message
news:00089487-06D4-46E2-9563-1398F34F7EED@microsoft.com...
> > But How Do I Find that? Is there any Environment Variable?
>
> select Collation =
convert(sysname,databasepropertyex(db_name(),'Collation'))
>
>
> > Does the Search oc Character Field Differ if that is RUN on a Case
Sensitive
> > DB or on a Case IN Sensitive DB?
>
> select
> *
> from
> (
> select cast('Smith' as varchar(25))
> union all
> select cast('smith' as varchar(25))
> ) as t(colA)
> where
> colA collate SQL_Latin1_General_CP1_CS_AS like 'S%'
>
> select
> *
> from
> (
> select cast('Smith' as varchar(25))
> union all
> select cast('smith' as varchar(25))
> ) as t(colA)
> where
> colA collate SQL_Latin1_General_CP1_CI_AS like 'S%'
>
>
>
> AMB
>
>
> "Prabhat" wrote:
>
> > Hi All?
> >
> > I know that My SQL Server 2000 (Default Installtion) DB is Case
insensitive.
> > But How Do I Find that? Is there any Environment Variable?
> >
> > And I have One Doubt...
> >
> > Does the Search oc Character Field Differ if that is RUN on a Case
Sensitive
> > DB or on a Case IN Sensitive DB? If Yes what is the Difference? and
which
> > One is Faster?
> >
> > Thanks
> > Prabhat
> >
> >
> >
Hi,
Thanks for suggestion, But will the Case Sensitive Search will be faster
then the Default case InSensitive?
I will also Try to find that.
Prabhat
[quoted text, click to view] "David Portas" <REMOVE_BEFORE_REPLYING_dportas@acm.org> wrote in message
news:48FF8FCA-D648-43B9-AB5D-EB2951C42892@microsoft.com...
> Case-sensitivity is determined by a Collation, which is defined for each
> character column in a database and as a default value for the database and
> the server. Read the topics on Collations and Collation Coercian to
> understand which collation will be applicable in any particular
circumstance.
>
> To determine the collation of a column you can interrogate the
> information_schema.columns view.
>
> To determine whether the current database's *default* collation is
> case-sensitive you can do:
>
> SELECT CASE WHEN 'A'='a' THEN 'CASE INSENSITIVE' ELSE 'CASE SENSITIVE' END
>
> --
> David Portas
> SQL Server MVP
> --
>
[quoted text, click to view] "Prabhat" <not_a_mail@hotmail.com> wrote in message
news:uRj%23nZ$vEHA.1400@TK2MSFTNGP11.phx.gbl...
> Hi Mark,
>
> What are those Extra Processing so that That will make the
> Case-insensitivity SLOW? can U please elaborate that?
I don't know exactly what happens behind the scenes, but consider that with
a case-sensitive search, only 'mark' will equal 'mark'. With a
case-insensitive search, 'mark' equals 'Mark', 'mARK, 'marK', etc. Instead
of simply matching one character against another, a case-insensitive search
has to match perform the additional mapping of (for example) upper to lower
case.
Hi Mark,
What are those Extra Processing so that That will make the
Case-insensitivity SLOW? can U please elaborate that?
Thanks
Prabhat
[quoted text, click to view] "Mark Wilden" <mark@mwilden.com> wrote in message
news:o_adnctK7bNk4x_cRVn-hg@sti.net...
> "Prabhat" <not_a_mail@hotmail.com> wrote in message
> news:OArzIsdvEHA.1292@TK2MSFTNGP10.phx.gbl...
> > Hi,
> >
> > Good example, But will the Case Sensitive Search will be faster then the
> > Default case InSensitive?
>
> Case-insensitivity does add some extra processing, so yes, it will be
> slower.
>
>
Hi Mark,
Yes! I Think You are right.
Thanks
Prabhat
[quoted text, click to view] "Mark Wilden" <mark@mwilden.com> wrote in message
news:lMqdnchlnLi2-xvcRVn-hQ@sti.net...
> "Prabhat" <not_a_mail@hotmail.com> wrote in message
> news:uRj%23nZ$vEHA.1400@TK2MSFTNGP11.phx.gbl...
> > Hi Mark,
> >
> > What are those Extra Processing so that That will make the
> > Case-insensitivity SLOW? can U please elaborate that?
>
> I don't know exactly what happens behind the scenes, but consider that
with
> a case-sensitive search, only 'mark' will equal 'mark'. With a
> case-insensitive search, 'mark' equals 'Mark', 'mARK, 'marK', etc. Instead
> of simply matching one character against another, a case-insensitive
search
> has to match perform the additional mapping of (for example) upper to
lower
> case.
>
>