How can i run a insert query script(.sql) to create tables and columns or pre populate few datas

醉酒当歌 提交于 2019-12-11 15:23:09

问题


I need to create tables and columns with some default data to run my Java web application in CloudFoundry.

I am not able to use any MySQL client to connect to the database ip which I received.

java.lang.System.getenv("VCAP_SERVICES");

Is it possible to connect to the db from STS or Eclipse, or is there any client published by VMware?


回答1:


you can use the VMC cli tool to create a tunnel to your MySQL service. When the tunnel is connected you can then opt to start a mysql client that will automatically connect to the instance.

Please see http://docs.cloudfoundry.com/tools/vmc/caldecott.html for an example of connecting to a MySQL service on CloudFoundry.



来源:https://stackoverflow.com/questions/10981512/how-can-i-run-a-insert-query-script-sql-to-create-tables-and-columns-or-pre-po

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!