Sample Header Ad - 728x90

How to update data of a field in an oracle table?

0 votes
1 answer
1305 views
My table name: KEY_PARAMETER It consists two fields named SET_NO. and MES_VAL SET_NO. is fixed which doesn't change but my MES_VAL filed is getting changed is every on minute. My intention is to update this MES_VAL field without deleting its old value. SQL> desc key_parameter; SQL> select SET_NO and MES_VAL from key_parameter; SET_NO. MES_VAL ------ ------- 2324 12.22 5555 -90.40 65467 89.98 1243 123 6754 12.67 5677 898.55 7853 11.00 9865 449.12 3244 90.33 3545 76.89 After one minute, when the MES_VAL field will be updated. It should be like this. SET_NO. MES_VAL ------ ------- 2324 17.67 5555 -90.5 65467 34,88 1243 88 6754 32,90 5677 227.9 7853 30.6 9865 109.3 3244 23.40 3545 132.8 In the back end, a Unix shell script is running in my Solaris system. Where my updated data is getting saved in a .txt file. I have tried using oracle sqlldr REPLACE command, but what is happening it is deleting it's data and then new data is getting populated into table. For the time being, operator are unable to view any data until new value is getting inserted. Also I have tried insert into command but what is happening instead of updating the field, it keeps the old data which I don't required.
Asked by Nainita (2972 rep)
Jun 5, 2018, 09:23 AM
Last activity: Aug 3, 2022, 05:58 PM