Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
No value given for one or more required parameters
Message
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Titre:
No value given for one or more required parameters
Divers
Thread ID:
01429969
Message ID:
01429969
Vues:
95
Using C#. I'm trying to run a SQL against an Excel file. I'm getting the error "no value given for one or more required parameters". I have been Googling this all day and can't get it to work.

This throws the error:
string Query = "SELECT [TPMA Run Date],[Buyer],[Item],[PO Number],[PO Line],[PO Due Date],[Date Required]," +
                "[New Date],[Status Comment],[Status Code],[Prior Week New Date],[Prior Week Status]," +
                "[Prior Week Status Code],[SEQNUM] FROM [Current MRP Action Messages$]";
If I do
string Query = "SELECT * FROM [Current MRP Action Messages$]";
then it works fine. I have checked the column headers in Excel. They are correct.

My conn string:
ConnectionString = @"provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + FileName + ";Extended Properties=\"Excel 8.0;HDR=NO;IMEX=1\"";
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Répondre
Fil
Voir

Click here to load this message in the networking platform