Project

General

Profile

« Previous | Next » 

Revision 9030

Added by Jing Tao over 9 years ago

Change a method name to use pid rather than guid.

View differences:

src/edu/ucsb/nceas/metacat/IdentifierManager.java
777 777
        } catch (McdbDocNotFoundException e) {
778 778
        	// try system metadata only
779 779
        	    //this will check if the guid field on the system metadata table has the id
780
        		idExists = systemMetadataGUIDExists(guid);
780
        		idExists = systemMetadataPIDExists(guid);
781 781
        		if(!idExists) {
782 782
        		    //if the guid field of the system metadata table doesn't have the id,
783 783
        		    //we will check if the serial_id field of the system metadata table has it
......
1016 1016
        return exists;
1017 1017
    }
1018 1018
    
1019
    public boolean systemMetadataGUIDExists(String guid) throws SQLException {
1019
    public boolean systemMetadataPIDExists(String guid) throws SQLException {
1020 1020
		logMetacat.debug("looking up system metadata for guid " + guid);
1021 1021
		boolean exists = false;
1022 1022
		String query = "select guid from systemmetadata where guid = ?";
......
1071 1071
        	dbConn.setAutoCommit(false);
1072 1072
        	
1073 1073
	    	// insert the record if needed
1074
        	if (!IdentifierManager.getInstance().systemMetadataGUIDExists(guid)) {
1074
        	if (!IdentifierManager.getInstance().systemMetadataPIDExists(guid)) {
1075 1075
    	        insertSystemMetadata(guid, dbConn);
1076 1076
			}
1077 1077
	        // update with the values

Also available in: Unified diff