473,326 Members | 2,048 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

Reading a Text Field from SQL Server into a string

Hi All,

I have a small problem. I have a database with an ntext field, I have
created an ado.net dataset over the table but when I get the value of
the field in the string, it gets truncated somewhere along the line.

Do I have to do something special to get the whole string?.

Any help will be appreciated. Thanks in advance.

Sergio
Nov 20 '05 #1
5 2230
Hi Sergio,

Did you ask this as well in the newsgroup.
microsoft.public.dotnet.framework.adonet

That when you are sure that there is not a Null character in your strings,
because that means that the string has a longer lenght however will only be
showed untill that Null character.

I hope this helps?

Cor
Nov 20 '05 #2
No, I didn't post that other article. However, do you mean that there
shouldn't be any chr(0) characters in the text field otherwise they get
truncated?.

Sergio
Winapp
Australia

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 20 '05 #3
> No, I didn't post that other article. However, do you mean that there
shouldn't be any chr(0) characters in the text field otherwise they get
truncated?.


Right
:-)

Cor
Nov 20 '05 #4
Hi Cor,
I checked the text field and there were no null chars. Any other
suggestions?. Thanks for your time.

Sergio
Winapp
Australia

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 20 '05 #5
Hi Serghino,

No however try it in the adonet newsgroup, with fields from the SQL server I
am also always strugling if it has to be Nvarchar or Nchar or Text or
otherwise try just the SQLserver group, the programming newsgroup is I
thought the one that is as well quiet active.

<news://msnews.microsoft.com/microsoft.public.dotnet.framework.adonet>

Web interface:

http://communities2.microsoft.com/co...amework.adonet

Cor
Hi Cor,
I checked the text field and there were no null chars. Any other
suggestions?. Thanks for your time.

Sergio
Winapp
Australia

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 20 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Row | last post by:
HI, I would first like to say its been about 3 years since looking at java im very rusty! I have to write a post it notes type applet which will function online. (reading from a flat text file)...
1
by: Boris Wilhelms | last post by:
Hello all, at first, sorry for my bad English, I’ll give my best  We have a strange problem reading Text- and VarChar-Fields. Our configuration: -Windows 2003 Server -MySQL Server 3.23.36...
7
by: jamait | last post by:
Hi all, I m trying to read in a text file into a datatable... Not sure on how to split up the information though, regex or substrings...? sample: Col1 Col2 ...
2
by: Roland Hall | last post by:
I have two(2) issues. I'm experiencing a little difficulty and having to resort to a work around. I already found one bug, although stated the bug was only in ODBC, which I'm not using. It...
0
by: Pavils Jurjans | last post by:
Hello, I have a third-paty application that uses text type field in MSSQL server to store data of incoming emails (full raw sources, including headers, etc.). Since the emails come in different...
21
by: JoKur | last post by:
Hello, First let me tell you that I'm very new to C# and learning as I go. I'm trying to write a client application to communicate with a server (that I didn't write). Each message from the...
7
by: Nez | last post by:
Help needed! Hello, I have looked everywhere for a solution to my problem and this is pretty much my last resource. I have created a table in a span with the innerhtml command in my code behind....
1
by: ChrisFrohlich | last post by:
ASP.NET 2.0 with Text DataTypes: I've got a similar question going in the SQL group, but I was wondering if anyone has successfully implemented reading/writing character data from a Text datatype...
2
by: filipk69 | last post by:
Could someone point me in the right direction, please. I have an enum something like this: enum TextFieldType { FieldABC = 3000, FieldXYZ = 3001, ….. ….. }
21
by: Stephen.Schoenberger | last post by:
Hello, My C is a bit rusty (.NET programmer normally but need to do this in C) and I need to read in a text file that is setup as a table. The general form of the file is 00000000 USNIST00Z...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.