Showing posts with label SQL. Show all posts
Showing posts with label SQL. Show all posts

Tuesday, 25 June 2024

How to backup SQL Server database using command prompt ?

In this video, I have explained how to backup SQL Server database using Command Prompt. 

Steps:-

1) Open command prompt.

2) Type following command in command prompt.

3) Hit enter.

SqlCmd -S BOSS-PC\SQLEXPRESS -U sa -P 1234 -Q "Backup Database MyDb_18122018 Το Disk='D:\Backup\MyDb_18122018.bak"

SqlCmd - It will use SQL server command tool.

-S BOSS-PC\SQLEXPRESS(It's SQL server name.)

-U sa (SQL server username)

-P 1234(SQL server password.)

-Q "Backup Database- It's SQL command MyDb_18122018(My database name.)

To Disk='D:\Backup\MyDb_18122018.bak" (Destination for storing database backup.)

Watch my YouTube video on same topic:- 


Sunday, 23 June 2024

How to grant permissions to user account in SQL server ?

In this video, I have explained how to grant permissions to user account in SQL Server.

Steps:-

1) Login into SQL server.

2) Expand databases, select database and expand security.

3) Expand users, all the users of database will appear.

4) Select particular user, right click on it and go to properties. New window will         appear.

5) Select Securable page.

6) Click on search button and add objects of all types

7) Select object type whose access you want to give to user. (for e.g. table or           stored procedures) and click on ok.

8) Select permissions for that object and click on ok.

    Above steps are explained in detail in below video


Saturday, 22 June 2024

Different Types Of Clauses In SQL Server

 
In this video, I have explained different types of clauses in SQL server. This video is helpful for beginners to learn SQL Server concept. 

  • Clauses are used with queries to find out exact data from table.
  • Clauses can be used with all join types

    Following are types of Clauses:-
  1. Where Clause
  2. Order By Clause
  3. Group By Clause
  4. Having Clause