2009-12-31 4 views
0

1. 엔티티를 유지할 수 있고 _admin에서 키, 아이디/이름을 볼 수 있습니다. 총 6 결과. 하지만 왜 내 엔터티 클래스 내부의 모든 속성을 표시하지?GAE는 지속 할 수 있지만 (createQuery) 엔티티를로드 할 수 없습니다.


2. createQuery를 사용하려고하면 객체를로드 할 수 없습니다. 콘솔에 오류가 없습니다. 코드가 방금 query.getResultList();

14:41:31,047 DEBUG [DataNucleus.Persistence] - Object Manager "[email protected]" opened for datastore "[email protected]" 
14:41:31,047 DEBUG [DataNucleus.Persistence] - Object Manager "[email protected]" opened for datastore "[email protected]" 
14:41:31,202 DEBUG [DataNucleus.Persistence] - Object Manager "[email protected]" closed 
14:41:31,202 DEBUG [DataNucleus.Persistence] - Object Manager "[email protected]" closed 

내가 데이터 저장소 뷰어에서 _admin

Key  ID/Name 
agt0ZXN0ZXRlZnNkZnIOCxIIdXNlcnRlc3QYAQw  1 
agt0ZXN0ZXRlZnNkZnIOCxIIdXNlcnRlc3QYAgw  2 
agt0ZXN0ZXRlZnNkZnIOCxIIdXNlcnRlc3QYAww  3 
agt0ZXN0ZXRlZnNkZnIOCxIIdXNlcnRlc3QYBAw  4 
agt0ZXN0ZXRlZnNkZnIOCxIIdXNlcnRlc3QYBQw  5 
agt0ZXN0ZXRlZnNkZnIOCxIIdXNlcnRlc3QYBgw  6 
agt0ZXN0ZXRlZnNkZnIOCxIIdXNlcnRlc3QYBww  7 
+0

1. 보이지 않는 엔티티 클래스의 속성에 대해 자세히 설명 할 수 있습니까? (여기에 엔터티 클래스를 게시 할 수도 있습니다) 2. "코드가 막혔습니다." 오류없이? 콘솔의 로그 파일에 있습니까? – aldrin

답변

1

에서 무엇을보고

public <T> List<T> list(Class<T> entityClass) { 
      //String queryStr = " from " + entityClass.getName(); 
      String queryStr= "select c from com.test.testing.model.Usertest c"; 
      Query query=entityManager.createQuery(queryStr); 

      return (List<T>) query.getResultList(); 
    } 

, 당신은 클릭하여 개체의 모든 속성을 볼 수있을 것 같은 내 DAO 모양 첫 번째 열의 링크

미안하지만 두 번째 질문에 도움이되지 않습니다. 저는 파이썬 인입니다.

+0

클릭 할 링크가 없습니다. 위의 내용을 추가했습니다. – cometta

+0

아마도 다른 SDK에 의해 노출 된 데이터 저장소 뷰어에는 비슷한 기능이 없습니다. 이 기법은 Python SDK와 잘 어울립니다. –

관련 문제