Bonjour,
Alors après avoir cherché toute la nuit ..
Est-ce qu'il existe un DELETE sur extDB3
Si oui pouvez-vous m'indiquer la marche à suivre ?
[CODE lang="sql" title="fn_querySwitch_fsmp"]/*
File: fn_querySwitch_fsmp.sqf
Author: Azira
Description:
Inserting data / Loading data
*/
params [
["_mode",0,[]],
["_index",0,[]],
["_name",objNull,[]],
["_uid",objNull,[]],
["_bilanprim","",[]],
["_douleur","",[]],
["_neuro","",[]],
["_respi","",[]],
["_circu","",[]],
["_lesionnel","",[]],
["_gtsapp","",[]]
];
if (_mode isEqualTo 0 || _name isEqualTo objNull || _uid isEqualTo objNull || _bilanprim isEqualTo "" || _douleur isEqualTo "" || _neuro isEqualTo "" || _respi isEqualTo "" || _circu isEqualTo "" || _lesionnel isEqualTo "" || _gtsapp isEqualTo "") exitWith {};
switch (_mode) do {
case 0: {
_query = format
[
"INSERT INTO intermedical (index, name, uid, bilanprim, douleur, neuro, respi, circu, lesionnel, gtsapp) VALUES('%1', '%2', '%3', '%4', '%5', '%6', '%7', '%8', '%9', '%10')",
_index,
_name,
_uid,
_bilanprim,
_douleur,
_neuro,
_respi,
_circu,
_lesionnel,
_gtsapp
];
[_query,1] call DB_fnc_asyncCall;
};
case 1: {
_query = format
[
"UPDATE intermedical SET bilanprim='%4', douleur='%5, neuro='%6', respi='%7', circu='%8', lesionnel='%9', gtsapp='%10' WHERE index='%1' AND name='%2' AND uid='%3'"
_index,
_name,
_uid,
_bilanprim,
_douleur,
_neuro,
_respi,
_circu,
_lesionnel,
_gtsapp
];
[_query,1] call DB_fnc_asyncCall;
};
case 2 : {
// SUPRESSION
};
case 3: {
private _query = format
[
"SELECT index, name, uid, bilanprim, douleur, neuro, respi, circu, lesionnel, gtsapp FROM intermedical WHERE index='%1' AND name='%2' AND uid='%3'"
_index,
_name,
_uid
];
private _queryResult = [_query,2] call DB_fnc_asyncCall;
if (_queryResult isEqualTo []) exitWith {};
[(_queryResult select [0,9])] remoteExec ["life_fnc_dataReceivedfmsp",remoteExecutedOwner];
};
};[/CODE]
Merci infiniment de votre aide
Alors après avoir cherché toute la nuit ..
Est-ce qu'il existe un DELETE sur extDB3
Si oui pouvez-vous m'indiquer la marche à suivre ?
[CODE lang="sql" title="fn_querySwitch_fsmp"]/*
File: fn_querySwitch_fsmp.sqf
Author: Azira
Description:
Inserting data / Loading data
*/
params [
["_mode",0,[]],
["_index",0,[]],
["_name",objNull,[]],
["_uid",objNull,[]],
["_bilanprim","",[]],
["_douleur","",[]],
["_neuro","",[]],
["_respi","",[]],
["_circu","",[]],
["_lesionnel","",[]],
["_gtsapp","",[]]
];
if (_mode isEqualTo 0 || _name isEqualTo objNull || _uid isEqualTo objNull || _bilanprim isEqualTo "" || _douleur isEqualTo "" || _neuro isEqualTo "" || _respi isEqualTo "" || _circu isEqualTo "" || _lesionnel isEqualTo "" || _gtsapp isEqualTo "") exitWith {};
switch (_mode) do {
case 0: {
_query = format
[
"INSERT INTO intermedical (index, name, uid, bilanprim, douleur, neuro, respi, circu, lesionnel, gtsapp) VALUES('%1', '%2', '%3', '%4', '%5', '%6', '%7', '%8', '%9', '%10')",
_index,
_name,
_uid,
_bilanprim,
_douleur,
_neuro,
_respi,
_circu,
_lesionnel,
_gtsapp
];
[_query,1] call DB_fnc_asyncCall;
};
case 1: {
_query = format
[
"UPDATE intermedical SET bilanprim='%4', douleur='%5, neuro='%6', respi='%7', circu='%8', lesionnel='%9', gtsapp='%10' WHERE index='%1' AND name='%2' AND uid='%3'"
_index,
_name,
_uid,
_bilanprim,
_douleur,
_neuro,
_respi,
_circu,
_lesionnel,
_gtsapp
];
[_query,1] call DB_fnc_asyncCall;
};
case 2 : {
// SUPRESSION
};
case 3: {
private _query = format
[
"SELECT index, name, uid, bilanprim, douleur, neuro, respi, circu, lesionnel, gtsapp FROM intermedical WHERE index='%1' AND name='%2' AND uid='%3'"
_index,
_name,
_uid
];
private _queryResult = [_query,2] call DB_fnc_asyncCall;
if (_queryResult isEqualTo []) exitWith {};
[(_queryResult select [0,9])] remoteExec ["life_fnc_dataReceivedfmsp",remoteExecutedOwner];
};
};[/CODE]
Merci infiniment de votre aide
Dernière édition: