Garayed.com  

Go Back   Garayed.com > mySQL
FAQ Members List Calendar Search Today's Posts Mark Forums Read


Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 06-27-2006, 01:31 AM
Dennis Kuntzemann
 
Posts: n/a
Default Object reference not set to an instance of an object

Hello I got the following error message:

Object reference not set to an instance of an object.
6/27/2006 9:17:02 AM Stack trace:
at MySql.Data.MySqlClient.PacketWriter.WriteStringNoN ull(String v)
at MySql.Data.MySqlClient.MySqlCommand.PrepareSqlBuff ers(String sql)
at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader( CommandBehavior
behavior)
at
MySql.Data.MySqlClient.MySqlCommand.System.Data.ID bCommand.ExecuteReader(Com
mandBehavior behavior)
at System.Data.Common.DbDataAdapter.FillFromCommand(O bject data, Int32
startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32
startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String
srcTable)
at Fact.TestConnect.connect2DB() in
c:\Inetpub\wwwroot\Fact\TestConnect.cs:line 114
Cycle finished



My source code close to the error look like this:

DataSet milestones = new DataSet();
foreach(string sl in serviceLevelList) {
Console.WriteLine(sl);
MySqlDataAdapter adapter = new MySqlDataAdapter(
"SELECT From Table where x='y'", dest.Connection);
adapter.MissingSchemaAction = MissingSchemaAction.AddWithKey;
adapter.MissingMappingAction = MissingMappingAction.Passthrough;
adapter.Fill(milestones, sl); <- error occurs



milestones and sl are not null. has anyone an clue what might help?

thanks in advance!!

best regards,

Dennis


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 02:29 AM.




LinkBacks Enabled by vBSEO 3.0.0 © 2007, Crawlability, Inc.