at the moment I am doing:-
cd into each directory then
ls -ltr | grep " 2003 " > free.sh
ls -ltr | grep " 2004 " >> free.sh
etc
then doing the same for files which have months e.g.
ls -ltr | grep " Mar " >> free.sh
etc..
Then using awk - print getting the file name
using vi editor to place an...
Can anyone help please. I am trying to find files that are older than 90days in a directory and subsequent directory within. Anyone have any ideas how I might do this.
I think I may need to use the find command along with touching a file which current date in some kind of ls loop.
e.g...
Hi,
Thanks I have now managed to resolve this query. asc did work but I carried out a select followed by a sub select retrieving the MAX(personid) where lead = 0 - I then just picked that one from the list as it didn't matter which one I choose.
This is on SQLSERVER 2005 by the way.
Cheers
thanks for your help. I did them as two separate statements, but I will try and see if I can convert to your suggestions to reduce my code.
However I do have another question. I want to from a list of only retrieve the first two where there are many names to one Ref as below but would always...
Hi, Can anyone help with my query. I have the following case statement. I am trying to set one variable, once I have set the first variable with the value, based on this value I want to set another variable. A kind of nested case I guess but not sure!!
My query is:-
SELECT placeref, mgearea...
Hi - I've managed to do with the following:-
;WITH redflags(field1,field2) AS
(SELECT A.field1,
(SELECT B.field2 + ' - ' FROM #tmpflag B WHERE B.field1=A.field2 FOR XML PATH(''))
'Concatinated'
FROM #tmpflag A
GROUP BY A.field1
)
SELECT field1 'PLACE REF',LEFT(field2,LEN(field2)-1) 'REDFLAG'...
Hi Ryan,
Thanks for your quick response, but I am new to SQLSERVER 2005 and so not sure what you have done, but I can not possibly insert every value, the values are only held in a tmp table. To carry out an insert for every value I would need to hard code all the values for this unless I am...
I am using SQLSERVER 2005
Can anyone help to concatenate character values into one string where the Field1 has the same reference. Output from one of my tmp tables looks like this:-
Field1 field2
32061350 Gas Works
32071470 Boiler Room
36010060 Boiler Room
36031890 Support Agency...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.