Options

varbinary in RTC

RobySpainRobySpain Member Posts: 57
edited 2011-04-26 in NAV Three Tier
Hi Experts,

I explain my problem. I have a NAV4 sql database. Someone update it to NAV2009 but only to the classic version. Now I am installing the RTC. My first problem was to change some fields from binary to text, because the RCT do not want this fields.

Now, when try to change some data in this table (in NAV or open directly the SQL Manager to do it) give me an Error:

"The following SQL Server error occurred when accesing the Customer table:
257,"42000",[Microsoft][ODBC SQL Server Driver][SQL Server]No se permite la conversión implícita del tipo de datos varchar a varbinary. Utilice la función CONVERT para ejecutar esta consulta." Not allowed implicit conversion of data type varchar to varbinary. Use the CONVERT function to run this query

This error appear when use the sentence MODIFY in the trigger OnModify of the table.

I tryed to delete these fields (binary fields) but not solve the problem.

Can you help me?? It looks as the sql server do not update the changes in the table (fields), but in the SQL Manager, the column is Varchar and not Varbinary. Any Idea???
Robyn

Comments

  • Options
    ara3nara3n Member Posts: 9,255
    Design the table in NAV and go properties and see the sql datatype. make sure it's blank and then save it.


    Actually change it back the way it was in sql. Go to NAV and make any changes required.
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
  • Options
    RobySpainRobySpain Member Posts: 57
    Hi Ara3n,

    I've changed the table in NAV from binary to Text or CODE. With TEXT do not appear the SQL DATATYPE property. With CODE, SQL DATATYPE is <Undefined>. In any case, the same error.

    I change directly the table properties in NAV. The changes are in SQL. But even if I delete the fields, I receive an error: the name of the column "namedeletecolumn" is not valid.

    Thanks for your help. Best regards,

    Robyn
  • Options
    ara3nara3n Member Posts: 9,255
    export all the data from table to a text file. create an FOB of the object.

    Drop the table from sql. Delete the record from sql from object designer.

    Import the FOB back.

    Dataport the data back.
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
Sign In or Register to comment.