Showing posts with label maximum. Show all posts
Showing posts with label maximum. Show all posts

Friday, February 24, 2012

Column max size for String

Hello I currently am using the nvarchar type which has a maximum size of 4000 char's. Is there any other type that I can use which can store a greater amount of char's ?

Many thanks

GrantVarchar can go up to 8000. You can usetext orntext fields which have no practical upper limit on the number of chars. Withtext orntext fields fields you lose some flexibility such as the ability to use thetext orntext field in a where clause.

text is for variable-length non-Unicode data.

ntext is for variable-length Unicode data.|||text datatypes can hold upto 2GB bytes of data ... And ntext also used the same limitation ... The only difference being text datatypes use 1 bytes for 1 character and ntext types use 2 bytes for storing single unicode character ...

Column Lenght

What is the query to find the maximum lenght used in the
row of a column. Ex: The column is defined to be varchar
(2500) and the longest used row size is 1852.
T.I.ATry something like this:
SELECT MAX(LEN(ColumnName)) FROM TableName
--
Vyas, MVP (SQL Server)
SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
"Jim" <anonymous@.discussions.microsoft.com> wrote in message
news:084701c52a72$a20d8300$a501280a@.phx.gbl...
> What is the query to find the maximum lenght used in the
> row of a column. Ex: The column is defined to be varchar
> (2500) and the longest used row size is 1852.
> T.I.A|||SELECT MAX(DATALENGTH(column_name)) FROM Table
--
Please post DDL, sample data and desired results.
See http://www.aspfaq.com/5006 for info.
"Jim" <anonymous@.discussions.microsoft.com> wrote in message
news:084701c52a72$a20d8300$a501280a@.phx.gbl...
> What is the query to find the maximum lenght used in the
> row of a column. Ex: The column is defined to be varchar
> (2500) and the longest used row size is 1852.
> T.I.A|||Thanks.........
>--Original Message--
>Try something like this:
>SELECT MAX(LEN(ColumnName)) FROM TableName
>--
>Vyas, MVP (SQL Server)
>SQL Server Articles and Code Samples @.
http://vyaskn.tripod.com/
>
>"Jim" <anonymous@.discussions.microsoft.com> wrote in
message
>news:084701c52a72$a20d8300$a501280a@.phx.gbl...
>> What is the query to find the maximum lenght used in the
>> row of a column. Ex: The column is defined to be varchar
>> (2500) and the longest used row size is 1852.
>> T.I.A
>
>.
>

Column Lenght

What is the query to find the maximum lenght used in the
row of a column. Ex: The column is defined to be varchar
(2500) and the longest used row size is 1852.
T.I.A
Try something like this:
SELECT MAX(LEN(ColumnName)) FROM TableName
Vyas, MVP (SQL Server)
SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
"Jim" <anonymous@.discussions.microsoft.com> wrote in message
news:084701c52a72$a20d8300$a501280a@.phx.gbl...
> What is the query to find the maximum lenght used in the
> row of a column. Ex: The column is defined to be varchar
> (2500) and the longest used row size is 1852.
> T.I.A
|||SELECT MAX(DATALENGTH(column_name)) FROM Table
Please post DDL, sample data and desired results.
See http://www.aspfaq.com/5006 for info.
"Jim" <anonymous@.discussions.microsoft.com> wrote in message
news:084701c52a72$a20d8300$a501280a@.phx.gbl...
> What is the query to find the maximum lenght used in the
> row of a column. Ex: The column is defined to be varchar
> (2500) and the longest used row size is 1852.
> T.I.A
|||Thanks.........

>--Original Message--
>Try something like this:
>SELECT MAX(LEN(ColumnName)) FROM TableName
>--
>Vyas, MVP (SQL Server)
>SQL Server Articles and Code Samples @.
http://vyaskn.tripod.com/
>
>"Jim" <anonymous@.discussions.microsoft.com> wrote in
message
>news:084701c52a72$a20d8300$a501280a@.phx.gbl...
>
>.
>

Column Lenght

What is the query to find the maximum lenght used in the
row of a column. Ex: The column is defined to be varchar
(2500) and the longest used row size is 1852.
T.I.ATry something like this:
SELECT MAX(LEN(ColumnName)) FROM TableName
Vyas, MVP (SQL Server)
SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
"Jim" <anonymous@.discussions.microsoft.com> wrote in message
news:084701c52a72$a20d8300$a501280a@.phx.gbl...
> What is the query to find the maximum lenght used in the
> row of a column. Ex: The column is defined to be varchar
> (2500) and the longest used row size is 1852.
> T.I.A|||SELECT MAX(DATALENGTH(column_name)) FROM Table
Please post DDL, sample data and desired results.
See http://www.aspfaq.com/5006 for info.
"Jim" <anonymous@.discussions.microsoft.com> wrote in message
news:084701c52a72$a20d8300$a501280a@.phx.gbl...
> What is the query to find the maximum lenght used in the
> row of a column. Ex: The column is defined to be varchar
> (2500) and the longest used row size is 1852.
> T.I.A|||Thanks.........

>--Original Message--
>Try something like this:
>SELECT MAX(LEN(ColumnName)) FROM TableName
>--
>Vyas, MVP (SQL Server)
>SQL Server Articles and Code Samples @.
http://vyaskn.tripod.com/
>
>"Jim" <anonymous@.discussions.microsoft.com> wrote in
message
>news:084701c52a72$a20d8300$a501280a@.phx.gbl...
>
>.
>

Thursday, February 16, 2012

Column count max for Merge replication still 246?

Is the maximum number columns per table still 246 for a Merge replication in SQL Server 2005?

yes its still 246 coulumns in SQL Server 2005 Merge replication

see this link

http://msdn2.microsoft.com/en-us/library/ms143432.aspx

Madhu

|||

Madhu,

Can I replicate a table more than 264 columns in Transactional replication.?

During my initial setup, the publisher did not allow me to publisher a table with more than 246 columns.?

Thank you.

Edwin

|||Transactional allows upto 1024 columns.