Cmdlet
New-OfficeAccess
Creates a native Access database without a provider, seed file or execution.
Syntax
Description
A path associates a live model without writing it; a content block atomically saves and closes it. The .mdb or .accdb extension selects the native file family.
Examples
Create a contacts table.
New-OfficeAccess -Path ./Contacts.accdb {
AccessTable Contacts { AccessColumn ContactId -Type AutoNumber; AccessColumn DisplayName -MaxLength 100 }
}Parameters
- -Force SwitchParameter
- Permit replacement of the associated destination.
- -Path String
- Optional live association; required for a completed content block.
- -Title String
- Database title.
- -WhatIf SwitchParameter
- Shows what would happen if the command runs.
- -Confirm SwitchParameter
- Prompts for confirmation before running the command.
- -AllowLoss SwitchParameter
- Accept reductions reported by native save.
- -Content ScriptBlock
- Authoring block completed before atomic publication.
- -PassThru SwitchParameter
- Return the saved FileInfo after the block completes.
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.