Re: Exception on select command while access finds it ok
From: Versteijn (versteijn_at_538mail.nl)
Date: 02/11/04
- Next message: William Ryan eMVP: "Re: lazy load, very lazy ...."
- Previous message: Yair Cohen: "lazy load, very lazy ...."
- In reply to: Cowboy \(Gregory A. Beamer\): "Re: Exception on select command while access finds it ok"
- Messages sorted by: [ date ] [ thread ]
Date: 11 Feb 2004 13:35:31 -0800
Hi Gregory,
I tried that already, but it did not work either. Solution: add the
field Model1ID to the table :D I did that but apparently overwrote the
database file or forgot to save it.
Howver, thank you for your help
Regards,
Freek Verstejin
"Cowboy \(Gregory A. Beamer\)" <NoSpamMgbworld@comcast.netNoSpamM> wrote in message news:<e0fa2iK8DHA.3360@tk2msftngp13.phx.gbl>...
> Just for a test, try:
>
> "SELECT Modellen.* FROM IntropaginaIndelingen JOIN Modellen " & _
> "ON IntropaginaIndelingen.Model1ID = Modellen.ModelID"
>
> This is more MS-centric SQL (which also conforms to ANSI SQL, BTW).
>
> --
> Gregory A. Beamer
> MVP; MCP: +I, SE, SD, DBA
>
> **********************************************************************
> Think Outside the Box!
> **********************************************************************
> "Versteijn" <versteijn@538mail.nl> wrote in message
> news:4d19834f.0402110403.e610700@posting.google.com...
> > Hello all,
> >
> > I have this command:
> >
> > "SELECT Modellen.* FROM IntropaginaIndelingen, Modellen " & _
> > "WHERE IntropaginaIndelingen.Model1ID = Modellen.ModelID"
> >
> > When I execute and output my commandtext and paste that in Access, it
> > works fine. When I try to execute it through OleDb, it fails with this
> > exception:
> >
> >
> > [OleDbException (0x80040e10): No value given for one or more required
> > parameters.]
> > System.Data.OleDb.OleDbCommand.ExecuteCommandTextErrorHandling(Int32
> > hr) +41
> >
> System.Data.OleDb.OleDbCommand.ExecuteCommandTextForSingleResult(tagDBPARAMS
> > dbParams, Object& executeResult) +174
> > System.Data.OleDb.OleDbCommand.ExecuteCommandText(Object&
> > executeResult) +92
> > System.Data.OleDb.OleDbCommand.ExecuteCommand(CommandBehavior
> > behavior, Object& executeResult) +65
> > System.Data.OleDb.OleDbCommand.ExecuteReaderInternal(CommandBehavior
> > behavior, String method) +112
> > System.Data.OleDb.OleDbCommand.ExecuteReader(CommandBehavior
> > behavior) +69
> >
> System.Data.OleDb.OleDbCommand.System.Data.IDbCommand.ExecuteReader(CommandB
> ehavior
> > behavior) +5
> > System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32
> > startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
> > CommandBehavior behavior) +304
> > System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32
> > startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
> > CommandBehavior behavior) +77
> > System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +38
> > MediaMaker.Tools.DataAccess.DbCommand.executeDataSet() in
> > C:\Documents and Settings\David\Mijn documenten\Visual Studio
> > Projects\MedMakTools\MediaMaker.Tools\DataAccess\DbCommand.vb:106
> > T2.DataAccess.ModelDalc.SelectIntroModel(Int32 Ref) in C:\Documents
> > and Settings\David\Mijn documenten\Visual Studio Projects\T
> > Site\DataAccess\ModelDalc.vb:234
> >
> >
> > I'n confused. When I leave the 'where' part, it works fine.
> > Any ideas?
> >
> > Regards,
> >
> > Freek Versteijn
- Next message: William Ryan eMVP: "Re: lazy load, very lazy ...."
- Previous message: Yair Cohen: "lazy load, very lazy ...."
- In reply to: Cowboy \(Gregory A. Beamer\): "Re: Exception on select command while access finds it ok"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|