[appengine-java] Re: having trouble implementing gwt in existing gae app
Anybody have any thoughts on what I could be missing? On Apr 5, 9:24 pm, zackmac wrote: > I'm using Eclipse 3.4.1, GAE 1.3.1 and trying to use GWT 2.0.3. I've > been working on my GAE app some time and that's working well - just > want to spice up the front-end a little. I added a new GWT module, > entry point class and HTML page from File -> New and then copied the > appropriate js head include in my existing index.jsp page, but I'm > still getting Missing required argument 'module[s]' > Google Web Toolkit 2.0.3. When running the app, I right-click on my > project and then go to Debug As and choose Java Application. Then I > found the com.google.gwt.dev.DevMode app to run and then I get the > Missing required argument 'module[s]' error. -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] having trouble implementing gwt in existing gae app
I'm using Eclipse 3.4.1, GAE 1.3.1 and trying to use GWT 2.0.3. I've been working on my GAE app some time and that's working well - just want to spice up the front-end a little. I added a new GWT module, entry point class and HTML page from File -> New and then copied the appropriate js head include in my existing index.jsp page, but I'm still getting Missing required argument 'module[s]' Google Web Toolkit 2.0.3. When running the app, I right-click on my project and then go to Debug As and choose Java Application. Then I found the com.google.gwt.dev.DevMode app to run and then I get the Missing required argument 'module[s]' error. -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: error when trying to run gae/j app - Usage: [options]
Solution worked great - thanks! On Mar 29, 3:00 pm, Jason Parekh wrote: > Hey Zack, > > Looks like the launch configuration got into a bad state. > > Before you proceed with the solution below, could you send us a copy of the > .launch file for this launch configuration? That file will be in your > WORKSPACE/.metadata/.plugins/org.eclipse.debug.core/.launches directory. > > The solution: You can safely delete the existing launch configuration (in > Run > Run configurations), close the dialog, and then try right-clicking on > your project > Run As > Web Application. > > jason > > On Mon, Mar 29, 2010 at 1:06 PM, zackmac wrote: > > getting this message when trying to run my gae/j app in Eclipse: > > > Usage: [options] > > > Options: > > --help, -h Show this help message and exit. > > --server=SERVER The server to use to determine the latest > > -s SERVER SDK version. > > --address=ADDRESS The address of the interface on the local > > machine > > -a ADDRESS to bind to (or 0.0.0.0 for all > > interfaces). > > --port=PORT The port number to bind to on the local > > machine. > > -p PORT > > --sdk_root=root Overrides where the SDK is located. > > --disable_update_check Disable the check for newer SDK versions. > > > I was experimenting with implementing gwt in my gae/j app but decided > > not to pursue that path further. Now, I'm just trying to run the app > > and have the "use gwt" settings unchecked but am still getting this > > error. I'm using Eclipse 3.4.1 and gae/j 1.3.1 > > > -- > > You received this message because you are subscribed to the Google Groups > > "Google App Engine for Java" group. > > To post to this group, send email to > > google-appengine-j...@googlegroups.com. > > To unsubscribe from this group, send email to > > google-appengine-java+unsubscr...@googlegroups.com > > . > > For more options, visit this group at > >http://groups.google.com/group/google-appengine-java?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: error when trying to run gae/j app - Usage: [options]
This is what's in the .launch file for this app: On Mar 29, 3:00 pm, Jason Parekh wrote: > Hey Zack, > > Looks like the launch configuration got into a bad state. > > Before you proceed with the solution below, could you send us a copy of the > .launch file for this launch configuration? That file will be in your > WORKSPACE/.metadata/.plugins/org.eclipse.debug.core/.launches directory. > > The solution: You can safely delete the existing launch configuration (in > Run > Run configurations), close the dialog, and then try right-clicking on > your project > Run As > Web Application. > > jason > > On Mon, Mar 29, 2010 at 1:06 PM, zackmac wrote: > > getting this message when trying to run my gae/j app in Eclipse: > > > Usage: [options] > > > Options: > > --help, -h Show this help message and exit. > > --server=SERVER The server to use to determine the latest > > -s SERVER SDK version. > > --address=ADDRESS The address of the interface on the local > > machine > > -a ADDRESS to bind to (or 0.0.0.0 for all > > interfaces). > > --port=PORT The port number to bind to on the local > > machine. > > -p PORT > > --sdk_root=root Overrides where the SDK is located. > > --disable_update_check Disable the check for newer SDK versions. > > > I was experimenting with implementing gwt in my gae/j app but decided > > not to pursue that path further. Now, I'm just trying to run the app > > and have the "use gwt" settings unchecked but am still getting this > > error. I'm using Eclipse 3.4.1 and gae/j 1.3.1 > > > -- > > You received this message because you are subscribed to the Google Groups > > "Google App Engine for Java" group. > > To post to this group, send email to > > google-appengine-j...@googlegroups.com. > > To unsubscribe from this group, send email to > > google-appengine-java+unsubscr...@googlegroups.com > > . > > For more options, visit this group at > >http://groups.google.com/group/google-appengine-java?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] error when trying to run gae/j app - Usage: [options]
getting this message when trying to run my gae/j app in Eclipse: Usage: [options] Options: --help, -h Show this help message and exit. --server=SERVERThe server to use to determine the latest -s SERVER SDK version. --address=ADDRESS The address of the interface on the local machine -a ADDRESS to bind to (or 0.0.0.0 for all interfaces). --port=PORTThe port number to bind to on the local machine. -p PORT --sdk_root=rootOverrides where the SDK is located. --disable_update_check Disable the check for newer SDK versions. I was experimenting with implementing gwt in my gae/j app but decided not to pursue that path further. Now, I'm just trying to run the app and have the "use gwt" settings unchecked but am still getting this error. I'm using Eclipse 3.4.1 and gae/j 1.3.1 -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: jdoql contains method
I followed the instructions presented by Google on the contains filter (:p.contains(lastName) but couldn't get it to work. I just decided to return the full record set and then use Java's contains method (ironically) to test each particular record contained the string in question. There's more than one way to skin a cat... On Dec 29 2009, 10:47 am, Chau Huynh wrote: > http://code.google.com/appengine/docs/java/datastore/queriesandindexe... > In "Query Filters" section, it mentions that "A filter specifies a field > name, an operator, and a value. The value must be provided by the app; it > cannot refer to another field, or be calculated in terms of other fields." > so it seems to me "desc.contains(ing)" filter might cause the issue. > > On Sun, Dec 27, 2009 at 4:19 AM, zackmac wrote: > > I'm trying to use the contains method in a query and having some > > trouble. The query is formatted like this: > > > "select from Transactions where userName == 'auser' && account == > > 'anAccount' && desc.contains(ing) order by transDate desc, > > categoryName" > > > desc is a column in my Transactions table. Don't think I'm quite > > understanding how the contains method works and how to implement in a > > query. > > > I get this error returned on my jsp when I try to run that query: > > org.datanucleus.store.appengine.query.DatastoreQuery > > $UnsupportedDatastoreFeatureException: Problem with query > > > -- > > > You received this message because you are subscribed to the Google Groups > > "Google App Engine for Java" group. > > To post to this group, send email to > > google-appengine-j...@googlegroups.com. > > To unsubscribe from this group, send email to > > google-appengine-java+unsubscr...@googlegroups.com > > . > > For more options, visit this group at > >http://groups.google.com/group/google-appengine-java?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Using UserService credentials with a SpreadsheetService
In my GAE/J web application, users authenticate via their google account. I check to see they've signed into google via this code in my jsp: UserService userService = UserServiceFactory.getUserService(); User user = userService.getCurrentUser(); if (user == null) response.sendRedirect("/index.jsp"); Is there anyway to use the user object above to query for that user's spreadsheets? I'm thinking that it would involve using user.getAuthDomain() but not sure if I'm right here. For instance, would this work?... service.setAuthSubToken(user.getAuthDomain()); -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: google docs error when trying to retrieve docs in GAE/J
I've tried looping through the document list as you suggested in number 2 by running the below code: for (int x = 0; x < 10; x ++) { try { DocumentListFeed feed = service.getFeed(documentListFeedUrl, DocumentListFeed.class); for (DocumentListEntry entry : feed.getEntries()) { System.out.println(entry.getTitle().getPlainText()); } } catch (Exception ex) { System.out.println("Document List error " + x + ": " + ex.toString()); } } Still unfortunately getting the "com.google.gdata.util.ResourceNotFoundException: Not Found" error - I'm using Eclipse for my IDE - I have has imported libraries the following: import java.net.URL; import com.google.gdata.client.docs.DocsService; import com.google.gdata.data.docs.DocumentListEntry; import com.google.gdata.data.docs.DocumentListFeed; Shouldn't need anything else, right? Also, I don't have a "bin" folder - I have a "lib" folder though... Thanks. On Dec 27, 2:24 am, Lior Harsat wrote: > Hi Zack, > > I has some (bad) experience with the google docs api. > there are two options that I know of that might cause the error you > see. > 1. you have a missing jar in your bin folder. > 2. GAE strange behavior I've noticed (not sure If i should call it a > bug). > > I assume you have explorer option one and it is not the case. > regarding option 2. I have witnessed the following: > a. many times a call to the DocsService.get*** will fail with no > apparent reason. subsequent calls may succeed. What I did is , I've > set a retry counter and simply caught the exceptions and retried > calling them. for most api setting the counter to 5 did the trick. for > others I needed 10. > b. the code examples in google docs code simply didn't work. In order > to work around this issue I played around with the API until I was > able to hack something. (use the local GAE for these games). > > I know my answer may not be a solution for you but at least its nice > to know that I wasn't the only one having issues with Google Docs > APIs. > > Thanx. Lior > > On Dec 27, 3:03 am, zackmac wrote: > > > I'm just trying to do an initial google docs example but am getting an > > error at the DocumentListFeed call (DocumentListFeed feed = > > service.getFeed(documentListFeedUrl, DocumentListFeed.class)): > > > com.google.gdata.util.ResourceNotFoundException: Not Found > > > This is my full code listing (with user and pwd changed): > > > DocsService service = new DocsService("TEST"); > > service.setUserCredentials("my_u...@gmail.com","my_pwd"); > > URL documentListFeedUrl = new URL("http://docs.google.com/feeds/ > > documents/private/full"); > > DocumentListFeed feed = service.getFeed(documentListFeedUrl, > > DocumentListFeed.class); > > > I've read some forums on this but it seems like I have everything in > > place that's needed... > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: google docs error when trying to retrieve docs in GAE/J
Nevermind - found out the problemo - was using the wrong URL - the original URL I used was "http://docs.google.com/feeds/documents/private/full";. Read another post and found it should be "http://docs.google.com/feeds/default/private/full"; - Just a little different but that did the trick... On Dec 27, 2:24 am, Lior Harsat wrote: > Hi Zack, > > I has some (bad) experience with the google docs api. > there are two options that I know of that might cause the error you > see. > 1. you have a missing jar in your bin folder. > 2. GAE strange behavior I've noticed (not sure If i should call it a > bug). > > I assume you have explorer option one and it is not the case. > regarding option 2. I have witnessed the following: > a. many times a call to the DocsService.get*** will fail with no > apparent reason. subsequent calls may succeed. What I did is , I've > set a retry counter and simply caught the exceptions and retried > calling them. for most api setting the counter to 5 did the trick. for > others I needed 10. > b. the code examples in google docs code simply didn't work. In order > to work around this issue I played around with the API until I was > able to hack something. (use the local GAE for these games). > > I know my answer may not be a solution for you but at least its nice > to know that I wasn't the only one having issues with Google Docs > APIs. > > Thanx. Lior > > On Dec 27, 3:03 am, zackmac wrote: > > > I'm just trying to do an initial google docs example but am getting an > > error at the DocumentListFeed call (DocumentListFeed feed = > > service.getFeed(documentListFeedUrl, DocumentListFeed.class)): > > > com.google.gdata.util.ResourceNotFoundException: Not Found > > > This is my full code listing (with user and pwd changed): > > > DocsService service = new DocsService("TEST"); > > service.setUserCredentials("my_u...@gmail.com","my_pwd"); > > URL documentListFeedUrl = new URL("http://docs.google.com/feeds/ > > documents/private/full"); > > DocumentListFeed feed = service.getFeed(documentListFeedUrl, > > DocumentListFeed.class); > > > I've read some forums on this but it seems like I have everything in > > place that's needed... > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] google docs error when trying to retrieve docs in GAE/J
I'm just trying to do an initial google docs example but am getting an error at the DocumentListFeed call (DocumentListFeed feed = service.getFeed(documentListFeedUrl, DocumentListFeed.class)): com.google.gdata.util.ResourceNotFoundException: Not Found This is my full code listing (with user and pwd changed): DocsService service = new DocsService("TEST"); service.setUserCredentials("my_u...@gmail.com","my_pwd"); URL documentListFeedUrl = new URL("http://docs.google.com/feeds/ documents/private/full"); DocumentListFeed feed = service.getFeed(documentListFeedUrl, DocumentListFeed.class); I've read some forums on this but it seems like I have everything in place that's needed... -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] jdoql contains method
I'm trying to use the contains method in a query and having some trouble. The query is formatted like this: "select from Transactions where userName == 'auser' && account == 'anAccount' && desc.contains(ing) order by transDate desc, categoryName" desc is a column in my Transactions table. Don't think I'm quite understanding how the contains method works and how to implement in a query. I get this error returned on my jsp when I try to run that query: org.datanucleus.store.appengine.query.DatastoreQuery $UnsupportedDatastoreFeatureException: Problem with query -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: javax.jdo.JDOObjectNotFoundException: Could not retrieve entity of kind Transactions with key Transactions(Transactions(67))
Finally found a way in case anybody was curious... Unfortunately, I have to loop through all of my pertinent records until I have a match on the keys. If anyone can suggest a different way (that works) that's more efficient than below, do tell... Query query = pm.newQuery(Categories.class, "userName == '" + user.getNickname() + "'"); List results = (List) query.execute(); for (Categories cat : results) { if (cat.getKey().toString().equals(reqParm)) { pm.deletePersistent(cat); } } query.closeAll(); I appreciate the input of datanucleus though he/she wasn't able to ultimately lead me to the solution. -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: javax.jdo.JDOObjectNotFoundException: Could not retrieve entity of kind Transactions with key Transactions(Transactions(67))
"com.google.appengine.api.datastore.Key:Categories(76)" is what's returned on the insert: Categories category = new Categories(user.getNickname(), account, categoryName); pm.makePersistent(category); Object o = JDOHelper.getObjectId(category); System.out.println(o.toString()); This is what's returned when doing the delete: Dec 4, 2009 12:57:54 PM org.datanucleus.jdo.JDOAdapter getNewSingleFieldIdentity SEVERE: Error encountered while creating SingleFieldIdentity instance of type "javax.jdo.identity.ObjectIdentity" Dec 4, 2009 12:57:54 PM org.datanucleus.jdo.JDOAdapter getNewSingleFieldIdentity SEVERE: java.lang.reflect.InvocationTargetException Dec 4, 2009 12:57:54 PM com.google.apphosting.utils.jetty.JettyLogger warn WARNING: /categories java.lang.NullPointerException at ma.CategoriesServlet.doPost(CategoriesServlet.java:61) at javax.servlet.http.HttpServlet.service(HttpServlet.java:713) at javax.servlet.http.HttpServlet.service(HttpServlet.java:806) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java: 487) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1093) at com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter (TransactionCleanupFilter.java:43) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1084) at org.mortbay.jetty.servlet.ServletHandler.handle (ServletHandler.java:360) at org.mortbay.jetty.security.SecurityHandler.handle (SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle (SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle (ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java: 405) at com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle (DevAppEngineWebAppContext.java:54) at org.mortbay.jetty.handler.HandlerWrapper.handle (HandlerWrapper.java:139) at com.google.appengine.tools.development.JettyContainerService $ApiProxyHandler.handle(JettyContainerService.java:306) at org.mortbay.jetty.handler.HandlerWrapper.handle (HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:313) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java: 506) at org.mortbay.jetty.HttpConnection$RequestHandler.content (HttpConnection.java:844) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:644) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381) at org.mortbay.io.nio.SelectChannelEndPoint.run (SelectChannelEndPoint.java:396) at org.mortbay.thread.BoundedThreadPool$PoolThread.run (BoundedThreadPool.java:442) Which log are you referring to? Can you point me to where it would be on my computer? On Dec 3, 7:36 am, datanucleus wrote: > > This is strange - when I retrieve the object after persisting via > > "JDOHelper.getObjectId(obj)", I get an object back no problem. > > Yes, but you haven't told us what is the "id" returned by that method. > And whats in the log when you invoke that pm.getObjectById ... ? > > > Then,before trying to delete the object, I do "pm.newObjectIdInstance > > (Categories.class, key)" and I get a NullPointerException. > > Perhaps if you post the actual exception and stack trace, cos without > it it means very little. > ANd whats in the log ? -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: javax.jdo.JDOObjectNotFoundException: Could not retrieve entity of kind Transactions with key Transactions(Transactions(67))
This is strange - when I retrieve the object after persisting via "JDOHelper.getObjectId(obj)", I get an object back no problem. Then, before trying to delete the object, I do "pm.newObjectIdInstance (Categories.class, key)" and I get a NullPointerException. I know in this post I've put in "Categories", but I'm doing the same thing using the Categories class as I am the Transactions class - the Categories class is just easier to work with. On Dec 3, 12:22 am, datanucleus wrote: > > Anybody have any other ideas? > > I already told you my idea, and don't see that you have checked those > things. Why not just do that ? -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: javax.jdo.JDOObjectNotFoundException: Could not retrieve entity of kind Transactions with key Transactions(Transactions(67))
I've been away for a week visiting with my wife's family but checked today to see if there was any new posts on this issue. None, unfortunately. Anybody have any other ideas? On Nov 21, 10:37 am, zackmac wrote: > Ok - before trying to delete the specific Transacation, I'm looping > through all Transactions to check if the delete request parm is the > same as Transaction.getKey().toString ["if (trans.getKey().toString > ().equals(reqParm)"]. This is returning true. Isn't that evidence > enough that the key exists? > > On Nov 21, 9:38 am, datanucleus wrote: > > > > Let me be more specific about what's happening... > > > Not sure why we need to know what your app does; an object has a JDO > > identity, set when you persist it, and that identity has to be used > > when finding it. If you put in something else then you get an > > exception. > > > When you persist your object what is its "identity" ? i.e > > JDOHelper.getObjectId(obj); > > > What is "pm.newObjectIdInstance(Transactions.class, key)" ? > > > If they aren't the same then you're putting the wrong "key" in. > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: javax.jdo.JDOObjectNotFoundException: Could not retrieve entity of kind Transactions with key Transactions(Transactions(67))
Ok - before trying to delete the specific Transacation, I'm looping through all Transactions to check if the delete request parm is the same as Transaction.getKey().toString ["if (trans.getKey().toString ().equals(reqParm)"]. This is returning true. Isn't that evidence enough that the key exists? On Nov 21, 9:38 am, datanucleus wrote: > > Let me be more specific about what's happening... > > Not sure why we need to know what your app does; an object has a JDO > identity, set when you persist it, and that identity has to be used > when finding it. If you put in something else then you get an > exception. > > When you persist your object what is its "identity" ? i.e > JDOHelper.getObjectId(obj); > > What is "pm.newObjectIdInstance(Transactions.class, key)" ? > > If they aren't the same then you're putting the wrong "key" in. -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=.
[appengine-java] Re: javax.jdo.JDOObjectNotFoundException: Could not retrieve entity of kind Transactions with key Transactions(Transactions(67))
Let me be more specific about what's happening... 1. In my jsp, I loop through a list of Transactions and display them in a table. At the right-most column, there's a delete button. 2. When that delete button is pushed, an indicator ("delete") plus Transaction.getKey() are stored as a request parameter. Also, a servlet is called to handle the delete button click. 3. Inside the servlet, this is the code that's used to process any request parm that has delete in it... for (Enumeration e = req.getParameterNames(); e.hasMoreElements ();) { parms = (String)e.nextElement(); System.out.println("parm="+parms); if (parms.contains("delete")) { recordDelete = true; Transactions trans = pm.getObjectById(Transactions.class, parms.replace("delete", "")); pm.deletePersistent(trans); System.out.println("Key=" + parms.replace ("delete", "")); } } 4. And, of course, when trying to use getObjectById, that's when the exception is thrown. I'm hoping someone can comment on this. I'm sure it's an easy fix to get around the problem... some little thing I'm just not seeing. On Nov 20, 7:21 am, zackmac wrote: > I figured I was - "parms.replace("delete",""))" - if the key is an > unencrypted string, I though I could just pass it in... > > On Nov 19, 1:21 pm, datanucleus wrote: > > > > Not sure what I'm missing here... > > > Putting the correct identity "key" in ? > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=.
[appengine-java] Re: javax.jdo.JDOObjectNotFoundException: Could not retrieve entity of kind Transactions with key Transactions(Transactions(67))
I figured I was - "parms.replace("delete",""))" - if the key is an unencrypted string, I though I could just pass it in... On Nov 19, 1:21 pm, datanucleus wrote: > > Not sure what I'm missing here... > > Putting the correct identity "key" in ? -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=.
[appengine-java] javax.jdo.JDOObjectNotFoundException: Could not retrieve entity of kind Transactions with key Transactions(Transactions(67))
I'm trying to delete a record and having some trouble. When a delete button is pushed on a jsp, the key associated with the delete button is being passed to a servlet (the delete button is attached to a list of Transactions). But, I get an exception on this code: Transactions trans = pm.getObjectById(Transactions.class, parms.replace ("delete", "")); pm.deletePersistent(trans); Not sure what I'm missing here... -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=.