Mukit1234

sql server connection from django

Feb 27th, 2021 (edited)
196
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.75 KB | None | 0 0
  1. DATABASES = {
  2. 'default': {
  3. 'ENGINE': 'sql_server.pyodbc',
  4. 'NAME': 'smart_library_database', #created database name
  5. 'USER': '',
  6. 'PASSWORD': '',
  7. 'HOST': 'DESKTOP-D3U9MI7',
  8. 'PORT': '',
  9.  
  10. 'OPTIONS': {
  11. 'driver': 'SQL Server Native Client 11.0',
  12. },
  13. },
  14. }
  15.  
  16. ##########################################################
  17. DATABASES = {
  18. 'default': {
  19. 'ENGINE': 'sql_server.pyodbc',
  20. 'NAME': 'database_name', #created database name
  21. 'USER': 'username if create',
  22. 'PASSWORD': 'pass of user',
  23. 'HOST': 'HOST_name',
  24. 'PORT': '',
  25.  
  26. 'OPTIONS': {
  27. 'driver': 'SQL Server Native Client 11.0',
  28. },
  29. },
  30. }
Add Comment
Please, Sign In to add comment