Solved

Adding password to Pradox table by SQL

Posted on 1998-11-04
10
140 Views
Last Modified: 2010-04-06
I create a new TTable by SQL like:

SQL.Add ( 'CREATE TABLE "temp.db" (Field1 Char(10)');
now I want to add a password to this Paradox-Table in runtime.

To open it later, I use TSession.AddPassword, that's working just fine.
0
Comment
Question by:Oli2
  • 4
  • 3
  • 3
10 Comments
 
LVL 8

Expert Comment

by:ZifNab
ID: 1345581
Oli2, you don't create a new table by a query. A query just combines tables to a new 'fictive' one. But the query will not exist anymore if you close your program.
0
 
LVL 1

Author Comment

by:Oli2
ID: 1345582
Zif, thanks, but that doesn't help me at all.
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1345583
Oli2,

sorry but I don't understand your q'n.

you want to give your query a password protection?

Zif.
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1345584
If you use a TDatabase and you start your query from there, then you can fill in the password and username into the params property or do it with code:

WITH db DO  BEGIN
  LoginPrompt := False;
  Params.Values['USER NAME'] := 'sa';
  Params.Values['PASSWORD'] := '<pwd>';
  Open;
END;

Regards, Zif.

Is this what you need?
0
 
LVL 4

Expert Comment

by:dwwang
ID: 1345585
I understand Oli2's question, he wants to add passwords to protect his table(that's a special function on Paradox), and he wants to do this in programm.

But I think it's impossible, table/query/any dataaccess controls only provide data ACCESSING methods. Adding passwords is not, it can only be done in Database Desktop from Inprise.
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 1

Author Comment

by:Oli2
ID: 1345586
dwwang: you got my problem just exactly right !!
Here's what I think: If the Database Desktop from Inprise can do it, then there's got to be a way. ( isn't the Database Desktop from Inprise written in Delphi ? )
Oli2
0
 
LVL 4

Expert Comment

by:dwwang
ID: 1345587
Yes, but it depends on the structure of Paradox table, which Inprise(Borland) has never published, and even changing from version to version. Public knowledge of Paradox structure are now limited to Version 4.

I even know a site tell people how to crack the password of a table, but not vice versa.

Good luck.
0
 
LVL 8

Accepted Solution

by:
ZifNab earned 50 total points
ID: 1345588
Hi all,

 Why then don't you use the BDE directly? With dbiDoRestructure you can change tables.

I just searched a little bit on the subject and found out this :

look for these examples at :

Example 4: Add a master password to a Paradox table.
Example 5: Add an auxilary password to a Paradox table.
Example 6: Remove a master password from a Paradox table.
Example 7: Remove an auxilary password from a Paradox table.

http://www.inprise.com/devsupport/bde/bdeapiex/dbidorestructure.html

Regards, Zif.
0
 
LVL 4

Expert Comment

by:dwwang
ID: 1345589
Well, that's why Zif is the NO.1 here.

Now I feel myself too lazy  :-(

Thank you for the information, Zif.

Regards,
Wang
0
 
LVL 1

Author Comment

by:Oli2
ID: 1345590
thanks, ZifNab, I found there what I was looking for. I knew I have to do it by calling DBI stuff, but didn't know exactly how. The idea to look for an answer at www.inprise.com didn't come to my mind. Guess that makes the 50 Pts. worth it.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Sending Gmail through Delphi 3 91
Syntax Check Delphi Seattle IOS app without MAC ? 1 92
Simple Delphi Question 9 83
Comparing dates in Delphi. Greater than/ Less than 3 119
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now