| 22 |
* |
* |
| 23 |
* $Revision$ |
* $Revision$ |
| 24 |
* $Log$ |
* $Log$ |
| 25 |
|
* Revision 1.119 2006/04/07 08:19:51 tani |
| 26 |
|
* doiをDBから取得する時の型指定をBLOBにあわせて修正. |
| 27 |
|
* |
| 28 |
* Revision 1.118 2006/01/10 10:56:30 tani |
* Revision 1.118 2006/01/10 10:56:30 tani |
| 29 |
* selectiveHarvesting:stat.item_idでorder by(asc) |
* selectiveHarvesting:stat.item_idでorder by(asc) |
| 30 |
* |
* |
| 3796 |
SQLBindParameter(hstmt, 11, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &publication_mday, 0, &cbPublication_mday ); |
SQLBindParameter(hstmt, 11, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &publication_mday, 0, &cbPublication_mday ); |
| 3797 |
SQLBindParameter(hstmt, 12, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_LONGVARCHAR, XNP_ITEM_LANG_LEN, 0, lang, 0, &cbLang ); |
SQLBindParameter(hstmt, 12, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_LONGVARCHAR, XNP_ITEM_LANG_LEN, 0, lang, 0, &cbLang ); |
| 3798 |
|
|
| 3799 |
|
//アイテム情報をitem構造体からSQL_CHAR配列へコピーする |
| 3800 |
strncpy2( (char*)title, item -> getTitle(), XNP_ITEM_TITLE_LEN ); |
strncpy2( (char*)title, item -> getTitle(), XNP_ITEM_TITLE_LEN ); |
| 3801 |
strncpy2( (char*)keywords, item -> getKeywords(), XNP_ITEM_KEYWORDS_LEN ); |
strncpy2( (char*)keywords, item -> getKeywords(), XNP_ITEM_KEYWORDS_LEN ); |
| 3802 |
strncpy2( (char*)description, item -> getDescription(), XNP_ITEM_DESCRIPTION_LEN ); |
strncpy2( (char*)description, item -> getDescription(), XNP_ITEM_DESCRIPTION_LEN ); |
| 3999 |
SQLBindCol( hstmt, 11, SQL_C_SLONG, &publication_month, 0, &cbPublication_month ); |
SQLBindCol( hstmt, 11, SQL_C_SLONG, &publication_month, 0, &cbPublication_month ); |
| 4000 |
SQLBindCol( hstmt, 12, SQL_C_SLONG, &publication_mday, 0, &cbPublication_mday ); |
SQLBindCol( hstmt, 12, SQL_C_SLONG, &publication_mday, 0, &cbPublication_mday ); |
| 4001 |
|
|
| 4002 |
|
//取得したアイテムの情報をitem構造体へコピーする |
| 4003 |
|
//DOIはBLOB型→char*型へ変換のため,引数でSQL_C_BINARYを明示する |
| 4004 |
*itemsLen = 0; |
*itemsLen = 0; |
| 4005 |
for( int i = 0; ( sqlcode = SQLFetch( hstmt ) ) == SQL_SUCCESS && i < iidsLen ; i++ ){ |
for( int i = 0; ( sqlcode = SQLFetch( hstmt ) ) == SQL_SUCCESS && i < iidsLen ; i++ ){ |
| 4006 |
dst[ i ].setItemID( item_id ); |
dst[ i ].setItemID( item_id ); |
| 4008 |
dst[ i ].setTitle( getResultCol( hstmt, 3 ).c_str() ); |
dst[ i ].setTitle( getResultCol( hstmt, 3 ).c_str() ); |
| 4009 |
dst[ i ].setKeywords( getResultCol( hstmt, 4 ).c_str() ); |
dst[ i ].setKeywords( getResultCol( hstmt, 4 ).c_str() ); |
| 4010 |
dst[ i ].setDescription( getResultCol( hstmt, 5 ).c_str() ); |
dst[ i ].setDescription( getResultCol( hstmt, 5 ).c_str() ); |
| 4011 |
dst[ i ].setDOI( getResultCol( hstmt, 6 ).c_str() ); |
dst[ i ].setDOI( getResultCol( hstmt, 6, SQL_C_BINARY ).c_str() ); |
| 4012 |
dst[ i ].setContributorUID( uid ); |
dst[ i ].setContributorUID( uid ); |
| 4013 |
dst[ i ].setCreationDate( creation_date ); |
dst[ i ].setCreationDate( creation_date ); |
| 4014 |
dst[ i ].setLastUpdateDate( last_update_date ); |
dst[ i ].setLastUpdateDate( last_update_date ); |
| 4276 |
SQLBindParameter(hstmt, 11, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_LONGVARCHAR, XNP_ITEM_LANG_LEN, 0, lang, 0, &cbLang ); |
SQLBindParameter(hstmt, 11, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_LONGVARCHAR, XNP_ITEM_LANG_LEN, 0, lang, 0, &cbLang ); |
| 4277 |
SQLBindParameter(hstmt, 12, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &item_id, 0, &cbItem_id ); |
SQLBindParameter(hstmt, 12, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &item_id, 0, &cbItem_id ); |
| 4278 |
|
|
| 4279 |
|
//DBから得られたカラムの値をitem構造体へコピーする |
| 4280 |
strncpy2( (char*)title, item -> getTitle(), XNP_ITEM_TITLE_LEN ); |
strncpy2( (char*)title, item -> getTitle(), XNP_ITEM_TITLE_LEN ); |
| 4281 |
strncpy2( (char*)keywords, item -> getKeywords(), XNP_ITEM_KEYWORDS_LEN ); |
strncpy2( (char*)keywords, item -> getKeywords(), XNP_ITEM_KEYWORDS_LEN ); |
| 4282 |
strncpy2( (char*)description, item -> getDescription(), XNP_ITEM_DESCRIPTION_LEN ); |
strncpy2( (char*)description, item -> getDescription(), XNP_ITEM_DESCRIPTION_LEN ); |