package com.xzff.web.entity;
import com.alibaba.fastjson.JSONObject;
import com.xzff.web.service.CityCardService;
import org.apache.commons.io.FileUtils;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;
import java.io.File;
import java.io.IOException;
import java.lang.reflect.Field;
import java.time.LocalDateTime;
import java.util.ArrayList;
//@RunWith(SpringRunner.class)
//@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
public class CityCardTest {
@Autowired
CityCardService cityCardService;
@Test
public void importDb() {
//指定要读取文件的
java批量读取本地json文件并解析数据,插入数据库
最新推荐文章于 2024-09-04 16:47:27 发布
该博客介绍了如何使用Java高效地批量读取本地的JSON文件,解析其中的数据,并将这些数据有效地插入到数据库中,涉及到文件I/O、JSON解析和数据库操作的相关技术。
订阅专栏 解锁全文
781

被折叠的 条评论
为什么被折叠?



