Two Errors When Use ASE Provider to connect SYBASE
Two Errors When Use ASE Provider to connect SYBASE
I Download UniDAC 3.0.0.3 TralVersion and I Connect Sybase ASE through ASE Provider.
1.The following error occurred when Start transaction to save two tables
Catalog procedure 'sp_statistics' can not be run in a transaction
2.I Found that TUniStoreProc does not automatically generate the parameters named 'RETURN_VALUE'
thanks
My english is very poor
________
MARIJUANA HEMP
1.The following error occurred when Start transaction to save two tables
Catalog procedure 'sp_statistics' can not be run in a transaction
2.I Found that TUniStoreProc does not automatically generate the parameters named 'RETURN_VALUE'
thanks
My english is very poor
________
MARIJUANA HEMP
Last edited by cxg417 on Thu 10 Mar 2011 10:57, edited 1 time in total.
Catalog procedure 'sp_statistics' can not be run in a transaction
This error only occurs when running in the designtime?but use UniSQLMonitor able to monitor this Error in the runtime
________
Ford axod transmission history
This error only occurs when running in the designtime?but use UniSQLMonitor able to monitor this Error in the runtime
________
Ford axod transmission history
Last edited by cxg417 on Tue 15 Feb 2011 14:58, edited 1 time in total.
Code:
try
UniConnection1.StartTransaction;
UniQuery1.ApplyUpdates;
UniQuery2.ApplyUpdates; ->Catalog procedure 'sp_statistics' can not be run in a transaction
UniConnection1.Commit;
except
UniConnection1.Rollback;
UniQuery1.RestoreUpdates;
UniQuery2.RestoreUpdates;
raise;
end;
UniQuery1.CommitUpdates;
UniQuery2.CommitUpdates;
________
GLASS BUBBLERS
try
UniConnection1.StartTransaction;
UniQuery1.ApplyUpdates;
UniQuery2.ApplyUpdates; ->Catalog procedure 'sp_statistics' can not be run in a transaction
UniConnection1.Commit;
except
UniConnection1.Rollback;
UniQuery1.RestoreUpdates;
UniQuery2.RestoreUpdates;
raise;
end;
UniQuery1.CommitUpdates;
UniQuery2.CommitUpdates;
________
GLASS BUBBLERS
Last edited by cxg417 on Tue 15 Feb 2011 14:59, edited 1 time in total.
The recent new error
3.Call RefreshRecord, Key fields not found
4.
Select sName,sAddr,sPhone
From Table1
Union All
Select sXM,sDZ,''
From Table2 Where sXM=:P_XM
Auto-generated field name is incorrect ,Auto-generated field name are 'sName','sAddr','_1'
but if
Select sName,sAddr,sPhone
From Table1
Union All
Select sXM,sDZ,''
From Table2 --Where sXM=:P_XM
then Auto-generated field name is correct
5.
UniStoredProc1.ParamByName('P_Name').AsString='A';
UniStoredProc1.ParamByName('P_Adde').AsString='B';
UniStoredProc1.Open;
Parameter values are not bound when first execute.
but Add 'UniStoredProc1.Prepare' can bound Value when first execute.
6.
UniQuery1.SQl.Text:='Select * From Hans_BZ..Table1'
But UniQuery1.Connection is Hans_RS,then
UniQuery Is ReadOnly after open.
But UniQuery isn't readonly after open when connect to MS SQL 2000
________
New mexico medical marijuana
3.Call RefreshRecord, Key fields not found
4.
Select sName,sAddr,sPhone
From Table1
Union All
Select sXM,sDZ,''
From Table2 Where sXM=:P_XM
Auto-generated field name is incorrect ,Auto-generated field name are 'sName','sAddr','_1'
but if
Select sName,sAddr,sPhone
From Table1
Union All
Select sXM,sDZ,''
From Table2 --Where sXM=:P_XM
then Auto-generated field name is correct
5.
UniStoredProc1.ParamByName('P_Name').AsString='A';
UniStoredProc1.ParamByName('P_Adde').AsString='B';
UniStoredProc1.Open;
Parameter values are not bound when first execute.
but Add 'UniStoredProc1.Prepare' can bound Value when first execute.
6.
UniQuery1.SQl.Text:='Select * From Hans_BZ..Table1'
But UniQuery1.Connection is Hans_RS,then
UniQuery Is ReadOnly after open.
But UniQuery isn't readonly after open when connect to MS SQL 2000
________
New mexico medical marijuana
Last edited by cxg417 on Tue 15 Feb 2011 14:59, edited 5 times in total.
Sybase Version: ASE 12.5
Sybase ODBC Driver Version :syodase.dll 4.20.0.67
syodbas.dll 4.20.0.28
________
MEDICAL MARIJUANA CARD
Sybase ODBC Driver Version :syodase.dll 4.20.0.67
syodbas.dll 4.20.0.28
________
MEDICAL MARIJUANA CARD
Last edited by cxg417 on Tue 15 Feb 2011 14:59, edited 1 time in total.
1. We have fixed the problem with sp_statistics. The fix will be included in the next UniDAC build.
3. Your query should contain key fields to perform RefreshRecord. UniDAC adds values of key fields to the WHERE clause of the generated SELECT statement.
UniDAC cannot generate the correct SQL statement to refresh record in a query with UNION. You should set a value to the SQLRefresh property manually.
4. Field names are generated by the ASE server. They do not depend on UniDAC.
5. Maybe the correct stored procedure call is not yet generated when you assing values to the parameters. You can generate the stored procedure call at design-time by setting the stored procedure name in the TUniStoredProc editor. You can generate the stored procedure call at run-time using the PrepareSQL method. Try to call it before assigning the parameters values.
6. We have fixed this problem. The fix will be included in the next build of UniDAC.
3. Your query should contain key fields to perform RefreshRecord. UniDAC adds values of key fields to the WHERE clause of the generated SELECT statement.
UniDAC cannot generate the correct SQL statement to refresh record in a query with UNION. You should set a value to the SQLRefresh property manually.
4. Field names are generated by the ASE server. They do not depend on UniDAC.
5. Maybe the correct stored procedure call is not yet generated when you assing values to the parameters. You can generate the stored procedure call at design-time by setting the stored procedure name in the TUniStoredProc editor. You can generate the stored procedure call at run-time using the PrepareSQL method. Try to call it before assigning the parameters values.
6. We have fixed this problem. The fix will be included in the next build of UniDAC.
The Same Code,The Same Data Structure,There is no problem when connect MS SQL.
Please Concern this problem about call RefreshRecord.
________
Herbalaire
Please Concern this problem about call RefreshRecord.
________
Herbalaire
Last edited by cxg417 on Tue 15 Feb 2011 14:59, edited 1 time in total.
Probably there is the same problem:
Your query should contain key fields to perform RefreshRecord. UniDAC adds values of key fields to the WHERE clause of the generated SELECT statement.
UniDAC cannot generate the correct SQL statement to refresh record in a query with UNION. You should set a value to the SQLRefresh property manually.
Your query should contain key fields to perform RefreshRecord. UniDAC adds values of key fields to the WHERE clause of the generated SELECT statement.
UniDAC cannot generate the correct SQL statement to refresh record in a query with UNION. You should set a value to the SQLRefresh property manually.