|
Hi,
I have put some free useful info on :
http://www.vkinfotek.com/data.html and
http://www.vkinfotek.com/object.html
If you need any additional specific info kindly email me or post here.
Regards
Bhar
|
|
|
|
|
We have a number of built scripts in VS2003 database projects and we utilize the Create Command File... command which creates a self-contained cmd file for running the scripts. We push this to our ops people for managing elevations of data/databases/code to production.
Visual Studio 2005 does not appear to have the Create Command File option in it anymore. But usually ( emphasize usually ) MS has an alternative somewhere. Is there an alternative or equivalent for creating the cmd file for a Database Project, and how do I use it???
We do not want our ops people to be selecting scripts and clicking Run since there is always the chance they can miss a script and impact a production deployment.
Thanks,
-- modified at 12:03 Tuesday 8th August, 2006
|
|
|
|
|
Hi,
I need to do a "select distinct emp_type from dtName" on a datatable in vb.net. in order to get a list of distinct employee types from a datatable in code. I can't work on DB side, caue i'm getting data from text file, and looping through every record is hideous!
Regards,
Tintin
|
|
|
|
|
Issue SQLcommand.Text = "select distinct emp_type from dtName" in your VB code.
Look where you want to go not where you don't want to crash.
Bikers Bible
|
|
|
|
|
i need to make table that have sounds i need to select sounds from this table to play in background automic in background when the form load and how i stop sound playing
ma_refay
|
|
|
|
|
You can use the TSQL SOUNDEX to evaluate if two string have the same sound.
<br />
SELECT SOUNDEX ('Smith'), SOUNDEX ('Smythe');<br />
<br />
----- ----- <br />
S530 S530 <br />
<br />
(1 row(s) affected)<br />
Look where you want to go not where you don't want to crash.
Bikers Bible
|
|
|
|
|
Sorry the above does not answer you question.
Store sounds as binary data blobs as you would with Images. Search for storing an image in a db and use similar code.
Look where you want to go not where you don't want to crash.
Bikers Bible
|
|
|
|
|
ma_refay wrote: how i stop sound playing
It would help if you gave us some clues, such as what programming language you're using...
Steve S
Developer for hire
|
|
|
|
|
How can i get the date of the day of the system
when i used this statement in the sql biulder of the dataenvironment of vb6
the sql analysis tell me that the error in the date
select * from emp
where hidate=Date();
i use it with () and without it and the problem still please
help
|
|
|
|
|
Your question is not clear. Do you want to get the system date?
if so then you can use getdate() for that purpose.
Best Regards,
Apurva Kaushal
|
|
|
|
|
LEARN_FOR_EVER wrote: help help help help h e l p
This is a useless subject line. Everyone posting a new thread here is looking for help in some form or another. Your subject line should be a brief description of the problem. e.g. "Date in SQL Server"
|
|
|
|
|
LEARN_FOR_EVER wrote: How can i get the date of the day of the system
GETDATE() returns the current date/time.
The rest of your question is not particularly clear. What do you want to do?
|
|
|
|
|
In stored procedure i used a query
"select Password from tblUser where username='User1' and password='Password'
the reselt is 'Password'
But at the backend the value of Password is 'password'
(that is small letters.
Since password validation needs case sensitive validation how am i supposed to used string comparator. Else is there any other option
ItsMe
|
|
|
|
|
If you are using SQL 2005, you can use HashBytes function to calculate a hashing value of password then compare two hashing values.
If you use SQL 2000, you can use BINARY_CHECKSUM function instead of.
|
|
|
|
|
I am using SQL 2000. i this function is quite complicated one. I just wanted to return true by comparing the below string
string1='User1'
string2='User1'
string3='user1' (here the character 'u' is small)
true when string1 and string2 are compared
false when string 3 is compared with either string1 or string2
ItsMe
|
|
|
|
|
select Password <br />
from tblUser <br />
where username='User1' and cast(password as binary)=cast('Password' as binary)
Run this little test in the SQL Query Analyzer:
declare @cTest1 varchar(10)
declare @cTest2 varchar(10)
select @cTest1 = 'test'
select @cTest2 = 'Test'
if (@cTest1 = @cTest2)
print 'They are equal as varchar'
else
print 'They are NOT equal as varchar'
if (cast(@cTest1 as binary) = cast(@cTest2 as binary))
print 'They are equal as binary'
else
print 'They are NOT equal as binary'
--EricDV Sig---------
Some problems are so complex that you have to be highly intelligent and well informed just to be undecided about them.
- Laurence J. Peters
|
|
|
|
|
Your biggest problem is that you are storing plaintext passwords in a dababase table. Any hacker who compromises a single user login will have access to every username and password in the system...
|
|
|
|
|
Hi,
How to cast the following value into datetime.
select CAST('17/01/2006 14:52:48' as DATETIME) --> gives out-of-range datetime value.
|
|
|
|
|
You are nearly there try this
<br />
select Convert(DATETIME, '17/01/2006 14:52:48')<br />
There are options that you can use as well; as described below.
example convertimg German date for today without time
<br />
select Convert(DATETIME, CAST(Day(getdate())as char(2)) + '.' + CAST(Month(getdate()) as char(2)) + '.' + CAST(Year(getdate())as char(4)) , 104)<br />
Without century (yy) (1) With century (yyyy) Standard Input/Output (3)
0 or 100 (1, 2) Default mon dd yyyy hh:miAM (or PM)
1 101 U.S. mm/dd/yyyy
2 102 ANSI yy.mm.dd
3 103 British/French dd/mm/yy
4 104 German dd.mm.yy
5 105 Italian dd-mm-yy
6 106 (1) - dd mon yy
7 107 (1) - Mon dd, yy
8 108 - hh:mm:ss -
9 or 109 (1, 2) Default + milliseconds mon dd yyyy hh:mi:ss:mmmAM (or PM)
10 110 USA mm-dd-yy
11 111 JAPAN yy/mm/dd
12 112 ISO yymmdd
13 or 113 (1, 2) Europe default + milliseconds dd mon yyyy hh:mm:ss:mmm(24h)
14 114 - hh:mi:ss:mmm(24h)
20 or 120 (2) ODBC canonical yyyy-mm-dd hh:mi:ss(24h)
21 or 121 (2) ODBC canonical (with milliseconds) yyyy-mm-dd hh:mi:ss.mmm(24h)
126 (4) ISO8601 yyyy-mm-ddThh:mm:ss.mmm (no spaces)
127(6) ISO8601 with time zone Z. yyyy-mm-ddThh:mm:ss.mmmZ (no spaces)
130 (1, 2) Hijri (5) dd mon yyyy hh:mi:ss:mmmAM
131 (2) Hijri (5) dd/mm/yy hh:mi:ss:mmmAM
-- modified at 7:05 Tuesday 8th August, 2006
Look where you want to go not where you don't want to crash.
Bikers Bible
|
|
|
|
|
For consistent date-time conversion behaviour, always use the ISO format: yyyyMMdd hh:mm:ss. All other formats are subject to the user's current locale setting.
Best practice when passing dates from an application into a query is to use parameterised queries with parameter objects. For example, in ADO.NET with SQL Server, use @name placeholders to mark the parameters, and SqlParameter objects to set the values of the parameters.
|
|
|
|
|
i need to select random row from table in my database to dir the contents of that row every time i dir different row how?!!!!!!!!!!!!!!!!
ma_refay
|
|
|
|
|
You can use newID() if your database is sqlserver for this purpose. It will give you random row from the table.
Best Regards,
Apurva Kaushal
|
|
|
|
|
NEWID() on its own won't give you a random row. It will only give you a new GUID.
|
|
|
|
|
But if we want to get the random row from a particular table then can't we get that with the help of newID().
Best Regards,
Apurva Kaushal
|
|
|
|
|
SELECT TOP 1 * FROM Table1 ORDER BY newid()
|
|
|
|