MFC/DAO temporary table ???
i don't know if this is the right place to post this, but is database related so i hope someone can help me ...
!!! all this is done in vc++ 6.0 using MFC/DAO !!!
i have a database with a table that has one numeric field called ID...
in my program, i assign a string to every value of this field...
so if the table has the following data
1
3
2
1
2
then my data will be in the following form
cow
chicken
wolf
cow
wolf
that is, every number has an assigned string.
the problem is that i want to store only the numeric field in the table and do all the processing in the program
so how can i have a recordset that contains the strings and to be able to sort it ?
another example :
i have a table that contains two fields : DATE and TEXT
but i want to have in my program three fields : DATE, TIME, and TEXT, where DATE and TIME is extracted from the DATE field in the database.
also i want to be able to sort by DATE or TIME in my program, so a database with folowing data
DATE TEXT
---------------- -----------
15/02/2001 12:28 Chris
19/02/2002 15:42 George
25/07/2003 09:48 John
will show up like this in my program
DATE TIME TEXT
---------- ----- -----------
15/02/2001 12:28 Chris
19/02/2002 15:42 George
25/07/2003 09:48 John
and i should be able to sort by DATE, or TIME, or TEXT
i'm showing data using a CListCtrl (not virtual)
please can somebody help me up with this ?
thanks ! (at least for reading this)