导出点的所有属性数据。
public List<CreateShapeFileResultModel> ExportGpsTrackByTaskId(string taskId, string path)
{
try
{
if (taskId == "" || taskId.Split(',').Length == 0)
{
return new SerializeJson<DataTable>(ResultType.failed, "没有传入任务ID", null).ToString();
}
string[] taskIdArr_ = taskId.Split(',');
string selectSql = "";
string selectTablePro = "";
DataTable gpsDt = new DataTable();
DataTable gpsDtPro = new DataTable();
List<CreateShapeFileResultModel> gpsPath = new List<CreateShapeFileResultModel>();
for (int i = 0; i < taskIdArr_.Length; i++)
{
selectSql = $@"select t.*,t1.RENWU_MC fileName from {T_PAT_GPSDATAEntity.Table_Name} t JOIN {T_PAT_XUNHURENWUEntity.Table_Name} t1 ON t1.{T_PAT_XUNHURENWUEntity.Field_PK_XHRW_ID} = {T_PAT_GPSDATAEntity.Field_TASKID} where {T_PAT_GPSDATAEntity.Field_TASKID} = '{taskIdArr_[i]}'";
selectTablePro = $@"select sys.columns.name,sys.types.name,sys.columns.max_length,sys.columns.precision,
sys.columns.scale,sys.columns.is_nullable,sys.columns.is_identity
from sys.columns,sys.tables,sys.types
where sys.tables.object_id=sys.columns.object_id
and sys.types.user_type_id=sys.columns.user_type_id
and sys.tables.name='{T_PAT_GPSDATAEntity.Table_Name}' ";
gpsDt = mDAL.GetDataForShow(select