MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / gen_select

Function gen_select

src/gpre/c_cxx.cpp:3127–3165  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3125//
3126
3127static void gen_select( const act* action, int column)
3128{
3129 TEXT name[MAX_REF_SIZE];
3130
3131 gpre_req* request = action->act_request;
3132 gpre_port* port = request->req_primary;
3133 gen_name(name, request->req_eof, true);
3134
3135 gen_s_start(action, column);
3136 printa(column, "if (!SQLCODE) ");
3137 column += INDENT;
3138 begin(column);
3139 gen_receive(action, column, port);
3140 printa(column, "if (!SQLCODE)");
3141 column += INDENT;
3142 begin(column);
3143 printa(column, "if (%s)", name);
3144 column += INDENT;
3145
3146 begin(column);
3147 gpre_nod* var_list = (gpre_nod*) action->act_object;
3148 if (var_list)
3149 for (int i = 0; i < var_list->nod_count; i++)
3150 {
3151 align(column);
3152 asgn_to(action, (ref*) var_list->nod_arg[i], column);
3153 }
3154
3155 endp(column);
3156
3157 printa(column - INDENT, "else");
3158 begin(column);
3159 printa(column, "SQLCODE = 100;");
3160 endp(column);
3161 column -= INDENT;
3162 endp(column);
3163 column -= INDENT;
3164 endp(column);
3165}
3166
3167
3168//____________________________________________________________

Callers 1

C_CXX_actionFunction · 0.70

Calls 8

gen_nameFunction · 0.70
gen_s_startFunction · 0.70
printaFunction · 0.70
beginFunction · 0.70
gen_receiveFunction · 0.70
alignFunction · 0.70
asgn_toFunction · 0.70
endpFunction · 0.70

Tested by

no test coverage detected