Another error trying to upgrade

5 posts, 0 answers
  1. cayates
    cayates avatar
    71 posts
    Member since:
    Feb 2007

    Posted 18 Nov 2008 Link to this post

    After fixing the error in my last thread I started getting another error that was not there before the switch to the Telerik version.

    It started throwing this error:

    Error executing query: Telerik.OpenAccess.RT.sql.SQLException: ORA-01008: not all variables bound

       at Telerik.OpenAccess.RT.Adonet2Generic.Impl.PreparedStatementImp.executeQuery()
       at OpenAccessRuntime.jdbc.conn.PooledPSWithParamLogging.executeQuery()
       at OpenAccessRuntime.jdbc.fetch.FetchResultImp.execute()
    SQL:
    SELECT b."USER_ID", c."ID", c."NAME" FROM "CF_USERS" a JOIN "CF_USER_ROLES" b ON (a."ID" = b."USER_ID") JOIN "CF_ROLES" c ON (b."ROLE_ID" = c."ID") WHERE a."ID" = ?         ORDER BY 1  Telerik.OpenAccess.RT.sql.SQLException: ORA-01008: not all variables bound

       at Telerik.OpenAccess.RT.Adonet2Generic.Impl.PreparedStatementImp.executeQuery()
       at OpenAccessRuntime.jdbc.conn.PooledPSWithParamLogging.executeQuery()
       at OpenAccessRuntime.jdbc.fetch.FetchResultImp.execute()

    The users class is tied to the roles class with a many-many.  The error is thrown when lazy-loading the roles collection.  Here are their app.config entries:

              <class name="Role"
                <extension key="db-do-not-create-table" value="true" /> 
                <extension key="db-table-name" value="CF_ROLES" /> 
                <field name="id"
                  <extension key="db-column"
                    <extension key="db-type" value="DECIMAL" /> 
                    <extension key="db-column-name" value="ID" /> 
                    <extension key="db-length" value="10" /> 
                  </extension> 
                </field> 
                <field name="name"
                  <extension key="db-column"
                    <extension key="db-type" value="VARCHAR" /> 
                    <extension key="db-column-name" value="NAME" /> 
                    <extension key="db-length" value="50" /> 
                  </extension> 
                </field> 
                <field name="privileges"
                  <collection> 
                    <extension key="inverse" value="role" /> 
                  </collection> 
                </field> 
                <field name="roles"
                  <collection> 
                    <extension key="db-link-table"
                      <extension key="db-table-name" value="CF_ROLE_ROLES" /> 
                      <extension key="db-owner-ref"
                        <extension key="db-column"
                          <extension key="db-type" value="DECIMAL" /> 
                          <extension key="db-column-name" value="PARENT_ROLE_ID" /> 
                          <extension key="db-length" value="10" /> 
                        </extension> 
                      </extension> 
                      <extension key="db-value"
                        <extension key="db-column"
                          <extension key="db-type" value="DECIMAL" /> 
                          <extension key="db-column-name" value="CHILD_ROLE_ID" /> 
                          <extension key="db-length" value="10" /> 
                        </extension> 
                      </extension> 
                    </extension> 
                    <extension key="ordered" value="false" /> 
                  </collection> 
                </field> 
                <field name="users"
                  <collection> 
                    <extension key="inverse" value="roles" /> 
                  </collection> 
                </field> 
                <extension key="db-optimistic-locking" value="changed" /> 
              </class> 
              <class name="User"
                <extension key="db-do-not-create-table" value="true" /> 
                <extension key="db-table-name" value="CF_USERS" /> 
                <field name="id"
                  <extension key="db-column"
                    <extension key="db-type" value="DECIMAL" /> 
                    <extension key="db-column-name" value="ID" /> 
                    <extension key="db-length" value="10" /> 
                  </extension> 
                </field> 
                <field name="email"
                  <extension key="db-column"
                    <extension key="db-type" value="VARCHAR" /> 
                    <extension key="db-column-name" value="EMAIL" /> 
                    <extension key="db-length" value="100" /> 
                  </extension> 
                </field> 
                <field name="username"
                  <extension key="db-column"
                    <extension key="db-type" value="VARCHAR" /> 
                    <extension key="db-column-name" value="USERNAME" /> 
                    <extension key="db-length" value="50" /> 
                  </extension> 
                </field> 
                <field name="privileges"
                  <collection> 
                    <extension key="inverse" value="user" /> 
                  </collection> 
                </field> 
                <field name="roles"
                  <collection> 
                    <extension key="db-link-table"
                      <extension key="db-table-name" value="CF_USER_ROLES" /> 
                      <extension key="db-owner-ref"
                        <extension key="db-column"
                          <extension key="db-type" value="DECIMAL" /> 
                          <extension key="db-column-name" value="USER_ID" /> 
                          <extension key="db-length" value="10" /> 
                        </extension> 
                      </extension> 
                      <extension key="db-value"
                        <extension key="db-column"
                          <extension key="db-type" value="DECIMAL" /> 
                          <extension key="db-column-name" value="ROLE_ID" /> 
                          <extension key="db-length" value="10" /> 
                        </extension> 
                      </extension> 
                    </extension> 
                    <extension key="ordered" value="false" /> 
                  </collection> 
                </field> 
                <extension key="db-optimistic-locking" value="changed" /> 
                <extension key="db-index" value="USERS_U_USERNAME_1"
                  <extension key="field-name" value="username" /> 
                  <extension key="db-unique" value="true" /> 
                  <extension key="db-clustered" value="true" /> 
                </extension> 
              </class> 

    Please help, thank you.


  2. Thomas
    Admin
    Thomas avatar
    590 posts

    Posted 19 Nov 2008 Link to this post

    Hello Chris,

    i tried but could not reproduce the error as you described it. Please find my test attached.

    Best regards,
    Thomas
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. DevCraft banner
  4. cayates
    cayates avatar
    71 posts
    Member since:
    Feb 2007

    Posted 19 Nov 2008 Link to this post

    There must be a difference between our environments that is contributing to the error because I get the same thing with your example.  Except this time it is a compile time error instead of a runtime exception.

    Here's what I did...I opened your example project, changed the connection settings for use with my database, and then attempted to run the project.  It created the tables (rle, usr, usr_rle) in my schema and then displayed this error.

    Here is a screenshot of the error.

    My database is Oracle 10.2.0.3.  I'm using VS 2008 .NET 3.5 (no SP1 installed yet).  Windows XP Pro, database on RHEL3.

    Thanks,

    Chris
  5. cayates
    cayates avatar
    71 posts
    Member since:
    Feb 2007

    Posted 19 Nov 2008 Link to this post

    I take that back.  I was connecting to an oracle 10.2.0.1 instance which was giving the error.  I switched to an oracle 10.2.0.3 instance and the error went away.  Is there a known issue or bug with 10.2.0.1 and Open Access?  Or do you know of a setting I could look into for the 10.2.0.1 instance to work?

    Thanks,

    Chris
  6. Thomas
    Admin
    Thomas avatar
    590 posts

    Posted 20 Nov 2008 Link to this post

    Hi Chris,

    I've not heard about such an issue yet. And - I'm using Oracle XE myself and that has the 10.2.1 number attached to it. I really suspect a client side problem here, please check your path settings and which dlls are loaded in your application.

    Regards,
    Thomas
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Back to Top
DevCraft banner