Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Parameters (VFPOLEDB)
Message
General information
Forum:
Visual FoxPro
Category:
Visual FoxPro and .NET
Miscellaneous
Thread ID:
01442771
Message ID:
01442809
Views:
22
Not quite there yet. I have:
VDataSourceG.SelectParameters.Add("mcust", TypeCode.String)
VDataSourceG.SelectParameters.Add("mnoun", TypeCode.String)
VDataSourceG.SelectCommand = "SELECT l_nbr,cust_name,noun,office,price,status from FY2010 WHERE cust_name like '%'+?+'%' and noun like'%'+ ?+'%'"
but it's not returning any records.



>>>>>>>I think Sergey nailed it, but now it's not clear how to set multiple parameters?
>>>>>>
>>>>>>Set them in the order they will be used
>>>>> Parameters(1) ?
>>>>>Parameters(2) ?
>>>>The SQL statement should be something like 'Select from x where y=? and z=?' . The question marks will be replaced by the parameters in the order in which they were added in .NET
>>>
>>>I still don't understand exactly, can you post a quick sample?
>>
>>http://www.west-wind.com/WebLog/posts/660586.aspx
>
>Thanks a lot - very clear.
"Build a man a fire, and he's warm for a day.
Set a man on fire, and he's warm for the rest of his life."
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform