thienfu Posted June 22, 2010 Share Posted June 22, 2010 hello all, i need help for command query to access my database access. for example: $result = $dbDatatBase.OpenRecordset("Select * From db") system will result all data on db and if $result = $dbDatatBase.OpenRecordset("Select * From db where tenant = 'test'") system will result all data on db with record name tenant and value test but how if i have inputbox like below : $search = GUICtrlCreateInput("",270, 50, 100, 20) what query i must command for system to result all data on db with record name tenant and value as value captured by above inpubox? i have try with below command but system cannot work $result = $dbDatatBase.OpenRecordset("Select * From db where tenant = $search") sorry for my bad english, hope u all can understand Link to comment Share on other sites More sharing options...
PsaltyDS Posted June 22, 2010 Share Posted June 22, 2010 First, please post in the appropriate forum, as this has nothing to do with GUIs: General Help and SupportAll you need to do is assemble the string with the "&" concatenate operator: $result = $dbDatatBase.OpenRecordset("Select * From db where tenant='" & $search & "'") Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
thienfu Posted June 22, 2010 Author Share Posted June 22, 2010 thanks for reply and sorry for wrong forum room Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now