Not sure if this is a DB or a programming issue. I have a stored proc in MySQL 5.2 that runs in the console as expected. however, when I call it in my app, I get an empty dataset. the code I use to call it is a custom class that handles all my DB input/output. I don't believe that is the issue (as it works and has been working for 2 years on many places).
Call from app:
CREATE DEFINER = `admin`@`localhost` PROCEDURE `NewProc`(IN _InvoiceNo varchar(7), IN _SalespersonCode varchar(4))
IF (_SalespersonCode ="admn") THEN
Select * from invoiceheader where InvoiceNumber LIKE concat(_InvoiceNo , "%") ORDER BY InvoiceDate desc LIMIT 100;
Select * from invoiceheader where InvoiceNumber LIKE concat(_InvoiceNo , "%") and SalesPersonCode =_SalespersonCode ORDER BY InvoiceDate desc LIMIT 100;
public void Fill(String UserName, String InvNo)
user usr = new user();
if (usr.UserType == 3 || usr.UserType == 5 || usr.UserType == 7)
_DS = _DA.GetDataset("getInvoiceHeaderByInvoiceNoPartial");
_DA is my custom data Access class that I regularly use. the GetDataset method's only requirement for the Proc, it that returns a dataset. I've stepped through the code, and nothing errors. I have verified the parameters sent match those that I used directly on the DB. just wondering if there is something I'm not seeing.