Changeset 865 for branches/prototype-v0/zoo-project/zoo-kernel/sqlapi.c
- Timestamp:
- Feb 8, 2018, 12:37:09 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/prototype-v0/zoo-project/zoo-kernel/sqlapi.c
r863 r865 379 379 char *sqlQuery=(char*)malloc((strlen(schema->value)+strlen(msg->value)+strlen(p->value)+strlen(sid->value)+64+1)*sizeof(char)); 380 380 sprintf(sqlQuery,"UPDATE %s.services set status=$$%s$$,message=$$%s$$ where uuid=$$%s$$;",schema->value,p->value,msg->value,sid->value); 381 if( zoo_ ds_nb == 0){381 if( zoo_DS == NULL || zoo_DS[zoo_ds_nb-1]==NULL ){ 382 382 init_sql(conf); 383 383 zoo_ds_nb++; 384 384 } 385 execSql(conf,0,sqlQuery); 386 cleanUpResultSet(conf,0); 387 close_sql(conf,0); 388 free(sqlQuery); 389 setMapInMaps(conf,"lenv","ds_nb","0"); 385 execSql(conf,zoo_ds_nb-1,sqlQuery); 386 cleanUpResultSet(conf,zoo_ds_nb-1); 387 free(sqlQuery); 390 388 return 0; 391 389 }
Note: See TracChangeset
for help on using the changeset viewer.