Skip to main content

Posts

SQL Server Related Query

HOW TO MODIFY A COLUMN SIZE, IF WE HAVE MULTIPLE TABLES WITH DIFFERENT SUFFIX AND THAY ALL CONTAINS SAME COLUMN DEFINITIONS, I NEED TO MODIFY A SPECIFIC COLUMN'S SIZE OF ALL TABLES USING ONE SCRIPT.  AS LIKE MENTIONED BELOW: UPDATE  INFORMATION_SCHEMA.COLUMNS SET  CHARACTER_MAXIMUM_LENGTH = 100, CHARACTER_OCTET_LENGTH = 100 WHERE  TABLE_NAME LIKE '__MYTABLENAME' AND  COLUMN_NAME = 'MYCOLUMNNAME' AND  CHARACTER_MAXIMUM_LENGTH < 100 ---------------------------------------------------------------------------------------------------------------------------------- Using OPENROWSET to read large files into SQL Server Problem OPENROWSET is a T-SQL function that allows for reading data from many sources including using the SQL Server's BULK import capability. One of the useful features of the BULK provider is its ability to read individual files from the file system into SQL Server, such as load

How do I build a data warehouse?

The steps are as follows: Start with  understanding the process followed by the org. / company  for which you’re thinking of creating a Datawarehouse. Decide whether you need just a Database or a Data Federation or a complete Datawarehouse. Create a list of questions that you want to answer for the business  (that’ll help the business analyse data better & make better decisions using the data) through the datawarehouse. Find out the Data Source Points  & the kind of systems that the data resides in (For example, some data might be in files whereas some might be in Websites like twitter / facebook or databases such as Oracle / SQL Server / MySQL). Build a  Requirement Specification Document  & get it approved / reviewed by the Business Owners. Perform Data Modelling  to create a set of tables that you’d need in the Datawarehouse / Database. Also define the kind of dimensions (Slowly Changing, Degenerated, Conformed, Static, etc) & facts (Early Arriving) in case

How to turn on Windows 10's Find My Device feature

Microsoft’s  Windows 10 November update  brings with it a handy “find my device” feature, but it’s not just for tablets or phones. Any Windows 10 device can take advantage of the new feature, including desktops and laptops. Find My Device in Windows 10 doesn’t do a whole lot right now. There isn’t a way to have your tablet make a sound, lock itself, erase data, or anything like that. Instead, you can only find out where its last known general location was. Nevertheless, if you want to try this feature out here’s how to turn it on. Find My Device is buried under  Settings > Update & Security . To active this feature go to  Start > Update & Security > Find My Device . On this screen you’ll see a big  Change  button under the heading “Find My Device is off.” Turn this slider to  On  and you’re done. Once you click  Change  you’ll see a pop-up panel that says “Save my device’s location periodically.” Turn the slider to  On  and you’re done. Fin

Paytm founder, Vijay Shekhar Sharma’s incredible life story!

Paytm founder, Vijay Shekhar Sharma’s incredible life story! Vijay Shekhar Sharma owns a company whose current value is a little over $3 billion in the market in 2016, a dream dreamt when he was struggling to make ends meet with Rs 10 in pocket. "To the winners, who won because they didn't give up."-  Vijay Shekhar Sharma , founder of  Paytm . The man, who always wears a welcoming smile, stands true to every word he wrote during the most difficult times of his life. Vijay Shekhar Sharma owns a company whose current value is a little over $3 billion in the market in 2016, a dream dreamt when he was struggling to make ends meet with Rs 10 in pocket. But he tasted victory the hard way. Nothing came easy for him. The tears he hides behind the chirpy self that he puts up in front of the world could not be hidden for long while recollecting his journey. Interestingly, it was not talking about his failures that brought tears in his eyes; it was his hard earned victory

SQL Server database backup using a Batch file

SQL Server database backup using a Batch file Using the code Test.bat file SET curr_dir=%cd% cd /D E: IF EXIST TEST ( cd TEST mkdir ScriptTEST DataTEST cd ScriptTEST ) ELSE ( mkdir TEST cd TEST mkdir ScriptTEST DataTEST cd ScriptTEST ) SET SRC="%~dp0TestBackUpSQL.sql" SET DEST="TestBackUpSQL.sql" if not exist %DEST% copy /V %SRC% %DEST% sqlcmd -i "E:\TEST\ScriptTEST\TestBackUpSQL.sql" 2. In here you need to enter the database name and the back up set will be generated with name+date+time of server. TestBackUpSQL.sql file DECLARE @pathName NVARCHAR ( 512 ), @databaseName NVARCHAR ( 512 ) SET @databaseName = ' Enter Your DataBase Name Here' SET @pathName = ' E:\TEST\DataTEST\Enter Your DB Back Up Name Here_' + Convert ( varchar ( 8 ), GETDATE(), 112 ) + ' _' + Replace(( Convert ( varchar ( 8 ), GETDATE(), 108 )), ' :' , ' -' )+ ' .bak' BACKUP DATABASE @datab

Demonetisation Drives Innovation: Now A Website To Know If Nearby ATMs Have Cash Or Not

Demonetisation Drives Innovation: Now A Website To Know If Nearby ATMs Have Cash Or Not It has been a week since PM  Narendra Modi’s drive  on curbing black money in India was launched. While the money launderers are busy finding loopholes in the decision, the ‘ aam janta ’ is lingering for cash around ATMs in the city. With over 200 people standing in a queue at a time, they are not even sure whether the ATMs have enough money. But as they say, necessity is the mother of invention,  Manjunath Talwar and Abhijit Khasnis , have come up with an online portal,  CashNoCash  – to determine if a nearby bank or ATM has cash available or not. The website allows a user to search the nearest ATMs based on their current location. Also, one can create alerts to send notifications when the ATMs gets refilled by cash As Manjunath shared with Inc42, “CashNoCash.com is a free service that allows you to find nearest cash points, their availability and waiting times. The status data is crowd

India to see 10 per cent salary increase in 2017: Survey

India to see 10 per cent salary increase in 2017: Survey NEW DELHI: Salaries are expected to rise by 10 per cent in 2017, while star performers will attract much more as companies are discernibly prioritising such employees, says a report. According to the 2016 Salary Budget Planning (Q3) Report released by global advisory, broking and solutions company Willis Towers Watson, salaries in India are projected to rise 10 per cent in 2017, same as the actual increase in 2016. Once average inflation for India of 5.7 per cent is taken into account, the projected increase in real terms for 2017 will be 4.3 per cent, down by a fraction from 4.4 per cent in 2016. The report noted that with tighter salary increase budgets, organisations are prioritising their top performers. Similar to trends in the Asia Pacific region, the report indicates that in India, 38 per cent of the budget for salary increase goes to top performers. Another 34 per cent is shared by above-average performers whi