Danks, This guy is a SQL guru :notworthy:Quote:
Originally Posted by app_engine
Printable View
Danks, This guy is a SQL guru :notworthy:Quote:
Originally Posted by app_engine
Does any one know how to convert 'american date format' to 'british date' format in SQL server , without changing the coalltion??
ssabbaa I figured it out
here goes
SELECT CONVERT(VARCHAR(8), GETDATE(), 3) AS [DD/MM/YY]
linux experts, how to share internet btw 2 laptops running ubuntu, thru wifi?
Sorry sakala , I am no linux expert
friend of mine - suggested
Is it working ?Quote:
never envounted patterns like O', which is normally used to concatinate the strings in SQL. fpr normal names '%name%' should work.
aana
Unga avatar and signature :notworthy:
:ty:
Is any one familiar with the hardest thing in SQL code, known as Cursor? :banghead:
I will explain what I need to do..
I have table A , and Table B
Table A Table B
--------- ------------
First_name First_name
Last_name Last_name
Address1 Address1
Adreess2 Address2
What I want to do, see if the firstname and last_name in Table B exist in Table A, if so then I want to update Address1 and address2 in table A with a value. This is easy to do for couple of rows.
using
Update Table A
set address1='test',
address2='test2'
where first_name in (select first_name from table B
where first_name like 'Super')
but the problem is in Table B , i have 10,000 first_name with values in the address1.. I need update table A9Address1) with a value based on table B's contact name, hence you end up with 10,,000 different names, with 10,000 different address, if it was just one addreess it would have been very easy, I can use the above script.
any ideas any one ?
Checking whether the first name / last name exists in table B is no big deal (for set processing, use EXISTS clause)
OTOH, if you have 10000 NEW addresses to be updated to table A, you got to STORE those addresses in a table (unless the requirement is to directly update from a flat file, then you need a script). Obviously, this flat file or table with new address should have the name reference as otherwise how you're going to relate?