Click here to Skip to main content
12,894,708 members (57,923 online)
Rate this:
 
Please Sign up or sign in to vote.
See more: VB VB.NET
Hai there guys. Sorry if my subject isn't clear enough because I don't know how else to put. So here's the thing, I need to debug and test a VB.NET windows application for hotel management system. I'm quite new to VB.NET, so there is a few lines of database query that I didn't get. There is a few lines such as :

Com.CommandText = "Select * from QRoom Order by RoomNo"


or

Com.CommandText = "Select Floor from QRoom where RoomNo=" & cbo.Text & ""


as you can see the table name there is QRoom but when I check within the Access database, there is no table name QRoom. But if I change the table name to the one that us in the database(which is my case, it is TblRoom), then there will be errors. So I didn't get why is that. Any help is appreciated. :)

p/s : the guy who wrote this code is unreachable st the moment so I cannot directly ask him. :(
Posted 26-Nov-12 22:03pm
nizam15577
Comments
André Kraak 27-Nov-12 4:37am
   
Did you check to see whether QRoom is a query in the database?
Does the table TblRoom contain the field RoomNo?
nizam15 27-Nov-12 4:42am
   
yes, there is a field name RoomNo within the TblRoom table.
where to check if there is a query in the database?sorry this is my first time using microsoft access.
André Kraak 27-Nov-12 4:51am
   
I tried finding something that shows where the queries are. This might help Queries For MS Access 2007[^].
nizam15 27-Nov-12 5:01am
   
thanks for the reference. Well if I follow that correctly, I can't seem to find any query for that particular table.
nizam15 27-Nov-12 5:32am
   
I did find the queries. But what I didn't understand is why is it when I change the queries I posted above to an actual table name within the database, it came up with an error :
"No value given for one or more required parameters."

as if that table doesn't exist.
Mathlab 27-Nov-12 10:58am
   
Did you check to see if its in the list of views?
Mathlab 27-Nov-12 10:59am
   
Please post the code preceeding the query
VitorHugoGarcia 28-Nov-12 5:02am
   
My best guest is that QRoom is a query with parameters.
Find the query and see which parameter it is waiting for and act accordingly.
VitorHugoGarcia 28-Nov-12 5:03am
   
Which version of ms access are you using ?
nizam15 28-Nov-12 9:40am
   
it's ok guys, I'm satisfied by finding what is the mysteries behind the Q table. Thanks a bunch guys~ :)
Ezra Neil 3-Jan-13 6:07am
   
I agree with this. It is most probably another query with parameter. Look carefully in the list of tables.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

    Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy | Mobile
Web01 | 2.8.170424.1 | Last Updated 27 Nov 2012
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100