Dataset Editor is read-only / login credentials

Dataset Editor is read-only / login credentials

Postby belidzs » Wed 30 Sep 2009 12:28

hi,

as a new user I'm currently testing your solution and trying to integrate into my software. Unfortunately I faced two problems.

First: I have two tables in my dataset (untyped dataset is located on a form), and let's say I want to add more tables, or edit the commands for the tables. I can only use dataset manager -> configure dataset with wizard function, because right click on dataset -> edit.. brings me a window with my tables, but none of the editing options. Double-clicking on the table objects brings up the pgsqldatatableeditor, but everything is read-only.

Using the wizard is not a good idea, since it usually messes up my previously generated components (it creates an unnecessary new connection object)

I was thinking that this happens because the connection is currently open, but this isn't the case. I think the solution is pretty simple, I just couldn't figure it out myself.

Second question: what is the best practice to get the login credentials from the user and pass it to the connection object without elimination the design-time preview feature? My requirements are the following: I use my own credentials while designing, but get it from the user during the runtime.
Currently I close the design-time connection to the server immediately after the main form loads, then I pass the userid and the password from two textboxes to the connection object. This process generates unneeded login to the server, and it is also not safe, since my credentials can be sniffed. Turning off data visualization during design-time works as a solution, but it decreases the usability of this component.

Any ideas?

belidzs

screenshot:
Image
belidzs
 
Posts: 29
Joined: Wed 30 Sep 2009 12:07

Postby belidzs » Thu 01 Oct 2009 11:05

no one? please, the solution should be really easy! and I'm quite short on time..

probably the developers could answer the question: why can't I edit the tables after I added them using the wizard? Is this the normal way of functioning? Why are there controls for editing the tables if I can't use them? I'm pretty sure there is a switch or a setting which doesn't let me edit my dataset..

Thanks in advance!!
belidzs
 
Posts: 29
Joined: Wed 30 Sep 2009 12:07

Postby Shalex » Thu 01 Oct 2009 15:12

1. This is designed behaviour: if you want to add more tables or edit the commands for the existing tables using our tools, you need to regenerate your Typed Devart DataSet from scratch via Tools | PostgreSQL | DataSet Wizard. As an alternative, you can use Microsoft's DataSet Editor that allows adding tables by drag&drop-ing them from Server Explorer. But be aware, Microsoft's DataSet Editor doesn't parse the PostgreSQL's specific keywords like "limit" or schema names before the table name (e.g., "postgres"."public"."mytable") - in this case please regenerate your Typed Devart DataSet via DataSet Wizard.

As for creating an additional PgSqlConnection object during regenerating your DataSet via DataSet Wizard, I cannot reproduce the issue with the latest 4.55.44 build of dotConnect for PostgreSQL. Maybe, you mean the PgSqlConnection object that is created if you are picking up a connection from Server Explorer in DataSet Wizard. If yes, it is necessary for design time development, and you always can delete it and reassign a new PgSqlConnection object to your DataSet in run time of your application.

2. As I mentioned above, in design time you can create the PgSqlConnection object for your design time development and remove this PgSqlConnection object when it is unnecessary any longer. Then create and assign a new (created in run-time) PgSqlConnection object to your DataSet in run-time with the credentials in a connetion string provided by a user in textboxes.
Shalex
Devart Team
 
Posts: 7654
Joined: Thu 14 Aug 2008 12:44

Postby belidzs » Thu 01 Oct 2009 21:47

Thanks for the answer! About the second issue I totally agree with you, changing the dataset object's connection property before the connection is even opened to a secure, non-filled connection is a good idea.

About my first problem:
I'm okay about the regeneration of the dataset, but there's an annoying issue: when I try to edit my dataset using the wizard, it preselects the previously selected tables, but it 'forgets' to preserve the existing commands. This can be a huge backdraw when I have a big dataset (with 15-20 customized tables) and I want to use the wizard to add only one table to the dataset. As you mentioned, I have to rely on the wizard, since microsoft's drag and drop doesn't work optimal with postgresql.

I tried to change the commands manually, and I have already found that inside the designer code there's several PgSqlCommand objects initialized from the resources file, but changing the parameters, or even deleting the objects and the resources file doesn't make any difference in the operation, the project can still be compiled and the datasource can be reached. On the other hand, changing the update and insert commands directly in the regular dataset.xsd file does actually work. After this kind of change I get a warning from the wizard that the xsd file has been changed. So neither option is suifficent. I cannot add a table without ruining the others' command parameters, and I cannot even edit the commands, or the wizard gives me warning.

Shalex wrote:As for creating an additional PgSqlConnection object during regenerating your DataSet via DataSet Wizard, I cannot reproduce the issue with the latest 4.55.44 build of dotConnect for PostgreSQL. Maybe, you mean the PgSqlConnection object that is created if you are picking up a connection from Server Explorer in DataSet Wizard. If yes, it is necessary for design time development, and you always can delete it and reassign a new PgSqlConnection object to your DataSet in run time of your application.


You are right, it was my fault, but not it wasn't your guess. I've selected in the last step to add the visual objects to the form, so the wizard added it again, instead of replacing the old ones. When I deselect this option, it works okay, except that I have to reset every datalink object's datasource property to the dataset object, since the references will change from dataset11.tablename to form1.tablename.
belidzs
 
Posts: 29
Joined: Wed 30 Sep 2009 12:07

Postby Shalex » Fri 02 Oct 2009 16:06

I am using the 4.55.44 version of dotConnect for PostgreSQL. You can see your current version in the Tools | PostgreSQL | About menu of Visual Studio.

1. If I edit the existing DataSet via DataSet Wizard, the commands for the existing tables remain the same in the case if I don't make uncheck/check the existing tables in the Choose database objects window (uncheck and check again makes the commands to be regenerated).

2. The DataLink's DataSource property is not reset to Form1.TableName after regenerating DataSet in my case. It contains the old value.

3. Please don't modify your DataSet's *.xsd file manually to be able to work with your DataSet via DataSet Wizard again.
Shalex
Devart Team
 
Posts: 7654
Joined: Thu 14 Aug 2008 12:44

Postby belidzs » Fri 02 Oct 2009 18:13

I use the same version, I've double checked it.

I don't know why you can't reproduce the bugs, but I made a screencapture to prove that the faulty behavior actually exists.

http://gazd.info/dotconnect.avi

I hope we can figure out what's wrong!
belidzs
 
Posts: 29
Joined: Wed 30 Sep 2009 12:07

Postby belidzs » Mon 05 Oct 2009 14:24

please confirm that you've already started to find out what's wrong, because I need to decide which connectivity component will I use.

thanks!!
belidzs
 
Posts: 29
Joined: Wed 30 Sep 2009 12:07

Postby Shalex » Mon 05 Oct 2009 16:31

We have reproduced the behaviour described by you. We will investigate the issue and notify you about the results as soon as possible.
Shalex
Devart Team
 
Posts: 7654
Joined: Thu 14 Aug 2008 12:44

Postby belidzs » Sun 18 Oct 2009 11:26

Shalex wrote:We have reproduced the behaviour described by you. We will investigate the issue and notify you about the results as soon as possible.


it's been two weeks since you started to remove the bug. are you always that slow? the quality of your support isn't good at all. how do you expect me or any other possible customer to choose your product after this? damn..
belidzs
 
Posts: 29
Joined: Wed 30 Sep 2009 12:07

Postby Shalex » Tue 20 Oct 2009 11:56

We have fixed the problems with DataSet Wizard you have reported. We will send you a special build of dotConnect for PostgreSQL Trial with prolonged evaluation in 2 working days. Sorry for the delay.
Shalex
Devart Team
 
Posts: 7654
Joined: Thu 14 Aug 2008 12:44

Postby Shalex » Wed 21 Oct 2009 12:35

We have sent a download link to you by e-mail. The issue with DataLink will be fixed in the next builds.
Shalex
Devart Team
 
Posts: 7654
Joined: Thu 14 Aug 2008 12:44

Postby belidzs » Fri 23 Oct 2009 12:02

thank you, it works now. sometimes the datasource property changes back from dataset.tablename to form.tablename after using the wizard, but it's a minor bug, the rest are fine.
belidzs
 
Posts: 29
Joined: Wed 30 Sep 2009 12:07


Return to dotConnect for PostgreSQL