473,320 Members | 1,719 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,320 software developers and data experts.

Oracle query in C# returns invalid Characters

Hello,

I am trying to create a simple Oracle application that queries some data
from Oracle. The problem is that it randomly returns trailing \0s instead of
the characters of a string.

Instead of:
NIC, returns sometimes as N\0\0
188524C-01, returns somtimes as 18852\0\0\0\0\0

Notice that length of the strings are the same, just some characters in the
end was replaced with \0s

this is my code:

\\\\\\\

this.DWConnection.Open();

OracleCommand oraCMD = new OracleCommand("Select * from table_v where (wname
= 'F18104854')" , this.DWConnection);

OracleDataReader myResultsReader = oraCMD.ExecuteReader();
while(myResultsReader.Read())
{
myResultsReader.GetValues(values);
}

this.DWConnection.Close();

Some Notes:
*It returns the correct number of records
*The problem seems to appear on String columns only
*The same column contains good and bad values
*Data Adapter causes the same problem
*Viewing data using the Query Builder tool, and Server Explorer works
*View data using the adapter at development time does NOT work

It may be something very silly I am missing...

Thanks,

--
RobertoP
Nov 16 '05 #1
0 1856

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

Similar topics

4
by: susmita_ganguly | last post by:
Hi I am trying to upgrade from oracle 8i to oracle 9i on the same server ..I don't know much abt migration . Can anyone help me out. Thanks. Susmita
7
by: vnl | last post by:
I'm trying to run a SQL query but can't find any records when trying to select a certain date. Here's the sql: SELECT field 1, field2, date_and_time, FROM table1 WHERE date_and_time =...
1
by: Andrew Arace | last post by:
I scoured the groups for some hands on code to perform the menial task of exporting table data from an Access 2000 database to Oracle database (in this case, it was oracle 8i but i'm assuming this...
6
by: Martin Lacoste | last post by:
Ok, before I headbutt the computer... don't know why when I add criteria in a query, I get an 'invalid procedure call'. I also don't know why after searching the help in access, the various access...
5
by: premmehrotra | last post by:
I am using Microsoft Access 2000 and Oracle 9.2.0.5 on Windows 2000. When I export a table from Access to Oracle using ODBC I get error: ORA 972 identifier too long I think the error is because...
6
by: Jean | last post by:
Hi, I am using an Access 2000 front-end to an Oracle 9 backend. I want to write a query that returns all records that are not older than one year for Column "Status_30" (which is a Date). ...
0
by: RobertoP | last post by:
Hello, I am trying to create a simple Oracle application that queries some data from Oracle. The problem is that it randomly returns trailing \0s instead of the characters of a string. ...
5
by: jonceramic | last post by:
Hi All, I started developing in Access, and people took notice and so we're starting to migrate into our corporate's bigger Oracle system. I'll still be using my developed Access front ends,...
7
by: =?Utf-8?B?QVRT?= | last post by:
HOWTO Run multiple SQL statements from ASP/ADO to an Oracle 10g. Please help, I'm trying to write an ASP page to use ADO to run a long query against an Oracle 10g database, to create tables,...
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...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
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...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.