| 9796 | // Generate a field list that correspond to table fields. |
| 9797 | template <typename T> |
| 9798 | static void dsqlExplodeFields(dsql_rel* relation, Array<NestConst<T> >& fields, bool includeComputed) |
| 9799 | { |
| 9800 | thread_db* tdbb = JRD_get_thread_data(); |
| 9801 | MemoryPool& pool = *tdbb->getDefaultPool(); |
| 9802 | |
| 9803 | for (dsql_fld* field = relation->rel_fields; field; field = field->fld_next) |
| 9804 | { |
| 9805 | // CVC: Ann Harrison requested to skip COMPUTED fields in INSERT w/o field list. |
| 9806 | // ASF: But not for views - CORE-5454 |
| 9807 | if (!includeComputed && !(relation->rel_flags & REL_view) && (field->flags & FLD_computed)) |
| 9808 | continue; |
| 9809 | |
| 9810 | FieldNode* fieldNode = FB_NEW_POOL(pool) FieldNode(pool); |
| 9811 | fieldNode->dsqlName = field->fld_name.c_str(); |
| 9812 | fields.add(fieldNode); |
| 9813 | } |
| 9814 | } |
| 9815 | |
| 9816 | // Find dbkey for named relation in statement's saved dbkeys. |
| 9817 | static dsql_par* dsqlFindDbKey(const DsqlDmlStatement* statement, const RelationSourceNode* relation_name) |
no test coverage detected