Wednesday, August 26, 2015

Excel FIND() function


IF Cell A1 = "cfuccillo003***********00300285569"

THEN Cell B2 = LEFT(A1, FIND("*",A1,1)-1)
 
 

Wednesday, August 5, 2015

ORACLE SQL BETWEEN two dates




SELECT * FROM ps_job
WHERE emplid = '00000000000'

  and action_dt between to_date('10/01/2014','mm-dd-yyyy') and to_date('06/30/2015','mm-dd-yyyy')


Monday, August 3, 2015

Display Column Properties

 SELECT b.name as 'schema_name', a.name, c.name as 'Column_Name', c.column_id, a.object_id, a.schema_id, a.parent_object_id, a.type, a.type_desc, a.create_date, a.modify_date
 FROM sys.columns c INNER JOIN (sys.objects a INNER JOIN sys.schemas b ON a.schema_id = b.schema_id) ON c.object_ID = a.object_id
 WHERE a.object_id IN (select object_ID from sys.columns where name like 'snapshot%')
  and b.name = 'dbo'
  and a.name = 'Flatfile_employee'
 ORDER BY a.[type], b.name, a.name