MCPcopy Create free account
hub / github.com/alliedmodders/sourcemod / SQL_GetFieldCount

Function SQL_GetFieldCount

core/logic/smn_database.cpp:993–1010  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

991}
992
993static cell_t SQL_GetFieldCount(IPluginContext *pContext, const cell_t *params)
994{
995 IQuery *query;
996 HandleError err;
997
998 if ((err = ReadQueryHndl(params[1], pContext, &query)) != HandleError_None)
999 {
1000 return pContext->ThrowNativeError("Invalid query Handle %x (error: %d)", params[1], err);
1001 }
1002
1003 IResultSet *rs = query->GetResultSet();
1004 if (!rs)
1005 {
1006 return 0;
1007 }
1008
1009 return rs->GetFieldCount();
1010}
1011
1012static cell_t SQL_FieldNumToName(IPluginContext *pContext, const cell_t *params)
1013{

Callers

nothing calls this directly

Calls 3

ReadQueryHndlFunction · 0.85
GetResultSetMethod · 0.45
GetFieldCountMethod · 0.45

Tested by

no test coverage detected