Tagged Questions
-2
votes
0answers
9 views
Adding markers to maps from coordinates from MySQL
I've spent now quite some time (2 days) trying to figure out how to get some data from MySQL database and then use it so I could put a marker on Google Map in my app.
I can add one marker that can ...
0
votes
0answers
13 views
JDBC Communications link failure and Connection refused with mysql
I try to access to a remote mysql database from a web projet with JDBC.
To do this, I have a class which does the connection :
@Stateless
public class LibraryPersistentBean implements ...
0
votes
1answer
10 views
Tomcat JDBC Connector not detected
I am developing a simple Java app which works under Tomcat. As database, I have chosen MySQL and it communicates with the Tomcat server via JDBC Connector. According to the documentation, I have ...
0
votes
2answers
20 views
'IN' keyword not working with embedded Derby database
I am working on my senior project and we are using an embedded Apache Derby database. I am trying to query data from the the three tables below but having trouble.
_________________
|Customers ...
1
vote
1answer
15 views
rewriteBatchedStatements introduces Syntax Error
I'm optimizing some SQL queries. And I've written them to use batches. Integration tests run fine, and everything is happy. But then I learn that MySQL doesn't give a performance increase unless ...
1
vote
1answer
20 views
Returning the single latest record for every device id in the table
I have the following table data:
+-----+---------------------+---------------------+------------+--------+------+-----------------+
| id | date_timer_off | date_timer_on | ...
0
votes
0answers
9 views
Mysql connection error for Spring framework (org.springframework.jdbc.CannotGetJdbcConnectionException: Could not get JDBC Connection; )
When I run the main class then this error pop up. I have checked most of the links for this issue but couldn't solve the problem. Please check the following files to get some idea about the problem ...
-8
votes
0answers
27 views
I am stuck with java JDBC database [on hold]
Can someone please list resources that can help me create a jdbc database
many thanks in adbanced
Link to coursework https://drive.google.com/open?id=0B8I0injZsiYPeVpYM2tFeFVpbEk
Lab Coursework 4 - ...
0
votes
0answers
26 views
i can't connect a restful to a mysql data base
i'm developing a restful web service ,actually i'm using a file but i want to make a data base connection instead so i can get data from the database instead of a file , i tried to make a database ...
-1
votes
0answers
12 views
Upload image to MySQL using Java [duplicate]
I'm trying to upload image with some information about the image - name, price, description. This is my Code:
/*
* To change this license header, choose License Headers in Project Properties.
* To ...
-1
votes
1answer
18 views
Exception in connection to the database using jconnect in Java
I get this exception when my code comes to this line. I use a java program to update my joomla website but suddenlly it didnt work and I got some thing is wrong with database connecting.
if (this.db....
0
votes
0answers
10 views
Spring Boot Database initialization MySQLException for Trigger
I am using Spring Boot Database initialization using Spring JDBC with schema.sql file.I am using MYSQL
If I have simple table creation in schema.sql as follows it works fine
CREATE TABLE Persons
(
...
-6
votes
0answers
22 views
database connection on android
I'm new to android programming and as a part a project I'm planning to make a NFC powered ATM. So, I'm planning to develop 2 apps:
1.The Client Side
2.A mock ATM app
Then, I want to connect it to ...
0
votes
0answers
27 views
How to display a Base64 image on a web Page efficiently
We have a portal that pulls data from two databases (MySQL and MSSQL). MySQL database contains basic customer details whereas the MSSQL contains customer Base64 Image String. Each of the databases ...
3
votes
1answer
26 views
One-to-many select in Jooq
I am trying out JOOQ and trying to select from 3 tables (Author, Books and Articles) using a join statement. The ERD is as follows:
Author ----< Books
|
|
^
Articles
The query I have is ...
-2
votes
1answer
24 views
How to take parameter from text box as a form of date
I have also one doubts how to use like and between operator in mysql.
I want to take two parameter from form and this particular date is use within like operator
my full code is:
String sql = "...
1
vote
1answer
19 views
JPQL Query gives exception when trying to add condition after order by
I am trying to execute a MySql query in JPQL.
Here is my MySql Query
select * from test.employee order by DEG != 'm2',DEG;
where test is schema name, employee is table name and DEG contains ...
0
votes
1answer
19 views
MySql Json object deserialisation optimization
I am having a field of type "text" in mysql and storing json data in it.
Eg:- "["android_app","iphone_app","windows_app"]";
I am interacting with mysql using hibernate and while reading this field I ...
0
votes
0answers
19 views
how to insert data into the databasae using crudrepository when table ID genereted using a trigger
how to insert data into the databasae using crudrepository when table ID genereted using a trigger
table fields declaration
@Id
@Generated(GenerationTime.ALWAYS)
@Column(name="t_tn_refno",insertable=...
0
votes
1answer
38 views
No Suitable Driver Found Exception: Hibernate [duplicate]
i am working on jax-rs(jersey) and want to connect to database by using hibernate. my projects works perfectly fine when i debug it as java application but as i run my project on server it gives No ...
0
votes
2answers
42 views
JAVA jdbc Eclipse SQLException
I was tring to add deatils to table but it showing some sql error
querry is
t=st1.executeUpdate("insert into stdetails(regno,nam,cid,gender,HouseName,place,guardian,phone,photo,did,Emailid,sem) ...
0
votes
1answer
22 views
MySQL ResultSet JsonWriter: jsonWriter.value((java.sql.Date) resultSet.getObject(column));
I want to write a MySQL Date column value with
jsonWriter.value((java.sql.Date) resultSet.getObject(column));
But it seems like it is not possible like that. It says long, Date, String all are not ...
-9
votes
0answers
44 views
Can someone please explain me this code? [on hold]
public class VinrMessagesInTable {
private Connection connection = null;
private Statement stmt = null;
static final Logger logger = Logger.getLogger(VinrMessageParser.class);
public ...
0
votes
0answers
30 views
How can I get database images into ArrayList using java? [on hold]
How can I get Images that are stored in MySQL Database to the Array List ?
0
votes
1answer
18 views
how to update mysql with textfield and jcombobox in java
private void UpdateActionPerformed(java.awt.event.ActionEvent evt) {
// TODO add your handling code here:
//Update
try{
if(!(jTextField1....
0
votes
0answers
14 views
Cant Show Data(Images and Texts) From DataBase MySql (LocalHost my phpAdmin) in ListView
This is my Videos_mosoe.java class (for get parse datas from database)
public class Videos_mosoe {
List < HashMap <String, Object >> pars_video_mosoe(String json) {
List < ...
-1
votes
1answer
25 views
how do I solve no such table error in android sqlite?
I have the problem that android sqlite gives me the error that my table does not exist. I have two classes, one database helperclass and one class that invokes methods like deleting, updating and ...
-1
votes
0answers
32 views
friend list not working properly [on hold]
I have 2 tables i.e., user and add_user
if user id 1 send a request to the user id 17
in user 1's friend list I will be able to see 17 as a friend
but at the same time, i am not able to see in ...
-3
votes
2answers
39 views
Check if date in database is bigger then today
So I have a table in my database with reservations.
In Java I only want to show the reservations of today and beyond.
PreparedStatement statement = con.prepareStatement(
"SELECT ...
0
votes
1answer
17 views
Generating sql tables by means of Spring automatically using predefined scrypt file
There is a functionality for embedded databases (like H2) which provides us with a possibility to automatically generate sql tables using a predefined scrypt file.
Bean example:
@Bean
public ...
-4
votes
0answers
16 views
in sales management system in java with mysql
How do I make an ordering feature to my sales. I already have my tables in MySql. The problem is; how do execute the proper program.
In ordering, I have (OrderID, BillingNO, ProductID, Quantity, ...
0
votes
1answer
19 views
MySQL Model solution for Hibernate
I have a question about a DB model which I am not totally sure of as I am not a DBA. I have deleted most of the columns to make this slightly simpler.
The scenario is this:
1. An attendee can be of ...
0
votes
0answers
35 views
Inserting data into table with foreign key using mybatis
I have 2 tables, Table 1 has a ID column which is auto generated. I have this Id as a foreign key with table 2, I am using mybatis to insert data into tables. I am stuck at point where I need to send ...
-5
votes
0answers
32 views
java y mysql error java.sql.SQLException: Access denied for user [on hold]
hola tengo la siguiente error cuando ejecuto desde computador remoto
java.sql.SQLException: Access denied for user 'TempC'@'10.105.0.92' (using password: YES)
las cadena de conexion que tengo es asi
...
1
vote
0answers
19 views
How to pass string variable from java class in an android activity to a php file?
In my android project i have a main screen, the java class associated with this activity holds an 'id' variable, how do I send this 'id' to a php so I can then run a query on my database?
Essentially ...
0
votes
1answer
22 views
Play- why PersistenceException is occured?
I want to update/edit my information on database. But when I am trying to do so, it shows error:
Execution exception
PersistenceException occured :
org.hibernate.PersistentObjectException: ...
0
votes
0answers
22 views
what is the best way to use 'enum' and 'Date' in POJO class? and how to do validation in POJO class for employee?
As you can see i am using 'enum' in employee_detail as well as in gender.java.
Here is my pojo class and enum class:
//Employee.java
package com.myp.ems.model;
import com.myp.ems.model.Gender;
import ...
0
votes
0answers
23 views
where I should put jar file, in connection to remote database, ssh , java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
I want to make a connection to the remote database ssh, in my java program, so I write a java code for this, I can ssh to the database server from my code but I can't access to the database, this is ...
-1
votes
0answers
27 views
JavaFX and MySQL
I have created a simple login system using JavaFX which checks for a predefined string username and password. For example, my application checks for the username "user" and password "pass" and ...
-2
votes
0answers
27 views
Apache Tomcat Error in Eclipse.Server Tomcat v8.0 Server at localhost failed to start. error
Error Message in eclipse.Suggest any Solutions to solve it
Apache Tomcat Error in Eclipse.Server Tomcat v8.0 Server at localhost failed to start. error...
at org.apache.tomcat.util.net.NioEndpoint....
1
vote
1answer
34 views
MySQL AUTO_INCREMENT and Hibernate Auto ID generation
Is it necessary to have DB Column defined as AUTO_INCREMENT to have Entity @Id Auto generation working properly? I am using Spring-Data-JPA with MySQL.
0
votes
2answers
45 views
Can't connect to MySQL database: No suitable driver found
I'm having some troubles with java and jdbc.
In particular, while my code perfectly works in a NetBeans project, when i try to execute it on a terminal or on my ubuntu vps (which is where i need it to ...
-1
votes
1answer
31 views
How to form two sql insert statements from the JSON array
I have got a JSON Array as shown below
[{
"link_video": "123"
}, {
"link_video": "456"
}]
By parsing i want to create two insert sql as
Insert into mytable values (123,456);
Insert into ...
0
votes
1answer
28 views
Insert in MySQL from JavaFX
Insert in mysql problem from javafx, i keep getting invalid value no matter what i do. Am trying to have an incrementing value when a button is clicked. The first value in the database is Doc - 1 ...
1
vote
0answers
30 views
is it good to use “enum” for same value in database as well as in program(JAVA)?
This is my employee_detail:
CREATE TABLE EMPLOYEE_DETAIL(
EMP_ID INT(10) NOT NULL PRIMARY KEY,
FIRST_NAME VARCHAR(32) NOT NULL,
LAST_NAME VARCHAR(32) NOT NULL,
EMAIL_ID VARCHAR(...
0
votes
0answers
54 views
java spring mysql database turkish character issue
I have a problem with recording text to mysql database. In the special charactes have been recorded as ? character.
This is my database.properties
jdbc.driverClassName=com.mysql.jdbc.Driver
jdbc.url=...
0
votes
0answers
40 views
Refresh page after Inserting data into table and displaying updated table
So I'm trying to create a basic web app using JSF. I have a primefaces table with 2 text inputs to add rows to the table. When I click the add button the row is inserted into the mySQL database.The ...
0
votes
1answer
38 views
select case with order by in jpa
SELECT * FROM orderTable order by
CASE priority when 'CRITICAL' THEN 1
when 'HIGH' then 2
when 'MEDIUM' then 3
when 'LOW' then 4
when 'NOT_ASSIGNED' then 5
end ASC ,
CreatedAt ASC;
...
1
vote
1answer
30 views
How do I best send data String or is there another better possibility? [on hold]
I want to send data of a mysql table through the network from a server to a client. How should I send the data? A string is not enough because I have 2 full text columns. How do I best send it over ...
0
votes
0answers
13 views
How can I insert records from my MYsql database into a jScrollPane
Hi I want to add a list of records into a jList inside a jscrollpane, can you guys help me please
Class Values:
public static JList<String> indicesJList;
indicesJList = new JList<String>...