This is not working because You are executing query like this :
select MaDaiLy from DaiLy where MaDaiLy = blablabla
select MaDaiLy from DaiLy where MaDaiLy = blablabla
To copy to clipboard, switch view to plain text mode
and of course You got an error from SQL engine because You don't have column 'blablabla' in table DaiLy. You should do this like :
checkexists->prepare("select MaDaiLy from DaiLy where MaDaiLy = ?");
checkexists->bindValue(0, ui.txtMaDL->text());
checkexists->prepare("select MaDaiLy from DaiLy where MaDaiLy = ?");
checkexists->bindValue(0, ui.txtMaDL->text());
To copy to clipboard, switch view to plain text mode
Bookmarks