|
|
@@ -79,7 +79,7 @@ public class McpServiceImpl implements IMcpService {
|
|
79
|
79
|
// ConnectConfig.builder()
|
|
80
|
80
|
// .uri(milvusServiceUrl)
|
|
81
|
81
|
// .build());
|
|
82
|
|
- }
|
|
|
82
|
+ }
|
|
83
|
83
|
|
|
84
|
84
|
@PreDestroy
|
|
85
|
85
|
public void destroyMilvusClient() {
|
|
|
@@ -104,16 +104,16 @@ public class McpServiceImpl implements IMcpService {
|
|
104
|
104
|
@Param(description = "章节名称") String title,
|
|
105
|
105
|
@Param(description = "技术文件地址") String templatePath) throws IOException
|
|
106
|
106
|
{
|
|
107
|
|
- try {
|
|
108
|
|
- if (templatePath.startsWith("/dev-api"))
|
|
109
|
|
- templatePath = templatePath.replace("/dev-api/profile", profile);
|
|
110
|
|
- templatePath =profile + templatePath;
|
|
111
|
|
- List<String> subTitles = extractSubTitles(templatePath, title);
|
|
112
|
|
- List<JSONObject> contexts = retrieveFromMilvus(collectionName, title, 10);
|
|
113
|
|
- return generateAnswerWithDocumentAndCollection(agentName, templatePath, subTitles, contexts);
|
|
114
|
|
- } catch (IOException e) {
|
|
115
|
|
- throw new RuntimeException(e);
|
|
116
|
|
- }
|
|
|
107
|
+ try {
|
|
|
108
|
+ if (templatePath.startsWith("/dev-api"))
|
|
|
109
|
+ templatePath = templatePath.replace("/dev-api/profile", profile);
|
|
|
110
|
+ templatePath =profile + templatePath;
|
|
|
111
|
+ List<String> subTitles = extractSubTitles(templatePath, title);
|
|
|
112
|
+ List<JSONObject> contexts = retrieveFromMilvus(collectionName, title, 10);
|
|
|
113
|
+ return generateAnswerWithDocumentAndCollection(agentName, templatePath, subTitles, contexts);
|
|
|
114
|
+ } catch (IOException e) {
|
|
|
115
|
+ throw new RuntimeException(e);
|
|
|
116
|
+ }
|
|
117
|
117
|
}
|
|
118
|
118
|
|
|
119
|
119
|
/**
|
|
|
@@ -122,27 +122,27 @@ public class McpServiceImpl implements IMcpService {
|
|
122
|
122
|
@ToolMapping(description = "执行SQL查询")
|
|
123
|
123
|
public JSONArray SQLQuery(@Param(description = "sql语句") String sqlString)
|
|
124
|
124
|
{
|
|
125
|
|
- sqlString = sqlString.replace("[","").replace("]","");
|
|
126
|
|
- return executeQuery(sqlString);
|
|
|
125
|
+ sqlString = sqlString.replace("[","").replace("]","");
|
|
|
126
|
+ return executeQuery(sqlString);
|
|
127
|
127
|
}
|
|
128
|
128
|
|
|
129
|
129
|
/**
|
|
130
|
|
- * 获取所有表名列表
|
|
131
|
|
- */
|
|
132
|
|
- @ToolMapping(description = "获取数据库中所有表名列表")
|
|
133
|
|
- public JSONArray GetAllTableNames()
|
|
134
|
|
- {
|
|
135
|
|
- return getAllTableNames();
|
|
136
|
|
- }
|
|
137
|
|
-
|
|
138
|
|
- /**
|
|
139
|
|
- * 获取指定表的结构信息
|
|
140
|
|
- */
|
|
141
|
|
- @ToolMapping(description = "获取指定表的结构信息")
|
|
142
|
|
- public JSONObject GetTableStructure(@Param(description = "表名") String tableName)
|
|
143
|
|
- {
|
|
144
|
|
- return getTableStructure(tableName);
|
|
145
|
|
- }
|
|
|
130
|
+ * 获取所有表名列表
|
|
|
131
|
+ */
|
|
|
132
|
+ @ToolMapping(description = "获取数据库中所有表名列表")
|
|
|
133
|
+ public JSONArray GetAllTableNames()
|
|
|
134
|
+ {
|
|
|
135
|
+ return getAllTableNames();
|
|
|
136
|
+ }
|
|
|
137
|
+
|
|
|
138
|
+ /**
|
|
|
139
|
+ * 获取指定表的结构信息
|
|
|
140
|
+ */
|
|
|
141
|
+ @ToolMapping(description = "获取指定表的结构信息")
|
|
|
142
|
+ public JSONObject GetTableStructure(@Param(description = "表名") String tableName)
|
|
|
143
|
+ {
|
|
|
144
|
+ return getTableStructure(tableName);
|
|
|
145
|
+ }
|
|
146
|
146
|
|
|
147
|
147
|
public JSONArray executeQuery(String sql) {
|
|
148
|
148
|
JSONArray result = new JSONArray();
|
|
|
@@ -337,25 +337,48 @@ public class McpServiceImpl implements IMcpService {
|
|
337
|
337
|
|
|
338
|
338
|
for (XWPFParagraph paragraph : document.getParagraphs()) {
|
|
339
|
339
|
String text = paragraph.getText();
|
|
340
|
|
- int level = Integer.parseInt(paragraph.getStyle());
|
|
341
|
|
-
|
|
342
|
|
- // 维护当前路径
|
|
343
|
|
- while (!currentPath.isEmpty() && Integer.parseInt(currentPath.get(currentPath.size() - 1).getStyle()) >= level) {
|
|
344
|
|
- currentPath.remove(currentPath.size() - 1);
|
|
345
|
|
- }
|
|
346
|
|
- currentPath.add(paragraph);
|
|
347
|
|
- if (foundParent) {
|
|
348
|
|
- if (level > parentLevel) { // 是子标题
|
|
349
|
|
- if (isLeafNode(document, paragraph, level)) {
|
|
350
|
|
- subTitles.add(text);
|
|
|
340
|
+ if (paragraph.getStyle() != null) {
|
|
|
341
|
+ String styleId = paragraph.getStyle();
|
|
|
342
|
+ XWPFStyle style = document.getStyles().getStyle(styleId);
|
|
|
343
|
+ String styleName = style.getName();
|
|
|
344
|
+ int level = 0;
|
|
|
345
|
+ if (styleName.equals("heading 2")) level = 2;
|
|
|
346
|
+ else if (styleName.equals("heading 3")) level = 3;
|
|
|
347
|
+ else if (styleName.equals("heading 4")) level = 4;
|
|
|
348
|
+ else continue;
|
|
|
349
|
+
|
|
|
350
|
+ // 维护当前路径
|
|
|
351
|
+ while (!currentPath.isEmpty()) {
|
|
|
352
|
+ XWPFParagraph lastPara = currentPath.get(currentPath.size() - 1);
|
|
|
353
|
+ String lastStyleId = lastPara.getStyle();
|
|
|
354
|
+ XWPFStyle lastStyle = document.getStyles().getStyle(lastStyleId);
|
|
|
355
|
+ String lastStyleName = lastStyle.getName();
|
|
|
356
|
+ int lastLevel = 0;
|
|
|
357
|
+ if (lastStyleName.equals("heading 2")) lastLevel = 2;
|
|
|
358
|
+ else if (lastStyleName.equals("heading 3")) lastLevel = 3;
|
|
|
359
|
+ else if (lastStyleName.equals("heading 4")) lastLevel = 4;
|
|
|
360
|
+ else break;
|
|
|
361
|
+
|
|
|
362
|
+ if (lastLevel >= level) {
|
|
|
363
|
+ currentPath.remove(currentPath.size() - 1);
|
|
|
364
|
+ } else {
|
|
|
365
|
+ break;
|
|
351
|
366
|
}
|
|
352
|
|
- } else {
|
|
353
|
|
- // 遇到同级或更高级别的标题,停止搜索
|
|
354
|
|
- break;
|
|
355
|
367
|
}
|
|
356
|
|
- } else if (text.equals(question)) {
|
|
357
|
|
- foundParent = true;
|
|
358
|
|
- parentLevel = level;
|
|
|
368
|
+ currentPath.add(paragraph);
|
|
|
369
|
+ if (foundParent) {
|
|
|
370
|
+ if (level > parentLevel) { // 是子标题
|
|
|
371
|
+ if (isLeafNode(document, paragraph, level)) {
|
|
|
372
|
+ subTitles.add(text);
|
|
|
373
|
+ }
|
|
|
374
|
+ } else {
|
|
|
375
|
+ // 遇到同级或更高级别的标题,停止搜索
|
|
|
376
|
+ break;
|
|
|
377
|
+ }
|
|
|
378
|
+ } else if (text.equals(question)) {
|
|
|
379
|
+ foundParent = true;
|
|
|
380
|
+ parentLevel = level;
|
|
|
381
|
+ }
|
|
359
|
382
|
}
|
|
360
|
383
|
}
|
|
361
|
384
|
|
|
|
@@ -374,10 +397,19 @@ public class McpServiceImpl implements IMcpService {
|
|
374
|
397
|
|
|
375
|
398
|
// 检查后续段落
|
|
376
|
399
|
XWPFParagraph nextP = doc.getParagraphs().get(index + 1);
|
|
377
|
|
- int nextLevel = Integer.parseInt(nextP.getStyle());
|
|
378
|
|
- // 遇到同级或更高级别标题,是叶子节点
|
|
379
|
|
- return nextLevel <= level; // 存在更低级别的标题,不是叶子节点
|
|
380
|
|
-
|
|
|
400
|
+ if (nextP.getStyle() != null) {
|
|
|
401
|
+ String styleId = nextP.getStyle();
|
|
|
402
|
+ XWPFStyle style = doc.getStyles().getStyle(styleId);
|
|
|
403
|
+ String styleName = style.getName();
|
|
|
404
|
+ int nextLevel = 0;
|
|
|
405
|
+ if (styleName.equals("heading 2")) nextLevel = 2;
|
|
|
406
|
+ else if (styleName.equals("heading 3")) nextLevel = 3;
|
|
|
407
|
+ else if (styleName.equals("heading 4")) nextLevel = 4;
|
|
|
408
|
+ else return true;
|
|
|
409
|
+ // 遇到同级或更高级别标题,是叶子节点
|
|
|
410
|
+ return nextLevel <= level; // 存在更低级别的标题,不是叶子节点
|
|
|
411
|
+ }
|
|
|
412
|
+ return true;
|
|
381
|
413
|
}
|
|
382
|
414
|
|
|
383
|
415
|
/**
|
|
|
@@ -390,8 +422,11 @@ public class McpServiceImpl implements IMcpService {
|
|
390
|
422
|
for (XWPFParagraph paragraph : document.getParagraphs()) {
|
|
391
|
423
|
String text = paragraph.getText().trim();
|
|
392
|
424
|
if (paragraph.getStyle() != null) {
|
|
|
425
|
+ String styleId = paragraph.getStyle();
|
|
|
426
|
+ XWPFStyle style = document.getStyles().getStyle(styleId);
|
|
|
427
|
+ String styleName = style.getName();
|
|
393
|
428
|
// 判断主标题
|
|
394
|
|
- if (paragraph.getStyle().equals("3") || paragraph.getStyle().equals("4") ) {
|
|
|
429
|
+ if (styleName.equals("heading 3") || styleName.equals("heading 4")) {
|
|
395
|
430
|
subTitles.append(text).append("\n");
|
|
396
|
431
|
}
|
|
397
|
432
|
}
|
|
|
@@ -456,9 +491,12 @@ public class McpServiceImpl implements IMcpService {
|
|
456
|
491
|
String text = paragraph.getText().trim();
|
|
457
|
492
|
if (text.isEmpty()) continue;
|
|
458
|
493
|
|
|
459
|
|
- if (paragraph.getStyle() != null) {
|
|
460
|
|
- // 二级标题(样式2)开始新的分段
|
|
461
|
|
- if (paragraph.getStyle().equals("2")) {
|
|
|
494
|
+ if (paragraph.getStyleID() != null) {
|
|
|
495
|
+ String styleId = paragraph.getStyleID();
|
|
|
496
|
+ XWPFStyle style = xwpfDocument.getStyles().getStyle(styleId);
|
|
|
497
|
+ String styleName = style.getName();
|
|
|
498
|
+ // 二级标题开始新的分段
|
|
|
499
|
+ if (styleName.equals("heading 2")) {
|
|
462
|
500
|
// 保存当前二级标题下的内容
|
|
463
|
501
|
if (currentLevel2Content.length() != 0) {
|
|
464
|
502
|
// 检查当前二级标题内容的字节数
|
|
|
@@ -474,16 +512,24 @@ public class McpServiceImpl implements IMcpService {
|
|
474
|
512
|
String[] paragraphs = currentLevel2Content.toString().split("\n");
|
|
475
|
513
|
for (String para : paragraphs) {
|
|
476
|
514
|
if (para.trim().isEmpty()) continue;
|
|
477
|
|
-
|
|
478
|
|
- // 检查是否是三级标题
|
|
|
515
|
+
|
|
|
516
|
+ // 检查是否是三级标题(简单判断:如果是三级标题,样式应该是3,但这里需要重新解析)
|
|
|
517
|
+ // 由于已经将内容转为字符串,这里采用另一种方式:假设三级标题以数字+点+空格开头(如"1.1.")
|
|
|
518
|
+ // 或者可以重新遍历段落,但为了效率,这里采用简单的判断方式
|
|
479
|
519
|
boolean isLevel3Title = false;
|
|
480
|
520
|
for (XWPFParagraph p : xwpfDocument.getParagraphs()) {
|
|
481
|
|
- if (p.getText().trim().equals(para.trim()) && p.getStyle() != null && p.getStyle().equals("3")) {
|
|
482
|
|
- isLevel3Title = true;
|
|
483
|
|
- break;
|
|
|
521
|
+ if (p.getText().trim().equals(para.trim()) && p.getStyle() != null) {
|
|
|
522
|
+ styleId = p.getStyle();
|
|
|
523
|
+ style = xwpfDocument.getStyles().getStyle(styleId);
|
|
|
524
|
+ styleName = style.getName();
|
|
|
525
|
+ // 二级标题(样式2)开始新的分段
|
|
|
526
|
+ if (styleName.equals("heading 3")) {
|
|
|
527
|
+ isLevel3Title = true;
|
|
|
528
|
+ break;
|
|
|
529
|
+ }
|
|
484
|
530
|
}
|
|
485
|
531
|
}
|
|
486
|
|
-
|
|
|
532
|
+
|
|
487
|
533
|
if (isLevel3Title) {
|
|
488
|
534
|
// 保存当前三级标题内容
|
|
489
|
535
|
if (currentLevel3Content.length() != 0) {
|
|
|
@@ -541,15 +587,21 @@ public class McpServiceImpl implements IMcpService {
|
|
541
|
587
|
String[] paragraphs = currentLevel2Content.toString().split("\n");
|
|
542
|
588
|
for (String para : paragraphs) {
|
|
543
|
589
|
if (para.trim().isEmpty()) continue;
|
|
544
|
|
-
|
|
|
590
|
+
|
|
545
|
591
|
boolean isLevel3Title = false;
|
|
546
|
592
|
for (XWPFParagraph p : xwpfDocument.getParagraphs()) {
|
|
547
|
|
- if (p.getText().trim().equals(para.trim()) && p.getStyle() != null && p.getStyle().equals("3")) {
|
|
548
|
|
- isLevel3Title = true;
|
|
549
|
|
- break;
|
|
|
593
|
+ if (p.getText().trim().equals(para.trim()) && p.getStyle() != null) {
|
|
|
594
|
+ String styleId = p.getStyle();
|
|
|
595
|
+ XWPFStyle style = xwpfDocument.getStyles().getStyle(styleId);
|
|
|
596
|
+ String styleName = style.getName();
|
|
|
597
|
+ // 二级标题(样式2)开始新的分段
|
|
|
598
|
+ if (styleName.equals("heading 3")) {
|
|
|
599
|
+ isLevel3Title = true;
|
|
|
600
|
+ break;
|
|
|
601
|
+ }
|
|
550
|
602
|
}
|
|
551
|
603
|
}
|
|
552
|
|
-
|
|
|
604
|
+
|
|
553
|
605
|
if (isLevel3Title) {
|
|
554
|
606
|
// 保存当前三级标题内容
|
|
555
|
607
|
if (currentLevel3Content.length() != 0) {
|
|
|
@@ -608,20 +660,20 @@ public class McpServiceImpl implements IMcpService {
|
|
608
|
660
|
StringBuilder currentLevel3Content = new StringBuilder();
|
|
609
|
661
|
Range level2Range = hwpfDocument.getRange();
|
|
610
|
662
|
boolean foundCurrentLevel2 = false;
|
|
611
|
|
-
|
|
|
663
|
+
|
|
612
|
664
|
for (int j = 0; j < level2Range.numParagraphs(); j++) {
|
|
613
|
665
|
Paragraph p = level2Range.getParagraph(j);
|
|
614
|
666
|
String paraText = p.text().trim();
|
|
615
|
667
|
if (paraText.isEmpty()) continue;
|
|
616
|
|
-
|
|
|
668
|
+
|
|
617
|
669
|
// 找到当前二级标题的开始
|
|
618
|
670
|
if (p.getStyleIndex() == 2 && paraText.equals(currentLevel2Content.toString().split("\n")[0].trim())) {
|
|
619
|
671
|
foundCurrentLevel2 = true;
|
|
620
|
672
|
}
|
|
621
|
|
-
|
|
|
673
|
+
|
|
622
|
674
|
if (foundCurrentLevel2) {
|
|
623
|
675
|
short paraStyleIndex = p.getStyleIndex();
|
|
624
|
|
-
|
|
|
676
|
+
|
|
625
|
677
|
if (paraStyleIndex == 3) {
|
|
626
|
678
|
// 三级标题
|
|
627
|
679
|
// 保存当前三级标题内容
|
|
|
@@ -643,7 +695,7 @@ public class McpServiceImpl implements IMcpService {
|
|
643
|
695
|
}
|
|
644
|
696
|
}
|
|
645
|
697
|
}
|
|
646
|
|
-
|
|
|
698
|
+
|
|
647
|
699
|
// 保存最后一个三级标题内容
|
|
648
|
700
|
if (currentLevel3Content.length() != 0) {
|
|
649
|
701
|
TextSegment segment = TextSegment.from(currentLevel3Content.toString());
|
|
|
@@ -676,20 +728,20 @@ public class McpServiceImpl implements IMcpService {
|
|
676
|
728
|
StringBuilder currentLevel3Content = new StringBuilder();
|
|
677
|
729
|
Range level2Range = hwpfDocument.getRange();
|
|
678
|
730
|
boolean foundCurrentLevel2 = false;
|
|
679
|
|
-
|
|
|
731
|
+
|
|
680
|
732
|
for (int j = 0; j < level2Range.numParagraphs(); j++) {
|
|
681
|
733
|
Paragraph p = level2Range.getParagraph(j);
|
|
682
|
734
|
String paraText = p.text().trim();
|
|
683
|
735
|
if (paraText.isEmpty()) continue;
|
|
684
|
|
-
|
|
|
736
|
+
|
|
685
|
737
|
// 找到当前二级标题的开始
|
|
686
|
738
|
if (p.getStyleIndex() == 2 && paraText.equals(currentLevel2Content.toString().split("\n")[0].trim())) {
|
|
687
|
739
|
foundCurrentLevel2 = true;
|
|
688
|
740
|
}
|
|
689
|
|
-
|
|
|
741
|
+
|
|
690
|
742
|
if (foundCurrentLevel2) {
|
|
691
|
743
|
short paraStyleIndex = p.getStyleIndex();
|
|
692
|
|
-
|
|
|
744
|
+
|
|
693
|
745
|
if (paraStyleIndex == 3) {
|
|
694
|
746
|
// 三级标题
|
|
695
|
747
|
// 保存当前三级标题内容
|
|
|
@@ -711,7 +763,7 @@ public class McpServiceImpl implements IMcpService {
|
|
711
|
763
|
}
|
|
712
|
764
|
}
|
|
713
|
765
|
}
|
|
714
|
|
-
|
|
|
766
|
+
|
|
715
|
767
|
// 保存最后一个三级标题内容
|
|
716
|
768
|
if (currentLevel3Content.length() != 0) {
|
|
717
|
769
|
TextSegment segment = TextSegment.from(currentLevel3Content.toString());
|
|
|
@@ -743,7 +795,7 @@ public class McpServiceImpl implements IMcpService {
|
|
743
|
795
|
*/
|
|
744
|
796
|
private JSONObject getTableStructure(String tableName) {
|
|
745
|
797
|
JSONObject result = new JSONObject();
|
|
746
|
|
-
|
|
|
798
|
+
|
|
747
|
799
|
try {
|
|
748
|
800
|
Class.forName("com.mysql.cj.jdbc.Driver");
|
|
749
|
801
|
} catch (ClassNotFoundException e) {
|
|
|
@@ -751,12 +803,12 @@ public class McpServiceImpl implements IMcpService {
|
|
751
|
803
|
}
|
|
752
|
804
|
|
|
753
|
805
|
try (Connection conn = DriverManager.getConnection(Solon.cfg().getProperty("cmc.mysqlService.jdbcUrl"),Solon.cfg().getProperty("cmc.mysqlService.username"), Solon.cfg().getProperty("cmc.mysqlService.password"))) {
|
|
754
|
|
-
|
|
|
806
|
+
|
|
755
|
807
|
DatabaseMetaData metaData = conn.getMetaData();
|
|
756
|
|
-
|
|
|
808
|
+
|
|
757
|
809
|
ResultSet columns = metaData.getColumns(null, null, tableName, null);
|
|
758
|
810
|
JSONArray columnsInfo = new JSONArray();
|
|
759
|
|
-
|
|
|
811
|
+
|
|
760
|
812
|
while (columns.next()) {
|
|
761
|
813
|
JSONObject column = new JSONObject();
|
|
762
|
814
|
column.put("columnName", columns.getString("COLUMN_NAME"));
|
|
|
@@ -767,23 +819,23 @@ public class McpServiceImpl implements IMcpService {
|
|
767
|
819
|
columnsInfo.add(column);
|
|
768
|
820
|
}
|
|
769
|
821
|
columns.close();
|
|
770
|
|
-
|
|
|
822
|
+
|
|
771
|
823
|
ResultSet primaryKeys = metaData.getPrimaryKeys(null, null, tableName);
|
|
772
|
824
|
JSONArray primaryKeyColumns = new JSONArray();
|
|
773
|
|
-
|
|
|
825
|
+
|
|
774
|
826
|
while (primaryKeys.next()) {
|
|
775
|
827
|
primaryKeyColumns.add(primaryKeys.getString("COLUMN_NAME"));
|
|
776
|
828
|
}
|
|
777
|
829
|
primaryKeys.close();
|
|
778
|
|
-
|
|
|
830
|
+
|
|
779
|
831
|
result.put("tableName", tableName);
|
|
780
|
832
|
result.put("columns", columnsInfo);
|
|
781
|
833
|
result.put("primaryKey", primaryKeyColumns);
|
|
782
|
|
-
|
|
|
834
|
+
|
|
783
|
835
|
} catch (SQLException e) {
|
|
784
|
836
|
throw new RuntimeException("获取表结构失败: " + tableName, e);
|
|
785
|
837
|
}
|
|
786
|
|
-
|
|
|
838
|
+
|
|
787
|
839
|
return result;
|
|
788
|
840
|
}
|
|
789
|
841
|
|
|
|
@@ -792,7 +844,7 @@ public class McpServiceImpl implements IMcpService {
|
|
792
|
844
|
*/
|
|
793
|
845
|
private JSONArray getAllTableNames() {
|
|
794
|
846
|
JSONArray tableNames = new JSONArray();
|
|
795
|
|
-
|
|
|
847
|
+
|
|
796
|
848
|
try {
|
|
797
|
849
|
Class.forName("com.mysql.cj.jdbc.Driver");
|
|
798
|
850
|
} catch (ClassNotFoundException e) {
|
|
|
@@ -800,10 +852,10 @@ public class McpServiceImpl implements IMcpService {
|
|
800
|
852
|
}
|
|
801
|
853
|
|
|
802
|
854
|
try (Connection conn = DriverManager.getConnection(Solon.cfg().getProperty("cmc.mysqlService.jdbcUrl"),Solon.cfg().getProperty("cmc.mysqlService.username"), Solon.cfg().getProperty("cmc.mysqlService.password"))) {
|
|
803
|
|
-
|
|
|
855
|
+
|
|
804
|
856
|
DatabaseMetaData metaData = conn.getMetaData();
|
|
805
|
857
|
ResultSet tables = metaData.getTables(null, null, null, new String[]{"TABLE"});
|
|
806
|
|
-
|
|
|
858
|
+
|
|
807
|
859
|
while (tables.next()) {
|
|
808
|
860
|
String tableName = tables.getString("TABLE_NAME");
|
|
809
|
861
|
String tableComment = tables.getString("REMARKS");
|
|
|
@@ -816,11 +868,11 @@ public class McpServiceImpl implements IMcpService {
|
|
816
|
868
|
}
|
|
817
|
869
|
}
|
|
818
|
870
|
tables.close();
|
|
819
|
|
-
|
|
|
871
|
+
|
|
820
|
872
|
} catch (SQLException e) {
|
|
821
|
873
|
throw new RuntimeException("获取表名列表失败", e);
|
|
822
|
874
|
}
|
|
823
|
|
-
|
|
|
875
|
+
|
|
824
|
876
|
return tableNames;
|
|
825
|
877
|
}
|
|
826
|
878
|
|