Note that there are some explanatory texts on larger screens.

plurals
  1. POJava exception out of memory
    text
    copied!<p>This is extremely strange. I am getting an out of memory exception when trying to create a file. However, there is more than enough space on the disk for the file to be created.</p> <p>The application is running on a Citrix (not sure if that is even relevant).</p> <p>I have no idea where to even start to debug this since I can clearly see that there is space on the disk.</p> <p>The file I'm trying to create is 4 KB and named <code>history.db</code></p> <p>Any ideas here?</p> <p>This is the code I'm using to create the file:</p> <pre><code>try { String databaseFileLocation = ""; String fileSeparator = System.getProperty("file.separator"); String homeDir = System.getProperty("user.home"); File myAppDir = new File(homeDir, ".imbox"); if (System.getProperty("os.name").contains("Windows")) { databaseFileLocation = "jdbc:sqlite:" + myAppDir + fileSeparator + "history_" + agentID + ".db"; } else if (System.getProperty("os.name").contains("Mac")) { databaseFileLocation = "jdbc:sqlite:history_" + agentID + ".db"; } Class.forName("org.sqlite.JDBC"); Connection conn = DriverManager.getConnection(databaseFileLocation); Statement stat = conn.createStatement(); stat.executeUpdate("CREATE TABLE IF NOT EXISTS visitorInfo (channelID text UNIQUE, currentPage, userCountry, userCity, org);"); stat.executeUpdate("CREATE TABLE IF NOT EXISTS chatHistory (channelID, sender, message, recipient, time);"); stat.executeUpdate("ALTER TABLE visitorInfo ADD COLUMN visitorTag;"); } catch (Exception eef) { eef.printStackTrace(); final ImageIcon icon = new javax.swing.ImageIcon(getClass().getResource("/resources/warning_icon.gif")); JOptionPane.showMessageDialog(null, "Failed to create database file.\n\nError description:\n" + eef.getMessage(), "Error when creating database file", JOptionPane.WARNING_MESSAGE, icon); } </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload