Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem tableupdating remote view
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00653475
Message ID:
00654054
Views:
21
The problem is with dbo. If you have dbo.plsis.id_plsis in your UpdateName, then you need dbo.plsis in the Tables property. Or remove all dbo and let SQL figure it out.


>>Alejandro,
>>
>>It might be best to run the GENDBC program on your view, then take a peek at the code that is generated for the view definition. If you need help interpreting the results, post the snippet of the resultant program here and we'll help you sort things out.
>>
>
>The snippet is pretty long. Not wishing to impose on the kindness of all here, I'm posting something that I think is typical about the view in question. If you need more I will be glad to add.
>
>
>FUNCTION MakeView_V_PLSIS
>***************** View setup for V_PLSIS ***************
>
>CREATE SQL VIEW "V_PLSIS" ;
>   REMOTE CONNECT "coneccion" ;
>   AS SELECT *     FROM dbo.plsis
>
>DBSetProp('V_PLSIS', 'View', 'UpdateType', 1)
>DBSetProp('V_PLSIS', 'View', 'WhereType', 1)
>DBSetProp('V_PLSIS', 'View', 'FetchMemo', .T.)
>DBSetProp('V_PLSIS', 'View', 'SendUpdates', .T.)
>DBSetProp('V_PLSIS', 'View', 'UseMemoSize', 255)
>DBSetProp('V_PLSIS', 'View', 'FetchSize', 100)
>DBSetProp('V_PLSIS', 'View', 'MaxRecords', -1)
>DBSetProp('V_PLSIS', 'View', 'Tables', 'PLSIS')
>DBSetProp('V_PLSIS', 'View', 'Prepared', .F.)
>DBSetProp('V_PLSIS', 'View', 'CompareMemo', .T.)
>DBSetProp('V_PLSIS', 'View', 'FetchAsNeeded', .F.)
>DBSetProp('V_PLSIS', 'View', 'FetchSize', 100)
>DBSetProp('V_PLSIS', 'View', 'Comment', "")
>DBSetProp('V_PLSIS', 'View', 'BatchUpdateCount', 1)
>DBSetProp('V_PLSIS', 'View', 'ShareConnection', .F.)
>
>*!* Field Level Properties for V_PLSIS -- ALEX: This is the primary key.  It is an identity column.
>* Props for the V_PLSIS.id_plsis field.
>DBSetProp('V_PLSIS.id_plsis', 'Field', 'KeyField', .T.)
>DBSetProp('V_PLSIS.id_plsis', 'Field', 'Updatable', .F.)
>DBSetProp('V_PLSIS.id_plsis', 'Field', 'UpdateName', 'dbo.plsis.id_plsis')
>DBSetProp('V_PLSIS.id_plsis', 'Field', 'DataType', "I")
>* Props for the V_PLSIS.npla field. -- ALEZ: This is a typical updateable field
>DBSetProp('V_PLSIS.npla', 'Field', 'KeyField', .F.)
>DBSetProp('V_PLSIS.npla', 'Field', 'Updatable', .T.)
>DBSetProp('V_PLSIS.npla', 'Field', 'UpdateName', 'PLSIS.NPLA')
>DBSetProp('V_PLSIS.npla', 'Field', 'DataType', "N(8,0)")
>
>
>Thanks,
>
>Alex
>
>
>>>I have a remote view to a table with only one record with row buffering. I do a GATHER MEMVAR and then REPLACE a few fields followed by TABLEUPDATE(.T.,.T.) buth the base table doesn't seem to be updated.
>>>
>>>I have set send updates =.T., sql where to primary key only (table has a primary key), and set update using sql update.
>>>
>>>What am I doing wrong?
>>>
>>>TIA,
>>>
>>>Alex
Previous
Reply
Map
View

Click here to load this message in the networking platform