We need to UNLOAD todays data from table-1 and LOAD into table-2 (this holds 1 weeks worth data). i.e after UNLOADing into a file, we will LOAD that file to table-2?
While UNLOADing data from table-1 using BMC utility, do we need to use 'ORDER BY' clause on SELECT statement to sort the primary keys?
My doubt is. Tables are defined with primary key always. So when we are loading, it will insert the rows into table taking primary key constraits. So why to use ORDER BY clause? Or will it take longer time for rearranging the loaded rows if ORDER BY clause is not given?
ORDER BY statement gives you in which order the table data will be displayed in ASCENDING order or DESCENDEING order u must knw that default is ASCENDING order respective of the primary key definition.
I think u will be knowing that ASC or DESC parameter is given with INDEX key definition which helps the query to manipulate quickly.
If the table_2 is created in such a way, in which it contains all the attributes of table_1 sucha as data type, primary key definition as same as table_1 index should be created on the primary key to boost up your query. INDEX key will reduce your time and tune your query accodingly.