Search code examples
powershellnosdbnosql

Connect NosDB standalone database from powershell


Using powershell scripts how can I connect to the standalone NosDB database?

Connect-DatabaseCluster apparently connects to the cluster by default.


Solution

  • If you do

     get-help Connect-DatabaseCluster -full
    

    You'll get a list of all the possible values. The important one for you is

    -StandAlone [<SwitchParameter>]
    Specifies if the database is standalone.
    
    Required?                    false
    Position?                    named
    Default value
    Accept pipeline input?       true (ByValue, ByPropertyName)
    Accept wildcard characters?  false
    

    So your command changes to

    Connect-DatabaseCluster -StandAlone
    

    Its written in the documentation