SQL table field
-
Hi all I am using SQL 2000 ver. How can i store large text data in my table field . What are the field propertys i have to use Thank you
Kirthi
modified on Thursday, July 31, 2008 2:04 AM
-
Hi all I am using SQL 2000 ver. How can i store large text data in my table field . What are the field propertys i have to use Thank you
Kirthi
modified on Thursday, July 31, 2008 2:04 AM
e.g Use Mystring VarChar(200) You can add as much string as you can and can increase a dimension.
Vuyiswa Maseko, Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding VB.NET/SQL7/2000/2005 http://vuyiswamb.007ihost.com http://Ecadre.007ihost.com vuyiswam@tshwane.gov.za
-
e.g Use Mystring VarChar(200) You can add as much string as you can and can increase a dimension.
Vuyiswa Maseko, Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding VB.NET/SQL7/2000/2005 http://vuyiswamb.007ihost.com http://Ecadre.007ihost.com vuyiswam@tshwane.gov.za
Hi thank you for reply but i want to put the table field length greater that 10,000 because my data is more to store thank you
Kirthi
-
Hi thank you for reply but i want to put the table field length greater that 10,000 because my data is more to store thank you
Kirthi
hi SQL Fields are not like Storing data in a text file. So if you probably tried to add a dimension of 20000 and get an error like this
The size (20000) given to the column 'name' exceeds the maximum allowed for any data type (8000).
You should know that the Limit is "8000", and i dont understand why would you store such a large string in a Database. So its not Possible with SQL
Vuyiswa Maseko, Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding VB.NET/SQL7/2000/2005 http://vuyiswamb.007ihost.com http://Ecadre.007ihost.com vuyiswam@tshwane.gov.za
-
hi SQL Fields are not like Storing data in a text file. So if you probably tried to add a dimension of 20000 and get an error like this
The size (20000) given to the column 'name' exceeds the maximum allowed for any data type (8000).
You should know that the Limit is "8000", and i dont understand why would you store such a large string in a Database. So its not Possible with SQL
Vuyiswa Maseko, Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding VB.NET/SQL7/2000/2005 http://vuyiswamb.007ihost.com http://Ecadre.007ihost.com vuyiswam@tshwane.gov.za
hi ya i know the error but just i am conforming is there any other way is there to store like acces (memo field) thank you
Kirthi
-
hi ya i know the error but just i am conforming is there any other way is there to store like acces (memo field) thank you
Kirthi
There is. Try the ntext data type. ntext Variable-length Unicode data with a maximum length of 2^30 - 1 (1,073,741,823) characters. Storage size, in bytes, is two times the number of characters entered. The SQL-2003 synonym for ntext is national text. BUT Important: ntext, text, and image data types will be removed in a future version of Microsoft SQL Server. Avoid using these data types in new development work, and plan to modify applications that currently use them. Use nvarchar(max), varchar(max), and varbinary(max) instead. For more information, see Using Large-Value Data Types.
Bob Ashfield Consultants Ltd
-
There is. Try the ntext data type. ntext Variable-length Unicode data with a maximum length of 2^30 - 1 (1,073,741,823) characters. Storage size, in bytes, is two times the number of characters entered. The SQL-2003 synonym for ntext is national text. BUT Important: ntext, text, and image data types will be removed in a future version of Microsoft SQL Server. Avoid using these data types in new development work, and plan to modify applications that currently use them. Use nvarchar(max), varchar(max), and varbinary(max) instead. For more information, see Using Large-Value Data Types.
Bob Ashfield Consultants Ltd
hi Ashfield Wow is it Possible? can i see an example code, because ntext even if you try 10000,it will not work, mybe am not doing it right see
create table #test
(
P_ID int null,
Pname ntext(10000) null
)Msg 131, Level 15, State 2, Line 5 The size (10000) given to the column 'Pname' exceeds the maximum allowed for any data type (8000).
ThanksVuyiswa Maseko, Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding VB.NET/SQL7/2000/2005 http://vuyiswamb.007ihost.com http://Ecadre.007ihost.com vuyiswam@tshwane.gov.za
-
hi Ashfield Wow is it Possible? can i see an example code, because ntext even if you try 10000,it will not work, mybe am not doing it right see
create table #test
(
P_ID int null,
Pname ntext(10000) null
)Msg 131, Level 15, State 2, Line 5 The size (10000) given to the column 'Pname' exceeds the maximum allowed for any data type (8000).
ThanksVuyiswa Maseko, Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding VB.NET/SQL7/2000/2005 http://vuyiswamb.007ihost.com http://Ecadre.007ihost.com vuyiswam@tshwane.gov.za
-
There is. Try the ntext data type. ntext Variable-length Unicode data with a maximum length of 2^30 - 1 (1,073,741,823) characters. Storage size, in bytes, is two times the number of characters entered. The SQL-2003 synonym for ntext is national text. BUT Important: ntext, text, and image data types will be removed in a future version of Microsoft SQL Server. Avoid using these data types in new development work, and plan to modify applications that currently use them. Use nvarchar(max), varchar(max), and varbinary(max) instead. For more information, see Using Large-Value Data Types.
Bob Ashfield Consultants Ltd
-
Hi Bob, Do you have more information on the future non-use of those fields you described? Thanks. Ryan