![]() ![]() //pgsql/src/backend/executor/spi /* /* /* /* raw_parsetree_list = pg_parse_query(src);/ /* foreach(list_item, raw_parsetree_list) query_list = pg_analyze_and_rewrite(parsetree, argtypes, nargs); query_list_list = lappend(query_list_list, query_list); plan_list = list_concat(plan_list, plan->qtlist = query_list_list; /*
/* /* Be sure to restore ActiveSnapshot on error exit */ /* Convert parameters to form wanted by executor */ paramLI = (ParamListInfo) for (k = 0; k < nargs; k++) /* foreach(query_list_list_item, query_list_list) foreach(query_list_item, query_list) planTree = lfirst(plan_list_item); _SPI_current->processed = 0; if (queryTree->commandType == CMD_UTILITY) if (stmt->filename == NULL) if (read_only && !QueryIsReadOnly(queryTree)) /* dest = CreateDestReceiver(queryTree->canSetTag ? DestSPI : DestNone, if (snapshot == InvalidSnapshot) if (queryTree->commandType == CMD_UTILITY) /* fail: /* ActiveSnapshot = saveActiveSnapshot; /* Save results for caller */ return res; static int switch (operation) #ifdef SPI_EXECUTOR_STATS if (fire_triggers) ExecutorStart(queryDesc, false); ExecutorRun(queryDesc, ForwardScanDirection, tcount); _SPI_current->processed = queryDesc->estate->es_processed; if (operation == CMD_SELECT && queryDesc->dest->mydest == DestSPI) /* Take care of any queued AFTER triggers */ ExecutorEnd(queryDesc); #ifdef SPI_EXECUTOR_STATS return res;
![]() |
pg的语句处理主控函数
最新推荐文章于 2024-06-20 20:59:47 发布
由于IE浏览器升级禁用了alt+x快捷键,请用alt+q快捷键来快速进入写说说入口
正在加载中...
显示评论签名
全选 删除取消批量删除批量删除