Page 1 of 1
Using Unidac on Delphi 2010 with Sybase
Posted: Fri 05 Aug 2011 15:25
Hi Team
We are testing Unidac with Sybase 15. We need to pass the application name or program name to the database while establishing the connection.
In order to identify the Unidac Connection in Backedn how can we set the program name?
Please let me know if any further information is required.
Thanks
AS
Posted: Mon 08 Aug 2011 13:07
by AlexP
Hello,
At the moment UniDAC does not support the ApplicationName property for ASEUniProvider, we will add this property in the next UniDAC version.
Now you can define this property in the following way:
Code: Select all
procedure TForm1.UniConnection1AfterConnect(Sender: TObject);
begin
UniConnection1.ExecSQL('set clientapplname ''my_test_app''',[]);
end;
Posted: Mon 08 Aug 2011 14:22
by sasdua
AlexP wrote:Hello,
At the moment UniDAC does not support the ApplicationName property for ASEUniProvider, we will add this property in the next UniDAC version.
Now you can define this property in the following way:
Code: Select all
procedure TForm1.UniConnection1AfterConnect(Sender: TObject);
begin
UniConnection1.ExecSQL('set clientapplname ''my_test_app''',[]);
end;
Alex..we tried this not working..Still Connection is getting failed.
we are taking program_name from master..sysprocess there still it is comming has null..
Basically to stop users to login to back end we are regulating in chk login trigger there we are getting program name from sysprocess.
Posted: Tue 09 Aug 2011 11:41
by AlexP
Hello,
We've added the Applicationname property for ASEUniProvider, and the value of Applicationname that was set, will be displayed in the program_name field when executing the following query:
select * from sysprocesses
This property will be available in the next version of UniDAC that we plan to release in one or two weeks.
Posted: Tue 09 Aug 2011 13:03
by sasdua
thanks alex,is it possible to provide us beta version for our testing?
Posted: Tue 09 Aug 2011 13:34
by AlexP
Hello,
I can send a trial beta version with this feature, please specify your IDE and e-mail address.
Posted: Tue 09 Aug 2011 14:58
by sasdua
we will send mail with the deatails.
Posted: Thu 11 Aug 2011 11:19
by AlexP
Hello,
I have answered you by e-mail.
Posted: Mon 15 Aug 2011 08:47
by sasdua
Hi Alex,
We have installed the updated beta build but can you please let us know how can we set the application name using the driver as we are not able to find it under any property.
Regards
AS
Posted: Mon 15 Aug 2011 11:28
by AlexP
Hello,
The ApplicationName option is available in the UniConnection dialog on the Options tab (in design-time), just like all other SpecificOptions. In run-time you can set this option in the following way (before connecting to database):
Code: Select all
UniConnection1.SpecificOptions.Values['ApplicationName']:= 'My_Application';
Posted: Mon 15 Aug 2011 15:29
by sasdua
Hi Alex,
After setting the Application Name , its still not working.
You can check after setting the application name and then running the exe file created of the project from command prompt and checking whats the name coming in sysprocess. We are still getting it as null.
Also, we have encountered a space issue. In BDE if backend used to send a space, it used to trim that and then assign it to the Edit Box value But Unidac is not trimming the space while assigning.
Please help to check the issue and let us know if any solution is there. As if we need to trim each and every value it requires a lot of effort as we have many forms in our existing application.
Regards
AS
Posted: Wed 17 Aug 2011 15:03
by AlexP
Hello,
We have fixed the issue with ApplicationName; a new beta version will be avaialble tomorrow on our FTP-server.
Please, provide more details regarding the issues with spaces.