有没有办法从数据库中获取最后一条记录而不使用:
Environment.SetEnvironmentVariable("clientname", clientname);
ProcessStartInfo pi = new ProcessStartInfo();
pi.FileName = Environment.ExpandEnvironmentVariables("test.bat");
pi.UseShellExecute = true;
Process.Start(pi);
答案 0 :(得分:0)
此代码选择LAST INSERTED ROW:
SELECT * FROM 'mytable' WHERE id = LAST_INSERT_ID();