User-defined datatype in a Sql Server attached tables

Neotheone70

New member
Local time
Today, 11:39
Joined
Dec 5, 2006
Messages
3
Hi all,
I'm trying to attach some table from a Sql Server database, but when I take a look to the content, I see all the fields filled by the value "#CANCELLED".
I supposed that the matter of such an issue could be the datatype used for some fields, a user-defined datatype. The only table content from the same Sql Server database I can see does not use that data type. I'm using a read-only account to access the Sql Server database. If I try to import the table, the data are imported correctly and the user-datatype is converted to text.
Any suggestions for a solution / workaround ?

Thanks

Bye
 
Have you tried a passthrough to pull the data and then use that query as your base instead of the table/view directly?
You can also use CAST(SqlColumn as VARCHAR(nn)) on the columns in a passthrough query to change the data type you see.
Any who, one suggestion.
 
Thank for your suggestion but with a passthrough query I cant modify the data.
But if I create a view in the Sql Server db, converting the columns with CAST/CONVERT then I can attach the view instead of the table itself.

That's seems to work as soon as U dont need to update the value of a converted field. One step forward anyway :)

Maybe I could try to update the converted field calling a Sql Server stored procedure...

Thanks again
 
Interesting, you stated you were using a READ ONLY account to access the data, then say you can't modify it?????????
A SP might be the way you need to go. good luck
 
So true FoFa. I started with a read-only account cause it was the only one I had at that moment... :) then I moved to a better one :p

Thanks again
 

Users who are viewing this thread

Back
Top Bottom