Error: Out of range value adjusted for column 'EngrAlertForNewQuestions' at row 1

Discussion in 'ASP .Net' started by Bobby Edward, Oct 5, 2008.

  1. Bobby Edward

    Bobby Edward Guest

    This line of code...

    Using db As New dsUsersTableAdapters.useroptionsTableAdapter

    Produces this error:

    Out of range value adjusted for column 'EngrAlertForNewQuestions' at row
    1

    Any idea what this means?

    FYI: The dsUsersTableAdapter is part of the XSD dataset that I
    automatically generated. It's defined as such...

    <TableAdapter BaseClass="System.ComponentModel.Component"
    DataAccessorModifier="AutoLayout, AnsiClass, Class, Public"
    DataAccessorName="useroptionsTableAdapter"
    GeneratorDataComponentClassName="useroptionsTableAdapter" Name="useroptions"
    UserDataComponentName="useroptionsTableAdapter">
    <MainSource>
    <DbSource ConnectionRef="MyProjectConnectionString
    (Web.config)" DbObjectName="MyProject.useroptions" DbObjectType="Table"
    FillMethodModifier="Public" FillMethodName="Fill" GenerateMethods="Both"
    GenerateShortCommands="true" GeneratorGetMethodName="GetData"
    GeneratorSourceName="Fill" GetMethodModifier="Public"
    GetMethodName="GetData" QueryType="Rowset" ScalarCallRetval="System.Object,
    mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
    UseOptimisticConcurrency="false" UserGetMethodName="GetData"
    UserSourceName="Fill">
    <DeleteCommand>
    <DbCommand CommandType="Text" ModifiedByUser="false">
    <CommandText>DELETE FROM `MyProject`.`useroptions` WHERE
    ((`UserOptionId` = :Original_UserOptionId))</CommandText>
    <Parameters>
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Int64" Direction="Input"
    ParameterName="Original_UserOptionId" Precision="0" ProviderType="BigInt"
    Scale="0" Size="0" SourceColumn="UserOptionId"
    SourceColumnNullMapping="false" SourceVersion="Original" />
    </Parameters>
    </DbCommand>
    </DeleteCommand>
    <InsertCommand>
    <DbCommand CommandType="Text" ModifiedByUser="false">
    <CommandText>INSERT INTO `MyProject`.`useroptions`
    (`MyProjectUserId`, `EngrAlertForNewQuestions`, `BBTagProjectResults`,
    `BBNotifyNewMatchingProjects`, `TPNotifyIfChange`, `IncludeInMyProjectDir`,
    `OptOutCommunication`) VALUES :)MyProjectUserId, :EngrAlertForNewQuestions,
    :BBTagProjectResults, :BBNotifyNewMatchingProjects, :TPNotifyIfChange,
    :IncludeInMyProjectDir, :OptOutCommunication)</CommandText>
    <Parameters>
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Int64" Direction="Input"
    ParameterName="MyProjectUserId" Precision="0" ProviderType="BigInt"
    Scale="0" Size="0" SourceColumn="MyProjectUserId"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="EngrAlertForNewQuestions" Precision="0"
    ProviderType="TinyInt" Scale="0" Size="0"
    SourceColumn="EngrAlertForNewQuestions" SourceColumnNullMapping="false"
    SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="BBTagProjectResults" Precision="0" ProviderType="TinyInt"
    Scale="0" Size="0" SourceColumn="BBTagProjectResults"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="BBNotifyNewMatchingProjects" Precision="0"
    ProviderType="TinyInt" Scale="0" Size="0"
    SourceColumn="BBNotifyNewMatchingProjects" SourceColumnNullMapping="false"
    SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="TPNotifyIfChange" Precision="0" ProviderType="TinyInt"
    Scale="0" Size="0" SourceColumn="TPNotifyIfChange"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="IncludeInMyProjectDir" Precision="0" ProviderType="TinyInt"
    Scale="0" Size="0" SourceColumn="IncludeInMyProjectDir"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="true" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="OptOutCommunication" Precision="0" ProviderType="TinyInt"
    Scale="0" Size="0" SourceColumn="OptOutCommunication"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    </Parameters>
    </DbCommand>
    </InsertCommand>
    <SelectCommand>
    <DbCommand CommandType="Text" ModifiedByUser="true">
    <CommandText>SELECT UserOptionId, MyProjectUserId,
    EngrAlertForNewQuestions, BBTagProjectResults, BBNotifyNewMatchingProjects,
    TPNotifyIfChange, IncludeInMyProjectDir,
    OptOutCommunication
    FROM useroptions</CommandText>
    <Parameters />
    </DbCommand>
    </SelectCommand>
    <UpdateCommand>
    <DbCommand CommandType="Text" ModifiedByUser="false">
    <CommandText>UPDATE `MyProject`.`useroptions` SET
    `MyProjectUserId` = :MyProjectUserId, `EngrAlertForNewQuestions` =
    :EngrAlertForNewQuestions, `BBTagProjectResults` = :BBTagProjectResults,
    `BBNotifyNewMatchingProjects` = :BBNotifyNewMatchingProjects,
    `TPNotifyIfChange` = :TPNotifyIfChange, `IncludeInMyProjectDir` =
    :IncludeInMyProjectDir, `OptOutCommunication` = :OptOutCommunication WHERE
    ((`UserOptionId` = :Original_UserOptionId))</CommandText>
    <Parameters>
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Int64" Direction="Input"
    ParameterName="MyProjectUserId" Precision="0" ProviderType="BigInt"
    Scale="0" Size="0" SourceColumn="MyProjectUserId"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="EngrAlertForNewQuestions" Precision="0"
    ProviderType="TinyInt" Scale="0" Size="0"
    SourceColumn="EngrAlertForNewQuestions" SourceColumnNullMapping="false"
    SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="BBTagProjectResults" Precision="0" ProviderType="TinyInt"
    Scale="0" Size="0" SourceColumn="BBTagProjectResults"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="BBNotifyNewMatchingProjects" Precision="0"
    ProviderType="TinyInt" Scale="0" Size="0"
    SourceColumn="BBNotifyNewMatchingProjects" SourceColumnNullMapping="false"
    SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="TPNotifyIfChange" Precision="0" ProviderType="TinyInt"
    Scale="0" Size="0" SourceColumn="TPNotifyIfChange"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="IncludeInMyProjectDir" Precision="0" ProviderType="TinyInt"
    Scale="0" Size="0" SourceColumn="IncludeInMyProjectDir"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="true" AutogeneratedName=""
    DataSourceName="" DbType="Byte" Direction="Input"
    ParameterName="OptOutCommunication" Precision="0" ProviderType="TinyInt"
    Scale="0" Size="0" SourceColumn="OptOutCommunication"
    SourceColumnNullMapping="false" SourceVersion="Current" />
    <Parameter AllowDbNull="false" AutogeneratedName=""
    DataSourceName="" DbType="Int64" Direction="Input"
    ParameterName="Original_UserOptionId" Precision="0" ProviderType="BigInt"
    Scale="0" Size="0" SourceColumn="UserOptionId"
    SourceColumnNullMapping="false" SourceVersion="Original" />
    </Parameters>
    </DbCommand>
    </UpdateCommand>
    </DbSource>
    </MainSource>
    <Mappings>
    <Mapping SourceColumn="UserOptionId"
    DataSetColumn="UserOptionId" />
    <Mapping SourceColumn="MyProjectUserId"
    DataSetColumn="MyProjectUserId" />
    <Mapping SourceColumn="EngrAlertForNewQuestions"
    DataSetColumn="EngrAlertForNewQuestions" />
    <Mapping SourceColumn="BBTagProjectResults"
    DataSetColumn="BBTagProjectResults" />
    <Mapping SourceColumn="BBNotifyNewMatchingProjects"
    DataSetColumn="BBNotifyNewMatchingProjects" />
    <Mapping SourceColumn="TPNotifyIfChange"
    DataSetColumn="TPNotifyIfChange" />
    <Mapping SourceColumn="IncludeInMyProjectDir"
    DataSetColumn="IncludeInMyProjectDir" />
    <Mapping SourceColumn="OptOutCommunication"
    DataSetColumn="OptOutCommunication" />
    </Mappings>
    <Sources />
    </TableAdapter>
     
    Bobby Edward, Oct 5, 2008
    #1
    1. Advertising

  2. Bobby Edward

    Bobby Edward Guest

    I figured it out. For some STRANGE reason the dataset wizard changed all my
    BOOLEAN fields to BYTES!!!!!

    When I passed "False" to the function it passed "255" for some reason. The
    MySQL db was probably expecting 1 or 0.

    This is crazy!!!!
     
    Bobby Edward, Oct 5, 2008
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Paul

    URL case is adjusted?

    Paul, Mar 4, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    365
    Eric Lawrence [MSFT]
    Mar 5, 2004
  2. Alec MacLean
    Replies:
    1
    Views:
    325
    bruce barker \(sqlwork.com\)
    Nov 13, 2006
  3. Borr
    Replies:
    1
    Views:
    150
    Dino Chiesa [Microsoft]
    Oct 28, 2003
  4. Paul

    URL case is adjusted?

    Paul, Mar 4, 2004, in forum: ASP .Net Web Services
    Replies:
    2
    Views:
    91
  5. Monty
    Replies:
    8
    Views:
    103
    Dr John Stockton
    Sep 9, 2003
Loading...

Share This Page