General

In sybase for the column what datatype the sybase expert's suggest
either char or varchar?

I heared that while doing update statistics ... the varchar is costlier 
than the space occupied by char.

Please share your knowledge.

Thanks and Best Regards
Gopi Chand T.
0
Gopi_Chand_T
6/14/2003 9:37:32 PM
sybase.ase.general 8655 articles. 0 followers. Follow

3 Replies
990 Views

Similar Articles

[PageSpeed] 30

The choice between "varchar" and "char" doesn't have much of anything to
do with the performance of "update statistics" that I know of.  There is
a small performance penalty for accessing variable length data on the
row, but it would only be notable under very high load.

Take a look at the manuals discussing datatypes to make your own
judgments.  The basic rule-of-thumb is that if you have a column whose
length varies widely, but on average is small, use varchar.  Note also,
that "char(x) NULL" is internally stored as "varchar(x)".

http://manuals.sybase.com:80/onlinebooks/group-as/asg1250e/refman/@Generic__BookTextView/3571;pt=3571#X

Gopi_Chand_T wrote:
> 
> In sybase for the column what datatype the sybase expert's suggest
> either char or varchar?
> 
> I heared that while doing update statistics ... the varchar is costlier
> than the space occupied by char.
> 
> Please share your knowledge.
> 
> Thanks and Best Regards
> Gopi Chand T.
0
Sherlock
6/16/2003 2:40:35 PM
I am not an expert, just an application developper.
I lost my hair with Oracle and char datatype because of this ( i use T-SQL
Syntax, but imagine that it runs on Oracle) :
Declare @foo char(2)
begin
 select @foo = 'A'
 if @foo = 'A'
   -- never reach this point !!!!
 else
   -- always execute this !!
end
Because @foo contains 'A ' (or ' A') wich is always different from 'A'.

I do not know what is ASE behaviour, because i am writing from home.
But i always use
Char(1)
Varchar(n) where n>=2

"Sherlock, Kevin" <ksherlo@qwest.com.nospam> a �crit dans le message news:
3EEDD6E0.7D1DE0AB@qwest.com.nospam...
> The choice between "varchar" and "char" doesn't have much of anything to
> do with the performance of "update statistics" that I know of.  There is
> a small performance penalty for accessing variable length data on the
> row, but it would only be notable under very high load.
>
> Take a look at the manuals discussing datatypes to make your own
> judgments.  The basic rule-of-thumb is that if you have a column whose
> length varies widely, but on average is small, use varchar.  Note also,
> that "char(x) NULL" is internally stored as "varchar(x)".
>
>
http://manuals.sybase.com:80/onlinebooks/group-as/asg1250e/refman/@Generic__
BookTextView/3571;pt=3571#X
>
> Gopi_Chand_T wrote:
> >
> > In sybase for the column what datatype the sybase expert's suggest
> > either char or varchar?
> >
> > I heared that while doing update statistics ... the varchar is costlier
> > than the space occupied by char.
> >
> > Please share your knowledge.
> >
> > Thanks and Best Regards
> > Gopi Chand T.


0
Olivier
6/16/2003 9:03:41 PM
> Declare @foo char(2)
> begin
>  select @foo = 'A'
>  if @foo = 'A'
>    -- never reach this point !!!!

This is where you will always end up in ASE.  In the case of both the
assignment, and the conditional expressions, the literal 'A' is
implicitly converted to a "char(2)".

>  else
>    -- always execute this !!

"Olivier Citeau" wrote:
> 
> I am not an expert, just an application developper.
> I lost my hair with Oracle and char datatype because of this ( i use T-SQL
> Syntax, but imagine that it runs on Oracle) :
> Declare @foo char(2)
> begin
>  select @foo = 'A'
>  if @foo = 'A'
>    -- never reach this point !!!!
>  else
>    -- always execute this !!
> end
> Because @foo contains 'A ' (or ' A') wich is always different from 'A'.
> 
> I do not know what is ASE behaviour, because i am writing from home.
> But i always use
> Char(1)
> Varchar(n) where n>=2
> 
> "Sherlock, Kevin" <ksherlo@qwest.com.nospam> a �crit dans le message news:
> 3EEDD6E0.7D1DE0AB@qwest.com.nospam...
> > The choice between "varchar" and "char" doesn't have much of anything to
> > do with the performance of "update statistics" that I know of.  There is
> > a small performance penalty for accessing variable length data on the
> > row, but it would only be notable under very high load.
> >
> > Take a look at the manuals discussing datatypes to make your own
> > judgments.  The basic rule-of-thumb is that if you have a column whose
> > length varies widely, but on average is small, use varchar.  Note also,
> > that "char(x) NULL" is internally stored as "varchar(x)".
> >
> >
> http://manuals.sybase.com:80/onlinebooks/group-as/asg1250e/refman/@Generic__
> BookTextView/3571;pt=3571#X
> >
> > Gopi_Chand_T wrote:
> > >
> > > In sybase for the column what datatype the sybase expert's suggest
> > > either char or varchar?
> > >
> > > I heared that while doing update statistics ... the varchar is costlier
> > > than the space occupied by char.
> > >
> > > Please share your knowledge.
> > >
> > > Thanks and Best Regards
> > > Gopi Chand T.
0
Sherlock
6/16/2003 10:33:40 PM
Reply:

Similar Artilces:

What generals generally do
Reading a McChrystal thread elsewhere, I came across someone quoting a US general http://en.wikipedia.org/wiki/Smedley_Butler > I spent 33 years and four months in active military service and > during that period I spent most of my time as a high class thug for > Big Business, for Wall Street and the bankers. In short, I was a > racketeer, a gangster for capitalism. I helped make Mexico and > especially Tampico safe for American oil interests in 1914. I helped > make Haiti and Cuba a decent place for the National City Bank boys to > collect revenues in. I ...

general
mailto:laura.biding@ntlworld.com ...

general
Name: Darran Logie Email: hawkalmightyathotmaildotcom Product: Firefox Summary: general Comments: firefox i have always found to be excellent. All the little addons and constant refinements are always welcomed. At the moment the only thing i am missing is download manager as its not compatible with the current version. Browser Details: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9) Gecko/2008051206 Firefox/3.0 From URL: http://hendrix.mozilla.org/ ...

superreview denied: [Bug 282182] sync xpfe general.xml with toolkit general.xml : [Attachment 217751] (Av2) <general.xml>
neil@parkwaycc.co.uk <neil@httl.net> has denied Serge GAUTHERIE <gautheri@noos.fr>'s request for superreview: Bug 282182: sync xpfe general.xml with toolkit general.xml https://bugzilla.mozilla.org/show_bug.cgi?id=282182 Attachment 217751: (Av2) <general.xml> https://bugzilla.mozilla.org/attachment.cgi?id=217751&action=edit ------- Additional Comments from neil@parkwaycc.co.uk <neil@httl.net> >+ <binding id="statusbarpanel-menu-iconic" display="xul:menu" extends="chrome://global/content/bindings/general.xml#statusbarpa...

superreview requested: [Bug 282182] sync xpfe general.xml with toolkit general.xml : [Attachment 217751] (Av2) <general.xml>
Serge GAUTHERIE <gautheri@noos.fr> has asked neil@parkwaycc.co.uk <neil@httl.net> for superreview: Bug 282182: sync xpfe general.xml with toolkit general.xml https://bugzilla.mozilla.org/show_bug.cgi?id=282182 Attachment 217751: (Av2) <general.xml> https://bugzilla.mozilla.org/attachment.cgi?id=217751&action=edit ------- Additional Comments from Serge GAUTHERIE <gautheri@noos.fr> (In reply to comment #2) > Hmm, if the diff is current (by date I would imagine so) then I do not > personally see a problem syncing this and grabbing toolkits version fr...

superreview requested: [Bug 282182] sync xpfe general.xml with toolkit general.xml : [Attachment 219626] (Av3-XPFE) <general.xml>++
Serge GAUTHERIE <gautheri@noos.fr> has asked neil@parkwaycc.co.uk <neil@httl.net> for superreview: Bug 282182: sync xpfe general.xml with toolkit general.xml https://bugzilla.mozilla.org/show_bug.cgi?id=282182 Attachment 219626: (Av3-XPFE) <general.xml>++ https://bugzilla.mozilla.org/attachment.cgi?id=219626&action=edit ------- Additional Comments from Serge GAUTHERIE <gautheri@noos.fr> Av3-XPFE-Bw, with full diff. Keeping [[ (Av3-XPFE-Bw) <general.xml>++ patch 2006-04-23 16:17 PDT 2.38 KB neil: review+ ]] ...

superreview granted: [Bug 282182] sync xpfe general.xml with toolkit general.xml : [Attachment 219626] (Av3-XPFE) <general.xml>++
neil@parkwaycc.co.uk <neil@httl.net> has granted Serge GAUTHERIE <gautheri@noos.fr>'s request for superreview: Bug 282182: sync xpfe general.xml with toolkit general.xml https://bugzilla.mozilla.org/show_bug.cgi?id=282182 Attachment 219626: (Av3-XPFE) <general.xml>++ https://bugzilla.mozilla.org/attachment.cgi?id=219626&action=edit ...

how to generalize?
DropDownList ddRegistrar=(DropDownList)e.Item.FindControl("ddRegistrar"); if(ddRegistrar!=null) { ddRegistrar.DataSource=m_RegistrarDL.Reader(); ddRegistrar.DataBind(); ddRegistrar.SelectedValue=((DataRowView)e.Item.DataItem).Row["Domain_Registrar_ID"].ToString(); } should be put in a function like but how van I generalize the following line? dd.DataSource=m_RegistrarDL.Reader(); e.g. dd.DataSource=DLs[Name].Reader(); public void DropDownList_Bind(string Name) { DropDownList dd=(DropDownList)e.Item.FindControl("dd"...

... in general
Name: Mikael Email: arlingatofirdotdk Product: Firefox Summary: ... in general Comments: Hi "Team Firefox" Thankyou for a much more up-to-date browser than IE is. There are some things that I miss from IE: 1.: When you mark a text and right-click with the mouse I cannot get it translates in "Google Translate" with Firefox. 2.: I would be nice if I could export my Bookmarks back to IE's folder "Foretrukne" aswell. Browser Details: Mozilla/5.0 (Windows; U; Windows NT 5.1; da; rv:1.9.2.13) Gecko/20101203 Firefox/3.6.13 From URL: htt...

Generalizing ?? !!
Rereading A03, I ran across the original reasoning behind why Perl 5's '?:' trinary operator became '?? ::' first, and then '?? !!'. Three reasons were given: * the '?' and ':' tokens are far too broadly useful to be gobbled up by the trinary operator. * the doubled symbols bring to mind the short-circuiting operators (e.g., '&&' and '||'), suggesting a similar short-circuiting behavior here. * the '!!' brings to mind "evaluate this when the condition fails". IMHO, the first point was always...

Web resources about - General - sybase.ase.general

Général - Wikipedia, the free encyclopedia
Général is the French word for general . There are two main categories of generals : the general officers ( officiers généraux ), which are the ...

Generał - Wikipedia, the free encyclopedia
Generał (pronounced [ɡɛˈnɛraw] ), is the generic Polish language term for the rank of General . In narrow sense it is used to denote the rank ...

Attorney-General George Brandis appeals decision on access to his diary
Attorney-General George Brandis is challenging a tribunal's ruling that his office reconsider a request from shadow attorney-general Mark Dreyfus ...

24/7 Wall St. » Blog Archive General Electric Q4 Earnings Beat (NYSE: GE)
General Electric Co. (NYSE: GE) reported fourth-quarter and full-year 2015 results before markets opened Friday. The conglomerate reported quarterly ...


South Africa: Director-General Mkuseli Apleni - Briefing On the Arrest of Mos Def
Document - Ladies and gentlemen, good morning! Thank you for coming over at such short notice.

General Motors bought Sidecar, gave Lyft millions, now it’s launching “Maven”
(credit: John F. Martin for General Motors) On Thursday, General Motors launched a new “personal mobility brand” called Maven, through which ...

General Motors unveils Maven, its new car-sharing brand
Filed under: Green , Ownership , GM , Transportation Alternatives For now, General Motors. In the future, General Mobility? GM executives unveiled ...

Business Insider is hiring a general manager for finance products
Business Insider is a fast-growing business site with deep financial, media, tech, and other industry verticals. Launched in 2007, we are now ...

General Motors' Maven is all about car sharing, not ride sharing
At its simplest, consider it GM's equivalent of Zipcar.

Resources last updated: 1/23/2016 9:27:10 PM