To do multible compids, use the following script:
php /var/www/html_j3sg/institutions/ChangeCompidOfAllInstitutionalAfewCompaniesAtATime.php
Please note that the script mentioned above (ChangeCompidOfAllInstitutionalAfewCompaniesAtATime) only updates the current13FFilingpositions table, no archived tables.

This script actual updates 13F current table as well as both archive13F tables.

We got coming in compid: : 130617
SELECT companies.* , sectors.level3des FROM companies, sectors WHERE companies.sector = sectors.level3num and compid = '130617'

The Shares Amount is 37904000

The cusip is 23338X102
NOT OLD

Retrive Rows from Table:
select * from current13Fpositions where cusip = '23338X102'
Number of Rows :15

update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '75.03' where entryId = '10166794'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '9.13' where entryId = '11443469'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '4.68' where entryId = '13022809'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '1.16' where entryId = '14677979'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '0.26' where entryId = '14873382'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '0' where entryId = '15474828'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '0.26' where entryId = '16172859'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '1.16' where entryId = '16194233'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '26.42' where entryId = '16639275'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '47.88' where entryId = '17197479'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '5.67' where entryId = '17274891'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '132.53' where entryId = '18669388'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '0.36' where entryId = '19147669'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '14.9' where entryId = '23170425'
update current13Fpositions set compid = '130617', sectorNum = '302002', sectorDes = 'Closed - End Fund - Debt', issuerCik = '0001231160' , percentOut = '35.64' where entryId = '55792196'
End Function

Retrive Rows from Table:
select * from archive13F where cusip = '23338X102'
Number of Rows :0

End Function
The Script is complete, exiting....