902 char *table_start, *table_end;
916 loader_file_config->
shp_file = strdup(filename);
919 table_start = loader_file_config->
shp_file + strlen(loader_file_config->
shp_file);
920 while (*table_start !=
'/' && *table_start !=
'\\' && table_start > loader_file_config->
shp_file)
927 table_end = loader_file_config->
shp_file + strlen(loader_file_config->
shp_file);
928 while (*table_end !=
'.' && table_end > loader_file_config->
shp_file && table_end > table_start )
932 loader_file_config->
table =
malloc(table_end - table_start + 1);
933 memcpy(loader_file_config->
table, table_start, table_end - table_start);
934 loader_file_config->
table[table_end - table_start] =
'\0';
937 for (i = 0; i < table_end - table_start; i++)
939 if (isupper(loader_file_config->
table[i]) != 0)
940 loader_file_config->
table[i] = tolower(loader_file_config->
table[i]);
944 loader_file_config->
schema = strdup(
"public");
952 return loader_file_config;
#define GEOGRAPHY_DEFAULT
static SHPLOADERCONFIG * global_loader_config