Questions tagged [datasource]

Datasource is a name given to the connection set up to a database from a server. The name is commonly used when creating a query to the database. The database source name (DSN) does not have to be the same as the filename for the database.

A data source is any of the following types of sources for (mostly) digitized data:

  • a database (in the Java software platform, datasource is a special name for the connection set up to a database from a server)
  • a computer file
  • a data stream

Please see more here (Wikipedia entry for Datasource) and here (Java 6 Datasource interface documentation)

4740 questions
20
votes
3 answers

attempt to reconnect jdbc pool datasource after database restarts

I have a web-app with a Java back-end that uses Tomcat jdbc-pool for database connections. This works fine. However I am trying to foolproof it before exporting it to other locations, and recently a scenario occurred where someone restarted the SQL…
egerardus
  • 11,316
  • 12
  • 80
  • 123
19
votes
4 answers

How to Casting DataSource to List?

I have the following method that load products on a DataGridView private void LoadProducts(List products) { Source.DataSource = products; // Source is BindingSource ProductsDataGrid.DataSource = Source; } And now I'm trying to…
Cristhian Boujon
  • 4,060
  • 13
  • 51
  • 90
18
votes
6 answers

Visual Studio won't update properties of my Data Source

I am using my class "Invoice" as a Data Source. But after adding more properties to it, Visual Studio refuses to refresh the data source and I can't find the new properties in my data source. Tried restarting project, deleting and adding object as…
18
votes
1 answer

Kendo ui datasource refresh?

I have used kendo grids and charts fine and refreshed them with the following example code: $("#Product").data("kendoGrid").dataSource.read(); However, I have used the datasource just to provide some basic data in a different view, like in this…
maff2002
  • 181
  • 1
  • 1
  • 3
18
votes
4 answers

Oracle data-source configuration for Spring

In the Spring framework, how is an Oracle data-source configured?
mauryat
  • 1,610
  • 5
  • 29
  • 53
17
votes
3 answers

How to make MySQL work on grails 2.0

Grails 2.0 seems to have some changes to DataSource.groovy and I don't seem to be able to get mysql running as it was in 1.3.7 I did grails install-dependency mysql:mysql-connector-java:5.1.16 rather than just dumping the .jar in lib. I hear this…
Mikey
  • 4,692
  • 10
  • 45
  • 73
16
votes
6 answers

jboss 7 AS datasource for sqlserver

I run jboss in standalone mode and have set my datasource in the standalone.xml to the following:
Marthin
  • 6,413
  • 15
  • 58
  • 95
16
votes
4 answers

SpEL @ConditionalOnProperty string property empty or nulll

I am currently having trouble with my dataSource bean creation on condition of String property from my applications.yaml file. Ideally, I would only like to create the dataSource bean only if the url is set in my application.yaml file. Shouldn't…
user3712237
  • 173
  • 1
  • 1
  • 8
16
votes
2 answers

How can I bind a DataSource to an InitialContext for JUnit testing?

I'm trying to run JUnit tests on database "worker" classes that do a jndi lookup on an InitialContext to get a DataSource. The worker classes are usually running on a Glassfish v3 App Server which has the appropriate jdbc resources defined. The code…
Brad H.
  • 315
  • 1
  • 4
  • 11
16
votes
1 answer

spring boot autoconfiguration with jdbc template autowiring dataSource issue

I'm new to Spring and to J2EE in general. I'm having trouble using JDBC template with Spring Boot autoconfiguration. What I did was I took the example of RESTful web service provided here and decided to extend it to use JDBC template relational…
Marek
  • 1,413
  • 2
  • 20
  • 36
15
votes
9 answers

My UITableView won't scroll down through the end of the data! Why?

Ok I don't know why this isn't working, but I have hooked up a tableView, with 19 items of text I'd like to set to each cell. The cells populate just fine, but when I try and scroll, it goes down there and I can see the cells that aren't visible on…
Stephen J.
  • 3,127
  • 4
  • 20
  • 28
15
votes
3 answers

ASP.NET - What is the difference of DataSourceID and DataSource?

What is the difference of DataSourceID and DataSource from the controls' attribute? Can I use them interchangeably? When I try to set DataSource property at the design time, by typing it on the aspx page, I get an exception that says "The…
kazinix
  • 28,987
  • 33
  • 107
  • 157
15
votes
1 answer

Produce a `DataSource` object for Postgres JDBC, programmatically

The JDBC Tutorial recommends using a DataSource object to obtain database connections rather than using the DriverManager class. To quote the Connecting with DataSource Objects page: DataSource objects … the preferred means of getting a connection…
Basil Bourque
  • 303,325
  • 100
  • 852
  • 1,154
15
votes
6 answers

Xcode storyboard delegate datasource scenes

After updating Xcode 7, some of my viewcontrollers' names changed to Delegate Scene, what to do about this? Thanks! Changing the title doesn't help
Ted
  • 22,696
  • 11
  • 95
  • 109
15
votes
3 answers

Should I close a Connection obtained from a DataSource manually?

When I get a Connection from the DataSource, should I close it manually? I mean in case I must close it, how it will be used in future requests?
Oleksandr Papchenko
  • 2,071
  • 21
  • 30