Hi,@Bit-101
Welcome to Microsoft T-SQL Q&A Forum!
To answer the question first, here is the forum for sql server . For IBM DB2 follow this link , if you have more complex IBM questions , it is recommended to consult the forum.
From your description , it seems that you want to delete some columns in the table , which is easy to achieve , IBM database on this part is the same with TSQL use.
You can try this:
DELETE [FROM] [database_name.]table_name [ WHERE where_conditions ]
DELETE table_ref FROM [joined_table_refs] [ WHERE where_conditions ]
The first form evaluates rows in a table against an optional WHERE clause and deletes all rows that match the WHERE condition , or all rows if WHERE is omitted.
And The second form evaluates one or more join clauses and deletes all matching rows from one of the tables . The join clause can contain non-Kudu tables , but the table from which the row is deleted must be a Kudu table . In this case , the FROM keyword is required to separate the name of the table whose rows are to be deleted from the table name of the join clause.
Here I don't know what the column names of your table mean , I guess you can use where condition to complete the filtering you need, like this:
Select JOBISRUNNING,STARTTEDTIM,COMPLETEDTIME, STARTBYPERON_REF
From JOBBSTATUS
Where STARTTEDTIM Between ----AND------
If you want to filter out records whose date is greater than a certain time period , you can change:
Where table_column> timestamp ('date') ----The date here stores data in date format
Okay, the above is part of what I know about using DB2 , I hope it can help you .
Best regards,
Bert Zhou
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our Documentation to enable e-mail notifications if you want to receive the related email notification for this thread.