Page 1 of 1

SQL error

PostPosted: Sat Jul 13, 2013 6:45 pm
by Geissler
Hi, I'm getting an error when trying to access the browser view. I used the musiccabinet installer, have PostgreSQL and the latest version of java installed. Have tried several different combinations, such as subsonic 4.7 and 4.8 with the standalone musiccabinet files added, installing PostgreSQL before AND after musiccabinet, but everything gets the same error. Thanks for any insight.

Error

Subsonic encountered an internal error. You can report this error in the Subsonic Forum. Please include the information below.

Exception org.springframework.jdbc.BadSqlGrammarException
Message PreparedStatementCallback; bad SQL grammar [select username, locale, theme_id, last_fm_enabled, last_fm_username, transcode_scheme, show_now_playing, party_mode_enabled, now_playing_allowed, avatar_scheme, system_avatar_id, changed, show_chat, album_order_ascending, album_order_by_year, default_home_view, default_home_artists, default_home_albums, default_home_songs, artist_grid_width, album_grid_layout, related_artists, recommended_artists, reluctant_artist_loading, only_album_artist_recommendations, various_artists_shortlist, view_stats_for_all_users from user_settings where username=?]; nested exception is java.sql.SQLException: Column not found: ALBUM_ORDER_ASCENDING in statement [select username, locale, theme_id, last_fm_enabled, last_fm_username, transcode_scheme, show_now_playing, party_mode_enabled, now_playing_allowed, avatar_scheme, system_avatar_id, changed, show_chat, album_order_ascending, album_order_by_year, default_home_view, default_home_artists, default_home_albums, default_home_songs, artist_grid_width, album_grid_layout, related_artists, recommended_artists, reluctant_artist_loading, only_album_artist_recommendations, various_artists_shortlist, view_stats_for_all_users from user_settings where username=?]
Java version Oracle Corporation 1.7.0_25
Operating system Windows 7 6.1
Server jetty/8.y.z-SNAPSHOT
Memory Used 25 of 36 MB
Stack trace org.springframework.jdbc.BadSqlGrammarException: PreparedStatementCallback; bad SQL grammar [select username, locale, theme_id, last_fm_enabled, last_fm_username, transcode_scheme, show_now_playing, party_mode_enabled, now_playing_allowed, avatar_scheme, system_avatar_id, changed, show_chat, album_order_ascending, album_order_by_year, default_home_view, default_home_artists, default_home_albums, default_home_songs, artist_grid_width, album_grid_layout, related_artists, recommended_artists, reluctant_artist_loading, only_album_artist_recommendations, various_artists_shortlist, view_stats_for_all_users from user_settings where username=?]; nested exception is java.sql.SQLException: Column not found: ALBUM_ORDER_ASCENDING in statement [select username, locale, theme_id, last_fm_enabled, last_fm_username, transcode_scheme, show_now_playing, party_mode_enabled, now_playing_allowed, avatar_scheme, system_avatar_id, changed, show_chat, album_order_ascending, album_order_by_year, default_home_view, default_home_artists, default_home_albums, default_home_songs, artist_grid_width, album_grid_layout, related_artists, recommended_artists, reluctant_artist_loading, only_album_artist_recommendations, various_artists_shortlist, view_stats_for_all_users from user_settings where username=?]
at org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator.doTranslate(SQLErrorCodeSQLExceptionTranslator.java:233)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:72)
at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:603)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:637)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:666)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:674)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:714)
at net.sourceforge.subsonic.dao.AbstractDao.query(AbstractDao.java:58)
at net.sourceforge.subsonic.dao.AbstractDao.queryOne(AbstractDao.java:62)
at net.sourceforge.subsonic.dao.UserDao.getUserSettings(UserDao.java:165)
at net.sourceforge.subsonic.service.SettingsService.getUserSettings(SettingsService.java:1021)
at net.sourceforge.subsonic.service.SettingsService.setDefaultMusicCabinetUserSettings(SettingsService.java:1091)
at net.sourceforge.subsonic.controller.MultiController.index(MultiController.java:93)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.web.servlet.mvc.multiaction.MultiActionController.invokeNamedMethod(MultiActionController.java:471)
at org.springframework.web.servlet.mvc.multiaction.MultiActionController.handleRequestInternal(MultiActionController.java:408)
at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:900)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:827)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:882)
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:778)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:735)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:648)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1336)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:311)
at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:116)
at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:113)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:101)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:113)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter.doFilter(RememberMeAuthenticationFilter.java:146)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:54)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:45)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.authentication.www.BasicAuthenticationFilter.doFilter(BasicAuthenticationFilter.java:150)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:182)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:105)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:87)
at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:323)
at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:173)
at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346)
at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:259)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1307)
at net.sourceforge.subsonic.filter.RequestEncodingFilter.doFilter(RequestEncodingFilter.java:43)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1307)
at net.sourceforge.subsonic.filter.ParameterDecodingFilter.doFilter(ParameterDecodingFilter.java:54)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1307)
at net.sourceforge.subsonic.filter.BootstrapVerificationFilter.doFilter(BootstrapVerificationFilter.java:54)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1307)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:453)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:559)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1072)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:382)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1006)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
at org.eclipse.jetty.server.Server.handle(Server.java:365)
at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:485)
at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:926)
at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:988)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:635)
at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)
at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:627)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:51)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
at java.lang.Thread.run(Unknown Source)
Caused by: java.sql.SQLException: Column not found: ALBUM_ORDER_ASCENDING in statement [select username, locale, theme_id, last_fm_enabled, last_fm_username, transcode_scheme, show_now_playing, party_mode_enabled, now_playing_allowed, avatar_scheme, system_avatar_id, changed, show_chat, album_order_ascending, album_order_by_year, default_home_view, default_home_artists, default_home_albums, default_home_songs, artist_grid_width, album_grid_layout, related_artists, recommended_artists, reluctant_artist_loading, only_album_artist_recommendations, various_artists_shortlist, view_stats_for_all_users from user_settings where username=?]
at org.hsqldb.jdbc.Util.throwError(Unknown Source)
at org.hsqldb.jdbc.jdbcPreparedStatement.(Unknown Source)
at org.hsqldb.jdbc.jdbcConnection.prepareStatement(Unknown Source)
at org.springframework.jdbc.core.JdbcTemplate$SimplePreparedStatementCreator.createPreparedStatement(JdbcTemplate.java:1436)
at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:581)
... 82 more

Re: SQL error

PostPosted: Sat Jul 13, 2013 9:29 pm
by flvinny521
Is this a new install? Did you complete the step where you input the postgres password into the musiccabinet web interface?

Re: SQL error

PostPosted: Sun Jul 14, 2013 4:27 am
by MoreTrife
flvinny521 wrote:Is this a new install? Did you complete the step where you input the postgres password into the musiccabinet web interface?


how do you do this? i am getting the same error. thanks.

Re: SQL error

PostPosted: Mon Jul 15, 2013 12:46 pm
by Geissler
flvinny521 wrote:Is this a new install? Did you complete the step where you input the postgres password into the musiccabinet web interface?

No, I never got that far. This error screen shows up before I can even see the login window.

Re: SQL error

PostPosted: Tue Jul 16, 2013 1:15 pm
by flvinny521
Geissler wrote:No, I never got that far. This error screen shows up before I can even see the login window.


OK, then this is beyond my capabilities to answer! I just know that was one thing that I forgot during a recent re-installation. I have no idea what your log means, just hoping for a lucky guess.

MoreTrife, does your error pop up before you can log in as well?

Re: SQL error

PostPosted: Tue Jul 16, 2013 8:53 pm
by shadow.8
Just a thought, what version of PostgreSQL do you have?

Re: SQL error

PostPosted: Tue Jul 16, 2013 9:36 pm
by Geissler
The newest. Not sure right now because I'm away from home, but could someone guide me through the installation steps once more? It's not very clear on the musiccabinet site

edit: 9.2.4

Re: SQL error

PostPosted: Tue Oct 22, 2013 9:38 pm
by achmetinternet
I get the same error!

EDIT: glad the forum is back. Just for reference, I am using Fedora and followed this guide:

http://virtuallyhyper.com/2013/02/insta ... -subsonic/

But it didn't work :(

Re: SQL error

PostPosted: Thu Oct 31, 2013 3:53 am
by KicknGuitar
Odd I was getting this for a day or two. Then everything worked fine again.
Attempting to reinstall PostgreSQL, I found it was just updated so I installed the new version. Restarted but no luck. Yet, later that day I tried connecting to the server and it magically wasn't giving me the error anymore.

I doubt this is useful but I figured I'd put it out there just incase. Good luck.