Warning: 'System.Data.OracleClient.OracleDataAdapter' is obsolete RRS feed

  • Question

  • Hi everyone,

    I would like to use Visual Studio 2012 build in Report Designer, and set for it manually connection created in my application code using Oracle.DataAccess.Client.

    When I try to do it, I get an error:

    Cannot implicitly convert type 'Oracle.DataAccess.Client.OracleConnection' to 'System.Data.OracleClient.OracleConnection'

    But I do not understand why Report Designer generates code using System.Data.OracleClient which is absolete ?

    I think is the real reason of my problem.

    Below, a few lines of code produced by Report Designer:

    public partial class SDT_DOCUM_REJESTRTableAdapter : global::System.ComponentModel.Component {
            private global::System.Data.OracleClient.OracleDataAdapter _adapter;
            private global::System.Data.OracleClient.OracleConnection _connection;
            private global::System.Data.OracleClient.OracleTransaction _transaction;        
            private global::System.Data.OracleClient.OracleCommand[] _commandCollection;



    Best wishes,

    Tomasz Krawczyk

    Thursday, March 14, 2013 10:36 PM

All replies

  • Hi there,

    I have moved this thread to report control forum for more responses.

    Thank you for your understanding and support.

    Best Regards,

    Jack Zhai [MSFT]
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Monday, March 18, 2013 5:18 AM
  • This is old and probably has been answered outside of here, but if not, I made this mistake a while back to.

    'Oracle.DataAccess.Client.OracleConnection' is not the same as 'System.Data.OracleClient.OracleConnection'

    Oracle.DataAccess.Client is Oracle's ADO guy, System.Data.OracleClient is Microsoft's Oracle ADO guy. So while very similarly named and used, they are different assemblies altogether.

    Monday, April 22, 2013 6:12 PM
  • Hello Sean,

    Thanks for Your reply. My problem is unsolved. I have to manualy edit source code generated by VisualStudio to work with Oracle's ADO. Every change made to DataSet causes regeneration of source code, and again I have to change it to use Oracle's ADO. The names of the classes are not real problem because I can use find and replace, the same to datatypes. Problem is with Parameters:


    this._commandCollection[1].Parameters.Add(new global::Oracle.DataAccess.Client.OracleParameter("OD_ID", global::Oracle.DataAccess.Client.OracleDbType.Decimal, 22, global::System.Data.ParameterDirection.Input, false, 10, 0, "DOCUM_ID", global::System.Data.DataRowVersion.Current, null));

    The Oracle's ADO has other parameter list then Microsoft's ADO. I compared it to Microsoft'a Parameter class and I know what to change but why the VisualStudio still uses Misrosoft's ADO even when it says that is absolete ?

    How to convince VisualStudio to produce source code using Oracle'a ADO ?

    Best Regards,

    Tomasz Krawczyk

    • Edited by kraft-pl Thursday, April 25, 2013 6:15 PM edit lexical errors
    Thursday, April 25, 2013 3:40 PM
  • Hi,

    Please help me to resolve/ clean this warning from my code, I am using VS 4.5 

    Warning 599 'System.Data.OracleClient.OracleConnection' is obsolete: 'OracleConnection has been deprecated.



    • Edited by shahzhu Monday, August 18, 2014 1:48 PM
    Monday, August 18, 2014 1:47 PM