ExecuteCommandTextErrorHandling

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Richard Steele (Basemap)

    ExecuteCommandTextErrorHandling

    Hi
    I have added an extra column to my MS Access (2000) table, currently have 10
    fields. it is a simple text field. I come to fill a data adapter from a
    simple query select column name from table and I get the following

    Message = No value given for one or more required parameters.
    Source = Microsoft JET Database Engine
    Stack = at
    System.Data.Ole Db.OleDbCommand .ExecuteCommand TextErrorHandli ng(Int32 hr)
    at
    System.Data.Ole Db.OleDbCommand .ExecuteCommand TextForSingleRe sult(tagDBPARAM S
    dbParams, Object& executeResult)
    at System.Data.Ole Db.OleDbCommand .ExecuteCommand Text(Object& executeResult)
    at System.Data.Ole Db.OleDbCommand .ExecuteCommand (CommandBehavio r
    behavior, Object& executeResult)
    at System.Data.Ole Db.OleDbCommand .ExecuteReaderI nternal(Command Behavior
    behavior, String method)
    at System.Data.Ole Db.OleDbCommand .ExecuteReader( CommandBehavior behavior)
    at
    System.Data.Ole Db.OleDbCommand .System.Data.ID bCommand.Execut eReader(Command Behavior behavior)
    at System.Data.Com mon.DbDataAdapt er.FillFromComm and(Object data, Int32
    startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
    CommandBehavior behavior)
    at System.Data.Com mon.DbDataAdapt er.Fill(DataSet dataSet, Int32
    startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
    CommandBehavior behavior)
    at System.Data.Com mon.DbDataAdapt er.Fill(DataSet dataSet)
    ........

    when I take out the column and run a select query it returns all the
    necessary data
    does any one know what the problem is?

    Thanks
  • W.G. Ryan eMVP

    #2
    Re: ExecuteCommandT extErrorHandlin g

    What does the command that you're firing look like?

    --
    W.G. Ryan, MVP

    www.tibasolutions.com | www.devbuzz.com | www.knowdotnet.com
    "Richard Steele (Basemap)" <RichardSteeleB asemap@discussi ons.microsoft.c om>
    wrote in message news:81AC15B8-2CBC-4A02-BCC3-1CB214EFD490@mi crosoft.com...[color=blue]
    > Hi
    > I have added an extra column to my MS Access (2000) table, currently have[/color]
    10[color=blue]
    > fields. it is a simple text field. I come to fill a data adapter from a
    > simple query select column name from table and I get the following
    >
    > Message = No value given for one or more required parameters.
    > Source = Microsoft JET Database Engine
    > Stack = at
    > System.Data.Ole Db.OleDbCommand .ExecuteCommand TextErrorHandli ng(Int32 hr)
    > at
    >[/color]
    System.Data.Ole Db.OleDbCommand .ExecuteCommand TextForSingleRe sult(tagDBPARAM S[color=blue]
    > dbParams, Object& executeResult)
    > at System.Data.Ole Db.OleDbCommand .ExecuteCommand Text(Object&[/color]
    executeResult)[color=blue]
    > at System.Data.Ole Db.OleDbCommand .ExecuteCommand (CommandBehavio r
    > behavior, Object& executeResult)
    > at System.Data.Ole Db.OleDbCommand .ExecuteReaderI nternal(Command Behavior
    > behavior, String method)
    > at System.Data.Ole Db.OleDbCommand .ExecuteReader( CommandBehavior[/color]
    behavior)[color=blue]
    > at
    >[/color]
    System.Data.Ole Db.OleDbCommand .System.Data.ID bCommand.Execut eReader(Command B
    ehavior behavior)[color=blue]
    > at System.Data.Com mon.DbDataAdapt er.FillFromComm and(Object data, Int32
    > startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
    > CommandBehavior behavior)
    > at System.Data.Com mon.DbDataAdapt er.Fill(DataSet dataSet, Int32
    > startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
    > CommandBehavior behavior)
    > at System.Data.Com mon.DbDataAdapt er.Fill(DataSet dataSet)
    > ........
    >
    > when I take out the column and run a select query it returns all the
    > necessary data
    > does any one know what the problem is?
    >
    > Thanks[/color]


    Comment

    • Richard Steele (Basemap)

      #3
      Re: ExecuteCommandT extErrorHandlin g

      Thanks for you assistance I worked out the problem, no real fix, just me
      having a dumb moment

      "W.G. Ryan eMVP" wrote:
      [color=blue]
      > What does the command that you're firing look like?
      >
      > --
      > W.G. Ryan, MVP
      >
      > www.tibasolutions.com | www.devbuzz.com | www.knowdotnet.com
      > "Richard Steele (Basemap)" <RichardSteeleB asemap@discussi ons.microsoft.c om>
      > wrote in message news:81AC15B8-2CBC-4A02-BCC3-1CB214EFD490@mi crosoft.com...[color=green]
      > > Hi
      > > I have added an extra column to my MS Access (2000) table, currently have[/color]
      > 10[color=green]
      > > fields. it is a simple text field. I come to fill a data adapter from a
      > > simple query select column name from table and I get the following
      > >
      > > Message = No value given for one or more required parameters.
      > > Source = Microsoft JET Database Engine
      > > Stack = at
      > > System.Data.Ole Db.OleDbCommand .ExecuteCommand TextErrorHandli ng(Int32 hr)
      > > at
      > >[/color]
      > System.Data.Ole Db.OleDbCommand .ExecuteCommand TextForSingleRe sult(tagDBPARAM S[color=green]
      > > dbParams, Object& executeResult)
      > > at System.Data.Ole Db.OleDbCommand .ExecuteCommand Text(Object&[/color]
      > executeResult)[color=green]
      > > at System.Data.Ole Db.OleDbCommand .ExecuteCommand (CommandBehavio r
      > > behavior, Object& executeResult)
      > > at System.Data.Ole Db.OleDbCommand .ExecuteReaderI nternal(Command Behavior
      > > behavior, String method)
      > > at System.Data.Ole Db.OleDbCommand .ExecuteReader( CommandBehavior[/color]
      > behavior)[color=green]
      > > at
      > >[/color]
      > System.Data.Ole Db.OleDbCommand .System.Data.ID bCommand.Execut eReader(Command B
      > ehavior behavior)[color=green]
      > > at System.Data.Com mon.DbDataAdapt er.FillFromComm and(Object data, Int32
      > > startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
      > > CommandBehavior behavior)
      > > at System.Data.Com mon.DbDataAdapt er.Fill(DataSet dataSet, Int32
      > > startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
      > > CommandBehavior behavior)
      > > at System.Data.Com mon.DbDataAdapt er.Fill(DataSet dataSet)
      > > ........
      > >
      > > when I take out the column and run a select query it returns all the
      > > necessary data
      > > does any one know what the problem is?
      > >
      > > Thanks[/color]
      >
      >
      >[/color]

      Comment

      Working...