c++ builder 2007, query count record from database
I have a simple application on C++Builder2007 and access 2007. I want to make a query so when a user hits a button to count the records on a specifiec date. I wrote the above but its not right. I want little help.
The fields are DATE->Date/Time Type... When i hit the button it says invalid integer.. I try to used the ADODATASET component but i dont have problem with that. Can i use something else;;;Like ADOQUERY. Wich is faster?
query="SELECT Count (DATE) FROM DEYAS WHERE DATE= '" + Edit14->Text + "'";
ADODataSet1->CommandText="SELECT COUNT (DATE) FROM BILLS WHERE DATE= '" + Edit14->Text + "'" ;
Re: c++ builder 2007, query count record from database
Hi. Sorry i thought i was clear. On Edit14->Text there is date with function DateToStr(Date());. I have these fields on database table.
Date->Date/Time with default value =Date()
So i want the user to hit the button and compare in the database with today date that have in edit14 and return the records.. For example 10 or 20. I dont know how to syntax right the query. How i syntax it first and then how i count it and return it on a new edit.
When it returns it says invalid integer. How i can see debugging sorry i am new in whole this