Showing posts with label appear. Show all posts
Showing posts with label appear. Show all posts

Friday, March 30, 2012

How to format Field ?

HOw to set the field (Password) in sqlServer database to '*' .
For example :
I key in VB : 123
In SqlServer database should appear : ***
Yoir help will be appreaciated.
daniel.Daniel:
I don't think that this is a datawarehouse question, but nevertheless
In SQLServer it is not possible to individually mask (as in MS Access) or
encrypt a single column as such. You would have to write your own encryption
routine or get one (many are available).
I usually encrypt my passwords and also set proper user rights restrictions
in order to protect the passwords.
Balaji Vasudevan
"Daniel" <anonymous@.discussions.microsoft.com> wrote in message
news:E11D06A0-335A-481D-8A7B-7D32FE0F6E9D@.microsoft.com...
quote:

> HOw to set the field (Password) in sqlServer database to '*' .
> For example :
> I key in VB : 123
> In SqlServer database should appear : ***
> Yoir help will be appreaciated.
> daniel.

Wednesday, March 28, 2012

How to format a number field..

i have a number field but i can't seem to make a format out of it..
e.g.
when i have a value of 1, i want to make it appear in the report like 0000000001 or if i have 11, i want to make it appear like 0000000011
Hope someone could help!
thanksHello DarylAps,

You have two options :

1. While selecting records from table itself use replicate function (assuming you are using mssql server ) and return formatted number.
or
else

2. Create a formula as shown below : assuming your numeric field name is col :

ReplicateString('0', 10-Length ({SqlCommand.col} ) )+{SqlCommand.col}

Here are the details of ReplicateString functions of CR :

ReplicateString (str, #copies)
Basic and Crystal syntax.

Arguments
str is the text string to be replicated.
#copies is a whole number indicating the number of times str is to be replicated.

I hope you like this resolution.

Thanks
Dilemma