Click here to Skip to main content
15,887,027 members
Home / Discussions / C#
   

C#

 
AnswerRe: Need football game comments Pin
Pete O'Hanlon22-Nov-12 5:26
mvePete O'Hanlon22-Nov-12 5:26 
GeneralMessage Closed Pin
22-Nov-12 5:51
mveRichard Deeming22-Nov-12 5:51 
GeneralRe: Need football game comments Pin
Pete O'Hanlon22-Nov-12 9:29
mvePete O'Hanlon22-Nov-12 9:29 
GeneralRe: Need football game comments Pin
Richard Deeming23-Nov-12 1:38
mveRichard Deeming23-Nov-12 1:38 
AnswerRe: Need football game comments Pin
BobJanova23-Nov-12 1:00
BobJanova23-Nov-12 1:00 
GeneralRe: Need football game comments Pin
leone23-Nov-12 9:23
leone23-Nov-12 9:23 
GeneralRe: Need football game comments Pin
BobJanova23-Nov-12 14:31
BobJanova23-Nov-12 14:31 
QuestionEmpty record returned with this query when querying Oracle database with .NET but gave rows in SQL+ Pin
awedaonline21-Nov-12 23:35
awedaonline21-Nov-12 23:35 
Hello guys;

The code below returns an empty records but gave records from SQL+.

C#
DbProviderFactory factory = DbProviderFactories.GetFactory("Oracle.DataAccess.Client");
DbConnection connection = factory.CreateConnection();

connection.ConnectionString = "Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=Simplex-IT-02)(PORT=1521)))
                     (CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=Simplex))); User Id=User_Test;Password=password;";

DataTable table = new DataTable();

DbCommand command = connection.CreateCommand();
command.Connection = connection;
command.CommandText = "SELECT text FROM user_views WHERE (view_name='ACCOUNT_BALANCES_BY_PERIOD');";

DbDataReader dataReader = command.ExecuteReader();

table.Load(dataReader);
dataReader.Close();


Meanwhile, when I replaced the command.CommandText with "SELECT DISTINCT view_name FROM user_views" it gave me list of all available views for the given schema.

Why can't I get the sql text of a given view?


Thank you in anticipation.
AnswerRe: Empty record returned with this query when querying Oracle database with .NET but gave rows in SQL+ Pin
Simon_Whale22-Nov-12 5:12
Simon_Whale22-Nov-12 5:12 
GeneralRe: Empty record returned with this query when querying Oracle database with .NET but gave rows in SQL+ Pin
awedaonline22-Nov-12 5:38
awedaonline22-Nov-12 5:38 
GeneralRe: Empty record returned with this query when querying Oracle database with .NET but gave rows in SQL+ Pin
Simon_Whale22-Nov-12 5:49
Simon_Whale22-Nov-12 5:49 
GeneralRe: Empty record returned with this query when querying Oracle database with .NET but gave rows in SQL+ Pin
Ray Yagubyan22-Nov-12 13:30
Ray Yagubyan22-Nov-12 13:30 
GeneralRe: Empty record returned with this query when querying Oracle database with .NET but gave rows in SQL+ Pin
awedaonline22-Nov-12 21:12
awedaonline22-Nov-12 21:12 
AnswerRe: Empty record returned with this query when querying Oracle database with .NET but gave rows in SQL+ Pin
jschell23-Nov-12 7:18
jschell23-Nov-12 7:18 
AnswerRe: Empty record returned with this query when querying Oracle database with .NET but gave rows in SQL+ Pin
PIEBALDconsult23-Nov-12 9:01
mvePIEBALDconsult23-Nov-12 9:01 
Questionvs.net 2010 exe on demo machine Pin
KrishnaRayalu_Talisetti21-Nov-12 23:01
KrishnaRayalu_Talisetti21-Nov-12 23:01 
AnswerRe: vs.net 2010 exe on demo machine Pin
Pete O'Hanlon21-Nov-12 23:36
mvePete O'Hanlon21-Nov-12 23:36 
AnswerRe: vs.net 2010 exe on demo machine Pin
Simon_Whale21-Nov-12 23:38
Simon_Whale21-Nov-12 23:38 
GeneralRe: vs.net 2010 exe on demo machine Pin
KrishnaRayalu_Talisetti21-Nov-12 23:41
KrishnaRayalu_Talisetti21-Nov-12 23:41 
GeneralRe: vs.net 2010 exe on demo machine Pin
Simon_Whale21-Nov-12 23:46
Simon_Whale21-Nov-12 23:46 
QuestionSAP Dotnet Integration Pin
rohitnegi0921-Nov-12 21:14
rohitnegi0921-Nov-12 21:14 
AnswerRe: SAP Dotnet Integration Pin
Pete O'Hanlon21-Nov-12 22:39
mvePete O'Hanlon21-Nov-12 22:39 
AnswerRe: SAP Dotnet Integration Pin
V.21-Nov-12 23:12
professionalV.21-Nov-12 23:12 
QuestionWrite XML Dynamically according to tree structure in windows c# Pin
rummer21-Nov-12 20:19
rummer21-Nov-12 20:19 
AnswerRe: Write XML Dynamically according to tree structure in windows c# Pin
markovl21-Nov-12 20:37
markovl21-Nov-12 20:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.